> ## Documentation Index
> Fetch the complete documentation index at: https://synthetiq.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Observability API

> Programmatic access to metrics, logs, and workflow data for deployed Synthetiq apps

For programmatic access, apps expose API endpoints for consuming metrics, logs, and workflow data. These are the same endpoints that power the metrics dashboard, log search, and workflows dashboard.

## Metrics endpoints

| Endpoint                      | Description                                                          |
| ----------------------------- | -------------------------------------------------------------------- |
| `metrics.timeSeries`          | Query time-series data with dimension filtering and period alignment |
| `metrics.transformTimeSeries` | Computed metrics (e.g., error rate = errors / total × 100)           |
| `metrics.listMetrics`         | Enumerate available metrics and their dimensions                     |
| `metrics.config`              | Current metrics configuration for the app                            |

## Log endpoints

| Endpoint      | Description                                                 |
| ------------- | ----------------------------------------------------------- |
| `logs.query`  | Structured log search with cursor-based pagination          |
| `logs.ingest` | Client-side event ingestion (for page views, custom events) |

## Workflow endpoints

| Endpoint                        | Description                                 |
| ------------------------------- | ------------------------------------------- |
| `workflowAdmin.getStats`        | Dashboard statistics and job trend data     |
| `workflowAdmin.getBackpressure` | Real-time queue pressure metrics            |
| `workflowAdmin.listJobs`        | Paginated job listing with status filtering |
| `workflowAdmin.getJobStatus`    | Detailed job status and step information    |
| `workflowAdmin.getStepLogs`     | Step execution logs and retry attempts      |
| `workflowAdmin.queryResults`    | Query workflow output tables                |
| `workflowAdmin.listSchedules`   | Scheduled workflow management               |
| `workflowAdmin.listWorkers`     | Active worker status and capacity           |

## Authentication

Metrics and log endpoints require the `logs:view` scope. Workflow endpoints require the `workflows:admin` scope. All requests are authenticated via the app's standard authentication.
