GET
/
api
/
v1
/
tokens
{
  "nodes": [
    {
      "id": "token_abc123",
      "name": "CI/CD Pipeline Token",
      "permissions": ["read", "list"],
      "created_at": "2025-09-29T10:00:00Z",
      "expires_at": "2025-12-31T23:59:59Z",
      "last_used": "2025-09-29T15:30:00Z"
    }
  ],
  "pageInfo": {
    "hasNextPage": false,
    "endCursor": null
  }
}
Retrieves a paginated list of all tokens associated with the authenticated project.
Requires User token authentication
Required permissions: list on token resource

Query Parameters

first
integer
Number of items to return (forward pagination)
after
string
Cursor for forward pagination
last
integer
Number of items to return (backward pagination)
before
string
Cursor for backward pagination

Example

curl -H "Authorization: Bearer $USER_TOKEN" \
  "https://api.garnet.ai/v1/tokens?first=20"

Response

nodes
array
List of token objects (token values are not included for security)
pageInfo
object
Pagination information
{
  "nodes": [
    {
      "id": "token_abc123",
      "name": "CI/CD Pipeline Token",
      "permissions": ["read", "list"],
      "created_at": "2025-09-29T10:00:00Z",
      "expires_at": "2025-12-31T23:59:59Z",
      "last_used": "2025-09-29T15:30:00Z"
    }
  ],
  "pageInfo": {
    "hasNextPage": false,
    "endCursor": null
  }
}