Skip to content

API Authentication

Every call to Flanks APIs must be authenticated.

Authenticate Requests

You will need an access_token to call the Flanks API. To get a new access_token, you will need to call the Token Endpoint.

Get access_token

https://api.flanks.io/v0/token

Generate a new access_token to use in your API calls.

Headers

Header

Value

Content-Type

application/json

Body (JSON encoded)

Parameter

Type

Value

client_id *

String

CLIENT_ID of your Application

client_secret *

String

CLIENT_SECRET of your Application

grant_type *

String

Must be client_credentials

(*) Mandatory Parameters

Responses

200 OK
{
    "access_token": "<ACCESS TOKEN>",
    "expires_in": 3600,
    "token_type": "Bearer",
    "scope": "<LIST OF SCOPES>",
}
403 Access Denied
{
    "error": "access_denied"
}

Either the CLIENT_ID, the CLIENT_SECRET or the grant_type are invalid.

500 Internal Error

{
    "error": "Internal Error"
}
The server encountered an unexpected condition that prevented it from fulfilling the request.