Generate Access Token
Generate Access Token
Create a new short-lived access token by validating your client_id
and client_secret
.
The access_token
is to be forwarded with all subsequent requests as
Authorization: Bearer {access_token}
HTTP header.
When the token expires you must regenerate your access_token
.
The client_id
and client_secret
can be supplied as POST body parameters, or as a HTTP basic auth header.
URL
Request
Response
client_id
: string
Your application's MoneyKit client ID.
example: live_5c739a369515e10fc9e0
client_secret
: string
Your application's MoneyKit client secret.
grant_type
: string
Token grant type. Only client_credentials
supported.
scope
: string
Actions to be allowed for this token, given as one or more strings separated by spaces. If omitted, all actions allowed for your application will be granted to this token.
Responses
201
Generated access token.
access_token
: string
Short-lived access token.
example: 52ea3d1b...4f9a53fffb67
token_type
: string
Always "bearer".
example: bearer
expires_in
: integer
How long until access_token
expires in seconds.
example: 3600
400
Invalid grant_type
error_code
: string
api_error.auth.unauthorized
default: "api_error.auth.unauthorized"
Allowed values:
"api_error.auth.unauthorized"
error_message
: string
Error message
example: Accounts access not permitted
documentation_url
: string
401
Unauthorized
error_code
: string
api_error.auth.unauthorized
default: "api_error.auth.unauthorized"
Allowed values:
"api_error.auth.unauthorized"
error_message
: string
Error message
example: Accounts access not permitted
documentation_url
: string