Skip to content
This repository has been archived by the owner on Sep 3, 2021. It is now read-only.

Latest commit

 

History

History
196 lines (120 loc) · 5.06 KB

AccessTokensApi.md

File metadata and controls

196 lines (120 loc) · 5.06 KB

AccessTokensApi

All URIs are relative to /api/v2

Method HTTP request Description
deleteToken DELETE /tokens/{tokenId} Delete an access token by ID.
getToken GET /tokens/{tokenId} Get a single access token by ID.
getTokens GET /tokens Returns a list of tokens in the account.
patchToken PATCH /tokens/{tokenId} Modify an access token by ID.
postToken POST /tokens Create a new token.
resetToken POST /tokens/{tokenId}/reset Reset an access token's secret key with an optional expiry time for the old key.

deleteToken

Delete an access token by ID.

Example

 deleteToken tokenId=value

Parameters

Name Type Description Notes
tokenId string The access token ID.

Return type

(empty response body)

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getToken

Get a single access token by ID.

Example

 getToken tokenId=value

Parameters

Name Type Description Notes
tokenId string The access token ID.

Return type

Token

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getTokens

Returns a list of tokens in the account.

Example

 getTokens  showAll=value

Parameters

Name Type Description Notes
showAll boolean If set to true, and the authentication access token has the "Admin" role, personal access tokens for all members will be retrieved. [optional]

Return type

Tokens

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

patchToken

Modify an access token by ID.

Example

 patchToken tokenId=value

Parameters

Name Type Description Notes
tokenId string The access token ID.
patchDelta array[PatchOperation] Requires a JSON Patch representation of the desired changes to the project. 'http://jsonpatch.com/'

Return type

Token

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

postToken

Create a new token.

Example

 postToken

Parameters

Name Type Description Notes
tokenBody TokenBody Create a new access token.

Return type

Token

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

resetToken

Reset an access token's secret key with an optional expiry time for the old key.

Example

 resetToken tokenId=value  expiry=value

Parameters

Name Type Description Notes
tokenId string The access token ID.
expiry integer An expiration time for the old token key, expressed as a Unix epoch time in milliseconds. By default, the token will expire immediately. [optional]

Return type

Token

Authorization

Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]