API ReferenceIntroduction
All endpoints
Documentation contract

API v1 · sha256:898ee484330817a84c170e0e87bf24f27e62e5838635ee4c9daf6a7a3d704ce9

This fingerprint identifies the contract used by these pages and exports. It is not a new API version.

The Tellagen API lets you manage incidents, services, teams, and custom fields programmatically.

Base URL

https://{company}.api.tellagen.com/api/v1/

Replace {company} with your company subdomain.

Content type

All requests and JSON responses use application/json unless an endpoint documents an empty response.

Rate limits

Authenticated requests share a workspace limit. Anonymous requests and failed authentication attempts use the trusted client IP. Responses include X-RateLimit-Limit and X-RateLimit-Remaining. A 429 Too Many Requests response also includes Retry-After.

Authentication

Authenticate by including an API token in the Authorization header.

Authorization: Bearer tllg_YOUR_TOKEN

Create API tokens in Settings > API keys. Tokens start with the tllg_ prefix and are only shown once at creation time.

Make your first request

Use a workspace API key to list incidents. This quickstart makes no changes and succeeds when the workspace has no incidents.

Prerequisites

For a workspace at https://acme.tellagen.com, the API origin is https://acme.api.tellagen.com. Use acme as the company placeholder in the request URL.

You need your workspace slug, an API key with incidents:read, curl, and a POSIX-compatible shell. Keep the key out of source control and application logs.

List incidents

Replace the company and token placeholders with your workspace slug and API key. For a local server, replace the API origin with its address.

bash
curl --request GET \
  --url 'https://{company}.api.tellagen.com/api/v1/incidents?limit=50' \
  --header 'Authorization: Bearer <token>'

Read the response

A successful request returns HTTP 200. The JSON example below is a successful empty workspace response. Authentication failures return 401, and a valid key without incidents:read returns 403. If pagination.has_more is true, follow pagination.next_cursor as described in the pagination guide.

json
{
  "incidents": [],
  "has_more": false,
  "pagination": {
    "limit": 50,
    "has_more": false
  }
}

Build reliable requests

Treat create retries, concurrent updates, and rate limits as separate cases. The API provides a specific signal for each one.

Idempotent creates

Send Idempotency-Key on POST /api/v1/incidents, POST /api/v1/incidents/{id}/timeline, POST /api/v1/services, and POST /api/v1/teams. A key is retained for 24 hours and can replay only the identical request body. Generate a new key for a logically new create.

Attach the key on the first create attempt, before any network uncertainty. If the 24-hour retention has expired, do not assume the old key can replay: look up the intended resource first and use a new key only when you have established that a new create is required.

A reused key with different content returns idempotency_key_reused. idempotency_in_progress means the identical request is still being handled and may be retried after Retry-After. idempotency_outcome_unknown means the earlier operation may have completed; do not retry automatically. Reconcile by listing or fetching the resource, or ask an operator to decide.

Revision-protected updates

API-key clients must send If-Tellagen-Resource-Version on PATCH /api/v1/incidents/{id}, PATCH /api/v1/timeline/{id}, PATCH /api/v1/services/{id}, PATCH /api/v1/teams/{id}, and PATCH /api/v1/custom-fields/{id}. Use the positive revision from the latest response or Tellagen-Resource-Version response header.

Those are the five revision-protected resource PATCH operations. PATCH /api/v1/teams/{id}/members/{userId}, PATCH /api/v1/incidents/{id}/custom-fields, and PATCH /api/v1/incidents/{id}/slack/channel-name use their operation-specific validation and do not take If-Tellagen-Resource-Version.

The token also needs the matching read scope to fetch the resource and its current revision before a protected PATCH. A 412 response means another writer changed the resource. Fetch the latest representation, compare your intended edit with the new state, and then either abandon it or send a reconciled PATCH with the new revision. Never overwrite automatically after a conflict.

Rate limits and request identity

A 429 response reports the current quota in X-RateLimit-Limit and X-RateLimit-Remaining. Wait for Retry-After before retrying. Bound attempts and add jitter when many workers share one workspace key.

Send a unique X-Request-ID when tracing a workflow. The response echoes an accepted ID or supplies one; record it with the status and structured error code.

Write requests accept one JSON document no larger than 1 MiB. Invalid JSON, multiple JSON values, unknown properties, and oversized bodies fail before application logic runs.

Versioning

All endpoints in this reference use /api/v1 and are supported.

Compatible changes
Tellagen can add optional response fields or enum values. Ignore response fields that your client does not use.
Breaking changes
Tellagen uses a new major version for incompatible changes.
Deprecated endpoints
Tellagen marks an endpoint deprecated at least 180 days before removal. Deprecated responses identify the replacement endpoint.

Scopes

Each API token is granted one or more scopes. A request will return 403 Forbidden if the token lacks the required scope.

API token scopes
ScopeDescription
incidents:readList and retrieve incidents, and discover writable workflow statuses and severities
incidents:writeCreate and update incidents and timeline events. Requires an active responder seat for the key owner.
slack_context:readRead Slack context collected for incident investigation
services:readList and retrieve services, and discover writable service tiers
services:writeCreate, update, and archive services. Requires an active responder seat and the manage_settings role permission.
teams:readList and retrieve teams and members
teams:writeCreate, update, and archive teams; manage members. Requires an active responder seat and the manage_teams role permission.
custom_fields:readList and retrieve custom field definitions and values
custom_fields:writeCreate, update, and archive custom fields; set incident field values. Definition changes require the manage_settings role permission. Incident value changes require an active responder seat.

Prerequisite definitions

A write operation can require these conditions in addition to its API scope.

active_responder
The API key owner must have an active responder seat.
manage_settings
The API key owner must have the manage_settings role permission.
manage_teams
The API key owner must have the manage_teams role permission.
mutable_incident
The incident must not be archived. Workflow-state restrictions are described by each operation.
slack_channel
The incident must have a linked Slack channel.

Errors

Errors always include stable code and human-readable message fields. They can also include field, details, and request_id. You can send X-Request-ID with a request. If you omit it, the API generates one. The response header and error body return the same value. Send that value to support when you report an unexpected error.

For support, include the request ID, method, path, response status, and time. Omit tokens and private request bodies.

Example error responses

Missing scope (403)

json
{
  "code": "missing_scope",
  "message": "insufficient scope: incidents:write required",
  "details": {
    "required_scope": "incidents:write"
  },
  "request_id": "01JEXAMPLE8R4N5W6Y7Z"
}

Stale resource version (412)

json
{
  "code": "precondition_failed",
  "message": "the resource changed; fetch it again and retry with the current resource version",
  "field": "If-Tellagen-Resource-Version",
  "request_id": "01JEXAMPLE8R4N5W6Y7Z"
}

Rate limit (429)

json
{
  "code": "rate_limited",
  "message": "rate limit exceeded",
  "details": {
    "retry_after_seconds": 1
  },
  "request_id": "01JEXAMPLE8R4N5W6Y7Z"
}
Stable API error codes
CodeMeaningNext actionRetry
authentication_requiredThe request has no valid API token or session.Send an active Bearer token for this workspace. Replace an expired or revoked key.After correcting authentication.
missing_scopeThe token lacks the scope named in details.required_scope.Read details.required_scope. Ask a workspace manager for a replacement key with that scope.After correcting access.
responder_seat_requiredThe key owner needs the seat named in details.required_seat.Ask a workspace manager to review the key owner’s responder seat.After correcting access.
missing_role_permissionThe key owner lacks details.required_permission or one of details.required_roles.Ask a workspace manager to review the owner’s role and the permission named in details.After correcting access.
permission_deniedAccess is denied without exposing private authorization state.Verify the workspace, key owner, and resource access with a workspace manager.After correcting access.
invalid_resource_stateThe operation is not valid for the current resource state.Read the current resource. Restore an archived resource or choose an operation allowed in its current state.After reconciling state.
invalid_relationship_stateRestore requires a retained owner or parent relationship to identify an active resource.Restore the retained parent or owning team before restoring this resource.After correcting the relationship.
duplicate_slugA team already uses the requested slug.Read the existing team or choose a different slug.After changing the request.
invalid_jsonThe request body is not one valid JSON document.Send one valid JSON object with Content-Type: application/json.After correcting the body.
unknown_fieldThe request contains an unsupported JSON property named in field.Remove or correct the property named in field. Use the request schema, not the response schema.After correcting the body.
request_body_too_largeThe request body is larger than 1 MiB.Reduce the body to 1 MiB or less.After reducing the body.
multiple_json_valuesThe request body contains more than one JSON document.Send one JSON document rather than concatenated documents.After correcting the body.
idempotency_key_reusedThe key was already used with different request content.Recover the original request for this key. Use a new key only for a different intended operation.Do not resend changed content with the same key.
idempotency_in_progressAn equal request with this key is still running. Retry later.Wait for Retry-After, then resend the identical body with the same key.After the indicated delay.
idempotency_outcome_unknownAn earlier request may have completed, but its result could not be stored. Do not retry it automatically.Read the resource state and contact support with the request ID before deciding whether to create again.Never retry automatically.
precondition_requiredAn API-key PATCH request omitted If-Tellagen-Resource-Version.Read the resource, then send its Tellagen-Resource-Version as If-Tellagen-Resource-Version.After adding the current version.
invalid_preconditionIf-Tellagen-Resource-Version is not a positive integer.Use the positive integer version returned for this resource. Do not use an ETag or a timestamp.After correcting the header.
precondition_failedThe resource changed after the client read it.Read the resource again. Reconcile your intended change with the current state before using its new version.After reconciling the change.
rate_limitedRetry after details.retry_after_seconds or the Retry-After header.Wait for Retry-After or details.retry_after_seconds. Limit concurrency across the workspace.After the indicated delay, with the original idempotency key where supported.
internalThe server failed without exposing an internal error.Keep the request ID. Read current state before retrying a write whose outcome is uncertain.Retry reads with bounded backoff. Follow operation-specific rules for writes.
invalid_slack_channel_name_requestThe channel-name request is invalid.Use custom mode with name, or workspace_template mode without name.After correcting the request.
slack_not_configuredThe workspace has no usable Slack integration.Ask a workspace manager to connect or repair Slack.After repairing the integration.
incident_slack_channel_missingThe incident has no linked Slack channel.Link a channel through the incident workspace before requesting a rename.After linking a channel.
slack_channel_not_foundSlack cannot find the linked channel.Verify the channel still exists and that the integration can access it.After repairing channel access.
slack_channel_name_takenAnother Slack channel uses the requested name.Choose another custom name or revise the workspace naming template.After choosing an available name.
invalid_idempotency_keyThe idempotency key has an invalid length or character.Use 1–128 visible, non-space ASCII characters. A UUID is suitable.After correcting the key.
HTTP error statuses
StatusMeaning
400Bad Request — invalid input or missing required fields
401Unauthorized — missing or invalid token
403Forbidden — insufficient scope or responder access
404Not Found — resource does not exist
409Conflict — resource state prevents the request
412Precondition Failed — the supplied resource version is stale
428Precondition Required — this operation needs If-Tellagen-Resource-Version
429Too Many Requests — rate limit exceeded
500Internal Server Error

Endpoint resources

Open one resource to read its endpoint contracts.