API access token scopes
Each API access token can be restricted to one or more scopes. The selected scopes determine which actions can be performed when using that token. Select only the scopes required by your integration.
A token can contain multiple scopes if the integration requires access to several parts of the API.
For example, an integration that needs to retrieve available assessments and invite candidates to them would require both Read Assessments and Invite Candidates.
We recommend following the principle of least privilege and granting only the scopes that are necessary for the integration to work.
How to create an API access token
To generate a new API access token:- Sign in to your Marty account.
- Open the Create API Access Token page:
https://app.marty.hr/settings/api-access-tokens/create - Enter a descriptive name in the Label field.
- Under Select scopes, choose the permissions required by your integration.
- Review the selected scopes.
- Click Create access token.
- Copy the generated token and store it securely.
ATS integrationReporting serviceProduction integrationDevelopment APIInternal automation
Using the API access token
After creating the token, use it to authenticate requests to the Marty API according to the authentication format described for the relevant API endpoints. The permissions available to each request are determined by the scopes assigned to the token. If an API request requires a scope that the token does not have, the request will not be authorized to perform that action. For this reason, make sure that the token includes all scopes required by your integration while avoiding unnecessary permissions.Keep your API access token secure
API access tokens provide access to Marty data and functionality according to their assigned scopes. They should be treated like passwords or other application secrets. Do not:- Commit API access tokens to source-code repositories.
- Include them directly in client-side applications.
- Share them in public documentation, tickets, or chat messages.
- Store them in plain text when a secure alternative is available.
- Expose them in application logs.
Recommended token management
For better security and easier administration, create separate API access tokens for different applications, integrations, and environments. For example, production and development environments should generally use different tokens. Using separate tokens makes it possible to:- Grant different scopes to different integrations.
- Identify which integration is using a particular token.
- Revoke one integration’s access without affecting others.
- Reduce the impact of an accidentally exposed token.
.png?fit=max&auto=format&n=sUS7VTlhqOQx_KUw&q=85&s=ad09d04a9a1eb5c6546c4e843a893b2b)
