Skip to content

Publish a new immutable metric version (optionally trigger backfill)

Auth: session ADMIN role, or ApiKeyAuth with scope metrics:write.

projectId
required
string
metricId
required
string
Media typeapplication/json
object
aggregationJson
required

JSON-encoded MetricAggregationDSL (re-validated).

string
>= 2 characters
triggerBackfill
boolean
backfillFrom

Unix ms.

integer
>= 1
backfillTo

Unix ms.

integer
>= 1
backfillSource

Explicit data source override; when omitted, auto-selected by lake coverage (ae never auto-selected).

string
Allowed values: lake transactions ae

{ version, created, backfillJob? }

Media typeapplication/json
object
key
additional properties
any

Validation / bad aggregationJson / DSL invalid

Media typeapplication/json

Validation error envelope (Zod). issues/details present on schema failures.

object
error
required
string
issues
Array<object>
object
key
additional properties
any
details
Array<object>
object
key
additional properties
any
Examplegenerated
json
{
"error": "example",
"issues": [
{}
],
"details": [
{}
]
}

Publish_failed

Media typeapplication/json
object
error
string
detail
string
Examplegenerated
json
{
"error": "example",
"detail": "example"
}