The OffBlocks API utilises the Bearer authentication mechanism. Before accessing any of the authenticated endpoints, you must obtain an authentication token by providing your client credentials: apiKey and apiSecret. This process is automatically handled for all requests in our Postman collection.
Retrieving an Authentication Token
The endpoint mentioned above returns a JSON Web Token (JWT) token. You must include this token as a Bearer token in the header of all requests that require authentication. Additionally, the response includes an expiration timestamp for the token, measured in seconds.
Initial Authentication
post
/auth/token
Retrieve authentication token using API credentials
Body
apiKeystring Β· uuidRequired
Unique API key used to identify your API integration. Note this can be different for live and sandbox environments
Example: d04953b7-5878-4fd0-8970-0a5f77fbce59
apiSecretstringRequired
API secret
Example: 64ec977db2e585887c80ed62fe9997994aed8093
Responses
200
Successful operation
application/json
tokenstringRequired
JWT token that can be used for further requests to authenticated endpoints