Guardrail triggers
Package: agentrouter.guardrails.v1 Service: GuardrailTriggersService
Endpoints
List guardrail trigger events
What it does: Lists trigger events matching the specified filters.
Request fields:
| Field | Required | Description |
|---|---|---|
customer_id | no | Owning customer scope; defaults to caller's session customer when empty. |
project_id | no | Owning project scope; defaults to caller's session project when empty. |
page | no | Cursor-pagination inputs. |
guardrail_ids | no | Filter to events for these guardrail ids. |
consumer_ids | no | Filter to events for these consumer ids. |
resource_ids | no | Filter to events for these resource ids. |
date_from | no | Inclusive start of the time range to query. |
date_to | no | Inclusive end of the time range to query. |
min_execution_duration_ms | no | Filter to events with execution_duration_ms >= this value. |
max_execution_duration_ms | no | Filter to events with execution_duration_ms <= this value. |
guardrail_types | no | Filter to events for guardrails of these types. |
exclude_guardrail_types | no | Exclude events for guardrails of these types. |
Response fields:
| Field | Required | Description |
|---|---|---|
triggers | no | Trigger events matching the request filters, one page's worth. |
page | no | Cursor-pagination outputs. |
total | no | Total count of matching triggers across all pages. |
{"signatures":{"go":"c.GuardrailTriggers().ListGuardrailTriggers(ctx, \u0026guardrailsv1.ListGuardrailTriggersRequest{...})","python":"client.guardrailtriggers.listguardrailtriggers(...)","typescript":"client.guardrailtriggers.listguardrailtriggers({...})","cli":"tare api guardrails triggers list","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"examples":{"go":"// No Go SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","python":"# No Python SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","typescript":"// No TypeScript SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","cli":"tare api guardrails triggers list","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"persona":"Authenticated (API key or session token)","httpVerb":"GET","httpPath":"/v1/customers/{customer_id}/projects/{project_id}/guardrails/triggers","slug":"list-guardrail-trigger-events"}
Get a guardrail trigger event
What it does: Returns a single trigger event by id.
Request fields:
| Field | Required | Description |
|---|---|---|
customer_id | no | Owning customer scope; defaults to caller's session customer when empty. |
project_id | no | Owning project scope; defaults to caller's session project when empty. |
id | yes | Required: id of the trigger event to fetch. |
Response fields:
| Field | Required | Description |
|---|---|---|
trigger | no | The requested guardrail trigger event. |
{"signatures":{"go":"c.GuardrailTriggers().GetGuardrailTrigger(ctx, \u0026guardrailsv1.GetGuardrailTriggerRequest{...})","python":"client.guardrailtriggers.getguardrailtrigger(...)","typescript":"client.guardrailtriggers.getguardrailtrigger({...})","cli":"tare api guardrails triggers get \u003cid\u003e","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers/01H...\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"examples":{"go":"// No Go SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","python":"# No Python SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","typescript":"// No TypeScript SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","cli":"tare api guardrails triggers get \u003cid\u003e","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers/01H...\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"persona":"Authenticated (API key or session token)","httpVerb":"GET","httpPath":"/v1/customers/{customer_id}/projects/{project_id}/guardrails/triggers/{id}","slug":"get-a-guardrail-trigger-event"}
Get guardrail trigger statistics
What it does: Returns aggregate statistics for trigger events in scope.
Request fields:
| Field | Required | Description |
|---|---|---|
customer_id | no | Owning customer scope; defaults to caller's session customer when empty. |
project_id | no | Owning project scope; defaults to caller's session project when empty. |
Response fields:
| Field | Required | Description |
|---|---|---|
total_triggers | no | Total number of trigger events in scope. |
avg_execution_time_ms | no | Average execution time across all triggers, in milliseconds. |
top_consumers | no | Ranked list of consumers by trigger count. |
top_resources | no | Ranked list of resources by trigger count. |
top_guardrails | no | Ranked list of guardrails by trigger count. |
time_distribution | no | Time-series distribution of trigger counts. |
{"signatures":{"go":"c.GuardrailTriggers().GetGuardrailTriggerStats(ctx, \u0026guardrailsv1.GetGuardrailTriggerStatsRequest{...})","python":"client.guardrailtriggers.getguardrailtriggerstats(...)","typescript":"client.guardrailtriggers.getguardrailtriggerstats({...})","cli":"tare api guardrails triggers stats","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers/stats\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"examples":{"go":"// No Go SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","python":"# No Python SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","typescript":"// No TypeScript SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","cli":"tare api guardrails triggers stats","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/triggers/stats\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"persona":"Authenticated (API key or session token)","httpVerb":"GET","httpPath":"/v1/customers/{customer_id}/projects/{project_id}/guardrails/triggers/stats","slug":"get-guardrail-trigger-statistics"}
Get guardrails dashboard summary
What it does: Returns a combined summary of guardrail posture and recent trigger activity for the dashboard view.
Request fields:
| Field | Required | Description |
|---|---|---|
customer_id | no | Owning customer scope; defaults to caller's session customer when empty. |
project_id | no | Owning project scope; defaults to caller's session project when empty. |
Response fields:
| Field | Required | Description |
|---|---|---|
guardrails | no | Summary of guardrails configured in scope. |
events | no | Summary of trigger events recorded in scope. |
{"signatures":{"go":"c.GuardrailTriggers().GetDashboard(ctx, \u0026guardrailsv1.GetDashboardRequest{...})","python":"client.guardrailtriggers.getdashboard(...)","typescript":"client.guardrailtriggers.getdashboard({...})","cli":"tare api guardrails dashboard","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/dashboard\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"examples":{"go":"// No Go SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","python":"# No Python SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","typescript":"// No TypeScript SDK wrapper for GuardrailTriggersService yet -- use the CLI or curl example below.","cli":"tare api guardrails dashboard","curl":"curl \"${AGENTROUTER_BASE_URL}/v1/customers/cust_01H.../projects/proj_01H.../guardrails/dashboard\" \\\n -H \"Authorization: Bearer ak-${AGENTROUTER_API_KEY}\""},"persona":"Authenticated (API key or session token)","httpVerb":"GET","httpPath":"/v1/customers/{customer_id}/projects/{project_id}/guardrails/dashboard","slug":"get-guardrails-dashboard-summary"}