Documentation Index
Fetch the complete documentation index at: https://docs.tierzero.ai/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The TierZero API allows you to programmatically ask questions to the TierZero AI agent and receive structured responses. This enables you to integrate TierZero’s intelligent analysis capabilities into your applications, automation workflows, and custom tools. The API uses standard HTTP methods with JSON payloads and requires authentication via organization API keys. All API responses are formatted in JSON and include relevant interaction IDs for tracking and follow-up.Authentication
All API requests require authentication using an organization API key. Include your API key in the request header:Resource Identifiers
The TierZero API uses Global IDs to identify resources like digests, alert agents, teams, and notification integrations. Global IDs are opaque string identifiers that you receive in API responses and use in subsequent requests. Example Global IDs:Endpoints
Alert Agent Management
Create Alert Agent (POST /api/v1/alert-responders)
Create a new alert agent that automatically investigates incoming alerts.
Request
Method:POST
Path: /api/v1/alert-responders
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/json
runbook or runbook.investigation_prompt is not provided, a default investigation prompt will be used: “Please investigate the issue and explain the root cause to the best of your abilities!”
Idempotency: If an alert agent with the same name exists for the organization and team, returns the existing responder instead of creating a duplicate.
Matching Criteria
Thematching_criteria field controls which alerts trigger this agent. You can provide either text_matches or match_rules — the API will auto-generate the other format and return both in the response.
Option 1: text_matches — Simple wildcard patterns (recommended for Terraform/Pulumi)
A flat list of patterns using * as a wildcard. All patterns must match (implicit AND).
| Pattern | Meaning | Example matches |
|---|---|---|
*stg/* | Contains stg/ | "deploy stg/api failed" |
release/* | Starts with release/ | "release/v2.1 rollback" |
*-critical | Ends with -critical | "db-critical" |
*error* | Contains error | "connection error timeout" |
*foo*bar* | Regex: foo.*bar | "foo-123-bar" |
match_rules — Structured rules with AND/OR logic
A tree of conditions supporting AND/OR operators and typed conditions. Max nesting depth of 2.
Condition types:
contains— substring match (case-insensitive)starts_with— prefix matchends_with— suffix matchregex— regular expression match
text_matches and match_rules are provided, match_rules takes precedence and text_matches will be regenerated from it.
Response
Status Code:200 OK
Get Alert Agent (GET /api/v1/alert-responders/{alert_id})
Retrieve detailed information about a specific alert agent.
Request
Method:GET
Path: /api/v1/alert-responders/{alert_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
alert_id(required): Alert agent Global ID
Response
Status Code:200 OK
List Alert Agents (GET /api/v1/alert-responders)
List all alert agents for your organization, optionally filtered by team.
Request
Method:GET
Path: /api/v1/alert-responders
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
team_name(optional): Filter by team name
Response
Status Code:200 OK
Update Alert Agent (PUT /api/v1/alert-responders/{alert_id})
Update an existing alert agent’s configuration.
Request
Method:PUT
Path: /api/v1/alert-responders/{alert_id}
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/json
alert_id(required): Alert agent Global ID
webhook_sources for Slack alerts or slack_channel_id for webhook-based alerts.
Response
Status Code:200 OK
Delete Alert Agent (DELETE /api/v1/alert-responders/{alert_id})
Delete an alert agent.
Request
Method:DELETE
Path: /api/v1/alert-responders/{alert_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
alert_id(required): Alert agent Global ID
Response
Status Code:200 OK
Enable Alert Agent (POST /api/v1/alert-responders/{alert_id}/enable)
Enable a paused alert agent to start processing alerts.
Request
Method:POST
Path: /api/v1/alert-responders/{alert_id}/enable
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
alert_id(required): Alert agent Global ID
Response
Status Code:200 OK
Disable Alert Agent (POST /api/v1/alert-responders/{alert_id}/disable)
Disable an alert agent to temporarily stop processing alerts.
Request
Method:POST
Path: /api/v1/alert-responders/{alert_id}/disable
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
alert_id(required): Alert agent Global ID
Response
Status Code:200 OK
List Webhook Subscriptions (GET /api/v1/webhook-subscriptions)
Discover available webhook subscriptions for your organization. Use this endpoint to find valid webhook_sources when creating or updating alert agents.
Request
Method:GET
Path: /api/v1/webhook-subscriptions
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
Response
Status Code:200 OK
List Notification Integrations (GET /api/v1/notification-integrations)
Discover available notification integrations for your organization. Use this endpoint to find valid notification_integration_ids when creating or updating alert agents.
Request
Method:GET
Path: /api/v1/notification-integrations
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
kind(optional): Filter by integration kind. Allowed values:DISCORD_WEBHOOK: Discord webhook integrationsSLACK_ALERT: Slack alert integrations (Auto-Detect)
Response
Status Code:200 OK
Investigation Management
Get Investigation (GET /api/v1/investigations/{investigation_id})
Retrieve details about a completed investigation (alert agent job run).
Request
Method:GET
Path: /api/v1/investigations/{investigation_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
investigation_id(required): Investigation Global ID (GraphQL JobRun ID)
Response
Status Code:200 OK
result field contains the investigation analysis with:
- Source markup (
††toolu_...††) replaced with numbered citations ([1],[2], etc.) - Timestamp markers (
§) removed - A “Sources:” section appended at the end with clickable links to data sources
Digest Agent Management
Create Digest Agent (POST /api/v1/digests)
Create a new scheduled digest agent job that periodically generates reports based on configured sections.
Request
Method:POST
Path: /api/v1/digests
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/json
Response
Status Code:200 OK
Get Digest Agent (GET /api/v1/digests/{digest_id})
Retrieve details about a specific digest agent job.
Request
Method:GET
Path: /api/v1/digests/{digest_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
digest_id(required): Digest Agent ID returned from create/update operations
Response
Status Code:200 OK
Update Digest Agent (PUT /api/v1/digests/{digest_id})
Update an existing digest agent job’s configuration.
Request
Method:PUT
Path: /api/v1/digests/{digest_id}
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/json
digest_id(required): Digest Agent ID
Response
Status Code:200 OK
Delete Digest Agent (DELETE /api/v1/digests/{digest_id})
Delete a digest agent job.
Request
Method:DELETE
Path: /api/v1/digests/{digest_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API key
digest_id(required): Digest Agent ID
Response
Status Code:200 OK
Run Digest Agent (POST /api/v1/digests/{digest_id}/run)
Manually trigger a digest agent job to run immediately or schedule it for later.
Request
Method:POST
Path: /api/v1/digests/{digest_id}/run
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/json
digest_id(required): Digest Agent ID
run_sync(optional): Iftrue, runs synchronously and returns results in the response. Default isfalse.scheduled_runtime(optional): Unix timestamp in seconds. If provided, schedules the digest agent to run at this time instead of running immediately. Must be in the future.
Response (Immediate Run - Async Mode)
Status Code:200 OK
Response (Immediate Run - Sync Mode with run_sync: true)
Status Code:200 OK
Response (Scheduled Run)
Status Code:200 OK
Cron Expression Reference
Digest Agent schedules use cron expressions with five fields:- Weekdays at 9 AM:
0 9 * * 0-4 - Daily at 9 AM:
0 9 * * * - Every Monday at 10 AM:
0 10 * * 0 - Every 6 hours:
0 */6 * * *
* (any), , (list), - (range), / (step)
Interaction Management
Get Interaction Results (GET /api/v1/interactions/{interaction_id})
Retrieve the results of a previous TierZero interaction using its interaction ID. This endpoint allows you to fetch results later, which is useful for polling scheduled actions or accessing historical interactions.
For scheduled actions, this endpoint returns the current status and results when complete.
Request
Method:GET
Path: /api/v1/interactions/{interaction_id}
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyAccept:application/json
interaction_id(required): The interaction ID returned from a previousPOST /api/v1/interactionscall
Response
Status Response (for async interactions in progress)
Status Code:200 OK
Complete Response (for completed interactions)
Status Code:200 OK
PENDING: Request received and queued for processingIN_PROGRESS: Currently being processed by TierZeroCOMPLETED: Processing complete, results availableFAILED: Processing failed due to an error
Error Responses
401 Unauthorized:Create Interaction (POST /api/v1/interactions)
Submit a question to the TierZero AI agent and receive an intelligent response based on your organization’s knowledge catalog and observability data.
Request
Method:POST
Path: /api/v1/interactions
Content-Type: application/json
Headers:
X-TierZero-Org-Api-Key(required): Your organization API keyContent-Type:application/jsonAccept:application/json
question(required): The question or prompt you want TierZero to analyze. For scheduled actions, this becomes the prompt that runs at the scheduled time.context(optional): Array of previous interactions to provide conversation contextuser_id(optional): Identifier for the user making the request, useful for tracking and analyticsuse_tools(optional): Iffalse, TierZero will respond without using any tools (no data queries, no integrations). Default istrue. Set tofalsefor faster responses when you only need analysis based on existing knowledgescheduled_runtimes(optional): List of Unix timestamps (in seconds) for when to execute. Each timestamp must be in the future (max 24 hours). Maximum of 10 timestamps allowed per request. Returnsinteraction_idand statusSCHEDULEDfor polling via GET endpoint.- Legacy Parameter:
scheduled_runtime(singular, integer) is still supported for backwards compatibility but deprecated. When using the legacy parameter, the API returns the old response format with top-levelinteraction_id,scheduled_runtime,url, andstatusfields instead of theinteractionsarray. New integrations should usescheduled_runtimes(plural, array).
- Legacy Parameter:
notifications(optional): Nested object containing notification configurations:slack(optional): Slack notification settingsslack_channel_ids: Array of Slack channel IDs (e.g.,["C01234567"]). Each ID should start with ‘C’ (public) or ‘G’ (private)
discord(optional): Discord notification settingsdiscord_webhook_urls: Array of Discord webhook URLs
web(optional): Webhook callback settings for async responsescallback_url: URL where results will be sentcustom_headers(optional): Dictionary of custom HTTP headers for callbacks (e.g.,{"Authorization": "Bearer token"}). If not provided, defaults to{"X-TierZero-Org-Api-Key": "your-api-key"}
- Synchronous (default): Returns result immediately in the response. No
scheduled_runtimesornotifications.web.callback_urlprovided. Status:COMPLETED. - Asynchronous with callback: Provide
notifications.web.callback_urlwithoutscheduled_runtimes. Returnsinteraction_idimmediately, executes in background, sends results to callback URL when done. Status:SCHEDULED. - Scheduled: Provide
scheduled_runtimes(list of future timestamps). Returnsinteraction_idimmediately, executes at specified times. Poll via GET endpoint or use notification channels. Status:SCHEDULED.
- A unique name is automatically generated for each scheduled action
- Scheduled actions are limited to at most 24 hours in the future
- Maximum of 10 scheduled runtimes allowed per request
- Notification targets (via
notificationsobject) are optional - you can query results usingGET /api/v1/interactions/{interaction_id}
Response
Synchronous Response (no callback_url, no scheduled_runtime)
Status Code:200 OK
Asynchronous Response (with callback_url, no scheduled_runtimes)
Status Code:200 OK
callback_url without scheduled_runtimes, the job executes immediately in the background and results are sent to the callback URL. Status is SCHEDULED.
Scheduled Action Response (with scheduled_runtimes)
Status Code:200 OK
scheduled_runtimes, jobs execute at the specified future times. The callback URL (if provided) will receive results when each scheduled job completes.
Legacy Response Format (DEPRECATED - using scheduled_runtime singular parameter)
Status Code: 200 OK
scheduled_runtime (singular) parameter. New integrations should use scheduled_runtimes (plural, array) which returns the interactions array format shown above.
Important Behavioral Notes:
-
One Interaction Per Scheduled Runtime: When using
scheduled_runtimes, each timestamp creates a separate interaction with its own uniqueinteraction_id. This is a 1:1 mapping - one timestamp = one job = one interaction. -
Tracking Individual Executions:
- Poll each interaction independently:
GET /api/v1/interactions/{interaction_id} - Each interaction has its own lifecycle and status
- Store ALL returned
interaction_ids if you need to track completion
- Poll each interaction independently:
-
Callback Behavior (when using
callback_url):- You will receive multiple callbacks - one per scheduled runtime
- Each callback includes the specific
interaction_idfor that execution - Callback payload structure:
-
Client Implementation Requirements:
- MUST store all
interaction_ids from theinteractionsarray - MUST handle multiple callbacks when using
callback_url(one per scheduled runtime) - Each callback’s
interaction_idcorresponds to one of the returned interactions
- MUST store all
Context Handling
Thecontext field allows you to provide conversation history for more contextual responses:
- Interaction ID Context: If a context item includes an
interaction_idfrom a previous API call, TierZero will retrieve the full conversation history for that interaction - Content-Only Context: If only
contentis provided, it will be treated as a user message in the conversation context - Mixed Context: You can combine both types of context items in a single request
Error Responses
400 Bad Request:Usage Examples
Alert Agent Management Examples
Create an Alert Agent
List Alert Agents
Get Alert Agent Details
Update Alert Agent
Enable/Disable Alert Agent
Delete Alert Agent
Investigation Management Examples
Get Investigation Details
Digest Agent Management Examples
Create a Daily Digest Agent
Get Digest Agent Details
Update a Digest Agent
Run a Digest Agent Immediately
Schedule a Digest Agent for Later
Delete a Digest Agent
Scheduled Action Examples
Scheduled actions use the same/api/v1/interactions endpoint with additional parameters.
Create Scheduled Action with Slack Notification
Schedule a TierZero agent to run at specific times and post results to a Slack channel:Create Scheduled Action with Discord Notification
Schedule an action to send results to a Discord webhook:Create Scheduled Action with Multiple Notifications
Send results to both Slack and Discord:Interaction Examples
Basic Question
Question with Context
Asynchronous Request with Callback
Scheduled Request with Polling
Request Without Tools (Knowledge-Only Response)
Retrieve Interaction Results
Response Format
TierZero responses are formatted as markdown and may include:- Analysis summaries with key findings
- Relevant log excerpts and error messages
- Metric trends and performance data
- Recommendations for investigation or resolution
- Links to relevant dashboards and tools
interaction_id can be used in subsequent API calls to maintain conversation context and build upon previous analyses.
Rate Limits
API requests are subject to rate limiting based on your organization’s plan. Rate limit information is included in response headers:X-RateLimit-Limit: Maximum requests per time windowX-RateLimit-Remaining: Remaining requests in current windowX-RateLimit-Reset: Time when the rate limit resets
Best Practices
- Provide Context: Use the
contextfield to maintain conversation history for better responses - Descriptive Questions: Ask specific, detailed questions for more accurate analysis
- Choose the Right Mode:
- Use synchronous mode for immediate responses (no
callback_urlorscheduled_runtime) - Use scheduled mode with polling (
scheduled_runtime) for time-based execution when you need full control over result retrieval - Use async mode with callbacks (
callback_url) for fire-and-forget scenarios with webhook handling
- Use synchronous mode for immediate responses (no
- Optimize Tool Usage:
- Set
use_tools: true(default) when you need TierZero to query data sources, run integrations, or perform real-time analysis - Set
use_tools: falsefor faster responses when you only need answers based on existing knowledge (e.g., documentation, runbooks, best practices)
- Set
- Track Interactions: Store interaction IDs to enable follow-up questions and conversation threading
- Handle Errors: Implement proper error handling for all HTTP status codes
- Respect Rate Limits: Monitor rate limit headers and implement backoff strategies
- Poll Efficiently: For scheduled mode, use reasonable polling intervals (2-5 seconds) and implement timeouts
- User Tracking: Use the
user_idfield for analytics, rate limiting, and audit trails