v13

latestOpenAPI 3.0.0zlibraw.githubusercontent.com2026-08-01265409652.5 KB
users

Get all API keys for a user

Gets all API keys for a user. Only the calling user or admin can retrieve api-keys. Access policy: authenticated

get/users/{id}/tokens

Path parameters

idinteger required

User identifier

Response

Success

dateCreatedinteger

Unix timestamp (UTC) when the API key was created

descriptionstring
digeststring

Digest represents SHA256 hash of the raw API key

idinteger
lastUsedinteger

Unix timestamp (UTC) when the API key was last used

prefixstring

API key identifier (7 char prefix)

userIdinteger

Example response

[
  {
    "description": "portainer-api-key",
    "id": 1,
    "userId": 1
  }
]