Skip to content

Fetch an guardrail

GET
/v1/guardrails/{guardrailId}
curl --request GET \
--url https://example.com/v1/guardrails/example \
--header 'Authorization: Bearer <token>'
guardrailId
required
string

GuardrailId — unique identifier for the guardrail.

Guardrail.

Media typeapplication/json
object
id
required
string
>= 1 characters
name
string
description
string
kind
required

How the guardrail is checked. Open string: the built-in kinds are listed in examples; adapters register strategies for their own kinds.

string
>= 1 characters
check
required

Reference to the concrete check implementation registered server-side.

string
>= 1 characters
config
object
key
additional properties
any
action
required
object
on-violation
required

What happens when the guardrail fires. Open string: the built-in actions are listed in examples; any other name needs an action handler registered under it where the guardrail is evaluated.

string
>= 1 characters
retry
object
maxAttempts
required
integer
>= 1 <= 10
escalateTo
string
compensateWith
string
severity
string
Allowed values: info warn error critical
scope
object
when
string
Allowed values: always ci-only runtime-only
agents
Array<string>
flows
Array<string>
tenants
Array<string>
budget
object
maxCostUsd
number
maxLatencyMs
integer
judgeCapabilities
object
key
additional properties
any
Example
{
"kind": "zero-llm",
"action": {
"on-violation": "halt"
},
"severity": "info",
"scope": {
"when": "always"
}
}

Missing / malformed / expired / revoked bearer token.

Media typeapplication/json
object
error
required
object
code
required

Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).

string
message
required
string
details

Optional, kind-specific.

object
key
additional properties
any
requestId
required

Server-assigned request id; also echoed via X-Request-Id header.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example",
"details": {},
"requestId": "example"
}
}

No guardrail with that id under this tenant.

Media typeapplication/json
object
error
required
object
code
required

Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).

string
message
required
string
details

Optional, kind-specific.

object
key
additional properties
any
requestId
required

Server-assigned request id; also echoed via X-Request-Id header.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example",
"details": {},
"requestId": "example"
}
}