AAtlas CRM

Authentication

Create an access token

Generate a short-lived Public API access token for a server-to-server API client.

Overview

Use this endpoint to exchange an API client ID and client secret for a Public API access token. Send the client credentials with HTTP Basic authentication and request only the scopes needed by the integration. Access tokens expire after 30 minutes. It uses http basic client authentication.

POST/oauth2/token

cURL

POST
bash
curl --request POST \  --url 'https://crm.notifyy.io/oauth2/token' \  --header 'Authorization: Basic base64(client_id:client_secret)' \  --header 'Content-Type: application/x-www-form-urlencoded' \  --data 'grant_type=client_credentials&scope=templates%3Awrite'

Authorization

HTTP Basic client authentication

Sample Request Body

bash
grant_type=client_credentials&scope=templates%3Awrite

Sample Response

json
{  "access_token": "eyJraWQiOiJub3RpZnl5LXB1YmxpYy1hcGkta2V5LTEiLCJhbGciOiJSUzI1NiJ9...",  "token_type": "Bearer",  "expires_in": 1800,  "scope": "templates:write"}

Status Codes

CodeDescription
200Access token was issued.
400Grant type, scope, or form data is invalid.
401Client authentication failed.

Headers

AuthorizationstringRequired

HTTP Basic credentials using base64(client_id:client_secret).

Example: Basic base64(client_id:client_secret)

Content-TypestringRequired

Form URL encoded request body.

Example: application/x-www-form-urlencoded

Request body

grant_typestringRequired

OAuth grant type. Notifyy Public API supports client_credentials for this endpoint.

Example: client_credentials

scopestringRequired

Space-delimited scopes requested for the access token. The API client must already be allowed to use each requested scope.

Example: templates:write

Response fields

access_tokenstring

Access token used in the Authorization header for Public API requests.

token_typestring

Token type returned by the OAuth server.

Example: Bearer

expires_ininteger

Token lifetime in seconds. Default is 1800 seconds, which is 30 minutes.

Example: 1800

scopestring

Scopes granted to the issued access token.

Example: templates:write