VercelVercel
Menu

Delete an authentication token

DELhttps://api.vercel.com/v3/user/tokens/{tokenId}
Invalidate an authentication token, such that it will no longer be valid for future HTTP requests.
https://api.vercel.com/v3/user/tokens/{tokenId}
const response = await fetch('https://api.vercel.com/v3/user/tokens/tokenId', {
method: 'DELETE',
headers: {
'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
'Content-Type': 'application/json',
},
});
const data = await response.json();
console.log(data);
Response
{
"tokenId": "5d9f2ebd38ddca62e5d51e9c1704c72530bdc8bfdd41e782a6687c48399e8391"
}
AuthorizationbearerToken

Default authentication mechanism

tokenIdstringRequired
The identifier of the token to invalidate. The special value "current" may be supplied, which invalidates the token that the HTTP request was authenticated with.
200Authentication token successfully deleted.
tokenIdstringRequired
The unique identifier of the token that was deleted.
400One of the provided values in the request query is invalid.
401The request is not authorized.
403You do not have permission to access this resource.
404Token not found with the requested `tokenId`.