latestOpenAPI 3.0.3GitGuardian2026-08-201871515.0 MB

511b067cdcb1

API Tokens

Retrieve details of an API token.

get/v1/api_tokens/{token_id}

Path parameters

token_idstring required
Example:5ddaad0c-5a0c-4674-beb5-1cd198d13360

Id of the token.

Response

Current token details

idstring

Id of API token

namestring

Name of API token

workspace_idinteger

Workspace id

type'personal_access_token' | 'service_account'
status'active' | 'expired' | 'revoked'
created_atstring date-time

Creation date of the API token

last_used_atstring date-time nullable

Last usage of the API token

expire_atstring date-time nullable

Expiration date of the API token

revoked_atstring date-time nullable

Revocation date of the API token

member_idinteger nullable

Member id

creator_idinteger nullable

Creator id

scopesstring[]

List of scopes

Example response

{
  "id": "5ddaad0c-5a0c-4674-beb5-1cd198d13360",
  "name": "myTokenName",
  "workspace_id": 42,
  "type": "personal_access_token",
  "status": "revoked",
  "created_at": "2023-05-20T12:40:55.662949Z",
  "last_used_at": "2023-05-24T12:40:55.662949Z",
  "revoked_at": "2023-05-27T12:40:55.662949Z",
  "member_id": 22015,
  "creator_id": 22015,
  "scopes": [
    "incidents:read",
    "scan"
  ]
}