Trend
Returns hourly or daily API metrics buckets for charts, alerting, and operational reviews. Metrics include API-key-authenticated Developer API traffic only; dashboard sessions, admin routes, hosted public flows, OAuth callbacks, inbound provider webhooks, health checks, and the metrics endpoints themselves are excluded.
Authorization
AuthorizationBearer <token>In header
Workspace API key.
Query Params
fromOptionalstring
Start timestamp in RFC3339 format. Defaults to 7 days before now.
toOptionalstring
End timestamp in RFC3339 format. Defaults to now. The maximum raw range is 90 days.
methodOptionalstring
Filter by HTTP method.
ValuesGET | POST | PUT | PATCH | DELETE
pathOptionalstring
Filter by normalized endpoint path, such as
/v1/posts/:id/publish.status_classOptionalstring
Filter by HTTP status class.
Values2xx | 3xx | 4xx | 5xx
intervalOptionalstring
Trend bucket size. Defaults to hour for ranges up to 7 days and day for longer ranges.
Valueshour | day
Response Body
200
data[]array
Hourly or daily buckets ordered oldest to newest.
data[].bucketstring
Bucket start timestamp.
data[].total_callsnumber
Total requests in the bucket.
data[].success_countnumber
Responses with status below 400.
data[].error_countnumber
All 4xx and 5xx responses in the bucket.
data[].client_error_countnumber
Responses from 400 through 499, including 429.
data[].server_error_countnumber
Responses with status 500 or higher.
data[].rate_limited_countnumber
Responses with status 429.
data[].p50_msnumber
Median latency in the bucket.
data[].p95_msnumber
95th percentile latency in the bucket.
data[].p99_msnumber
99th percentile latency in the bucket.
data[].avg_msnumber
Average latency in the bucket.
400
error.codestring
Usually "UNAUTHORIZED", "VALIDATION_ERROR", or "INTERNAL_ERROR".
error.normalized_codestring
Lowercase alias such as "unauthorized" or "validation_error".
error.messagestring
Human-readable error message.
request_idstring
Request identifier for debugging and support.
401
error.codestring
Usually "UNAUTHORIZED", "VALIDATION_ERROR", or "INTERNAL_ERROR".
error.normalized_codestring
Lowercase alias such as "unauthorized" or "validation_error".
error.messagestring
Human-readable error message.
request_idstring
Request identifier for debugging and support.
500
error.codestring
Usually "UNAUTHORIZED", "VALIDATION_ERROR", or "INTERNAL_ERROR".
error.normalized_codestring
Lowercase alias such as "unauthorized" or "validation_error".
error.messagestring
Human-readable error message.
request_idstring
Request identifier for debugging and support.
Related Endpoints
GET/v1/api-metrics/overall for aggregate totals.
GET/v1/api-metrics/summary for per-endpoint latency and error rows.
GET/v1/api-metrics/trend for hourly or daily chart buckets.
GET/v1/api-metrics/status-codes for exact status-code distribution.
Trend error_count uses the same 4xx-plus-5xx definition as error_rate_pct; 429 responses are also exposed separately through rate_limited_count.