Command for displaying various information on terminal.
% crystal build runner.cr
% ./runner get --immediately --config ./config.json
% ./runner puts
Gmail requires authentication by code.
To do the authentication, execute with the with-auth
option.
% ./runner get --immediately --with-auth --config ./config.json
- service
- Service name. "gmail" or "twitter".
- key
- Unique key.
- expires_in
- The expiration date of the data. Not used when
immediately
option is specified.
- The expiration date of the data. Not used when
- path
- Absolute path of the directory containing client_secret file.
{
"order": [
{
"service": "gmail",
"key": "gmail",
"expires_in": 600,
"path": "/your/env/dir/gmail/"
},
{
"service": "twitter",
"key": "twitter",
"expires_in": 600,
"path": "/your/env/dir/twitter/"
},
{
"service": "twitter",
"key": "<unique key>",
"arg": "u:<Twitter screen name>",
"expires_in": 600,
"path": "/your/env/dir/twitter/"
},
{
"service": "twitter",
"key": "<unique key>",
"arg": "s:<Search word of Twitter>",
"expires_in": 600,
"path": "/your/env/dir/twitter/"
}
]
}
The client_secret
file is required for operation.
Please download the client_secret file from the authentication information of Google Cloud Platform console.
{
"consumer_key": "your consumer key",
"consumer_secret": "your consumer secret",
"token": "your token",
"token_secret": "your token secret"
}