patch
https://api.doit.com/analytics/v1/custom-metrics/
Changes the fields in the body and leaves the others as they are
(JSON Merge Patch, RFC 7396). Requires the
analytics:calculatedMetrics entitlement and a metrics write
permission, and the caller must own the metric, be an editor of it,
or the metric must be editable by everyone. Send the metric's etag
in If-Match.
- A field you leave out is not changed.
variablesreplaces the whole list, and the letters follow the
new order. The formula must still name only defined letters, so
sendformulatoo when the number or order of variables changes.decimalssets both bounds: sendminandmaxtogether.
decimals: nullremoves the display precision.- Every other field rejects
null. Senddescription: ""to clear
the description.
With dryRun=true, the response is the metric as it would be after
the update, and nothing is written.
Errors (RFC 9457 Problem Details, code field):
400 validation_failed: an empty body, or the updated metric
breaks a rule.detailsuses the samefieldpaths andissue
values ascreateCustomMetric.400 idempotency_key_required: noIdempotency-Keyheader.400 tenant_id_required: a caller with access to more than one
customer sent noX-Tenant-Id.403 analytics.feature_not_entitled: the customer does not have
the calculated metrics entitlement.403 analytics.custom_metric_not_owner: the caller may not edit this
metric.403 forbidden: no metrics write permission, a read-only token,
or anX-Tenant-Idthat the credential cannot access.404 not_found: no custom metric with this id for the customer.409 analytics.custom_metric_modified: another request changed the
metric while this one was running. Retryable: read the metric
again, then retry.409 idempotency_request_in_progress: a request with the same
Idempotency-Keyis still running. Retry with backoff.412 precondition_failed:If-Matchdoes not match the current
etag. Read the metric again, then retry.422 idempotency_key_reused: theIdempotency-Keywas used with
a different body.428 precondition_required: noIf-Matchheader.503 service_unavailable: the customer's extended metrics could
not be checked, or anextendedkey is missing while part of the
data that decides the list could not be read. The key is not
rejected: retry afterRetry-Afterseconds.
Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…