Revoke an API key
import requests
url = "https://app.langwatch.ai/api/api-keys/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.langwatch.ai/api/api-keys/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request DELETE \
--url https://app.langwatch.ai/api/api-keys/{id} \
--header 'Authorization: Bearer <token>'{
"success": true
}API Keys
Revoke API key
Revoke (soft-delete) an API key. Revoked keys can no longer authenticate. Requires organization:manage permission.
DELETE
/
api
/
api-keys
/
{id}
Revoke an API key
import requests
url = "https://app.langwatch.ai/api/api-keys/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.langwatch.ai/api/api-keys/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request DELETE \
--url https://app.langwatch.ai/api/api-keys/{id} \
--header 'Authorization: Bearer <token>'{
"success": true
}Authorizations
Admin API key for organization-level operations (managing projects, API keys). Create one in Settings > API Keys or via POST /api/api-keys. Format: sk-lw-{id}_{secret}.
Path Parameters
API key ID
Response
API key revoked successfully
Was this page helpful?
⌘I