Revoke an API token
DELETE
/api/v2/organizations/{organization}/tokens/{token_id}
const url = 'https://dashboard.quantcdn.io/api/v2/organizations/test-org/tokens/42';const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://dashboard.quantcdn.io/api/v2/organizations/test-org/tokens/42 \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”organization
required
string
Organization identifier
Example
test-orgtoken_id
required
integer
Token ID to revoke
Example
42Responses
Section titled “Responses”Token revoked successfully.
Media typeapplication/json
object
message
string
Example
{ "message": "Token revoked successfully"}Access is forbidden.
Media typeapplication/json
object
message
required
Error message
string
error
required
Error flag
boolean
Example
{ "message": "The requested resource was not found", "error": true}Token not found.
Media typeapplication/json
object
message
required
Error message
string
error
required
Error flag
boolean
Example
{ "message": "The requested resource was not found", "error": true}