Version v0.43 of Metabase is no longer supported. Check out the docs for the current stable version, Metabase v0.63.
Metric
/api/metric endpoints.
- DELETE /api/metric/:id
- GET /api/metric/
- GET /api/metric/:id
- GET /api/metric/:id/related
- GET /api/metric/:id/revisions
- POST /api/metric/
- POST /api/metric/:id/revert
- PUT /api/metric/:id
- PUT /api/metric/:id/important_fields
DELETE /api/metric/:id
Archive a Metric. (DEPRECATED – Just pass updated value of :archived to the PUT endpoint instead.).
PARAMS:
-
id -
revision_messagevalue must be a non-blank string.
GET /api/metric/
Fetch all Metrics.
GET /api/metric/:id
Fetch Metric with ID.
PARAMS:
id
GET /api/metric/:id/related
Return related entities.
PARAMS:
id
GET /api/metric/:id/revisions
Fetch Revisions for Metric with ID.
PARAMS:
id
POST /api/metric/
Create a new Metric.
PARAMS:
-
namevalue must be a non-blank string. -
descriptionvalue may be nil, or if non-nil, value must be a string. -
table_idvalue must be an integer greater than zero. -
definitionvalue must be a map.
POST /api/metric/:id/revert
Revert a Metric to a prior Revision.
PARAMS:
-
id -
revision_idvalue must be an integer greater than zero.
PUT /api/metric/:id
Update a Metric with ID.
PARAMS:
-
points_of_interestvalue may be nil, or if non-nil, value must be a string. -
descriptionvalue may be nil, or if non-nil, value must be a string. -
archivedvalue may be nil, or if non-nil, value must be a boolean. -
definitionvalue may be nil, or if non-nil, value must be a map. -
revision_messagevalue must be a non-blank string. -
show_in_getting_startedvalue may be nil, or if non-nil, value must be a boolean. -
namevalue may be nil, or if non-nil, value must be a non-blank string. -
caveatsvalue may be nil, or if non-nil, value must be a string. -
id -
how_is_this_calculatedvalue may be nil, or if non-nil, value must be a string.
PUT /api/metric/:id/important_fields
Update the important Fields for a Metric with ID.
(This is used for the Getting Started guide).
You must be a superuser to do this.
PARAMS:
-
id -
important_field_idsvalue must be an array. Each value must be an integer greater than zero.
Read docs for other versions of Metabase.