Reporter icon

Reporter

Interact with Reporter API

Actions120

API Token → Create an API token

AI-generated

Summary

Creates an API token with the specified name and abilities, optionally setting its expiration, scope, client or assessment restrictions, and owner. The token is created for the authenticated user unless an eligible admin specifies another user.

Inputs

  • Name (required) — Token name, up to 191 characters.
  • Abilities (required) — One or more ability strings, each a subset of the creating token’s abilities; cannot include api_token:read or api_token:write.
  • Expires at — Optional ISO 8601 expiration date after now and no later than the creating token’s expiration.
  • Scope — Optional scope: 0 grants access to all clients and assessments available to the user; 1 restricts access to the selected clients; 2 restricts access to the selected assessments.
  • Clients — Optional client IDs for a client-restricted scope.
  • Assessments — Optional assessment IDs for an assessment-restricted scope.
  • User id — Optional existing user ID. Creates the token for that user; only admins can create tokens for other users.

Output shape

A single API response record for the created token.

The source sends the name and abilities in the request body and adds populated optional fields from Additional Fields. Exact response fields and whether the token secret is included are not shown.

Links

Discussion