Revoke an MCP tool grant
import requests
url = "https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request DELETE \
--url https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role} \
--header 'Authorization: Bearer <token>'{
"status": "revoked"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "permission_denied",
"permission": "<string>",
"scope_type": "<string>"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}MCP Servers
Revoke an MCP tool grant
Removes one tool grant, so members with that role can no longer use the tool. Requires the ai.manage permission.
DELETE
/
api
/
v1
/
org
/
mcp-servers
/
{server_id}
/
grants
/
{tool_name}
/
{role}
Revoke an MCP tool grant
import requests
url = "https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request DELETE \
--url https://platform.ankra.app/api/v1/org/mcp-servers/{server_id}/grants/{tool_name}/{role} \
--header 'Authorization: Bearer <token>'{
"status": "revoked"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "permission_denied",
"permission": "<string>",
"scope_type": "<string>"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The registered MCP server's id.
The granted tool's name.
The role the tool is granted to.
Response
The grant was revoked
Available options:
revoked