Scoped Access Tokens

Create a scoped access token

Changed on

Creates an opaque bearer token that expires exactly one hour after issuance and is restricted to the requested repositories.

post/api/ee/scoped_access_token

Request

  • The document declares no server URL.
  • Auth
    • HTTP bearer
    • or API key in header X-Sourcebot-Api-Key

Request body

repoIdsinteger[] required

Repository IDs to bind to the token. Every ID must identify a repository accessible to the API-key owner.

Response

Scoped access token created. The opaque token value is returned only in this response.

idstring required

Identifier used to revoke the token.

tokenstring required

Opaque bearer token. This value is returned only when the token is created.

createdAtstring date-time required
expiresAtstring date-time required
repoIdsinteger[] required

Changes