curl --request GET \
--url https://api.portkey.ai/v1/guardrails/{guardrailId} \
--header 'x-portkey-api-key: <api-key>'{
"id": "<string>",
"name": "<string>",
"slug": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_updated_at": "2023-11-07T05:31:56Z",
"owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"updated_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"checks": [
{
"parameters": {
"jwksUri": "<string>",
"headerKey": "<string>",
"cacheMaxAge": 86400,
"clockTolerance": 5,
"maxTokenAge": "1d",
"algorithms": [
"RS256"
]
},
"name": "<string>",
"is_enabled": true
}
],
"actions": {
"deny": false,
"async": false,
"on_success": {
"feedback": {
"value": 5,
"weight": 1,
"metadata": ""
}
},
"on_fail": {
"feedback": {
"value": -5,
"weight": 1,
"metadata": ""
}
}
}
}Retrieve Guardrail
Retrieves details of a specific guardrail by ID or slug
curl --request GET \
--url https://api.portkey.ai/v1/guardrails/{guardrailId} \
--header 'x-portkey-api-key: <api-key>'{
"id": "<string>",
"name": "<string>",
"slug": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_updated_at": "2023-11-07T05:31:56Z",
"owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"updated_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"checks": [
{
"parameters": {
"jwksUri": "<string>",
"headerKey": "<string>",
"cacheMaxAge": 86400,
"clockTolerance": 5,
"maxTokenAge": "1d",
"algorithms": [
"RS256"
]
},
"name": "<string>",
"is_enabled": true
}
],
"actions": {
"deny": false,
"async": false,
"on_success": {
"feedback": {
"value": 5,
"weight": 1,
"metadata": ""
}
},
"on_fail": {
"feedback": {
"value": -5,
"weight": 1,
"metadata": ""
}
}
}
}Documentation Index
Fetch the complete documentation index at: https://portkey-docs-fix-cache-hit-elaborate.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Path Parameters
Guardrail UUID or slug (with guard_ prefix)
Response
Guardrail details retrieved successfully
Unique identifier of the guardrail
Name of the guardrail
URL-friendly slug
Creation timestamp
Last update timestamp
UUID of the user who created the guardrail
Organisation UUID
Workspace UUID (null for organisation-level guardrails)
Current status of the guardrail
active, archived UUID of the user who last updated the guardrail
Array of configured guardrail checks
Show child attributes
Show child attributes
Actions to take when guardrail checks fail or pass
Show child attributes
Show child attributes
Was this page helpful?

