Metrics
Live KPIs, historical series, published snapshots, and metric preferences.
- Audience
- Developer
- Truth
- Mixed sources
- Surface
- API
- Status
- Active
Related documentation: Developer documentation
Authorization
BearerAuth API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Query Parameters
UUID of the company. Alternatively, pass as X-Company-Id request header.
uuidOnly the latest live actuals are available on this endpoint. Use /api/metrics/series for history.
"current""current"Header Parameters
Company UUID. Alternative to the companyId query parameter.
uuidResponse Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/company/metrics?companyId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"metrics": {
"mrr": 0,
"arr": 0,
"runway": 0,
"headcount": 0,
"customer_count": 0,
"churn_rate": 0,
"mrr_growth": 0,
"burn": 0,
"nrr": 0,
"ltv": 0,
"cac": 0,
"ltv_cac_ratio": 0,
"property1": 0,
"property2": 0
},
"source": "company_metrics_actual",
"mode": "live_actual",
"currency": "string",
"periodKey": "string",
"period": "string",
"asOf": "2019-08-24T14:15:22Z"
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}Authorization
BearerAuth API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Query Parameters
Optional authorized company override. Otherwise the company bound to the OAuth session or API key is used.
uuidHeader Parameters
Company UUID. Alternative to the companyId query parameter.
uuidResponse Body
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/metrics/catalog"{
"companyId": "8bb73d03-06b4-47c7-80c7-59301f770eda",
"currency": "string",
"sourceBoundary": "company_internal",
"definitions": [
{
"metricId": "string",
"label": "string",
"unit": "string",
"unitLabel": "string",
"cadence": "string",
"aggregation": "string",
"valueSemantics": "string",
"direction": "string",
"description": "string",
"custom": true,
"archived": true
}
]
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Query Parameters
UUID of the company. Alternatively, pass as X-Company-Id request header.
uuidHeader Parameters
Company UUID. Alternative to the companyId query parameter.
uuidResponse Body
application/json
application/json
curl -X GET "https://example.com/api/metrics/grants?companyId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"grants": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"company_id": "b2e6a1c3-1a5e-44ae-a8fd-81f76fd715cf",
"granted_by": "a8e4a498-f971-4203-a849-4967743579d4",
"recipient_company_id": "ba825776-f958-472b-98bb-035551940fe9",
"recipient_user_id": "771fbdeb-44ee-40ed-804a-b56382184d65",
"scope": [
"metrics"
],
"metric_ids": [
"string"
],
"include_historical": true,
"status": "active",
"note": "string",
"expires_at": "2019-08-24T14:15:22Z",
"revoked_at": "2019-08-24T14:15:22Z",
"revoked_by": "609d09bf-be33-45e0-963a-ff4cf608e85c",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
]
}{
"error": "string",
"status": 0,
"details": {}
}API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/metrics/grants" \ -H "Content-Type: application/json" \ -d '{ "companyId": "8bb73d03-06b4-47c7-80c7-59301f770eda", "scope": [ "metrics" ] }'{
"grant": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"company_id": "b2e6a1c3-1a5e-44ae-a8fd-81f76fd715cf",
"granted_by": "a8e4a498-f971-4203-a849-4967743579d4",
"recipient_company_id": "ba825776-f958-472b-98bb-035551940fe9",
"recipient_user_id": "771fbdeb-44ee-40ed-804a-b56382184d65",
"scope": [
"metrics"
],
"metric_ids": [
"string"
],
"include_historical": true,
"status": "active",
"note": "string",
"expires_at": "2019-08-24T14:15:22Z",
"revoked_at": "2019-08-24T14:15:22Z",
"revoked_by": "609d09bf-be33-45e0-963a-ff4cf608e85c",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Path Parameters
UUID of the grant to revoke.
uuidQuery Parameters
UUID of the company. Alternatively, pass as X-Company-Id request header.
uuidHeader Parameters
Company UUID. Alternative to the companyId query parameter.
uuidResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/api/metrics/grants/497f6eca-6276-4993-bfeb-53cbbbba6f08/revoke?companyId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"grant": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"company_id": "b2e6a1c3-1a5e-44ae-a8fd-81f76fd715cf",
"granted_by": "a8e4a498-f971-4203-a849-4967743579d4",
"recipient_company_id": "ba825776-f958-472b-98bb-035551940fe9",
"recipient_user_id": "771fbdeb-44ee-40ed-804a-b56382184d65",
"scope": [
"metrics"
],
"metric_ids": [
"string"
],
"include_historical": true,
"status": "active",
"note": "string",
"expires_at": "2019-08-24T14:15:22Z",
"revoked_at": "2019-08-24T14:15:22Z",
"revoked_by": "609d09bf-be33-45e0-963a-ff4cf608e85c",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}Authorization
SessionCookie Authenticated Operalta web session Cookie header. In practice this usually contains sb-<project-ref>-auth-token=... and may include chunked siblings; use the full Cookie header copied from a logged-in browser session.
In: header
Query Parameters
UUID of the VC company whose display preferences to read.
uuidResponse Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/metrics/preferences?vcCompanyId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"preferences": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"vcCompanyId": "6aa49b58-8c9c-4df8-9a0b-8a74a1560b94",
"requestedMetrics": [
"string"
],
"tableColumns": [
"string"
],
"cardPages": [
{
"id": "string",
"title": "string",
"metricIds": [
"string"
]
}
],
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}Authorization
SessionCookie Authenticated Operalta web session Cookie header. In practice this usually contains sb-<project-ref>-auth-token=... and may include chunked siblings; use the full Cookie header copied from a logged-in browser session.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/api/metrics/preferences" \ -H "Content-Type: application/json" \ -d '{ "vcCompanyId": "6aa49b58-8c9c-4df8-9a0b-8a74a1560b94" }'{
"preferences": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"vcCompanyId": "6aa49b58-8c9c-4df8-9a0b-8a74a1560b94",
"requestedMetrics": [
"string"
],
"tableColumns": [
"string"
],
"cardPages": [
{
"id": "string",
"title": "string",
"metricIds": [
"string"
]
}
],
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}Authorization
BearerAuth API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Path Parameters
UUID of the company whose published metrics to read.
uuidQuery Parameters
Optional exact published month or quarter. Requires a grant with historical access. When omitted, returns the latest allowed publication or historical set based on the grant.
^\d{4}-(?:(?:0[1-9]|1[0-2])|[qQ][1-4])$Inclusive lower bound for available publications. Requires a grant with historical access.
^\d{4}(?:-(?:0[1-9]|1[0-2]|[qQ][1-4]))?$Inclusive upper bound for available publications. Requires a grant with historical access.
^\d{4}(?:-(?:0[1-9]|1[0-2]|[qQ][1-4]))?$Maximum published periods returned in one page.
241 <= value <= 100Opaque nextCursor from a previous response. Keep the same company, period bounds, and grant context.
length <= 500Response Body
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/metrics/published/497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"grantId": "4eda52b3-a1b8-4aae-b545-9c8c3c9c7709",
"scope": [
"string"
],
"expiresAt": "2019-08-24T14:15:22Z",
"mode": "published_grant",
"source": "report_metric_snapshots",
"sourceBoundary": "published_snapshot",
"missingPublication": true,
"company": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string",
"vertical": "string",
"stage": "string",
"currency": "string"
},
"metrics": {
"summary": {},
"periods": [
{
"periodKey": "string",
"periodType": "string",
"reportId": "836df459-dc40-4aa1-972a-6eb0a864dff9",
"versionNumber": 0,
"sentAt": "2019-08-24T14:15:22Z",
"data": {},
"units": {
"property1": "string",
"property2": "string"
},
"unitLabels": {
"property1": "string",
"property2": "string"
},
"currency": "string"
}
]
},
"publication": {
"reportId": "836df459-dc40-4aa1-972a-6eb0a864dff9",
"periodKey": "string",
"versionNumber": 0,
"sentAt": "2019-08-24T14:15:22Z",
"shareToken": "string",
"viewerPolicy": {}
},
"truncated": true,
"nextCursor": "string"
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}Authorization
BearerAuth API key obtained from Operalta Settings → API Keys. Format: op_xxxxx. Pass as Authorization: Bearer op_....
In: header
Query Parameters
Optional authorized company override. Otherwise the company bound to the OAuth session or API key is used.
uuidComma-separated metric versions: actual, budget, and/or forecast. Actuals are stored and available only at month grain and require metrics.actuals:read; plans require metrics.plans:read.
"actual"Optional comma-separated canonical or company-defined metric identifiers. At most 50.
Inclusive lower period bound matching periodType.
^\d{4}(?:-(?:0[1-9]|1[0-2])|-Q[1-4])?$Inclusive upper period bound matching periodType. A bounded window cannot exceed 60 periods.
^\d{4}(?:-(?:0[1-9]|1[0-2])|-Q[1-4])?$Single storage grain for this request. Requests containing actual must use month; quarter and year are available for budget and forecast data.
"month" | "quarter" | "year""desc""asc" | "desc"Maximum logical metric rows returned in this page.
241 <= value <= 100Opaque nextCursor from a previous response with the same periodType, order, versions, metric IDs, and period bounds.
length <= 500Header Parameters
Company UUID. Alternative to the companyId query parameter.
uuidResponse Body
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/metrics/series?periodType=month"{
"companyId": "8bb73d03-06b4-47c7-80c7-59301f770eda",
"currency": "string",
"sourceBoundary": "company_internal",
"query": {
"metricIds": [
"string"
],
"fromPeriod": "string",
"toPeriod": "string",
"periodType": "month",
"versions": [
"actual"
],
"order": "asc",
"limit": 0
},
"items": [
{
"periodKey": "string",
"periodType": "month",
"version": "actual",
"metrics": {
"property1": 0,
"property2": 0
},
"source": "string",
"updatedAt": "2019-08-24T14:15:22Z"
}
],
"observations": [
{
"metricId": "string",
"value": 0,
"unit": "string",
"currency": "string",
"periodKey": "string",
"periodType": "month",
"version": "actual",
"sourceBoundary": "company_internal",
"source": "string",
"updatedAt": "2019-08-24T14:15:22Z"
}
],
"nextCursor": "string",
"truncated": true
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}{
"error": "string",
"status": 0,
"details": {}
}