Agent SLOs
Agent SLOs let you define measurable health targets for your monitoring agents and track scored evaluations over time. Each SLO has an optional numeric target and direction (at-or-above or at-or-below), and agents record a score at the end of every monitoring session. Firetiger computes a healthy field from the most recent score compared to the target.
Service: firetiger.agentslos.v1.AgentSlosService
Resource name patterns: agents/{agent_id}/slos/{slo_id} and agents/{agent_id}/slos/{slo_id}/records/{record_id}
Access: Read-write
Example flow
Define an SLO on an agent, record an evaluation, then check the agent’s health status.
1. Create an SLO
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/CreateAgentSlo" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{
"parent": "agents/cache-monitor",
"agent_slo_id": "cache-hit-ratio",
"agent_slo": {
"display_name": "Cache Hit Ratio",
"unit": "%",
"target_value": 95.0,
"target_direction": "SLO_TARGET_DIRECTION_AT_OR_ABOVE"
}
}'
{
"agent_slo": {
"name": "agents/cache-monitor/slos/cache-hit-ratio",
"display_name": "Cache Hit Ratio",
"unit": "%",
"target_value": 95.0,
"target_direction": "SLO_TARGET_DIRECTION_AT_OR_ABOVE"
}
}
2. Record an evaluation
Agents call this at the end of each monitoring session.
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/RecordSloEvaluation" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{
"slo_name": "agents/cache-monitor/slos/cache-hit-ratio",
"score": 97.3,
"notes": "Cache hit ratio within normal range after morning traffic spike."
}'
{
"agent_slo": {
"name": "agents/cache-monitor/slos/cache-hit-ratio",
"display_name": "Cache Hit Ratio",
"unit": "%",
"target_value": 95.0,
"target_direction": "SLO_TARGET_DIRECTION_AT_OR_ABOVE"
},
"agent_slo_record": {
"name": "agents/cache-monitor/slos/cache-hit-ratio/records/rec-abc123",
"score": 97.3,
"notes": "Cache hit ratio within normal range after morning traffic spike."
}
}
3. List SLOs with health status
After at least one evaluation, healthy is computed server-side from the most recent score.
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/ListAgentSlos" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{"parent": "agents/cache-monitor"}'
{
"agent_slos": [
{
"name": "agents/cache-monitor/slos/cache-hit-ratio",
"display_name": "Cache Hit Ratio",
"unit": "%",
"target_value": 95.0,
"target_direction": "SLO_TARGET_DIRECTION_AT_OR_ABOVE",
"healthy": true,
"recent_records": [
{"name": "agents/cache-monitor/slos/cache-hit-ratio/records/rec-abc123", "score": 97.3}
]
}
]
}
Methods
| Method | Description |
|---|---|
| CreateAgentSlo | Define a new SLO for an agent |
| GetAgentSlo | Retrieve an SLO by name |
| UpdateAgentSlo | Update an existing SLO |
| DeleteAgentSlo | Delete an SLO and all its records |
| ListAgentSlos | List SLOs for an agent with recent records and health |
| ListAgentSloRecords | List evaluation records for an SLO |
| RecordSloEvaluation | Record a scored evaluation for an SLO |
CreateAgentSlo
Define a new SLO for an agent.
POST /firetiger.agentslos.v1.AgentSlosService/CreateAgentSlo
REST alternative:
POST /v1/agents/{agent}/slos
| Field | Type | Required | Description |
|---|---|---|---|
parent |
string | Yes | Agent resource name (e.g. agents/my-agent) |
agent_slo_id |
string | No | ID for the SLO. Auto-generated if omitted |
agent_slo.display_name |
string | Yes | Human-readable name (e.g. "Cache Hit Ratio") |
agent_slo.description |
string | No | Longer description of what this SLO measures |
agent_slo.unit |
string | No | Unit suffix for display (e.g. "%", "ms") |
agent_slo.target_value |
double | Yes | Numeric threshold for health computation |
agent_slo.target_direction |
string | No | SLO_TARGET_DIRECTION_AT_OR_ABOVE (default) or SLO_TARGET_DIRECTION_AT_OR_BELOW |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/CreateAgentSlo" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{
"parent": "agents/my-agent",
"agent_slo_id": "error-rate",
"agent_slo": {
"display_name": "Error Rate",
"unit": "%",
"target_value": 1.0,
"target_direction": "SLO_TARGET_DIRECTION_AT_OR_BELOW"
}
}'
GetAgentSlo
Retrieve an SLO by name, including recent records and health status.
POST /firetiger.agentslos.v1.AgentSlosService/GetAgentSlo
REST alternative:
GET /v1/agents/{agent}/slos/{slo}
| Field | Type | Required | Description |
|---|---|---|---|
name |
string | Yes | SLO resource name (e.g. agents/my-agent/slos/error-rate) |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/GetAgentSlo" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{"name": "agents/my-agent/slos/error-rate"}'
UpdateAgentSlo
Update an existing SLO. Only fields specified in update_mask are changed.
POST /firetiger.agentslos.v1.AgentSlosService/UpdateAgentSlo
REST alternative:
PATCH /v1/agents/{agent}/slos/{slo}
| Field | Type | Required | Description |
|---|---|---|---|
agent_slo.name |
string | Yes | SLO resource name |
agent_slo.* |
— | No | Fields to update |
update_mask |
string | No | Comma-separated field paths. All mutable fields updated if omitted |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/UpdateAgentSlo" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{
"agent_slo": {
"name": "agents/my-agent/slos/error-rate",
"target_value": 0.5
},
"update_mask": "target_value"
}'
DeleteAgentSlo
Delete an SLO and all its evaluation records.
POST /firetiger.agentslos.v1.AgentSlosService/DeleteAgentSlo
REST alternative:
DELETE /v1/agents/{agent}/slos/{slo}
| Field | Type | Required | Description |
|---|---|---|---|
name |
string | Yes | SLO resource name |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/DeleteAgentSlo" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{"name": "agents/my-agent/slos/error-rate"}'
ListAgentSlos
List all SLOs for an agent. Each SLO includes up to 24 recent evaluation records and a computed healthy field (omitted when no target is configured).
POST /firetiger.agentslos.v1.AgentSlosService/ListAgentSlos
REST alternative:
GET /v1/agents/{agent}/slos
| Field | Type | Required | Description |
|---|---|---|---|
parent |
string | Yes | Agent resource name (e.g. agents/my-agent) |
page_size |
int | No | Maximum number of SLOs to return |
page_token |
string | No | Pagination token from a previous response |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/ListAgentSlos" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{"parent": "agents/my-agent"}'
ListAgentSloRecords
List evaluation records for an SLO in chronological order.
POST /firetiger.agentslos.v1.AgentSlosService/ListAgentSloRecords
REST alternative:
GET /v1/agents/{agent}/slos/{slo}/records
| Field | Type | Required | Description |
|---|---|---|---|
parent |
string | Yes | SLO resource name (e.g. agents/my-agent/slos/error-rate) |
page_size |
int | No | Maximum number of records to return |
page_token |
string | No | Pagination token from a previous response |
order_by |
string | No | Sort order. Default: create_time asc |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/ListAgentSloRecords" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{"parent": "agents/my-agent/slos/error-rate", "page_size": 50}'
RecordSloEvaluation
Record a scored evaluation for an SLO. Agents call this once per SLO at the end of each monitoring session. Returns the updated SLO and the newly created record.
POST /firetiger.agentslos.v1.AgentSlosService/RecordSloEvaluation
REST alternative:
POST /v1/agents/{agent}/slos/{slo}:record
| Field | Type | Required | Description |
|---|---|---|---|
slo_name |
string | Yes | SLO resource name (e.g. agents/my-agent/slos/error-rate) |
score |
double | Yes | The measured value. Must be a finite number (NaN and Inf are rejected) |
notes |
string | No | Explanation of the score and any notable observations |
session_name |
string | No | Session that produced this evaluation (e.g. agents/my-agent/sessions/ses-abc) |
curl -X POST "https://api.cloud.firetiger.com/firetiger.agentslos.v1.AgentSlosService/RecordSloEvaluation" \
-u "$USERNAME:$PASSWORD" \
-H "Content-Type: application/json" \
-d '{
"slo_name": "agents/my-agent/slos/error-rate",
"score": 0.3,
"notes": "Error rate dropped after the hotfix deployment at 14:20 UTC."
}'