Project Access Tokens

Per-day request counts for one access token

Changed on

Returns a zero-filled daily series of request counts for a single token, oldest first, so the response always has exactly days entries.

days defaults to 30 and is capped at 60, matching how long per-day counts are retained.

A project access token may read only its own usage; asking for another token's returns 403. A platform token may read any token in the project.

get/projects/{id}/access-tokens/{tokenId}/usage

Request

  • Base URL
    https://api.volcano.dev
  • Auth
    • HTTP bearer
    • or HTTP bearer

Path parameters

id, string uuid required

Project ID

tokenId, string uuid required

Project access token ID

Query parameters

days, integer

Number of trailing days to return (1-60, default 30).

Response

Successful response

ProjectAccessTokenUsage required

Zero-filled daily request counts for a single token, oldest first. Every day in the window is present, so a gap reads as zero rather than missing.

Counts every request the token authenticated, including ones then refused — a read-only token attempting a write, or a token presented on another project's route. That is deliberate: after a leak, the probing is the part you want to see, and a counter that hid it would make a token look idle while it was being tried.

token_id, string uuid required
name, string required
token_prefix, string required

The token's display prefix, which identifies the credential when its name does not. Revoking frees a name, so a project that rotated ci-deploy has two entries here both called ci-deploy. Not usable as a credential.

days, integer required

Number of daily entries returned, always equal to the requested window.

daily, ProjectAccessTokenUsageDailyEntry[] required
total_requests, integer required

Changes