Version v0.43 of Metabase is no longer supported. Check out the docs for the current stable version, Metabase v0.63.
Table
/api/table endpoints.
- GET /api/table/
- GET /api/table/:id
- GET /api/table/:id/fks
- GET /api/table/:id/query_metadata
- GET /api/table/:id/related
- GET /api/table/card__:id/fks
- GET /api/table/card__:id/query_metadata
- POST /api/table/:id/discard_values
- POST /api/table/:id/rescan_values
- PUT /api/table/
- PUT /api/table/:id
- PUT /api/table/:id/fields/order
GET /api/table/
Get all Tables.
GET /api/table/:id
Get Table with ID.
PARAMS:
id
GET /api/table/:id/fks
Get all foreign keys whose destination is a Field that belongs to this Table.
PARAMS:
id
GET /api/table/:id/query_metadata
Get metadata about a Table useful for running queries.
Returns DB, fields, field FKs, and field values.
Passing include_hidden_fields=true will include any hidden Fields in the response. Defaults to false
Passing include_sensitive_fields=true will include any sensitive Fields in the response. Defaults to false.
These options are provided for use in the Admin Edit Metadata page.
PARAMS:
-
id -
include_sensitive_fieldsvalue may be nil, or if non-nil, value must be a valid boolean string (‘true’ or ‘false’). -
include_hidden_fieldsvalue may be nil, or if non-nil, value must be a valid boolean string (‘true’ or ‘false’).
GET /api/table/:id/related
Return related entities.
PARAMS:
id
GET /api/table/card__:id/fks
Return FK info for the ‘virtual’ table for a Card. This is always empty, so this endpoint serves mainly as a placeholder to avoid having to change anything on the frontend.
GET /api/table/card__:id/query_metadata
Return metadata for the ‘virtual’ table for a Card.
PARAMS:
id
POST /api/table/:id/discard_values
Discard the FieldValues belonging to the Fields in this Table. Only applies to fields that have FieldValues. If this Table’s Database is set up to automatically sync FieldValues, they will be recreated during the next cycle.
PARAMS:
id
POST /api/table/:id/rescan_values
Manually trigger an update for the FieldValues for the Fields belonging to this Table. Only applies to Fields that are eligible for FieldValues.
PARAMS:
id
PUT /api/table/
Update all Table in ids.
PARAMS:
-
idsvalue must be an array. Each value must be an integer greater than zero. The array cannot be empty. -
display_namevalue may be nil, or if non-nil, value must be a non-blank string. -
entity_typevalue may be nil, or if non-nil, value must be a valid entity type (keyword or string). -
visibility_typevalue may be nil, or if non-nil, value must be one of:cruft,hidden,technical. -
descriptionvalue may be nil, or if non-nil, value must be a string. -
caveatsvalue may be nil, or if non-nil, value must be a string. -
points_of_interestvalue may be nil, or if non-nil, value must be a string. -
show_in_getting_startedvalue may be nil, or if non-nil, value must be a boolean.
PUT /api/table/:id
Update Table with ID.
PARAMS:
-
visibility_typevalue may be nil, or if non-nil, value must be one of:cruft,hidden,technical. -
field_ordervalue may be nil, or if non-nil, value must be one of:alphabetical,custom,database,smart. -
display_namevalue may be nil, or if non-nil, value must be a non-blank string. -
points_of_interestvalue may be nil, or if non-nil, value must be a string. -
entity_typevalue may be nil, or if non-nil, value must be a valid entity type (keyword or string). -
descriptionvalue may be nil, or if non-nil, value must be a string. -
show_in_getting_startedvalue may be nil, or if non-nil, value must be a boolean. -
caveatsvalue may be nil, or if non-nil, value must be a string. -
id
PUT /api/table/:id/fields/order
Reorder fields.
PARAMS:
-
id -
field_ordervalue must be an array. Each value must be an integer greater than zero.
Read docs for other versions of Metabase.