PersonalAccessToken
Snyk API reference for the PersonalAccessToken endpoints, including request parameters and response schemas
List personal access tokens
API key value must be prefixed with "Token ".
Return the page of results immediately before this cursor
v1.eyJpZCI6IjExMDAifQo=Number of results to return per page
10Example: 10Return the page of results immediately after this cursor
v1.eyJpZCI6IjEwMDAifQo=Requested API version
2026-03-25Pattern: ^(wip|work-in-progress|experimental|beta|((([0-9]{4})-([0-1][0-9]))-((3[01])|(0[1-9])|([12][0-9]))(~(wip|work-in-progress|experimental|beta))?))$Return the personal access tokens associated with the calling principal
Bad Request: A parameter provided as a part of the request was invalid.
Unauthorized: the request requires an authentication token.
Forbidden: the request requires an authentication token with more or different permissions.
Not Found: The resource being operated on could not be found.
Internal Server Error: An error was encountered while attempting to process the request.
GET /rest/self/personal_access_tokens?version=2026-03-25 HTTP/1.1
Host: api.snyk.io
Authorization: YOUR_API_KEY
Accept: */*
{
"data": [
{
"attributes": {
"created_at": "2021-07-01T00:00:00Z",
"expires_at": "2021-07-01T00:00:00Z",
"label": "my token",
"tenant_id": "550e8400-e29b-41d4-a716-446655440000"
},
"id": "01HSBP9DKDK39KWZQV84PSPRHY",
"type": "personal_access_token"
}
],
"jsonapi": {
"version": "1.0"
},
"links": {
"first": "https://example.com/api/resource?ending_before=v1.eyJpZCI6IjExIn0K",
"last": "https://example.com/api/resource?starting_after=v1.eyJpZCI6IjMwIn0K",
"next": "https://example.com/api/resource?starting_after=v1.eyJpZCI6IjEwIn0K"
},
"meta": {
"max_active_tokens": 1,
"max_expiry_days": 1
}
}Delete a personal access token
API key value must be prefixed with "Token ".
The personal access token id
01HSBP9DKDK39KWZQV84PSPRHYRequested API version
2026-03-25Pattern: ^(wip|work-in-progress|experimental|beta|((([0-9]{4})-([0-1][0-9]))-((3[01])|(0[1-9])|([12][0-9]))(~(wip|work-in-progress|experimental|beta))?))$The operation completed successfully with no content
Bad Request: A parameter provided as a part of the request was invalid.
Unauthorized: the request requires an authentication token.
Forbidden: the request requires an authentication token with more or different permissions.
Not Found: The resource being operated on could not be found.
Conflict: The requested operation conflicts with the current state of the resource in some way.
Internal Server Error: An error was encountered while attempting to process the request.
DELETE /rest/self/personal_access_tokens/{personal_access_token_id}?version=2026-03-25 HTTP/1.1
Host: api.snyk.io
Authorization: YOUR_API_KEY
Accept: */*
No content
Last updated
Was this helpful?

