remove_guardrails_policy
Delete a specific guardrails policy by name using Enkrypt AI MCP Server. This tool removes predefined safety policies, returning details of the deleted policy for verification.
Instructions
Remove an existing guardrails policy.
Args: policy_name: The name of the policy to remove.
Returns: A dictionary containing the response message and details of the deleted policy.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| policy_name | Yes |
Input Schema (JSON Schema)
{
"properties": {
"policy_name": {
"title": "Policy Name",
"type": "string"
}
},
"required": [
"policy_name"
],
"title": "remove_guardrails_policyArguments",
"type": "object"
}
Implementation Reference
- src/mcp_server.py:179-194 (handler)The handler function decorated with @mcp.tool() that implements the remove_guardrails_policy tool. It deletes the specified guardrails policy using the guardrails_client and returns the response as a dictionary. This serves as both the handler and registration in the FastMCP framework.@mcp.tool() def remove_guardrails_policy(policy_name: str) -> Dict[str, Any]: """ Remove an existing guardrails policy. Args: policy_name: The name of the policy to remove. Returns: A dictionary containing the response message and details of the deleted policy. """ # Remove the policy delete_policy_response = guardrails_client.delete_policy(policy_name=policy_name) # Return the response as a dictionary return delete_policy_response.to_dict()