Create an аccess token tо API: Auth.CreateApiToken
The method and parameters
The method is used to create an access token to JSON-RPC API. Every API method, except for this method, must include a request authorization token either in the Token
parameter or in the Authorization
request header.
This method must be called from a local address (localhost
) - otherwise, an error will always be returned.
string Auth.CreateApiToken
(unsigned ttl
)
Parameters
unsigned ttl
REQUIRED – the duration of the generated token, in seconds. If 0
is specified, the duration is unlimited.
POST /api/ |
200 |
An OAuth token
JSON
|
400 |
JSON-RPC error
JSON
|
500 |