Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Auto-update documentation for master (#69048)

github-automation-metabase8d5a4f68047c
diff --git a/docs/api.json b/docs/api.json
index 28718469a2e..d88479ff58e 100644
--- a/docs/api.json
+++ b/docs/api.json
@@ -1147,6 +1147,29 @@
"$ref" : "#/components/schemas/metabase-enterprise.action-v2.api.api-action-expression"
} ]
},
+ "metabase-enterprise.agent-api.api.column-metadata" : {
+ "description" : "Metadata for a single result column.",
+ "type" : "object",
+ "properties" : {
+ "base_type" : {
+ "type" : "string"
+ },
+ "display_name" : {
+ "type" : "string"
+ },
+ "effective_type" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "name", "base_type", "display_name" ]
+ },
"metabase-enterprise.agent-api.api.construct-query-metric-request" : {
"description" : "Request schema for constructing a query from a metric.\n Only supports filters and group_by (aggregation is defined by the metric).",
"allOf" : [ {
@@ -1296,6 +1319,45 @@
},
"required" : [ "query" ]
},
+ "metabase-enterprise.agent-api.api.execute-query-response" : {
+ "description" : "Response from query execution. The HTTP status is always 202 because results are streamed —\n check the `status` field to determine success or failure.",
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "object",
+ "properties" : {
+ "cols" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.column-metadata"
+ }
+ },
+ "rows" : {
+ "type" : "array",
+ "items" : {
+ "type" : "array",
+ "items" : { }
+ }
+ }
+ },
+ "required" : [ "cols", "rows" ]
+ },
+ "error" : {
+ "type" : "string"
+ },
+ "row_count" : {
+ "type" : "integer"
+ },
+ "running_time" : {
+ "type" : "integer"
+ },
+ "status" : {
+ "type" : "string",
+ "enum" : [ "completed", "failed" ]
+ }
+ },
+ "required" : [ "status" ]
+ },
"metabase-enterprise.agent-api.api.field" : {
"description" : "A field from a table or metric. The field_id format is '<prefix><entity-id>-<field-index>' where prefix indicates the source (t=table, c=metric) and index is the position in the entity's fields.",
"type" : "object",
@@ -1378,6 +1440,33 @@
}
}
},
+ "metabase-enterprise.agent-api.api.measure" : {
+ "description" : "A reusable aggregation expression associated with a table. Reference via measure_id in the aggregations array.",
+ "type" : "object",
+ "properties" : {
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display_name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "type" : "integer"
+ },
+ "name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "id", "name" ]
+ },
"metabase-enterprise.agent-api.api.metric" : {
"description" : "A metric with its queryable dimensions and segments. The default_time_dimension_field_id is the field_id of the recommended time dimension for temporal breakouts.",
"type" : "object",
@@ -1814,6 +1903,16 @@
"type" : "null"
} ]
},
+ "measures" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.measure"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
"description" : {
"oneOf" : [ {
"type" : "string"
@@ -2682,8 +2781,10 @@
"additionalProperties" : { }
},
"metabase-enterprise.metabot-v3.tools.api.aggregation" : {
- "description" : "Aggregation - either field-based or measure-based.",
+ "description" : "Aggregation — count (field optional), field-based (field required), or measure-based.",
"anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.count-aggregation"
+ }, {
"$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.field-aggregation"
}, {
"$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.measure-aggregation"
@@ -2970,6 +3071,32 @@
"metabase-enterprise.metabot-v3.tools.api.count" : {
"type" : "integer"
},
+ "metabase-enterprise.metabot-v3.tools.api.count-aggregation" : {
+ "description" : "Count aggregation — counts rows, no field_id needed.\n Use sort_order to order results by this aggregation ('asc' or 'desc').",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "bucket" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.bucket"
+ },
+ "function" : {
+ "const" : "count"
+ },
+ "sort_order" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "asc", "desc" ]
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "function" ]
+ }, {
+ "type" : "object",
+ "properties" : { }
+ } ]
+ },
"metabase-enterprise.metabot-v3.tools.api.create-dashboard-subscription-arguments" : {
"allOf" : [ {
"type" : "object",
@@ -2999,7 +3126,7 @@
},
"operation" : {
"type" : "string",
- "enum" : [ "equals", "not-equals", "number-equals", "number-not-equals" ]
+ "enum" : [ "equals", "not-equals" ]
},
"values" : {
"type" : "array",
@@ -3133,7 +3260,7 @@
} ]
},
"metabase-enterprise.metabot-v3.tools.api.field-aggregation" : {
- "description" : "Aggregation using a field and function.\n\n - field_id: Required. For 'count', any valid field_id can be provided (the value is ignored since count operates on rows).\n - function: The aggregation function to apply.\n - sort_order: Optional. Use this to order results by this aggregation ('asc' or 'desc').\n This is the correct way to sort by aggregation results - do NOT use order_by for aggregations.",
+ "description" : "Aggregation using a field and function. field_id is required.\n Use sort_order to order results by this aggregation ('asc' or 'desc').",
"allOf" : [ {
"type" : "object",
"properties" : {
@@ -3145,7 +3272,7 @@
},
"function" : {
"type" : "string",
- "enum" : [ "avg", "count", "count-distinct", "max", "min", "sum" ]
+ "enum" : [ "avg", "count-distinct", "max", "min", "sum" ]
},
"sort_order" : {
"oneOf" : [ {
@@ -4314,7 +4441,7 @@
},
"operation" : {
"type" : "string",
- "enum" : [ "equals", "not-equals", "greater-than", "greater-than-or-equal", "less-than", "less-than-or-equal", "number-equals", "number-not-equals", "number-greater-than", "number-greater-than-or-equal", "number-less-than", "number-less-than-or-equal" ]
+ "enum" : [ "equals", "not-equals", "greater-than", "greater-than-or-equal", "less-than", "less-than-or-equal" ]
},
"value" : {
"anyOf" : [ {
@@ -4909,7 +5036,7 @@
},
"operation" : {
"type" : "string",
- "enum" : [ "equals", "not-equals", "string-equals", "string-not-equals", "string-contains", "string-not-contains", "string-starts-with", "string-ends-with" ]
+ "enum" : [ "equals", "not-equals", "string-contains", "string-not-contains", "string-starts-with", "string-ends-with" ]
},
"value" : {
"type" : "string"
@@ -5084,7 +5211,7 @@
},
"operation" : {
"type" : "string",
- "enum" : [ "equals", "not-equals", "greater-than", "greater-than-or-equal", "less-than", "less-than-or-equal", "date-equals", "date-not-equals", "date-before", "date-on-or-before", "date-after", "date-on-or-after" ]
+ "enum" : [ "equals", "not-equals", "greater-than", "greater-than-or-equal", "less-than", "less-than-or-equal" ]
},
"value" : {
"anyOf" : [ {
@@ -5422,7 +5549,7 @@
"type" : "string"
},
"schema" : {
- "anyOf" : [ {
+ "oneOf" : [ {
"type" : "string",
"minLength" : 1
}, {
@@ -5448,7 +5575,7 @@
"type" : "string"
},
"schema" : {
- "anyOf" : [ {
+ "oneOf" : [ {
"type" : "string",
"minLength" : 1
}, {
@@ -5538,2570 +5665,2913 @@
"$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.table-incremental-target"
} ]
},
- "metabase.actions.schema..action.for-insert" : {
- "description" : "Schema for inserting a new Action (REST API or internally).",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "archived" : {
- "type" : "boolean"
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "model_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- },
- "name" : {
- "type" : "string"
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
- },
- "type" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.type"
- },
- "visualization_settings" : {
- "oneOf" : [ {
- "type" : "object"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "name", "type", "model_id" ]
- }, {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
- }, {
- "type" : "object",
- "properties" : { }
- } ]
- } ]
- },
- "metabase.actions.schema..action.for-update" : {
- "description" : "Schema for updating an Action (REST API or internally).",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "visualization_settings" : {
- "oneOf" : [ {
- "type" : "object"
- }, {
- "type" : "null"
- } ]
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
- },
- "name" : {
- "type" : "string"
- },
- "archived" : {
- "type" : "boolean"
- },
- "type" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.type"
- },
- "model_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- },
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- }
+ "metabase-enterprise.workspaces.api.appdb-or-ref-id" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
}, {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
- }, {
- "type" : "object",
- "properties" : { }
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
} ]
},
- "metabase.actions.schema..http-action.json-query" : {
- "description" : "must be a valid json-query, something like '.item.title'",
- "type" : "string"
- },
- "metabase.actions.schema..http-action.template" : {
+ "metabase-enterprise.workspaces.api.graph-edge" : {
"type" : "object",
"properties" : {
- "body" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "from_entity_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.appdb-or-ref-id"
},
- "headers" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "from_entity_type" : {
+ "type" : "string"
},
- "method" : {
- "type" : "string",
- "enum" : [ "GET", "POST", "PUT", "DELETE", "PATCH" ]
+ "to_entity_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.appdb-or-ref-id"
},
- "parameters" : {
+ "to_entity_type" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "from_entity_id", "from_entity_type", "to_entity_id", "to_entity_type" ]
+ },
+ "metabase-enterprise.workspaces.api.graph-node" : {
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "dependents_count" : {
+ "type" : "object",
+ "additionalProperties" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.appdb-or-ref-id"
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "input-table", "external-transform", "workspace-transform" ]
+ }
+ },
+ "required" : [ "id", "type", "dependents_count", "data" ]
+ },
+ "metabase-enterprise.workspaces.api.graph-node-type" : {
+ "type" : "string",
+ "enum" : [ "input-table", "external-transform", "workspace-transform" ]
+ },
+ "metabase-enterprise.workspaces.api.input-table" : {
+ "type" : "object",
+ "properties" : {
+ "db_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "schema" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "url" : {
+ "table" : {
"type" : "string"
+ },
+ "table_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "method", "url" ],
- "additionalProperties" : false
+ "required" : [ "db_id", "schema", "table", "table_id" ]
},
- "metabase.actions.schema..implicit-action.kind" : {
- "description" : "Unsupported implicit action kind",
+ "metabase-enterprise.workspaces.api.output-table" : {
+ "type" : "object",
+ "properties" : {
+ "db_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "global" : {
+ "type" : "object",
+ "properties" : {
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "table" : {
+ "type" : "string"
+ },
+ "table_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "transform_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "transform_id", "schema", "table", "table_id" ]
+ },
+ "isolated" : {
+ "type" : "object",
+ "properties" : {
+ "schema" : {
+ "type" : "string"
+ },
+ "table" : {
+ "type" : "string"
+ },
+ "table_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "transform_id" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }, {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ } ]
+ }
+ },
+ "required" : [ "transform_id", "schema", "table", "table_id" ]
+ }
+ },
+ "required" : [ "db_id", "global", "isolated" ]
+ },
+ "metabase-enterprise.workspaces.api.status" : {
"type" : "string",
- "enum" : [ "row/create", "row/update", "row/delete", "bulk/create", "bulk/update", "bulk/delete" ]
+ "enum" : [ "archived", "ready", "broken", "pending", "uninitialized" ]
},
- "metabase.actions.schema.action" : {
- "description" : "An Action as it should appear when we `SELECT` it from the app DB.",
- "allOf" : [ {
+ "metabase-enterprise.workspaces.api.transform-source" : {
+ "oneOf" : [ {
"type" : "object",
"properties" : {
- "visualization_settings" : {
- "oneOf" : [ {
- "type" : "object"
- }, {
- "type" : "null"
- } ]
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
- },
- "made_public_by_id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.user"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string"
- },
- "archived" : {
- "type" : "boolean"
+ "query" : {
+ "$ref" : "#/components/schemas/metabase.queries.schema.query"
},
- "updated_at" : { },
"type" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.type"
- },
- "created_at" : { },
- "public_uuid" : {
- "oneOf" : [ {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- }, {
- "type" : "null"
- } ]
- },
- "model_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ "const" : "query"
+ }
+ },
+ "required" : [ "type", "query" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "body" : {
+ "type" : "string"
},
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
+ "source-database" : {
+ "type" : "integer"
},
- "creator_id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.user"
- }, {
- "type" : "null"
- } ]
+ "source-tables" : {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "integer"
+ }
},
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "type" : {
+ "const" : "python"
}
},
- "required" : [ "id" ]
- }, {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
- }, {
- "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
- }, {
- "type" : "object",
- "properties" : { }
- } ]
+ "required" : [ "source-tables", "type", "body" ],
+ "additionalProperties" : false
} ]
},
- "metabase.actions.schema.http-action" : {
+ "metabase-enterprise.workspaces.api.transform-target" : {
"type" : "object",
"properties" : {
- "error_handle" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema..http-action.json-query"
- }, {
- "type" : "null"
- } ]
+ "database" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "response_handle" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema..http-action.json-query"
- }, {
- "type" : "null"
- } ]
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
},
- "template" : {
+ "schema" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema..http-action.template"
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "table" ]
}
- }
+ },
+ "required" : [ "type", "name" ],
+ "additionalProperties" : false
},
- "metabase.actions.schema.id" : {
- "description" : "Valid Action ID",
+ "metabase-enterprise.workspaces.types.appdb-id" : {
+ "description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
},
- "metabase.actions.schema.implicit-action" : {
+ "metabase-enterprise.workspaces.types.dry-run-result" : {
+ "description" : "Result of a transform dry-run (preview without persisting).\n Data is nested under :data to match /api/dataset response format.",
"type" : "object",
"properties" : {
- "kind" : {
+ "data" : {
+ "type" : "object",
+ "properties" : {
+ "cols" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "results_metadata" : {
+ "type" : "object",
+ "properties" : {
+ "columns" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : { }
+ }
+ }
+ }
+ },
+ "rows" : {
+ "type" : "array",
+ "items" : { }
+ }
+ }
+ },
+ "message" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.actions.schema..implicit-action.kind"
+ "type" : "string"
}, {
"type" : "null"
} ]
+ },
+ "status" : {
+ "type" : "string",
+ "enum" : [ "succeeded", "failed" ]
}
- }
+ },
+ "required" : [ "status" ]
},
- "metabase.actions.schema.query-action" : {
+ "metabase-enterprise.workspaces.types.execution-result" : {
"type" : "object",
"properties" : {
- "database_id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- }, {
+ "end_time" : {
+ "oneOf" : [ { }, {
"type" : "null"
} ]
},
- "dataset_query" : {
+ "message" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema.query"
+ "type" : "string"
}, {
"type" : "null"
} ]
- }
- }
- },
- "metabase.actions.schema.type" : {
- "description" : "Unsupported action type",
- "type" : "string",
- "enum" : [ "http", "implicit", "query" ]
- },
- "metabase.actions.types..scope.raw" : {
- "anyOf" : [ {
- "type" : "object",
- "properties" : {
- "dashboard-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
},
- "required" : [ "dashboard-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "dashcard-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "start_time" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
},
- "required" : [ "dashcard-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "card-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "status" : {
+ "type" : "string",
+ "enum" : [ "succeeded", "failed" ]
},
- "required" : [ "card-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "model-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "table" : {
+ "type" : "object",
+ "properties" : {
+ "name" : {
+ "type" : "string"
+ },
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "name" ]
+ }
+ },
+ "required" : [ "status", "table" ]
+ },
+ "metabase-enterprise.workspaces.types.problem" : {
+ "description" : "A problem detected during workspace validation.",
+ "type" : "object",
+ "properties" : {
+ "block_merge" : {
+ "type" : "boolean"
},
- "required" : [ "model-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "table-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "category" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.problem-category"
},
- "required" : [ "table-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "webhook-id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "data" : {
+ "type" : "object",
+ "properties" : { }
},
- "required" : [ "webhook-id" ]
- }, {
- "type" : "object",
- "properties" : {
- "unknown" : {
- "type" : "string",
- "enum" : [ "model-action" ]
- }
+ "problem" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.problem-name"
},
- "required" : [ "unknown" ]
- } ]
- },
- "metabase.analyze.query-results.ResultsMetadata" : {
- "description" : "value must be an array of valid results column metadata maps.",
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
+ "severity" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.severity"
}
- }, {
- "type" : "null"
- } ]
- },
- "metabase.api-keys.schema..key.masked" : {
- "description" : "Masked string like 'mb_1234**********'.",
- "allOf" : [ {
- "$ref" : "#/components/schemas/metabase.api-keys.schema..key.raw"
- }, {
- "type" : "string",
- "pattern" : "^mb_.*{4}\\*+$"
- } ]
+ },
+ "required" : [ "category", "problem", "severity", "block_merge", "data" ]
},
- "metabase.api-keys.schema..key.raw" : {
- "description" : "Unhashed string of the form 'mb_<base-64-bytes>'.",
+ "metabase-enterprise.workspaces.types.problem-category" : {
"type" : "string",
- "minLength" : 12,
- "maxLength" : 254
- },
- "metabase.api-keys.schema.id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "enum" : [ "external", "external-downstream", "unused", "internal", "internal-downstream" ]
},
- "metabase.api-keys.schema.name" : {
+ "metabase-enterprise.workspaces.types.problem-name" : {
"type" : "string",
- "minLength" : 1,
- "maxLength" : 254
+ "enum" : [ "target-conflict", "not-run", "stale", "cycle", "failed", "removed-table", "removed-field" ]
},
- "metabase.api-keys.schema.prefix" : {
- "description" : "Prefix string of an API Key, suitable for passing around unmasked. This must be unique.",
+ "metabase-enterprise.workspaces.types.ref-id" : {
"type" : "string",
- "minLength" : 7,
- "maxLength" : 7
- },
- "metabase.cache.api..cache-strategy.base.ee" : {
- "type" : "object",
- "properties" : {
- "type" : {
- "type" : "string",
- "enum" : [ "nocache", "ttl", "duration", "schedule" ]
- }
- },
- "required" : [ "type" ]
+ "minLength" : 1
},
- "metabase.cache.api..cache-strategy.base.oss" : {
- "type" : "object",
- "properties" : {
- "type" : {
- "type" : "string",
- "enum" : [ "nocache", "ttl" ]
- }
- },
- "required" : [ "type" ]
+ "metabase-enterprise.workspaces.types.severity" : {
+ "type" : "string",
+ "enum" : [ "error", "warning", "info" ]
},
- "metabase.cache.api..cache-strategy.ee" : {
- "description" : "Schema for a caching strategy in EE when we have an premium token with `:cache-granular-controls`.",
+ "metabase.actions.schema..action.for-insert" : {
+ "description" : "Schema for inserting a new Action (REST API or internally).",
"allOf" : [ {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.base.ee"
+ "type" : "object",
+ "properties" : {
+ "archived" : {
+ "type" : "boolean"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "model_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.type"
+ },
+ "visualization_settings" : {
+ "oneOf" : [ {
+ "type" : "object"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "name", "type", "model_id" ]
}, {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.nocache"
+ "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
}, {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ttl"
+ "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
}, {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee.duration"
+ "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
}, {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee.schedule"
+ "type" : "object",
+ "properties" : { }
} ]
} ]
},
- "metabase.cache.api..cache-strategy.ee.duration" : {
- "type" : "object",
- "properties" : {
- "duration" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "refresh_automatically" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "type" : {
- "const" : "duration"
- },
- "unit" : {
- "type" : "string",
- "enum" : [ "hours", "minutes", "seconds", "days" ]
- }
- },
- "required" : [ "type", "duration", "unit" ],
- "additionalProperties" : false
- },
- "metabase.cache.api..cache-strategy.ee.schedule" : {
- "type" : "object",
- "properties" : {
- "refresh_automatically" : {
- "oneOf" : [ {
+ "metabase.actions.schema..action.for-update" : {
+ "description" : "Schema for updating an Action (REST API or internally).",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "visualization_settings" : {
+ "oneOf" : [ {
+ "type" : "object"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "archived" : {
"type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "schedule" : {
- "$ref" : "#/components/schemas/metabase.util.cron.CronScheduleString"
- },
- "type" : {
- "const" : "schedule"
- }
- },
- "required" : [ "type", "schedule" ],
- "additionalProperties" : false
- },
- "metabase.cache.api..cache-strategy.nocache" : {
- "type" : "object",
- "properties" : {
- "type" : {
- "const" : "nocache"
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.type"
+ },
+ "model_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
}
- },
- "required" : [ "type" ]
- },
- "metabase.cache.api..cache-strategy.oss" : {
- "description" : "Schema for a caching strategy (OSS)",
- "allOf" : [ {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.base.oss"
}, {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.nocache"
+ "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
}, {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ttl"
+ "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
+ }, {
+ "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
+ }, {
+ "type" : "object",
+ "properties" : { }
} ]
} ]
},
- "metabase.cache.api..cache-strategy.ttl" : {
- "type" : "object",
- "properties" : {
- "min_duration_ms" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "multiplier" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "type" : {
- "const" : "ttl"
- }
- },
- "required" : [ "type", "multiplier", "min_duration_ms" ],
- "additionalProperties" : false
- },
- "metabase.cache.api.cache-strategy" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee"
- }, {
- "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.oss"
- } ]
+ "metabase.actions.schema..http-action.json-query" : {
+ "description" : "must be a valid json-query, something like '.item.title'",
+ "type" : "string"
},
- "metabase.channel.models.channel.Channel" : {
- "description" : "Channel schema.",
+ "metabase.actions.schema..http-action.template" : {
"type" : "object",
"properties" : {
- "active" : {
- "type" : "boolean"
+ "body" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
},
- "description" : {
+ "headers" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "details" : {
- "type" : "object",
- "properties" : { }
+ "method" : {
+ "type" : "string",
+ "enum" : [ "GET", "POST", "PUT", "DELETE", "PATCH" ]
},
- "name" : {
- "type" : "string"
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
},
- "type" : {
+ "url" : {
"type" : "string"
}
},
- "required" : [ "name", "type", "details" ]
+ "required" : [ "method", "url" ],
+ "additionalProperties" : false
},
- "metabase.channel.models.channel.ChannelTemplate" : {
- "description" : "Channel Template schema.",
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "channel_type" : { },
- "details" : {
- "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplateEmailDetails"
- }
- },
- "required" : [ "channel_type", "details" ]
- }, { } ]
+ "metabase.actions.schema..implicit-action.kind" : {
+ "description" : "Unsupported implicit action kind",
+ "type" : "string",
+ "enum" : [ "row/create", "row/update", "row/delete", "bulk/create", "bulk/update", "bulk/delete" ]
},
- "metabase.channel.models.channel.ChannelTemplateEmailDetails" : {
- "oneOf" : [ {
+ "metabase.actions.schema.action" : {
+ "description" : "An Action as it should appear when we `SELECT` it from the app DB.",
+ "allOf" : [ {
"type" : "object",
"properties" : {
- "path" : {
- "type" : "string"
+ "visualization_settings" : {
+ "oneOf" : [ {
+ "type" : "object"
+ }, {
+ "type" : "null"
+ } ]
},
- "recipient-type" : {
- "enum" : [ "cc", "bcc", "cc", "bcc" ]
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
},
- "subject" : {
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ },
+ "made_public_by_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.user"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
"type" : "string"
},
+ "archived" : {
+ "type" : "boolean"
+ },
+ "updated_at" : { },
"type" : {
- "enum" : [ "email/handlebars-resource", "email/handlebars-text", "email/handlebars-resource", "email/handlebars-text" ]
- }
- },
- "required" : [ "type", "subject", "path" ]
- }, {
- "type" : "object",
- "properties" : {
- "body" : {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.actions.schema.type"
},
- "recipient-type" : {
- "enum" : [ "cc", "bcc", "cc", "bcc" ]
+ "created_at" : { },
+ "public_uuid" : {
+ "oneOf" : [ {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ }, {
+ "type" : "null"
+ } ]
},
- "subject" : {
- "type" : "string"
+ "model_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
},
- "type" : {
- "enum" : [ "email/handlebars-resource", "email/handlebars-text", "email/handlebars-resource", "email/handlebars-text" ]
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "creator_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.user"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "type", "subject", "body" ]
- } ]
- },
- "metabase.collections-rest.api.DashboardQuestionCandidate" : {
- "type" : "object",
- "properties" : {
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "type" : "integer",
- "minimum" : 1
- },
- "name" : {
- "type" : "string"
- },
- "sole_dashboard_info" : {
+ "required" : [ "id" ]
+ }, {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.actions.schema.http-action"
+ }, {
+ "$ref" : "#/components/schemas/metabase.actions.schema.implicit-action"
+ }, {
+ "$ref" : "#/components/schemas/metabase.actions.schema.query-action"
+ }, {
"type" : "object",
- "properties" : {
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "type" : "integer",
- "minimum" : 1
- },
- "name" : {
- "type" : "string"
- }
- },
- "required" : [ "id", "name", "description" ]
- }
- },
- "required" : [ "id", "name", "description", "sole_dashboard_info" ]
- },
- "metabase.collections-rest.api.DashboardQuestionCandidatesResponse" : {
- "type" : "object",
- "properties" : {
- "data" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidate"
- }
- },
- "total" : {
- "type" : "integer"
- }
- },
- "required" : [ "data", "total" ]
- },
- "metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse" : {
- "type" : "object",
- "properties" : {
- "moved" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- }
- },
- "required" : [ "moved" ]
- },
- "metabase.collections.schema.CardType" : {
- "type" : "string",
- "enum" : [ "model", "question", "metric" ]
+ "properties" : { }
+ } ]
+ } ]
},
- "metabase.collections.schema.Collection" : {
+ "metabase.actions.schema.http-action" : {
"type" : "object",
"properties" : {
- "git_sync_enabled" : {
- "type" : "boolean"
- },
- "can_delete" : {
- "type" : "boolean"
- },
- "entity_id" : {
- "type" : "string"
- },
- "authority_level" : {
+ "error_handle" : {
"oneOf" : [ {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.actions.schema..http-action.json-query"
}, {
"type" : "null"
} ]
},
- "is_sample" : {
- "type" : "boolean"
- },
- "children" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.Collection"
- }
- },
- "id" : {
- "anyOf" : [ {
- "type" : "string"
- }, {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- } ]
- },
- "effective_ancestors" : {
- "type" : "object",
- "properties" : { }
- },
- "effective_location" : {
- "type" : "string"
- },
- "is_remote_synced" : {
- "type" : "boolean"
- },
- "name" : {
- "type" : "string"
- },
- "slug" : {
- "type" : "string"
- },
- "archived" : {
- "type" : "boolean"
- },
- "location" : {
+ "response_handle" : {
"oneOf" : [ {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.actions.schema..http-action.json-query"
}, {
"type" : "null"
} ]
},
- "can_write" : {
- "type" : "boolean"
- },
- "type" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionType"
- },
- "here" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
- },
- "uniqueItems" : true
- },
- "parent_id" : {
+ "template" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "string"
- }, {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- } ]
+ "$ref" : "#/components/schemas/metabase.actions.schema..http-action.template"
}, {
"type" : "null"
} ]
- },
- "can_restore" : {
- "type" : "boolean"
- },
- "is_personal" : {
- "type" : "boolean"
- },
- "personal_owner_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "below" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
- }
- },
- "description" : {
+ }
+ }
+ },
+ "metabase.actions.schema.id" : {
+ "description" : "Valid Action ID",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "metabase.actions.schema.implicit-action" : {
+ "type" : "object",
+ "properties" : {
+ "kind" : {
"oneOf" : [ {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.actions.schema..implicit-action.kind"
}, {
"type" : "null"
} ]
}
- },
- "required" : [ "id", "name", "description", "can_write", "can_restore", "can_delete", "archived", "location" ]
+ }
},
- "metabase.collections.schema.CollectionItem" : {
+ "metabase.actions.schema.query-action" : {
"type" : "object",
"properties" : {
- "last-edit-info" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.LastEditInfo"
- },
- "model" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
- },
- "copy" : {
- "type" : "boolean"
- },
- "collection_preview" : {
+ "database_id" : {
"oneOf" : [ {
- "type" : "boolean"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
}, {
"type" : "null"
} ]
},
- "dashboard_count" : {
+ "dataset_query" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "$ref" : "#/components/schemas/metabase.queries.schema.query"
}, {
"type" : "null"
} ]
+ }
+ }
+ },
+ "metabase.actions.schema.type" : {
+ "description" : "Unsupported action type",
+ "type" : "string",
+ "enum" : [ "http", "implicit", "query" ]
+ },
+ "metabase.actions.types..scope.raw" : {
+ "anyOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "dashboard-id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
},
- "can_delete" : {
- "type" : "boolean"
- },
- "entity_id" : {
- "type" : "string"
+ "required" : [ "dashboard-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "dashcard-id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
},
- "authority_level" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "required" : [ "dashcard-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "card-id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
},
- "collection" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.collections.schema.Collection"
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "effective_location" : {
- "type" : "string"
- },
- "fully_parameterized" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string"
- },
- "archived" : {
- "type" : "boolean"
- },
- "collection_position" : {
- "oneOf" : [ {
+ "required" : [ "card-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "model-id" : {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "location" : {
- "type" : "string"
+ }
},
- "database_id" : {
- "oneOf" : [ {
+ "required" : [ "model-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "table-id" : {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "can_write" : {
- "type" : "boolean"
- },
- "collection_id" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "string"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "based_on_upload" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "string"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "moderated_status" : {
- "type" : "string"
- },
- "type" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionType"
- }, {
- "$ref" : "#/components/schemas/metabase.collections.schema.CardType"
- } ]
- },
- "here" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
- },
- "uniqueItems" : true
- },
- "display" : {
- "type" : "string"
- },
- "can_restore" : {
- "type" : "boolean"
+ }
},
- "personal_owner_id" : {
- "oneOf" : [ {
+ "required" : [ "table-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "webhook-id" : {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
- }, {
- "type" : "null"
- } ]
+ }
},
- "below" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ "required" : [ "webhook-id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "unknown" : {
+ "type" : "string",
+ "enum" : [ "model-action" ]
}
},
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "required" : [ "unknown" ]
+ } ]
+ },
+ "metabase.analyze.query-results.ResultsMetadata" : {
+ "description" : "value must be an array of valid results column metadata maps.",
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
}
- },
- "required" : [ "id", "name", "description", "archived" ]
+ }, {
+ "type" : "null"
+ } ]
},
- "metabase.collections.schema.CollectionItemModel" : {
+ "metabase.api-keys.schema..key.masked" : {
+ "description" : "Masked string like 'mb_1234**********'.",
+ "allOf" : [ {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema..key.raw"
+ }, {
+ "type" : "string",
+ "pattern" : "^mb_.*{4}\\*+$"
+ } ]
+ },
+ "metabase.api-keys.schema..key.raw" : {
+ "description" : "Unhashed string of the form 'mb_<base-64-bytes>'.",
"type" : "string",
- "enum" : [ "card", "dataset", "metric", "dashboard", "snippet", "collection", "indexed-entity", "indexed-entity", "document", "table" ]
+ "minLength" : 12,
+ "maxLength" : 254
},
- "metabase.collections.schema.CollectionType" : {
+ "metabase.api-keys.schema.id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "metabase.api-keys.schema.name" : {
"type" : "string",
- "enum" : [ "instance-analytics", "trash", "remote-synced", "library", "library-models", "library-metrics" ]
+ "minLength" : 1,
+ "maxLength" : 254
},
- "metabase.collections.schema.LastEditInfo" : {
+ "metabase.api-keys.schema.prefix" : {
+ "description" : "Prefix string of an API Key, suitable for passing around unmasked. This must be unique.",
+ "type" : "string",
+ "minLength" : 7,
+ "maxLength" : 7
+ },
+ "metabase.cache.api..cache-strategy.base.ee" : {
"type" : "object",
"properties" : {
- "email" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "type" : {
+ "type" : "string",
+ "enum" : [ "nocache", "ttl", "duration", "schedule" ]
+ }
+ },
+ "required" : [ "type" ]
+ },
+ "metabase.cache.api..cache-strategy.base.oss" : {
+ "type" : "object",
+ "properties" : {
+ "type" : {
+ "type" : "string",
+ "enum" : [ "nocache", "ttl" ]
+ }
+ },
+ "required" : [ "type" ]
+ },
+ "metabase.cache.api..cache-strategy.ee" : {
+ "description" : "Schema for a caching strategy in EE when we have an premium token with `:cache-granular-controls`.",
+ "allOf" : [ {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.base.ee"
+ }, {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.nocache"
+ }, {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ttl"
+ }, {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee.duration"
+ }, {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee.schedule"
+ } ]
+ } ]
+ },
+ "metabase.cache.api..cache-strategy.ee.duration" : {
+ "type" : "object",
+ "properties" : {
+ "duration" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
- "first_name" : {
+ "refresh_automatically" : {
"oneOf" : [ {
- "type" : "string"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "type" : {
+ "const" : "duration"
},
- "last_name" : {
+ "unit" : {
+ "type" : "string",
+ "enum" : [ "hours", "minutes", "seconds", "days" ]
+ }
+ },
+ "required" : [ "type", "duration", "unit" ],
+ "additionalProperties" : false
+ },
+ "metabase.cache.api..cache-strategy.ee.schedule" : {
+ "type" : "object",
+ "properties" : {
+ "refresh_automatically" : {
"oneOf" : [ {
- "type" : "string"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "timestamp" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "schedule" : {
+ "$ref" : "#/components/schemas/metabase.util.cron.CronScheduleString"
+ },
+ "type" : {
+ "const" : "schedule"
}
},
- "required" : [ "id", "email", "first_name", "last_name", "timestamp" ]
- },
- "metabase.documents.schema..document.id" : {
- "description" : "Valid Document ID",
- "type" : "integer",
- "minimum" : 1
- },
- "metabase.legacy-mbql.schema.!=" : {
- "description" : "schema for a valid MBQL 4 :!= clause",
- "allOf" : [ ]
- },
- "metabase.legacy-mbql.schema.*" : {
- "description" : "schema for a valid MBQL 4 :* clause",
- "allOf" : [ ]
- },
- "metabase.legacy-mbql.schema.+" : {
- "description" : "schema for a valid MBQL 4 :+ clause",
- "allOf" : [ ]
+ "required" : [ "type", "schedule" ],
+ "additionalProperties" : false
},
- "metabase.legacy-mbql.schema.-" : {
- "description" : "schema for a valid MBQL 4 :- clause",
- "allOf" : [ ]
+ "metabase.cache.api..cache-strategy.nocache" : {
+ "type" : "object",
+ "properties" : {
+ "type" : {
+ "const" : "nocache"
+ }
+ },
+ "required" : [ "type" ]
},
- "metabase.legacy-mbql.schema..NativeQuery.Common" : {
+ "metabase.cache.api..cache-strategy.oss" : {
+ "description" : "Schema for a caching strategy (OSS)",
"allOf" : [ {
- "type" : "object",
- "properties" : {
- "collection" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "template-tags" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
- }
- }
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.base.oss"
}, {
- "allOf" : [ ]
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.nocache"
+ }, {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ttl"
+ } ]
} ]
},
- "metabase.legacy-mbql.schema..TemplateTag.Common" : {
- "description" : "Things required by all template tag types.",
+ "metabase.cache.api..cache-strategy.ttl" : {
"type" : "object",
"properties" : {
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ "min_duration_ms" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
},
- "name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "multiplier" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
"type" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagType"
+ "const" : "ttl"
}
},
- "required" : [ "type", "name", "display-name" ]
+ "required" : [ "type", "multiplier", "min_duration_ms" ],
+ "additionalProperties" : false
},
- "metabase.legacy-mbql.schema..TemplateTag.FieldFilter" : {
- "description" : "Things required by all template tag types.",
+ "metabase.cache.api.cache-strategy" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.ee"
+ }, {
+ "$ref" : "#/components/schemas/metabase.cache.api..cache-strategy.oss"
+ } ]
+ },
+ "metabase.channel.models.channel.Channel" : {
+ "description" : "Channel schema.",
"type" : "object",
"properties" : {
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
- },
- "name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "required" : {
+ "active" : {
"type" : "boolean"
},
- "type" : {
- "const" : "dimension"
- },
- "alias" : {
- "type" : "string"
- },
- "options" : {
- "description" : "optional map to be appended to filter clause",
+ "description" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema..TemplateTag.FieldFilter.Options"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "dimension" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
- },
- "default" : { },
- "widget-type" : {
- "default" : "category",
- "description" : "which type of widget the frontend should show for this Field Filter; this also affects which parameter types\n are allowed to be specified for it.",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.WidgetType"
- }
- },
- "required" : [ "type", "name", "display-name", "dimension", "widget-type" ]
- },
- "metabase.legacy-mbql.schema..TemplateTag.FieldFilter.Options" : {
- "type" : "object",
- "additionalProperties" : { }
- },
- "metabase.legacy-mbql.schema..TemplateTag.RawValue" : {
- "description" : "Things required by all template tag types.",
- "type" : "object",
- "properties" : {
- "default" : { },
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ "details" : {
+ "type" : "object",
+ "properties" : { }
},
"name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "required" : {
- "type" : "boolean"
+ "type" : "string"
},
"type" : {
- "type" : "string",
- "enum" : [ "date", "number", "boolean", "text" ]
+ "type" : "string"
}
},
- "required" : [ "type", "name", "display-name" ]
+ "required" : [ "name", "type", "details" ]
},
- "metabase.legacy-mbql.schema..TemplateTag.Snippet" : {
- "description" : "Things required by all template tag types.",
- "type" : "object",
- "properties" : {
- "database" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- },
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
- },
- "name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "metabase.channel.models.channel.ChannelTemplate" : {
+ "description" : "Channel Template schema.",
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "channel_type" : { },
+ "details" : {
+ "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplateEmailDetails"
+ }
},
- "snippet-id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.snippet"
+ "required" : [ "channel_type", "details" ]
+ }, { } ]
+ },
+ "metabase.channel.models.channel.ChannelTemplateEmailDetails" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "path" : {
+ "type" : "string"
+ },
+ "recipient-type" : {
+ "enum" : [ "cc", "bcc", "cc", "bcc" ]
+ },
+ "subject" : {
+ "type" : "string"
+ },
+ "type" : {
+ "enum" : [ "email/handlebars-resource", "email/handlebars-text", "email/handlebars-resource", "email/handlebars-text" ]
+ }
},
- "snippet-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "required" : [ "type", "subject", "path" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "body" : {
+ "type" : "string"
+ },
+ "recipient-type" : {
+ "enum" : [ "cc", "bcc", "cc", "bcc" ]
+ },
+ "subject" : {
+ "type" : "string"
+ },
+ "type" : {
+ "enum" : [ "email/handlebars-resource", "email/handlebars-text", "email/handlebars-resource", "email/handlebars-text" ]
+ }
},
- "type" : {
- "const" : "snippet"
- }
- },
- "required" : [ "type", "name", "display-name", "snippet-name", "snippet-id" ]
+ "required" : [ "type", "subject", "body" ]
+ } ]
},
- "metabase.legacy-mbql.schema..TemplateTag.SourceQuery" : {
- "description" : "Things required by all template tag types.",
+ "metabase.collections-rest.api.DashboardQuestionCandidate" : {
"type" : "object",
"properties" : {
- "card-id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- },
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
},
"id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ "type" : "integer",
+ "minimum" : 1
},
"name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "type" : "string"
},
- "type" : {
- "const" : "card"
- }
- },
- "required" : [ "type", "name", "display-name", "card-id" ]
- },
- "metabase.legacy-mbql.schema..TemplateTag.TemporalUnit" : {
- "description" : "Things required by all template tag types.",
- "type" : "object",
- "properties" : {
- "alias" : {
- "type" : "string"
- },
- "default" : { },
- "dimension" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
- },
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
- },
- "name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "required" : {
- "type" : "boolean"
- },
- "type" : {
- "const" : "temporal-unit"
+ "sole_dashboard_info" : {
+ "type" : "object",
+ "properties" : {
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "id", "name", "description" ]
}
},
- "required" : [ "type", "name", "display-name", "dimension" ]
+ "required" : [ "id", "name", "description", "sole_dashboard_info" ]
},
- "metabase.legacy-mbql.schema..TemplateTag.Value.Common" : {
- "description" : "Things required by all template tag types.",
+ "metabase.collections-rest.api.DashboardQuestionCandidatesResponse" : {
"type" : "object",
"properties" : {
- "default" : { },
- "display-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
- },
- "name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "required" : {
- "type" : "boolean"
+ "data" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidate"
+ }
},
- "type" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagType"
+ "total" : {
+ "type" : "integer"
}
},
- "required" : [ "type", "name", "display-name" ]
+ "required" : [ "data", "total" ]
},
- "metabase.legacy-mbql.schema..legacy-column-metadata.binning-info" : {
+ "metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse" : {
"type" : "object",
"properties" : {
- "bin_width" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
- },
- "binning_strategy" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
- },
- "num_bins" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
- },
- "strategy" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
+ "moved" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
}
},
- "required" : [ "strategy" ]
+ "required" : [ "moved" ]
},
- "metabase.legacy-mbql.schema..legacy-column-metadata.qualified-keys" : {
+ "metabase.collections.schema.CardType" : {
+ "type" : "string",
+ "enum" : [ "model", "question", "metric" ]
+ },
+ "metabase.collections.schema.Collection" : {
"type" : "object",
"properties" : {
- "lib/external-remap" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.remapping.external"
- }, {
- "type" : "null"
- } ]
+ "git_sync_enabled" : {
+ "type" : "boolean"
},
- "lib/source-column-alias" : {
+ "can_delete" : {
+ "type" : "boolean"
+ },
+ "entity_id" : {
+ "type" : "string"
+ },
+ "authority_level" : {
"oneOf" : [ {
- "description" : "Name for a column as returned/projected by the previous stage of the query or source Table/source Card. The\n left-hand side (LHS) of\n\n SELECT lhs AS rhs",
"type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/type" : {
- "default" : "metadata/column",
- "const" : "metadata/column"
+ "is_sample" : {
+ "type" : "boolean"
},
- "lib/source-uuid" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.uuid"
+ "children" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.Collection"
+ }
+ },
+ "id" : {
+ "anyOf" : [ {
+ "type" : "string"
}, {
- "type" : "null"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
} ]
},
- "qp/implicit-field?" : {
+ "effective_ancestors" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "effective_location" : {
+ "type" : "string"
+ },
+ "is_remote_synced" : {
+ "type" : "boolean"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "slug" : {
+ "type" : "string"
+ },
+ "archived" : {
+ "type" : "boolean"
+ },
+ "location" : {
"oneOf" : [ {
- "type" : "boolean"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/ref-name" : {
+ "can_write" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionType"
+ },
+ "here" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ },
+ "uniqueItems" : true
+ },
+ "parent_id" : {
"oneOf" : [ {
- "type" : "string"
+ "anyOf" : [ {
+ "type" : "string"
+ }, {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ } ]
}, {
"type" : "null"
} ]
},
- "lib/deduplicated-name" : {
- "description" : "The simply-deduplicated name that was historically used in QP results metadata (originally calculated by\n the [[metabase.query-processor.middleware.annotate]] middleware, now calculated\n by [[metabase.lib.middleware.result-metadata]]). This just adds suffixes to column names e.g. `ID` and `ID` become\n `ID` and `ID_2`, respectively. Kept around because many old field refs use this column name.",
+ "can_restore" : {
+ "type" : "boolean"
+ },
+ "is_personal" : {
+ "type" : "boolean"
+ },
+ "personal_owner_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "below" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ }
+ },
+ "description" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
+ }
+ },
+ "required" : [ "id", "name", "description", "can_write", "can_restore", "can_delete", "archived", "location" ]
+ },
+ "metabase.collections.schema.CollectionItem" : {
+ "type" : "object",
+ "properties" : {
+ "last-edit-info" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.LastEditInfo"
},
- "lib/original-expression-name" : {
+ "model" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ },
+ "copy" : {
+ "type" : "boolean"
+ },
+ "collection_preview" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "lib/card-id" : {
+ "dashboard_count" : {
"oneOf" : [ {
- "description" : "Valid Card ID",
+ "description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
}, {
"type" : "null"
} ]
},
- "lib/expression-name" : {
+ "can_delete" : {
+ "type" : "boolean"
+ },
+ "entity_id" : {
+ "type" : "string"
+ },
+ "authority_level" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/breakout?" : {
+ "collection" : {
"oneOf" : [ {
- "type" : "boolean"
+ "$ref" : "#/components/schemas/metabase.collections.schema.Collection"
}, {
"type" : "null"
} ]
},
- "metabase.lib.field/temporal-unit" : {
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "effective_location" : {
+ "type" : "string"
+ },
+ "fully_parameterized" : {
"oneOf" : [ {
- "type" : "string",
- "enum" : [ "day", "day-of-month", "day-of-week", "day-of-year", "default", "hour", "hour-of-day", "millisecond", "minute", "minute-of-hour", "month", "month-of-year", "quarter", "quarter-of-year", "second", "second-of-minute", "week", "week-of-year", "year", "year-of-era" ]
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "metabase.lib.field/binning" : {
- "oneOf" : [ {
- "description" : "Schema for `:binning` options passed to a `:field` clause.",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "strategy" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
- }
- },
- "required" : [ "strategy" ]
- }, {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "strategy" : {
- "const" : "default"
- }
- },
- "required" : [ "strategy" ]
- }, {
- "type" : "object",
- "properties" : {
- "bin-width" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
- },
- "strategy" : {
- "const" : "bin-width"
- }
- },
- "required" : [ "strategy", "bin-width" ]
- }, {
- "type" : "object",
- "properties" : {
- "num-bins" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
- },
- "strategy" : {
- "const" : "num-bins"
- }
- },
- "required" : [ "strategy", "num-bins" ]
- } ]
- } ]
- }, {
- "type" : "null"
- } ]
+ "name" : {
+ "type" : "string"
},
- "lib/model-display-name" : {
+ "archived" : {
+ "type" : "boolean"
+ },
+ "collection_position" : {
"oneOf" : [ {
- "type" : "string"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
},
- "lib/internal-remap" : {
+ "location" : {
+ "type" : "string"
+ },
+ "database_id" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.remapping.internal"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
},
- "metabase.lib.join/join-alias" : {
+ "can_write" : {
+ "type" : "boolean"
+ },
+ "collection_id" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "string"
+ } ]
}, {
"type" : "null"
} ]
},
- "lib/original-binning" : {
+ "based_on_upload" : {
"oneOf" : [ {
- "description" : "Schema for `:binning` options passed to a `:field` clause.",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "strategy" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
- }
- },
- "required" : [ "strategy" ]
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "strategy" : {
- "const" : "default"
- }
- },
- "required" : [ "strategy" ]
- }, {
- "type" : "object",
- "properties" : {
- "bin-width" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
- },
- "strategy" : {
- "const" : "bin-width"
- }
- },
- "required" : [ "strategy", "bin-width" ]
- }, {
- "type" : "object",
- "properties" : {
- "num-bins" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
- },
- "strategy" : {
- "const" : "num-bins"
- }
- },
- "required" : [ "strategy", "num-bins" ]
- } ]
+ "type" : "string"
} ]
}, {
"type" : "null"
} ]
},
- "lib/original-join-alias" : {
+ "moderated_status" : {
+ "type" : "string"
+ },
+ "type" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionType"
+ }, {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CardType"
+ } ]
+ },
+ "here" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ },
+ "uniqueItems" : true
+ },
+ "display" : {
+ "type" : "string"
+ },
+ "can_restore" : {
+ "type" : "boolean"
+ },
+ "personal_owner_id" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
},
- "lib/original-display-name" : {
+ "below" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItemModel"
+ }
+ },
+ "description" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
- },
- "lib/source" : {
+ }
+ },
+ "required" : [ "id", "name", "description", "archived" ]
+ },
+ "metabase.collections.schema.CollectionItemModel" : {
+ "type" : "string",
+ "enum" : [ "card", "dataset", "metric", "dashboard", "snippet", "collection", "indexed-entity", "indexed-entity", "document", "table" ]
+ },
+ "metabase.collections.schema.CollectionType" : {
+ "type" : "string",
+ "enum" : [ "instance-analytics", "trash", "remote-synced", "library", "library-models", "library-metrics" ]
+ },
+ "metabase.collections.schema.LastEditInfo" : {
+ "type" : "object",
+ "properties" : {
+ "email" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.source"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/ref-display-name" : {
+ "first_name" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/original-name" : {
- "description" : "The original name of the column as it appeared in the very first place it came from (i.e., the physical name of the\n column in the table it appears in). This should be the same as the `:lib/source-column-alias` for the very first\n usage of the column.\n Allowed to be blank because some databases like SQL Server allow blank column names.",
+ "id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "last_name" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "lib/desired-column-alias" : {
+ "timestamp" : {
"oneOf" : [ {
- "description" : "Name we should use as a column alias for a column in this stage of a query. The desired column alias in stage N\n becomes the source column alias in stage N+1. The right-hand side (RHS) in\n\n SELECT lhs AS rhs",
"type" : "string"
}, {
"type" : "null"
} ]
}
- }
- },
- "metabase.legacy-mbql.schema./" : {
- "description" : "schema for a valid MBQL 4 :/ clause",
- "allOf" : [ ]
+ },
+ "required" : [ "id", "email", "first_name", "last_name", "timestamp" ]
},
- "metabase.legacy-mbql.schema.<" : {
- "description" : "schema for a valid MBQL 4 :< clause",
- "allOf" : [ ]
+ "metabase.documents.schema..document.id" : {
+ "description" : "Valid Document ID",
+ "type" : "integer",
+ "minimum" : 1
},
- "metabase.legacy-mbql.schema.<=" : {
- "description" : "schema for a valid MBQL 4 :<= clause",
+ "metabase.legacy-mbql.schema.!=" : {
+ "description" : "schema for a valid MBQL 4 :!= clause",
"allOf" : [ ]
},
- "metabase.legacy-mbql.schema.=" : {
- "description" : "schema for a valid MBQL 4 := clause",
+ "metabase.legacy-mbql.schema.*" : {
+ "description" : "schema for a valid MBQL 4 :* clause",
"allOf" : [ ]
},
- "metabase.legacy-mbql.schema.>" : {
- "description" : "schema for a valid MBQL 4 :> clause",
+ "metabase.legacy-mbql.schema.+" : {
+ "description" : "schema for a valid MBQL 4 :+ clause",
"allOf" : [ ]
},
- "metabase.legacy-mbql.schema.>=" : {
- "description" : "schema for a valid MBQL 4 :>= clause",
+ "metabase.legacy-mbql.schema.-" : {
+ "description" : "schema for a valid MBQL 4 :- clause",
"allOf" : [ ]
},
- "metabase.legacy-mbql.schema.Addable" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpressionArg"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DateTimeExpressionArg"
- }, {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.interval"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.segment"
- } ]
- } ]
- },
- "metabase.legacy-mbql.schema.Aggregation" : {
- "description" : "Schema for anything that is a valid `:aggregation` clause.",
+ "metabase.legacy-mbql.schema..NativeQuery.Common" : {
"allOf" : [ {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation-options"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.UnnamedAggregation"
- } ]
- }, {
- "description" : "Normalization should automatically unwrap :aggregation-options with an empty options map"
- } ]
- },
- "metabase.legacy-mbql.schema.AggregationOptionsOptions" : {
- "description" : "Additional options for any aggregation clause when wrapping it in `:aggregation-options`.",
+ "type" : "object",
+ "properties" : {
+ "collection" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "template-tags" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
+ }
+ }
+ }, {
+ "allOf" : [ ]
+ } ]
+ },
+ "metabase.legacy-mbql.schema..TemplateTag.Common" : {
+ "description" : "Things required by all template tag types.",
"type" : "object",
"properties" : {
"display-name" : {
"$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
},
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
"name" : {
"$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagType"
}
- }
+ },
+ "required" : [ "type", "name", "display-name" ]
},
- "metabase.legacy-mbql.schema.AggregationRefOptions" : {
+ "metabase.legacy-mbql.schema..TemplateTag.FieldFilter" : {
+ "description" : "Things required by all template tag types.",
"type" : "object",
"properties" : {
- "base-type" : {
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "required" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "const" : "dimension"
+ },
+ "alias" : {
+ "type" : "string"
+ },
+ "options" : {
+ "description" : "optional map to be appended to filter clause",
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema..TemplateTag.FieldFilter.Options"
}, {
"type" : "null"
} ]
},
+ "dimension" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
+ },
+ "default" : { },
+ "widget-type" : {
+ "default" : "category",
+ "description" : "which type of widget the frontend should show for this Field Filter; this also affects which parameter types\n are allowed to be specified for it.",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.WidgetType"
+ }
+ },
+ "required" : [ "type", "name", "display-name", "dimension", "widget-type" ]
+ },
+ "metabase.legacy-mbql.schema..TemplateTag.FieldFilter.Options" : {
+ "type" : "object",
+ "additionalProperties" : { }
+ },
+ "metabase.legacy-mbql.schema..TemplateTag.RawValue" : {
+ "description" : "Things required by all template tag types.",
+ "type" : "object",
+ "properties" : {
+ "default" : { },
"display-name" : {
"$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
},
- "effective-type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
- }, {
- "type" : "null"
- } ]
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
},
"name" : {
"$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "required" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "date", "number", "boolean", "text" ]
}
- }
- },
- "metabase.legacy-mbql.schema.Aggregations" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
},
- "minItems" : 1
- },
- "metabase.legacy-mbql.schema.AnyMBQLClause" : {
- "description" : "Schema for ANY valid MBQL clause"
- },
- "metabase.legacy-mbql.schema.ArithmeticDateTimeUnit" : {
- "type" : "string",
- "enum" : [ "millisecond", "second", "minute", "hour", "day", "week", "month", "quarter", "year" ]
- },
- "metabase.legacy-mbql.schema.BooleanExpression" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.and"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.or"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.="
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.!="
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.<"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.>"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.<="
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.>="
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.between"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.starts-with"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ends-with"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.contains"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.in"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-in"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.does-not-contain"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.inside"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.is-empty"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-empty"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.is-null"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-null"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-time-interval"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.time-interval"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.during"
- } ]
+ "required" : [ "type", "name", "display-name" ]
},
- "metabase.legacy-mbql.schema.Breakouts" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ "metabase.legacy-mbql.schema..TemplateTag.Snippet" : {
+ "description" : "Things required by all template tag types.",
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
+ },
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "snippet-id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.snippet"
+ },
+ "snippet-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "type" : {
+ "const" : "snippet"
+ }
},
- "minItems" : 1
+ "required" : [ "type", "name", "display-name", "snippet-name", "snippet-id" ]
},
- "metabase.legacy-mbql.schema.CaseOptions" : {
+ "metabase.legacy-mbql.schema..TemplateTag.SourceQuery" : {
+ "description" : "Things required by all template tag types.",
"type" : "object",
"properties" : {
- "default" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
+ "card-id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ },
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "type" : {
+ "const" : "card"
}
- }
- },
- "metabase.legacy-mbql.schema.CaseSubclause" : {
- "type" : "array",
- "prefixItems" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
- } ]
- },
- "metabase.legacy-mbql.schema.CaseSubclauses" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CaseSubclause"
},
- "minItems" : 1
+ "required" : [ "type", "name", "display-name", "card-id" ]
},
- "metabase.legacy-mbql.schema.CheckKeysForQueryType" : {
- "allOf" : [ ]
+ "metabase.legacy-mbql.schema..TemplateTag.TemporalUnit" : {
+ "description" : "Things required by all template tag types.",
+ "type" : "object",
+ "properties" : {
+ "alias" : {
+ "type" : "string"
+ },
+ "default" : { },
+ "dimension" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
+ },
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "required" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "const" : "temporal-unit"
+ }
+ },
+ "required" : [ "type", "name", "display-name", "dimension" ]
},
- "metabase.legacy-mbql.schema.CheckQueryDoesNotHaveSourceMetadata" : {
- "description" : "`:source-metadata` is added to queries when `card__id` source queries are resolved. It contains info about the\n columns in the source query.\n\n Where this is added was changed in Metabase 0.33.0 -- previously, when `card__id` source queries were resolved, the\n middleware would add `:source-metadata` to the top-level; to support joins against source queries, this has been\n changed so it is always added at the same level the resolved `:source-query` is added.\n\n This should automatically be fixed by `normalize`; if we encounter it, it means some middleware is not functioning\n properly."
- },
- "metabase.legacy-mbql.schema.DatabaseID" : {
- "description" : "Schema for a valid `:database` ID, in the top-level 'outer' query. Either a positive integer (referring to an\n actual Database), or the saved questions virtual ID, which is a placeholder used for queries using the\n `:source-table \"card__id\"` shorthand for a source query resolved by middleware (since clients might not know the\n actual DB for that source query.)",
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- } ]
- },
- "metabase.legacy-mbql.schema.DateOrDatetimeLiteral" : {
- "description" : "Schema for a valid date or datetime literal.",
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-datetime"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.absolute-datetime"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.literal.datetime"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.literal.date"
- } ]
- },
- "metabase.legacy-mbql.schema.DateTimeExpressionArg" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
- }, {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DateOrDatetimeLiteral"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
- } ]
- } ]
- },
- "metabase.legacy-mbql.schema.DateTimeUnit" : {
- "description" : "Valid unit for *datetime* bucketing.",
- "type" : "string",
- "enum" : [ "quarter", "day", "hour", "week", "second", "default", "day-of-week", "hour-of-day", "month", "month-of-year", "day-of-month", "year", "day-of-year", "millisecond", "year-of-era", "week-of-year", "quarter-of-year", "minute-of-hour", "minute" ]
- },
- "metabase.legacy-mbql.schema.DateUnit" : {
- "description" : "Valid unit for date bucketing.",
- "type" : "string",
- "enum" : [ "quarter", "day", "week", "default", "day-of-week", "month", "month-of-year", "day-of-month", "year", "day-of-year", "year-of-era", "week-of-year", "quarter-of-year" ]
- },
- "metabase.legacy-mbql.schema.DatetimeDiffUnit" : {
- "description" : "Valid units for a datetime-diff clause.",
- "type" : "string",
- "enum" : [ "second", "minute", "hour", "day", "week", "month", "quarter", "year" ]
- },
- "metabase.legacy-mbql.schema.DatetimeExpression" : {
- "description" : "Schema for the definition of a date function expression.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.+"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-add"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-subtract"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.convert-timezone"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.now"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.date"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.today"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
- } ]
- },
- "metabase.legacy-mbql.schema.DatetimeOptions" : {
+ "metabase.legacy-mbql.schema..TemplateTag.Value.Common" : {
+ "description" : "Things required by all template tag types.",
"type" : "object",
"properties" : {
- "mode" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeOptionsMode"
- }
- }
- },
- "metabase.legacy-mbql.schema.DatetimeOptionsMode" : {
- "type" : "string",
- "enum" : [ "simple-bytes", "unix-nanoseconds", "simple", "iso", "iso-bytes", "unix-seconds", "unix-milliseconds", "unix-microseconds" ]
- },
- "metabase.legacy-mbql.schema.Emptyable" : {
- "description" : "Schema for a valid is-empty or not-empty argument.",
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpressionArg"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
- } ]
- },
- "metabase.legacy-mbql.schema.EqualityComparable" : {
- "description" : "Schema for things that make sense in a `=` or `!=` filter, i.e. things that can be compared for equality.",
- "oneOf" : [ {
- "anyOf" : [ {
+ "default" : { },
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.template-tag.id"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "required" : {
"type" : "boolean"
- }, {
- "type" : "number"
- }, {
- "type" : "string"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemporalLiteral"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "metabase.legacy-mbql.schema.EqualityFilterFieldArg" : {
- "description" : "Schema for the first arg to `=`, `!=`, and friends.",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.EqualityComparable"
- },
- "metabase.legacy-mbql.schema.ExpressionArg" : {
- "oneOf" : [ {
- "type" : "number"
- }, {
- "type" : "boolean"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
- }, {
- "type" : "string"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
- } ]
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagType"
+ }
+ },
+ "required" : [ "type", "name", "display-name" ]
},
- "metabase.legacy-mbql.schema.ExpressionName" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "metabase.legacy-mbql.schema..legacy-column-metadata.binning-info" : {
+ "type" : "object",
+ "properties" : {
+ "bin_width" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
+ },
+ "binning_strategy" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
+ },
+ "num_bins" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
+ },
+ "strategy" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
+ }
+ },
+ "required" : [ "strategy" ]
},
- "metabase.legacy-mbql.schema.ExpressionRefOptions" : {
- "description" : "Options for a legacy `:expression` ref in MBQL 4 are the same as in MBQL 5, except that `:lib/uuid` is optional and\n it cannot be empty.",
- "default" : { },
+ "metabase.legacy-mbql.schema..legacy-column-metadata.qualified-keys" : {
"type" : "object",
"properties" : {
- "base-type" : {
+ "lib/external-remap" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.remapping.external"
}, {
"type" : "null"
} ]
},
- "database-type" : {
+ "lib/source-column-alias" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "description" : "Name for a column as returned/projected by the previous stage of the query or source Table/source Card. The\n left-hand side (LHS) of\n\n SELECT lhs AS rhs",
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "display-name" : {
+ "lib/type" : {
+ "default" : "metadata/column",
+ "const" : "metadata/column"
+ },
+ "lib/source-uuid" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.uuid"
}, {
"type" : "null"
} ]
},
- "effective-type" : {
+ "qp/implicit-field?" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "lib/uuid" : {
- "type" : "string",
- "minLength" : 36,
- "maxLength" : 36
+ "lib/ref-name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
},
- "name" : {
+ "lib/deduplicated-name" : {
+ "description" : "The simply-deduplicated name that was historically used in QP results metadata (originally calculated by\n the [[metabase.query-processor.middleware.annotate]] middleware, now calculated\n by [[metabase.lib.middleware.result-metadata]]). This just adds suffixes to column names e.g. `ID` and `ID` become\n `ID` and `ID_2`, respectively. Kept around because many old field refs use this column name.",
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "semantic-type" : {
+ "lib/original-expression-name" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.semantic-or-relation-type"
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
},
- "temporal-unit" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
- }
- }
- },
- "metabase.legacy-mbql.schema.Expressions" : {
- "type" : "object",
- "additionalProperties" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionDef"
- }
- },
- "metabase.legacy-mbql.schema.ExtractWeekMode" : {
- "description" : "Valid modes to extract weeks.",
- "type" : "string",
- "enum" : [ "iso", "us", "instance" ]
- },
- "metabase.legacy-mbql.schema.FieldOrExpressionDef" : {
- "description" : "Schema for anything that is accepted as a top-level expression definition, either an arithmetic expression such as a\n `:+` clause or a `:field` or `:value` clause.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
- }, {
- "type" : "number"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
- }, {
- "type" : "string"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
- }, {
- "type" : "boolean"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
- }, { }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.offset"
+ "lib/card-id" : {
+ "oneOf" : [ {
+ "description" : "Valid Card ID",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/expression-name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/breakout?" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "metabase.lib.field/temporal-unit" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "day", "day-of-month", "day-of-week", "day-of-year", "default", "hour", "hour-of-day", "millisecond", "minute", "minute-of-hour", "month", "month-of-year", "quarter", "quarter-of-year", "second", "second-of-minute", "week", "week-of-year", "year", "year-of-era" ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "metabase.lib.field/binning" : {
+ "oneOf" : [ {
+ "description" : "Schema for `:binning` options passed to a `:field` clause.",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "strategy" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
+ }
+ },
+ "required" : [ "strategy" ]
+ }, {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "strategy" : {
+ "const" : "default"
+ }
+ },
+ "required" : [ "strategy" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "bin-width" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
+ },
+ "strategy" : {
+ "const" : "bin-width"
+ }
+ },
+ "required" : [ "strategy", "bin-width" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "num-bins" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
+ },
+ "strategy" : {
+ "const" : "num-bins"
+ }
+ },
+ "required" : [ "strategy", "num-bins" ]
+ } ]
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/model-display-name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/internal-remap" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.remapping.internal"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "metabase.lib.join/join-alias" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/original-binning" : {
+ "oneOf" : [ {
+ "description" : "Schema for `:binning` options passed to a `:field` clause.",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "strategy" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.strategy"
+ }
+ },
+ "required" : [ "strategy" ]
+ }, {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "strategy" : {
+ "const" : "default"
+ }
+ },
+ "required" : [ "strategy" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "bin-width" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.bin-width"
+ },
+ "strategy" : {
+ "const" : "bin-width"
+ }
+ },
+ "required" : [ "strategy", "bin-width" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "num-bins" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.num-bins"
+ },
+ "strategy" : {
+ "const" : "num-bins"
+ }
+ },
+ "required" : [ "strategy", "num-bins" ]
+ } ]
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/original-join-alias" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/original-display-name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/source" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata..column.source"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/ref-display-name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/original-name" : {
+ "description" : "The original name of the column as it appeared in the very first place it came from (i.e., the physical name of the\n column in the table it appears in). This should be the same as the `:lib/source-column-alias` for the very first\n usage of the column.\n Allowed to be blank because some databases like SQL Server allow blank column names.",
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/desired-column-alias" : {
+ "oneOf" : [ {
+ "description" : "Name we should use as a column alias for a column in this stage of a query. The desired column alias in stage N\n becomes the source column alias in stage N+1. The right-hand side (RHS) in\n\n SELECT lhs AS rhs",
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ },
+ "metabase.legacy-mbql.schema./" : {
+ "description" : "schema for a valid MBQL 4 :/ clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.<" : {
+ "description" : "schema for a valid MBQL 4 :< clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.<=" : {
+ "description" : "schema for a valid MBQL 4 :<= clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.=" : {
+ "description" : "schema for a valid MBQL 4 := clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.>" : {
+ "description" : "schema for a valid MBQL 4 :> clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.>=" : {
+ "description" : "schema for a valid MBQL 4 :>= clause",
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.Addable" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpressionArg"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DateTimeExpressionArg"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.interval"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.segment"
+ } ]
} ]
},
- "metabase.legacy-mbql.schema.FieldOrExpressionRef" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.expression"
+ "metabase.legacy-mbql.schema.Aggregation" : {
+ "description" : "Schema for anything that is a valid `:aggregation` clause.",
+ "allOf" : [ {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation-options"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.UnnamedAggregation"
+ } ]
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
+ "description" : "Normalization should automatically unwrap :aggregation-options with an empty options map"
} ]
},
- "metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-datetime"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
- } ]
+ "metabase.legacy-mbql.schema.AggregationOptionsOptions" : {
+ "description" : "Additional options for any aggregation clause when wrapping it in `:aggregation-options`.",
+ "type" : "object",
+ "properties" : {
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }
+ }
},
- "metabase.legacy-mbql.schema.FieldRefOptions" : {
- "description" : "Options for an MBQL 4 `:field` ref are the same as MBQL 5, except that `:lib/uuid` is not required and it cannot be\n empty.",
- "oneOf" : [ {
- "default" : { },
- "type" : "object",
- "properties" : {
- "binning" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.binning"
- },
- "inherited-temporal-unit" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
- },
- "database-type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "metabase.lib.field/original-temporal-unit" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
- },
- "display-name" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "source-field-name" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "effective-type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
- }, {
- "type" : "null"
- } ]
- },
- "base-type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
- }, {
- "type" : "null"
- } ]
- },
- "lib/uuid" : {
- "type" : "string",
- "minLength" : 36,
- "maxLength" : 36
- },
- "name" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "metabase.lib.field/original-effective-type" : {
+ "metabase.legacy-mbql.schema.AggregationRefOptions" : {
+ "type" : "object",
+ "properties" : {
+ "base-type" : {
+ "oneOf" : [ {
"$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
- },
- "source-field" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- },
- "join-alias" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.join.alias"
- },
- "lib/original-binning" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.binning.binning"
- },
- "temporal-unit" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
- },
- "source-field-join-alias" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- },
- "semantic-type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.semantic-or-relation-type"
- }, {
- "type" : "null"
- } ]
- }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "effective-type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
}
- }, {
- "type" : "null"
- } ]
+ }
},
- "metabase.legacy-mbql.schema.Fields" : {
- "allOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
- },
- "minItems" : 1
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.helpers.distinct"
- } ]
+ "metabase.legacy-mbql.schema.Aggregations" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
+ },
+ "minItems" : 1
},
- "metabase.legacy-mbql.schema.Filter" : {
- "description" : "Schema for a valid MBQL `:filter` clause.",
+ "metabase.legacy-mbql.schema.AnyMBQLClause" : {
+ "description" : "Schema for ANY valid MBQL clause"
+ },
+ "metabase.legacy-mbql.schema.ArithmeticDateTimeUnit" : {
+ "type" : "string",
+ "enum" : [ "millisecond", "second", "minute", "hour", "day", "week", "month", "quarter", "year" ]
+ },
+ "metabase.legacy-mbql.schema.BooleanExpression" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.and"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.or"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.="
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.!="
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.segment"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.<"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.>"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.<="
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.>="
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.between"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.starts-with"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ends-with"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.contains"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.in"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-in"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.does-not-contain"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.inside"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.is-empty"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-empty"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.is-null"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.not-null"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-time-interval"
}, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.time-interval"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.during"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.Breakouts" : {
+ "type" : "array",
+ "items" : {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ },
+ "minItems" : 1
+ },
+ "metabase.legacy-mbql.schema.CaseOptions" : {
+ "type" : "object",
+ "properties" : {
+ "default" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
+ }
+ }
+ },
+ "metabase.legacy-mbql.schema.CaseSubclause" : {
+ "type" : "array",
+ "prefixItems" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
} ]
},
- "metabase.legacy-mbql.schema.IntGreaterThanZeroOrNumericExpression" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
+ "metabase.legacy-mbql.schema.CaseSubclauses" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CaseSubclause"
+ },
+ "minItems" : 1
+ },
+ "metabase.legacy-mbql.schema.CheckKeysForQueryType" : {
+ "allOf" : [ ]
+ },
+ "metabase.legacy-mbql.schema.CheckQueryDoesNotHaveSourceMetadata" : {
+ "description" : "`:source-metadata` is added to queries when `card__id` source queries are resolved. It contains info about the\n columns in the source query.\n\n Where this is added was changed in Metabase 0.33.0 -- previously, when `card__id` source queries were resolved, the\n middleware would add `:source-metadata` to the top-level; to support joins against source queries, this has been\n changed so it is always added at the same level the resolved `:source-query` is added.\n\n This should automatically be fixed by `normalize`; if we encounter it, it means some middleware is not functioning\n properly."
+ },
+ "metabase.legacy-mbql.schema.DatabaseID" : {
+ "description" : "Schema for a valid `:database` ID, in the top-level 'outer' query. Either a positive integer (referring to an\n actual Database), or the saved questions virtual ID, which is a placeholder used for queries using the\n `:source-table \"card__id\"` shorthand for a source query resolved by middleware (since clients might not know the\n actual DB for that source query.)",
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
} ]
},
- "metabase.legacy-mbql.schema.Join" : {
- "description" : "Perform the equivalent of a SQL `JOIN` with another Table or nested `:source-query`. JOINs are either explicitly\n specified in the incoming query, or implicitly generated when one uses a `:field` clause with `:source-field`.\n\n In the top-level query, you can reference Fields from the joined table or nested query by including `:source-field`\n in the `:field` options (known as implicit joins); for explicit joins, you *must* specify `:join-alias` yourself; in\n the `:field` options, e.g.\n\n ;; for joins against other Tables/MBQL source queries\n [:field 1 {:join-alias \"my_join_alias\"}]\n\n ;; for joins against native queries\n [:field \"my_field\" {:base-type :field/Integer, :join-alias \"my_join_alias\"}]",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "alias" : {
- "description" : "The name used to alias the joined table or query. This is usually generated automatically and generally looks\n like `table__via__field`. You can specify this yourself if you need to reference a joined field with a `:join-alias`\n in the options.\n\n Driver implementations: This is guaranteed to be present after pre-processing.",
- "$ref" : "#/components/schemas/metabase.lib.schema.join.alias"
- },
- "condition" : {
- "description" : "The condition on which to JOIN. Can be anything that is a valid `:filter` clause. For automatically-generated\n JOINs this is usually something like\n\n [:= <source-table-fk-field> [:field <dest-table-pk-field> {:join-alias <join-table-alias>}]]",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
- },
- "fields" : {
- "description" : "The Fields from this join to include in parent-level results. This can be either `:none`, `:all`, or a sequence\n of `:field` clauses.\n\n * `:none`: no Fields from the joined table or nested query are included (unless indirectly included by breakouts or\n other clauses). This is the default, and what is used for automatically-generated joins.\n\n * `:all`: will include all of the Field from the joined table or query\n\n * a sequence of Field clauses: include only the Fields specified. Valid clauses are the same as the top-level\n `:fields` clause. This should be non-empty and all elements should be distinct. The normalizer will automatically\n remove duplicate fields for you, and replace empty clauses with `:none`.\n\n Driver implementations: you can ignore this clause. Relevant fields will be added to top-level `:fields` clause with\n appropriate aliases.",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.JoinFields"
- },
- "fk-field-id" : {
- "description" : "Mostly used only internally. When a join is implicitly generated via a `:field` clause with\n `:source-field`, the ID of the foreign key field in the source Table will be recorded here. This information is used\n to add `fk_field_id` information to the `:cols` in the query results, and also for drill-thru. When generating\n explicit joins by hand you can usually omit this information, altho it doesn't hurt to include it if you know it.\n\n Don't set this information yourself. It will have no effect.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }, {
- "type" : "null"
- } ]
- },
- "source-metadata" : {
- "description" : "Metadata about the source query being used, if pulled in from a Card via the\n `:source-table \"card__id\"` syntax. added automatically by the `resolve-card-id-source-tables` middleware.",
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
- }
- }, {
- "type" : "null"
- } ]
- },
- "source-query" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceQuery"
- },
- "source-table" : {
- "description" : "*What* to JOIN. Self-joins can be done by using the same `:source-table` as in the query where\n this is specified. YOU MUST SUPPLY EITHER `:source-table` OR `:source-query`, BUT NOT BOTH!",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceTable"
- },
- "strategy" : {
- "description" : "Defaults to `:left-join`; used for all automatically-generated JOINs\n\n Driver implementations: this is guaranteed to be present after pre-processing.",
- "$ref" : "#/components/schemas/metabase.lib.schema.join.strategy"
- }
- },
- "required" : [ "condition" ]
- }, {
- "allOf" : [ ]
- } ]
- },
- "metabase.legacy-mbql.schema.JoinFields" : {
+ "metabase.legacy-mbql.schema.DateOrDatetimeLiteral" : {
+ "description" : "Schema for a valid date or datetime literal.",
"anyOf" : [ {
- "type" : "string",
- "enum" : [ "all", "none" ]
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-datetime"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Fields"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.absolute-datetime"
+ }, {
+ "$ref" : "#/components/schemas/metabase.lib.schema.literal.datetime"
+ }, {
+ "$ref" : "#/components/schemas/metabase.lib.schema.literal.date"
} ]
},
- "metabase.legacy-mbql.schema.Joins" : {
- "description" : "Schema for a valid sequence of `Join`s. Must be a non-empty sequence, and `:alias`, if specified, must be unique.",
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Join"
- },
- "minItems" : 1
- },
- "metabase.legacy-mbql.schema.MBQLQuery" : {
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "breakout" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Breakouts"
- },
- "source-metadata" : {
- "description" : "Info about the columns of the source query. Added in automatically by middleware. This metadata is\n primarily used to let power things like binning when used with Field Literals instead of normal Fields.",
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
- }
- }, {
- "type" : "null"
- } ]
- },
- "source-query" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceQuery"
- },
- "limit" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.int-greater-than-or-equal-to-zero"
- },
- "filter" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
- },
- "joins" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Joins"
- },
- "aggregation" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregations"
- },
- "fields" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Fields"
- },
- "source-table" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceTable"
- },
- "order-by" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderBys"
- },
- "page" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.page"
- },
- "expressions" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Expressions"
- }
- }
+ "metabase.legacy-mbql.schema.DateTimeExpressionArg" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
}, {
- "type" : "object",
- "properties" : { }
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.RemoveFieldRefsFromFieldsAlreadyInBreakout"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
}, {
- "allOf" : [ ]
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DateOrDatetimeLiteral"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ } ]
} ]
},
- "metabase.legacy-mbql.schema.NativeQuery" : {
- "description" : "Schema for a valid, normalized native [inner] query.",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "collection" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "query" : { },
- "template-tags" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
- }
- },
- "required" : [ "query" ]
- }, {
- "allOf" : [ ]
- } ]
+ "metabase.legacy-mbql.schema.DateTimeUnit" : {
+ "description" : "Valid unit for *datetime* bucketing.",
+ "type" : "string",
+ "enum" : [ "quarter", "day", "hour", "week", "second", "default", "day-of-week", "hour-of-day", "month", "month-of-year", "day-of-month", "year", "day-of-year", "millisecond", "year-of-era", "week-of-year", "quarter-of-year", "minute-of-hour", "minute" ]
},
- "metabase.legacy-mbql.schema.NativeSourceQuery" : {
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "collection" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
- }, {
- "type" : "null"
- } ]
- },
- "native" : { },
- "template-tags" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
- }
- },
- "required" : [ "native" ]
- }, {
- "allOf" : [ ]
- } ]
+ "metabase.legacy-mbql.schema.DateUnit" : {
+ "description" : "Valid unit for date bucketing.",
+ "type" : "string",
+ "enum" : [ "quarter", "day", "week", "default", "day-of-week", "month", "month-of-year", "day-of-month", "year", "day-of-year", "year-of-era", "week-of-year", "quarter-of-year" ]
},
- "metabase.legacy-mbql.schema.NumericExpression" : {
- "description" : "Schema for the definition of a numeric expression. All numeric expressions evaluate to numeric values.",
+ "metabase.legacy-mbql.schema.DatetimeDiffUnit" : {
+ "description" : "Valid units for a datetime-diff clause.",
+ "type" : "string",
+ "enum" : [ "second", "minute", "hour", "day", "week", "month", "quarter", "year" ]
+ },
+ "metabase.legacy-mbql.schema.DatetimeExpression" : {
+ "description" : "Schema for the definition of a date function expression.",
"oneOf" : [ {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.+"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.-"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.~1"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.*"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.length"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.floor"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-add"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ceil"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-subtract"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.round"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.convert-timezone"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.abs"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.now"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.power"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.date"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.sqrt"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.exp"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.today"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.log"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.DatetimeOptions" : {
+ "type" : "object",
+ "properties" : {
+ "mode" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeOptionsMode"
+ }
+ }
+ },
+ "metabase.legacy-mbql.schema.DatetimeOptionsMode" : {
+ "type" : "string",
+ "enum" : [ "simple-bytes", "unix-nanoseconds", "simple", "iso", "iso-bytes", "unix-seconds", "unix-milliseconds", "unix-microseconds" ]
+ },
+ "metabase.legacy-mbql.schema.Emptyable" : {
+ "description" : "Schema for a valid is-empty or not-empty argument.",
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpressionArg"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-diff"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.integer"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.float"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.temporal-extract"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-year"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-quarter"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-month"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-week"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-day"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-day-of-week"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-hour"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-minute"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-second"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
} ]
},
- "metabase.legacy-mbql.schema.NumericExpressionArg" : {
+ "metabase.legacy-mbql.schema.EqualityComparable" : {
+ "description" : "Schema for things that make sense in a `=` or `!=` filter, i.e. things that can be compared for equality.",
"oneOf" : [ {
- "type" : "number"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ "anyOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "number"
+ }, {
+ "type" : "string"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemporalLiteral"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.EqualityFilterFieldArg" : {
+ "description" : "Schema for the first arg to `=`, `!=`, and friends.",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.EqualityComparable"
+ },
+ "metabase.legacy-mbql.schema.ExpressionArg" : {
+ "oneOf" : [ {
+ "type" : "number"
+ }, {
+ "type" : "boolean"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
+ }, {
+ "type" : "string"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Reference"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
} ]
},
- "metabase.legacy-mbql.schema.OrderBy" : {
- "description" : "Schema for an `order-by` clause subclause.",
+ "metabase.legacy-mbql.schema.ExpressionName" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "metabase.legacy-mbql.schema.ExpressionRefOptions" : {
+ "description" : "Options for a legacy `:expression` ref in MBQL 4 are the same as in MBQL 5, except that `:lib/uuid` is optional and\n it cannot be empty.",
+ "default" : { },
+ "type" : "object",
+ "properties" : {
+ "base-type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "database-type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display-name" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "effective-type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "lib/uuid" : {
+ "type" : "string",
+ "minLength" : 36,
+ "maxLength" : 36
+ },
+ "name" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "semantic-type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.semantic-or-relation-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "temporal-unit" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
+ }
+ }
+ },
+ "metabase.legacy-mbql.schema.Expressions" : {
+ "type" : "object",
+ "additionalProperties" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionDef"
+ }
+ },
+ "metabase.legacy-mbql.schema.ExtractWeekMode" : {
+ "description" : "Valid modes to extract weeks.",
+ "type" : "string",
+ "enum" : [ "iso", "us", "instance" ]
+ },
+ "metabase.legacy-mbql.schema.FieldOrExpressionDef" : {
+ "description" : "Schema for anything that is accepted as a top-level expression definition, either an arithmetic expression such as a\n `:+` clause or a `:field` or `:value` clause.",
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.asc"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.desc"
+ "type" : "number"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
+ }, {
+ "type" : "string"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
+ }, {
+ "type" : "boolean"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
+ }, { }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.offset"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
} ]
},
- "metabase.legacy-mbql.schema.OrderBys" : {
- "allOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderBy"
- },
- "minItems" : 1
+ "metabase.legacy-mbql.schema.FieldOrExpressionRef" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.expression"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.helpers.distinct"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
} ]
},
- "metabase.legacy-mbql.schema.OrderComparable" : {
- "description" : "Schema for things that make sense in a filter like `>` or `<`, i.e. things that can be sorted.",
+ "metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.relative-datetime"
}, {
- "anyOf" : [ {
- "type" : "number"
- }, {
- "type" : "string"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemporalLiteral"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime"
- } ]
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
} ]
},
- "metabase.legacy-mbql.schema.OrderedFilterFieldArg" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderComparable"
- },
- "metabase.legacy-mbql.schema.Query" : {
- "allOf" : [ {
- "type" : "object",
- "properties" : { }
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CheckQueryDoesNotHaveSourceMetadata"
- }, {
+ "metabase.legacy-mbql.schema.FieldRefOptions" : {
+ "description" : "Options for an MBQL 4 `:field` ref are the same as MBQL 5, except that `:lib/uuid` is not required and it cannot be\n empty.",
+ "oneOf" : [ {
+ "default" : { },
"type" : "object",
"properties" : {
- "update-row" : {
+ "binning" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.binning"
+ },
+ "inherited-temporal-unit" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
+ },
+ "database-type" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
}, {
"type" : "null"
} ]
},
- "settings" : {
+ "metabase.lib.field/original-temporal-unit" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
+ },
+ "display-name" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.settings.settings"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
}, {
"type" : "null"
} ]
},
- "constraints" : {
+ "source-field-name" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "effective-type" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.constraints.constraints"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
}, {
"type" : "null"
} ]
},
- "query" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.MBQLQuery"
- },
- "native" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NativeQuery"
- },
- "info" : {
- "description" : "Used when recording info about this run in the QueryExecution log; things like context query was\n ran in and User who ran it.",
+ "base-type" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.info.info"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
}, {
"type" : "null"
} ]
},
- "middleware" : {
+ "lib/uuid" : {
+ "type" : "string",
+ "minLength" : 36,
+ "maxLength" : 36
+ },
+ "name" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.middleware-options.middleware-options"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
}, {
"type" : "null"
} ]
},
- "database" : {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatabaseID"
+ "metabase.lib.field/original-effective-type" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.base-type"
},
- "type" : {
- "description" : "Type of query. `:query` = MBQL; `:native` = native.",
- "type" : "string",
- "enum" : [ "query", "native" ]
+ "source-field" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
},
- "parameters" : {
+ "join-alias" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.join.alias"
+ },
+ "lib/original-binning" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.binning.binning"
+ },
+ "temporal-unit" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
+ },
+ "source-field-join-alias" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "semantic-type" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.parameters"
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.semantic-or-relation-type"
}, {
"type" : "null"
} ]
+ }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.Fields" : {
+ "allOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ },
+ "minItems" : 1
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.helpers.distinct"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.Filter" : {
+ "description" : "Schema for a valid MBQL `:filter` clause.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatetimeExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.BooleanExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.segment"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRef"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.IntGreaterThanZeroOrNumericExpression" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.Join" : {
+ "description" : "Perform the equivalent of a SQL `JOIN` with another Table or nested `:source-query`. JOINs are either explicitly\n specified in the incoming query, or implicitly generated when one uses a `:field` clause with `:source-field`.\n\n In the top-level query, you can reference Fields from the joined table or nested query by including `:source-field`\n in the `:field` options (known as implicit joins); for explicit joins, you *must* specify `:join-alias` yourself; in\n the `:field` options, e.g.\n\n ;; for joins against other Tables/MBQL source queries\n [:field 1 {:join-alias \"my_join_alias\"}]\n\n ;; for joins against native queries\n [:field \"my_field\" {:base-type :field/Integer, :join-alias \"my_join_alias\"}]",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "alias" : {
+ "description" : "The name used to alias the joined table or query. This is usually generated automatically and generally looks\n like `table__via__field`. You can specify this yourself if you need to reference a joined field with a `:join-alias`\n in the options.\n\n Driver implementations: This is guaranteed to be present after pre-processing.",
+ "$ref" : "#/components/schemas/metabase.lib.schema.join.alias"
},
- "create-row" : {
+ "condition" : {
+ "description" : "The condition on which to JOIN. Can be anything that is a valid `:filter` clause. For automatically-generated\n JOINs this is usually something like\n\n [:= <source-table-fk-field> [:field <dest-table-pk-field> {:join-alias <join-table-alias>}]]",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
+ },
+ "fields" : {
+ "description" : "The Fields from this join to include in parent-level results. This can be either `:none`, `:all`, or a sequence\n of `:field` clauses.\n\n * `:none`: no Fields from the joined table or nested query are included (unless indirectly included by breakouts or\n other clauses). This is the default, and what is used for automatically-generated joins.\n\n * `:all`: will include all of the Field from the joined table or query\n\n * a sequence of Field clauses: include only the Fields specified. Valid clauses are the same as the top-level\n `:fields` clause. This should be non-empty and all elements should be distinct. The normalizer will automatically\n remove duplicate fields for you, and replace empty clauses with `:none`.\n\n Driver implementations: you can ignore this clause. Relevant fields will be added to top-level `:fields` clause with\n appropriate aliases.",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.JoinFields"
+ },
+ "fk-field-id" : {
+ "description" : "Mostly used only internally. When a join is implicitly generated via a `:field` clause with\n `:source-field`, the ID of the foreign key field in the source Table will be recorded here. This information is used\n to add `fk_field_id` information to the `:cols` in the query results, and also for drill-thru. When generating\n explicit joins by hand you can usually omit this information, altho it doesn't hurt to include it if you know it.\n\n Don't set this information yourself. It will have no effect.",
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
}, {
"type" : "null"
} ]
+ },
+ "source-metadata" : {
+ "description" : "Metadata about the source query being used, if pulled in from a Card via the\n `:source-table \"card__id\"` syntax. added automatically by the `resolve-card-id-source-tables` middleware.",
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "source-query" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceQuery"
+ },
+ "source-table" : {
+ "description" : "*What* to JOIN. Self-joins can be done by using the same `:source-table` as in the query where\n this is specified. YOU MUST SUPPLY EITHER `:source-table` OR `:source-query`, BUT NOT BOTH!",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceTable"
+ },
+ "strategy" : {
+ "description" : "Defaults to `:left-join`; used for all automatically-generated JOINs\n\n Driver implementations: this is guaranteed to be present after pre-processing.",
+ "$ref" : "#/components/schemas/metabase.lib.schema.join.strategy"
}
},
- "required" : [ "type" ]
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CheckKeysForQueryType"
+ "required" : [ "condition" ]
}, {
"allOf" : [ ]
} ]
},
- "metabase.legacy-mbql.schema.Reference" : {
- "description" : "Schema for any type of valid Field clause, or for an indexed reference to an aggregation clause.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
- }, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.expression"
+ "metabase.legacy-mbql.schema.JoinFields" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all", "none" ]
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Fields"
} ]
},
- "metabase.legacy-mbql.schema.RelativeDatetimeUnit" : {
- "type" : "string",
- "enum" : [ "default", "minute", "hour", "day", "week", "month", "quarter", "year" ]
+ "metabase.legacy-mbql.schema.Joins" : {
+ "description" : "Schema for a valid sequence of `Join`s. Must be a non-empty sequence, and `:alias`, if specified, must be unique.",
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Join"
+ },
+ "minItems" : 1
},
- "metabase.legacy-mbql.schema.RemoveFieldRefsFromFieldsAlreadyInBreakout" : { },
- "metabase.legacy-mbql.schema.SourceQuery" : {
- "description" : "Schema for a valid value for a `:source-query`.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NativeSourceQuery"
+ "metabase.legacy-mbql.schema.MBQLQuery" : {
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "breakout" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Breakouts"
+ },
+ "source-metadata" : {
+ "description" : "Info about the columns of the source query. Added in automatically by middleware. This metadata is\n primarily used to let power things like binning when used with Field Literals instead of normal Fields.",
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "source-query" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceQuery"
+ },
+ "limit" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.int-greater-than-or-equal-to-zero"
+ },
+ "filter" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Filter"
+ },
+ "joins" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Joins"
+ },
+ "aggregation" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregations"
+ },
+ "fields" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Fields"
+ },
+ "source-table" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.SourceTable"
+ },
+ "order-by" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderBys"
+ },
+ "page" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.page"
+ },
+ "expressions" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Expressions"
+ }
+ }
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.MBQLQuery"
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.RemoveFieldRefsFromFieldsAlreadyInBreakout"
+ }, {
+ "allOf" : [ ]
} ]
},
- "metabase.legacy-mbql.schema.SourceTable" : {
- "description" : "Schema for a valid value for the `:source-table` clause of an MBQL query.",
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.table"
+ "metabase.legacy-mbql.schema.NativeQuery" : {
+ "description" : "Schema for a valid, normalized native [inner] query.",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "collection" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "query" : { },
+ "template-tags" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
+ }
+ },
+ "required" : [ "query" ]
}, {
- "description" : "`card__<id>` string Table ID",
- "type" : "string",
- "pattern" : "^card__[1-9]\\d*$"
+ "allOf" : [ ]
} ]
},
- "metabase.legacy-mbql.schema.StringExpression" : {
+ "metabase.legacy-mbql.schema.NativeSourceQuery" : {
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "collection" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "native" : { },
+ "template-tags" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemplateTagMap"
+ }
+ },
+ "required" : [ "native" ]
+ }, {
+ "allOf" : [ ]
+ } ]
+ },
+ "metabase.legacy-mbql.schema.NumericExpression" : {
+ "description" : "Schema for the definition of a numeric expression. All numeric expressions evaluate to numeric values.",
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.substring"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.+"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.trim"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.-"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ltrim"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.~1"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.rtrim"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.*"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.replace"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.lower"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.length"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.upper"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.floor"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.concat"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ceil"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.regex-match-first"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.round"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.abs"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.power"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.sqrt"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.host"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.exp"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.domain"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.log"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.subdomain"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.path"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
}, {
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.month-name"
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-diff"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.integer"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.float"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.temporal-extract"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-year"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-quarter"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-month"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-week"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-day"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-day-of-week"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-hour"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-minute"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.get-second"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.NumericExpressionArg" : {
+ "oneOf" : [ {
+ "type" : "number"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NumericExpression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Aggregation"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.Reference"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.OrderBy" : {
+ "description" : "Schema for an `order-by` clause subclause.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.asc"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.desc"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.OrderBys" : {
+ "allOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderBy"
+ },
+ "minItems" : 1
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.helpers.distinct"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.OrderComparable" : {
+ "description" : "Schema for things that make sense in a filter like `>` or `<`, i.e. things that can be sorted.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.value"
+ }, {
+ "anyOf" : [ {
+ "type" : "number"
+ }, {
+ "type" : "string"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.TemporalLiteral"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ExpressionArg"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.FieldOrExpressionRefOrRelativeDatetime"
+ } ]
+ } ]
+ },
+ "metabase.legacy-mbql.schema.OrderedFilterFieldArg" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.OrderComparable"
+ },
+ "metabase.legacy-mbql.schema.Query" : {
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CheckQueryDoesNotHaveSourceMetadata"
+ }, {
+ "type" : "object",
+ "properties" : {
+ "update-row" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "settings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.settings.settings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "constraints" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.constraints.constraints"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "query" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.MBQLQuery"
+ },
+ "native" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NativeQuery"
+ },
+ "info" : {
+ "description" : "Used when recording info about this run in the QueryExecution log; things like context query was\n ran in and User who ran it.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.info.info"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "middleware" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.middleware-options.middleware-options"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "database" : {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.DatabaseID"
+ },
+ "type" : {
+ "description" : "Type of query. `:query` = MBQL; `:native` = native.",
+ "type" : "string",
+ "enum" : [ "query", "native" ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "create-row" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "type" ]
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.CheckKeysForQueryType"
+ }, {
+ "allOf" : [ ]
+ } ]
+ },
+ "metabase.legacy-mbql.schema.Reference" : {
+ "description" : "Schema for any type of valid Field clause, or for an indexed reference to an aggregation clause.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.aggregation"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.expression"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.RelativeDatetimeUnit" : {
+ "type" : "string",
+ "enum" : [ "default", "minute", "hour", "day", "week", "month", "quarter", "year" ]
+ },
+ "metabase.legacy-mbql.schema.RemoveFieldRefsFromFieldsAlreadyInBreakout" : { },
+ "metabase.legacy-mbql.schema.SourceQuery" : {
+ "description" : "Schema for a valid value for a `:source-query`.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.NativeSourceQuery"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.MBQLQuery"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.SourceTable" : {
+ "description" : "Schema for a valid value for the `:source-table` clause of an MBQL query.",
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.table"
+ }, {
+ "description" : "`card__<id>` string Table ID",
+ "type" : "string",
+ "pattern" : "^card__[1-9]\\d*$"
+ } ]
+ },
+ "metabase.legacy-mbql.schema.StringExpression" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.substring"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.trim"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ltrim"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.rtrim"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.replace"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.lower"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.upper"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.concat"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.regex-match-first"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.coalesce"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.host"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.domain"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.subdomain"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.path"
+ }, {
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.month-name"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.quarter-name"
}, {
@@ -9586,7 +10056,7 @@
"metabase.lib.schema.info.context" : {
"description" : "Schema for `info.context`; used for informational purposes to record how a query was executed.",
"type" : "string",
- "enum" : [ "action", "ad-hoc", "cache-refresh", "collection", "map-tiles", "pulse", "dashboard-subscription", "dashboard", "question", "csv-download", "xlsx-download", "json-download", "public-dashboard", "public-question", "public-csv-download", "public-xlsx-download", "public-json-download", "embedded-dashboard", "embedded-question", "embedded-csv-download", "embedded-xlsx-download", "embedded-json-download", "table-grid" ]
+ "enum" : [ "action", "ad-hoc", "agent", "cache-refresh", "collection", "map-tiles", "pulse", "dashboard-subscription", "dashboard", "question", "csv-download", "xlsx-download", "json-download", "public-dashboard", "public-question", "public-csv-download", "public-xlsx-download", "public-json-download", "embedded-dashboard", "embedded-question", "embedded-csv-download", "embedded-xlsx-download", "embedded-json-download", "table-grid" ]
},
"metabase.lib.schema.info.hash" : {
"type" : "string",
@@ -12368,1298 +12838,1957 @@
"required" : [ "payload_type" ]
} ]
}, {
- "oneOf" : [ {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "creator" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "handlers" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "active" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.channel.models.channel.Channel"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_type" : { },
+ "notification_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "recipients" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.notification.models.NotificationRecipient"
+ }
+ },
+ "template" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplate"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "template_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "channel_type" ]
+ }
+ },
+ "payload" : {
+ "$ref" : "#/components/schemas/metabase.notification.models.NotificationCard"
+ },
+ "subscriptions" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.notification.models.NotificationSubscription"
+ }
+ }
+ },
+ "required" : [ "payload" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "creator" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "handlers" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "active" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.channel.models.channel.Channel"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_type" : { },
+ "notification_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "recipients" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.notification.models.NotificationRecipient"
+ }
+ },
+ "template" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplate"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "template_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "channel_type" ]
+ }
+ },
+ "subscriptions" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.notification.models.NotificationSubscription"
+ }
+ }
+ }
+ } ]
+ } ]
+ },
+ "metabase.notification.models.Notification" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "payload_id" : {
+ "type" : "null"
+ },
+ "payload_type" : {
+ "type" : "string",
+ "enum" : [ "notification/dashboard", "notification/system-event", "notification/testing", "notification/card" ]
+ }
+ },
+ "required" : [ "payload_type" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "creator_id" : {
+ "type" : "integer"
+ },
+ "payload_id" : {
+ "type" : "integer"
+ },
+ "payload_type" : {
+ "type" : "string",
+ "enum" : [ "notification/dashboard", "notification/system-event", "notification/testing", "notification/card" ]
+ }
+ },
+ "required" : [ "payload_type" ]
+ }, { } ]
+ },
+ "metabase.notification.models.NotificationCard" : {
+ "description" : "Schema for :model/NotificationCard.",
+ "type" : "object",
+ "properties" : {
+ "card" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "card_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "send_condition" : {
+ "type" : "string",
+ "enum" : [ "goal_below", "has_result", "goal_above" ]
+ },
+ "send_once" : {
+ "type" : "boolean"
+ }
+ },
+ "required" : [ "card_id" ]
+ },
+ "metabase.notification.models.NotificationHandler" : {
+ "type" : "object",
+ "properties" : {
+ "active" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "channel_type" : { },
+ "notification_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "template_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "channel_type" ]
+ },
+ "metabase.notification.models.NotificationRecipient" : {
+ "description" : "Schema for :model/NotificationRecipient.",
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "details" : { },
+ "notification_handler_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "permissions_group_id" : { },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
+ },
+ "user_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "type", "user_id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "details" : { },
+ "notification_handler_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "permissions_group_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
+ },
+ "user_id" : { }
+ },
+ "required" : [ "type", "permissions_group_id" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "type" : "object",
+ "properties" : {
+ "value" : { }
+ },
+ "required" : [ "value" ],
+ "additionalProperties" : false
+ },
+ "notification_handler_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "permissions_group_id" : { },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
+ },
+ "user_id" : { }
+ },
+ "required" : [ "type", "details" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "type" : "object",
+ "properties" : {
+ "is_optional" : {
+ "type" : "boolean"
+ },
+ "pattern" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "pattern" ],
+ "additionalProperties" : false
+ },
+ "notification_handler_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "permissions_group_id" : { },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
+ },
+ "user_id" : { }
+ },
+ "required" : [ "type", "details" ]
+ } ]
+ },
+ "metabase.notification.models.NotificationSubscription" : {
+ "description" : "Schema for :model/NotificationSubscription.",
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "cron_schedule" : {
+ "type" : "null"
+ },
+ "event_name" : {
+ "anyOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "string"
+ } ]
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-subscription/cron", "notification-subscription/system-event" ]
+ }
+ },
+ "required" : [ "type", "event_name" ]
+ }, {
+ "type" : "object",
+ "properties" : {
+ "cron_schedule" : {
+ "type" : "string"
+ },
+ "event_name" : {
+ "type" : "null"
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "notification-subscription/cron", "notification-subscription/system-event" ]
+ },
+ "ui_display_type" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "cron/raw", "cron/builder" ]
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "type", "cron_schedule" ]
+ } ]
+ },
+ "metabase.parameters.schema.legacy-ref" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter..target.legacy-expression-ref"
+ }, {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter..target.legacy-field-ref"
+ } ]
+ },
+ "metabase.parameters.schema.parameter" : {
+ "description" : "parameter must be a map with :id and :type keys",
+ "type" : "object",
+ "properties" : {
+ "filteringParameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "mappings" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
+ }
+ }, {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
+ },
+ "uniqueItems" : true
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "sectionId" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ },
+ "values_source_config" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.values-source-config"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "slug" : {
+ "type" : "string"
+ },
+ "values_query_type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.values-query-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.type"
+ },
+ "temporal_units" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "target" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.target"
+ },
+ "values_source_type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.values-source-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "default" : { }
+ },
+ "required" : [ "id", "type" ]
+ },
+ "metabase.parameters.schema.parameter-mapping" : {
+ "description" : "parameter_mapping must be a map with :parameter_id and :target keys",
+ "type" : "object",
+ "properties" : {
+ "card_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashcard" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "parameter_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ },
+ "target" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.target"
+ }
+ },
+ "required" : [ "parameter_id", "target" ]
+ },
+ "metabase.parameters.schema.parameter-mappings" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
+ }
+ },
+ "metabase.parameters.schema.parameters" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ }
+ },
+ "metabase.parameters.schema.values-query-type" : {
+ "type" : "string",
+ "enum" : [ "none", "list", "search" ]
+ },
+ "metabase.parameters.schema.values-source-config" : {
+ "description" : "Schema for valid source_options within a Parameter",
+ "type" : "object",
+ "properties" : {
+ "card_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ },
+ "label_field" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.legacy-ref"
+ },
+ "value_field" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.legacy-ref"
+ },
+ "values" : { }
+ }
+ },
+ "metabase.parameters.schema.values-source-type" : {
+ "type" : "string",
+ "enum" : [ "static-list", "card" ]
+ },
+ "metabase.queries.schema..card.result-metadata" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata.lib-or-legacy-column"
+ }
+ },
+ "metabase.queries.schema.card" : {
+ "description" : "Schema for an instance of a `:model/Card` (everything is optional to support updates).",
+ "type" : "object",
+ "properties" : {
+ "dataset_query" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.queries.schema.query"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "database_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "document_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.documents.schema..document.id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.queries.schema..card.result-metadata"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.collection"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata..card.type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashboard_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.dashboard"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ },
+ "metabase.queries.schema.card-type" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.metadata..card.type"
+ },
+ "metabase.queries.schema.empty-map" : {
+ "description" : "An empty map, allowed for Card.dataset_query for historic purposes.",
+ "const" : { }
+ },
+ "metabase.queries.schema.query" : {
+ "description" : "Schema for Card.dataset_query. Cards are for some wacko reason allowed to be saved with empty queries (`{}`), but not\n `NULL` ones, because the column is non-null. This sorta seems like an oversight but fixing all the tests that save\n Cards with empty queries is too much to attempt at this point. So a Card either has an empty query or a valid MBQL 5\n query.",
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.queries.schema.empty-map"
+ }, {
+ "allOf" : [ {
+ "description" : "Valid MBQL 5 query.",
"type" : "object",
"properties" : {
- "creator" : {
+ "lib/metadata" : {
+ "description" : "Schema for something that satisfies the [[metabase.lib.metadata.protocols/MetadataProvider]] protocol."
+ },
+ "update-row" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
+ },
+ "lib/type" : {
+ "default" : "mbql/query",
+ "const" : "mbql/query"
+ },
+ "settings" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.settings.settings"
+ },
+ "constraints" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.constraints.constraints"
+ },
+ "info" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.info.info"
+ },
+ "middleware" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.middleware-options.middleware-options"
+ },
+ "database" : {
"oneOf" : [ {
- "type" : "object",
- "properties" : { }
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
}, {
- "type" : "null"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
} ]
},
- "handlers" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "active" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "channel" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.channel.models.channel.Channel"
- }, {
- "type" : "null"
- } ]
- },
- "channel_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "channel_type" : { },
- "notification_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "recipients" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.notification.models.NotificationRecipient"
- }
- },
- "template" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplate"
- }, {
- "type" : "null"
- } ]
- },
- "template_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "channel_type" ]
- }
+ "stages" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.stages"
},
- "payload" : {
- "$ref" : "#/components/schemas/metabase.notification.models.NotificationCard"
+ "parameters" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.parameters"
},
- "subscriptions" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.notification.models.NotificationSubscription"
- }
+ "create-row" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
}
},
- "required" : [ "payload" ]
+ "required" : [ "lib/type", "lib/metadata", "stages" ]
}, {
+ "$ref" : "#/components/schemas/metabase.lib.schema.util.unique-uuids"
+ }, {
+ "allOf" : [ ]
+ } ]
+ } ]
+ },
+ "metabase.query-processor.schema..query-result.data" : {
+ "description" : "Schema for the :data key of query results.",
+ "type" : "object",
+ "properties" : {
+ "insights" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "results_metadata" : {
"type" : "object",
"properties" : {
- "creator" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "handlers" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "active" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "channel" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.channel.models.channel.Channel"
- }, {
- "type" : "null"
- } ]
- },
- "channel_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "channel_type" : { },
- "notification_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "recipients" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.notification.models.NotificationRecipient"
- }
- },
- "template" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.channel.models.channel.ChannelTemplate"
- }, {
- "type" : "null"
- } ]
- },
- "template_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "channel_type" ]
- }
- },
- "subscriptions" : {
+ "columns" : {
"type" : "array",
"items" : {
- "$ref" : "#/components/schemas/metabase.notification.models.NotificationSubscription"
+ "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
}
}
- }
- } ]
- } ]
- },
- "metabase.notification.models.Notification" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "payload_id" : {
- "type" : "null"
},
- "payload_type" : {
- "type" : "string",
- "enum" : [ "notification/dashboard", "notification/system-event", "notification/testing", "notification/card" ]
+ "required" : [ "columns" ]
+ },
+ "download_perms" : {
+ "type" : "string"
+ },
+ "format-rows?" : {
+ "type" : "boolean"
+ },
+ "is_sandboxed" : {
+ "type" : "boolean"
+ },
+ "cols" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
}
},
- "required" : [ "payload_type" ]
- }, {
- "type" : "object",
- "properties" : {
- "creator_id" : {
- "type" : "integer"
- },
- "payload_id" : {
- "type" : "integer"
- },
- "payload_type" : {
- "type" : "string",
- "enum" : [ "notification/dashboard", "notification/system-event", "notification/testing", "notification/card" ]
+ "results_timezone" : {
+ "type" : "string"
+ },
+ "rows" : {
+ "type" : "array",
+ "items" : {
+ "type" : "array",
+ "items" : { }
}
},
- "required" : [ "payload_type" ]
- }, { } ]
+ "native_form" : {
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "required" : [ "cols", "rows" ]
},
- "metabase.notification.models.NotificationCard" : {
- "description" : "Schema for :model/NotificationCard.",
+ "metabase.query-processor.schema..result-metadata.column" : {
+ "description" : "A single result metadata column as returned by the Query Processor.",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
+ },
+ "metabase.query-processor.schema.any-query" : {
+ "description" : "Schema for a map that is in the general shape of either a legacy MBQL or MBQL 5 query. Query may not be normalized\n yet!\n\n This schema is not very strict because we need to handle different types of queries (legacy MBQL, pMBQL,\n super-legacy MBQL, internal audit app queries, etc.) and it might not be normalized yet.",
"type" : "object",
"properties" : {
- "card" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : { }
+ "database" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
}, {
- "type" : "null"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
} ]
- },
- "card_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "send_condition" : {
- "type" : "string",
- "enum" : [ "goal_below", "has_result", "goal_above" ]
- },
- "send_once" : {
- "type" : "boolean"
}
- },
- "required" : [ "card_id" ]
+ }
},
- "metabase.notification.models.NotificationHandler" : {
+ "metabase.query-processor.schema.export-format" : {
+ "description" : "Schema for valid export formats for downloading query results.",
+ "type" : "string",
+ "enum" : [ "csv", "api", "xlsx", "json" ]
+ },
+ "metabase.query-processor.schema.query-result" : {
+ "description" : "Schema for query execution results returned by the Query Processor.",
"type" : "object",
"properties" : {
- "active" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "row_count" : {
+ "type" : "integer"
},
- "channel_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "error" : {
+ "type" : "string"
},
- "channel_type" : { },
- "notification_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "started_at" : {
+ "type" : "string"
},
- "template_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "channel_type" ]
- },
- "metabase.notification.models.NotificationRecipient" : {
- "description" : "Schema for :model/NotificationRecipient.",
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "details" : { },
- "notification_handler_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "permissions_group_id" : { },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
- },
- "user_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
},
- "required" : [ "type", "user_id" ]
- }, {
- "type" : "object",
- "properties" : {
- "details" : { },
- "notification_handler_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "permissions_group_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
- },
- "user_id" : { }
+ "context" : { },
+ "status" : {
+ "type" : "string",
+ "enum" : [ "completed", "failed" ]
},
- "required" : [ "type", "permissions_group_id" ]
- }, {
- "type" : "object",
- "properties" : {
- "details" : {
- "type" : "object",
- "properties" : {
- "value" : { }
- },
- "required" : [ "value" ],
- "additionalProperties" : false
- },
- "notification_handler_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "permissions_group_id" : { },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
- },
- "user_id" : { }
+ "error_type" : {
+ "type" : "string"
},
- "required" : [ "type", "details" ]
- }, {
- "type" : "object",
- "properties" : {
- "details" : {
- "type" : "object",
- "properties" : {
- "is_optional" : {
- "type" : "boolean"
- },
- "pattern" : {
- "type" : "string"
- }
- },
- "required" : [ "pattern" ],
- "additionalProperties" : false
- },
- "notification_handler_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "permissions_group_id" : { },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-recipient/raw-value", "notification-recipient/user", "notification-recipient/template", "notification-recipient/group" ]
- },
- "user_id" : { }
+ "running_time" : {
+ "type" : "integer"
},
- "required" : [ "type", "details" ]
- } ]
- },
- "metabase.notification.models.NotificationSubscription" : {
- "description" : "Schema for :model/NotificationSubscription.",
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "cron_schedule" : {
- "type" : "null"
- },
- "event_name" : {
- "anyOf" : [ {
- "type" : "string"
- }, {
- "type" : "string"
- } ]
- },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-subscription/cron", "notification-subscription/system-event" ]
- }
+ "json_query" : {
+ "type" : "object",
+ "properties" : { }
},
- "required" : [ "type", "event_name" ]
- }, {
- "type" : "object",
- "properties" : {
- "cron_schedule" : {
- "type" : "string"
- },
- "event_name" : {
+ "average_execution_time" : {
+ "oneOf" : [ {
+ "type" : "integer"
+ }, {
"type" : "null"
- },
- "type" : {
- "type" : "string",
- "enum" : [ "notification-subscription/cron", "notification-subscription/system-event" ]
- },
- "ui_display_type" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "cron/raw", "cron/builder" ]
- }, {
- "type" : "null"
- } ]
- }
+ } ]
},
- "required" : [ "type", "cron_schedule" ]
- } ]
- },
- "metabase.parameters.schema.legacy-ref" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter..target.legacy-expression-ref"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter..target.legacy-field-ref"
- } ]
+ "cached" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "data" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema..query-result.data"
+ }
+ },
+ "required" : [ "status", "row_count" ]
},
- "metabase.parameters.schema.parameter" : {
- "description" : "parameter must be a map with :id and :type keys",
+ "metabase.sync.schedules.ExpandedSchedulesMap" : {
+ "description" : "value must be a valid map of schedule maps for a DB.",
"type" : "object",
"properties" : {
- "filteringParameters" : {
+ "cache_field_values" : {
"oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
- }
+ "$ref" : "#/components/schemas/metabase.util.cron.ScheduleMap"
}, {
"type" : "null"
} ]
},
- "mappings" : {
+ "metadata_sync" : {
+ "$ref" : "#/components/schemas/metabase.util.cron.ScheduleMap"
+ }
+ }
+ },
+ "metabase.task-history.api.RunEntity" : {
+ "type" : "object",
+ "properties" : {
+ "entity_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "entity_name" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
- }
- }, {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
- },
- "uniqueItems" : true
- } ]
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "sectionId" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.common.non-blank-string"
+ "entity_type" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "card", "database" ]
+ }
+ },
+ "required" : [ "entity_type", "entity_id" ]
+ },
+ "metabase.task-history.api.RunFilterParams" : {
+ "type" : "object",
+ "properties" : {
+ "entity-id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
- "values_source_config" : {
+ "entity-type" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "card", "database" ]
+ },
+ "run-type" : {
+ "type" : "string",
+ "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
+ },
+ "started-at" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "status" : {
+ "type" : "string",
+ "enum" : [ "started", "success", "failed", "abandoned" ]
+ }
+ }
+ },
+ "metabase.task-history.api.TaskHistory" : {
+ "type" : "object",
+ "properties" : {
+ "task_details" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.values-source-config"
+ "type" : "object",
+ "properties" : { }
}, {
"type" : "null"
} ]
},
"id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
- "name" : {
- "type" : "string"
+ "started_at" : { },
+ "ended_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
},
- "slug" : {
- "type" : "string"
+ "status" : {
+ "type" : "string",
+ "enum" : [ "started", "success", "failed", "unknown" ]
},
- "values_query_type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.values-query-type"
- }, {
+ "logs" : {
+ "oneOf" : [ { }, {
"type" : "null"
} ]
},
- "type" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.type"
+ "task" : {
+ "type" : "string"
},
- "temporal_units" : {
+ "duration" : {
"oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.temporal-bucketing.unit"
- }
+ "type" : "integer"
}, {
"type" : "null"
} ]
},
- "target" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.target"
- },
- "values_source_type" : {
+ "run_id" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.values-source-type"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
- },
- "default" : { }
+ }
},
- "required" : [ "id", "type" ]
+ "required" : [ "id", "task", "started_at", "ended_at", "duration", "status" ]
},
- "metabase.parameters.schema.parameter-mapping" : {
- "description" : "parameter_mapping must be a map with :parameter_id and :target keys",
+ "metabase.task-history.api.TaskRun" : {
"type" : "object",
"properties" : {
- "card_id" : {
+ "run_type" : {
+ "type" : "string",
+ "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
+ },
+ "entity_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "started_at" : { },
+ "failed_count" : {
+ "type" : "integer"
+ },
+ "ended_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "entity_name" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "dashcard" : {
- "type" : "object",
- "properties" : { }
+ "status" : {
+ "type" : "string",
+ "enum" : [ "started", "success", "failed", "abandoned" ]
},
- "parameter_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ "task_count" : {
+ "type" : "integer"
},
- "target" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.target"
+ "success_count" : {
+ "type" : "integer"
+ },
+ "entity_type" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "card", "database" ]
}
},
- "required" : [ "parameter_id", "target" ]
- },
- "metabase.parameters.schema.parameter-mappings" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
- }
- },
- "metabase.parameters.schema.parameters" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
- }
- },
- "metabase.parameters.schema.values-query-type" : {
- "type" : "string",
- "enum" : [ "none", "list", "search" ]
+ "required" : [ "id", "run_type", "entity_type", "entity_id", "started_at", "ended_at", "status" ]
},
- "metabase.parameters.schema.values-source-config" : {
- "description" : "Schema for valid source_options within a Parameter",
+ "metabase.task-history.api.TaskRunWithTasks" : {
"type" : "object",
"properties" : {
- "card_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- },
- "label_field" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.legacy-ref"
- },
- "value_field" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.legacy-ref"
+ "run_type" : {
+ "type" : "string",
+ "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
},
- "values" : { }
- }
- },
- "metabase.parameters.schema.values-source-type" : {
- "type" : "string",
- "enum" : [ "static-list", "card" ]
- },
- "metabase.queries.schema..card.result-metadata" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata.lib-or-legacy-column"
- }
- },
- "metabase.queries.schema.card" : {
- "description" : "Schema for an instance of a `:model/Card` (everything is optional to support updates).",
- "type" : "object",
- "properties" : {
- "dataset_query" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema.query"
- }, {
- "type" : "null"
- } ]
+ "tasks" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.task-history.api.TaskHistory"
+ }
},
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
+ "entity_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
"id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- }, {
- "type" : "null"
- } ]
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
- "name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "started_at" : { },
+ "failed_count" : {
+ "type" : "integer"
},
- "database_id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- }, {
+ "ended_at" : {
+ "oneOf" : [ { }, {
"type" : "null"
} ]
},
- "document_id" : {
+ "entity_name" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.documents.schema..document.id"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "result_metadata" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema..card.result-metadata"
- }, {
- "type" : "null"
- } ]
+ "status" : {
+ "type" : "string",
+ "enum" : [ "started", "success", "failed", "abandoned" ]
},
- "collection_id" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.collection"
- }, {
- "type" : "null"
- } ]
+ "task_count" : {
+ "type" : "integer"
},
- "type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata..card.type"
- }, {
- "type" : "null"
- } ]
+ "success_count" : {
+ "type" : "integer"
},
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
+ "entity_type" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "card", "database" ]
+ }
+ },
+ "required" : [ "id", "run_type", "entity_type", "entity_id", "started_at", "ended_at", "status", "tasks" ]
+ },
+ "metabase.task-history.api.TaskRunsResponse" : {
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.task-history.api.TaskRun"
+ }
},
- "description" : {
+ "limit" : {
"oneOf" : [ {
- "type" : "string"
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
},
- "dashboard_id" : {
+ "offset" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.dashboard"
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
}, {
"type" : "null"
} ]
+ },
+ "total" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
}
- }
+ },
+ "required" : [ "total", "limit", "offset", "data" ]
},
- "metabase.queries.schema.card-type" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.metadata..card.type"
+ "metabase.tiles.api.legacy-ref" : {
+ "description" : "Form-encoded JSON-encoded legacy MBQL :field ref.",
+ "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
},
- "metabase.queries.schema.empty-map" : {
- "description" : "An empty map, allowed for Card.dataset_query for historic purposes.",
- "const" : { }
+ "metabase.tiles.api.parameters" : {
+ "description" : "Form-encoded JSON-encoded array of parameter maps.",
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
},
- "metabase.queries.schema.query" : {
- "description" : "Schema for Card.dataset_query. Cards are for some wacko reason allowed to be saved with empty queries (`{}`), but not\n `NULL` ones, because the column is non-null. This sorta seems like an oversight but fixing all the tests that save\n Cards with empty queries is too much to attempt at this point. So a Card either has an empty query or a valid MBQL 5\n query.",
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema.empty-map"
- }, {
- "allOf" : [ {
- "description" : "Valid MBQL 5 query.",
- "type" : "object",
- "properties" : {
- "lib/metadata" : {
- "description" : "Schema for something that satisfies the [[metabase.lib.metadata.protocols/MetadataProvider]] protocol."
- },
- "update-row" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
- },
- "lib/type" : {
- "default" : "mbql/query",
- "const" : "mbql/query"
- },
- "settings" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.settings.settings"
- },
- "constraints" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.constraints.constraints"
- },
- "info" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.info.info"
- },
- "middleware" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.middleware-options.middleware-options"
- },
- "database" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- } ]
- },
- "stages" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.stages"
- },
- "parameters" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.parameters"
- },
- "create-row" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.actions.row"
- }
- },
- "required" : [ "lib/type", "lib/metadata", "stages" ]
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.util.unique-uuids"
- }, {
- "allOf" : [ ]
- } ]
- } ]
+ "metabase.tiles.api.query" : {
+ "description" : "Form-encoded JSON-encoded MBQL query.",
+ "$ref" : "#/components/schemas/metabase.lib.schema.query"
},
- "metabase.query-processor.schema..query-result.data" : {
- "description" : "Schema for the :data key of query results.",
+ "metabase.timeline.api.timeline.Timeline" : {
"type" : "object",
"properties" : {
- "insights" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : { }
- }
- },
- "results_metadata" : {
- "type" : "object",
- "properties" : {
- "columns" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
- }
- }
- },
- "required" : [ "columns" ]
- },
- "download_perms" : {
- "type" : "string"
- },
- "format-rows?" : {
- "type" : "boolean"
- },
- "is_sandboxed" : {
- "type" : "boolean"
- },
- "cols" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema..result-metadata.column"
- }
- },
- "results_timezone" : {
- "type" : "string"
- },
- "rows" : {
- "type" : "array",
- "items" : {
- "type" : "array",
- "items" : { }
- }
- },
- "native_form" : {
- "type" : "object",
- "properties" : { }
+ "id" : {
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "cols", "rows" ]
+ "required" : [ "id" ]
},
- "metabase.query-processor.schema..result-metadata.column" : {
- "description" : "A single result metadata column as returned by the Query Processor.",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.legacy-column-metadata"
+ "metabase.timeline.api.timeline.include" : {
+ "type" : "string",
+ "enum" : [ "events" ]
},
- "metabase.query-processor.schema.any-query" : {
- "description" : "Schema for a map that is in the general shape of either a legacy MBQL or MBQL 5 query. Query may not be normalized\n yet!\n\n This schema is not very strict because we need to handle different types of queries (legacy MBQL, pMBQL,\n super-legacy MBQL, internal audit app queries, etc.) and it might not be normalized yet.",
+ "metabase.users-rest.api.user-group-membership" : {
+ "description" : "Group Membership info of a User.\n In which :is_group_manager is only included if `advanced-permissions` is enabled.",
"type" : "object",
"properties" : {
- "database" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- }, {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.saved-questions-virtual-database"
- } ]
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "is_group_manager" : {
+ "description" : "Only relevant if `advanced-permissions` is enabled. If it is, you should always include this key.",
+ "type" : "boolean"
}
- }
+ },
+ "required" : [ "id" ]
},
- "metabase.query-processor.schema.export-format" : {
- "description" : "Schema for valid export formats for downloading query results.",
+ "metabase.util.cron.CronHour" : {
+ "type" : "integer",
+ "minimum" : 0,
+ "maximum" : 23
+ },
+ "metabase.util.cron.CronMinute" : {
+ "type" : "integer",
+ "minimum" : 0,
+ "maximum" : 59
+ },
+ "metabase.util.cron.CronScheduleString" : {
+ "description" : "value must be a valid Quartz cron schedule string.",
"type" : "string",
- "enum" : [ "csv", "api", "xlsx", "json" ]
+ "minLength" : 1
},
- "metabase.query-processor.schema.query-result" : {
- "description" : "Schema for query execution results returned by the Query Processor.",
+ "metabase.util.cron.ScheduleMap" : {
+ "description" : "value must be a valid schedule map. See schema in metabase.util.cron for details.",
"type" : "object",
"properties" : {
- "row_count" : {
- "type" : "integer"
- },
- "error" : {
- "type" : "string"
- },
- "started_at" : {
- "type" : "string"
- },
- "database_id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.database"
- },
- "context" : { },
- "status" : {
- "type" : "string",
- "enum" : [ "completed", "failed" ]
- },
- "error_type" : {
- "type" : "string"
- },
- "running_time" : {
- "type" : "integer"
+ "schedule_day" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "sun", "mon", "tue", "wed", "thu", "fri", "sat" ]
+ }, {
+ "type" : "null"
+ } ]
},
- "json_query" : {
- "type" : "object",
- "properties" : { }
+ "schedule_frame" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "first", "mid", "last" ]
+ }, {
+ "type" : "null"
+ } ]
},
- "average_execution_time" : {
+ "schedule_hour" : {
"oneOf" : [ {
- "type" : "integer"
+ "$ref" : "#/components/schemas/metabase.util.cron.CronHour"
}, {
"type" : "null"
} ]
},
- "cached" : {
+ "schedule_minute" : {
"oneOf" : [ {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.util.cron.CronMinute"
}, {
"type" : "null"
} ]
},
- "data" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema..query-result.data"
+ "schedule_type" : {
+ "type" : "string",
+ "enum" : [ "hourly", "daily", "weekly", "monthly" ]
}
},
- "required" : [ "status", "row_count" ]
+ "required" : [ "schedule_type" ]
},
- "metabase.sync.schedules.ExpandedSchedulesMap" : {
- "description" : "value must be a valid map of schedule maps for a DB.",
+ "metabase.warehouse-schema-rest.api.table.data-authority-write" : {
+ "description" : "Schema for writing a valid table data authority.",
+ "type" : "string",
+ "enum" : [ "computed", "authoritative", "unconfigured", "ingested" ]
+ },
+ "metabase.warehouse-schema-rest.api.table.data-layers" : {
+ "type" : "string",
+ "enum" : [ "copper", "bronze", "gold", "silver" ]
+ },
+ "metabase.warehouse-schema-rest.api.table.data-sources" : {
+ "type" : "string",
+ "enum" : [ "source-data", "transform", "unknown", "ingested", "metabase-transform", "upload" ]
+ },
+ "metabase.warehouses-rest.api.available-settings" : {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "object",
+ "properties" : {
+ "enabled" : {
+ "type" : "boolean"
+ },
+ "reasons" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "key" : {
+ "type" : "string"
+ },
+ "message" : {
+ "anyOf" : [ {
+ "type" : "string"
+ }, { } ]
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "error", "warning" ]
+ }
+ },
+ "required" : [ "key", "type", "message" ]
+ }
+ }
+ },
+ "required" : [ "enabled" ]
+ }
+ },
+ "metabase.xrays.api.automagic-dashboards.base-64-encoded-json" : {
+ "description" : "form-encoded base-64-encoded JSON"
+ },
+ "metabase.xrays.api.automagic-dashboards.entity-id-or-query" : {
+ "description" : "One of these:\n\n * A non-empty string with an Entity ID (including `card__<id>`-encoded Card IDs)\n\n * a form-encoded base-64-encoded JSON-encoded MBQL query\n\n * The name of a transform\n\n (Effectively since the names of transforms are unconstrained this parameter is allowed to be any form-encoded\n string.)",
+ "type" : "string",
+ "minLength" : 1
+ },
+ "metabot.reaction.redirect" : {
"type" : "object",
"properties" : {
- "cache_field_values" : {
+ "type" : {
+ "const" : "metabot.reaction/redirect"
+ },
+ "url" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "type", "url" ]
+ }
+ }
+ },
+ "paths" : {
+ "/api/action/" : {
+ "get" : {
+ "summary" : "GET /api/action/",
+ "description" : "Returns actions that can be used for QueryActions. By default lists all viewable actions. Pass optional\n `?model-id=<model-id>` to limit to actions on a particular model.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "model-id",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.util.cron.ScheduleMap"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
}, {
"type" : "null"
} ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ }
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/action" ]
+ },
+ "post" : {
+ "summary" : "POST /api/action/",
+ "description" : "Create a new action.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema..action.for-insert"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/public" : {
+ "get" : {
+ "summary" : "GET /api/action/public",
+ "description" : "Fetch a list of Actions with public UUIDs. These actions are publicly-accessible *if* public sharing is enabled.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ }
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/{action-id}" : {
+ "get" : {
+ "summary" : "GET /api/action/{action-id}",
+ "description" : "Fetch an Action.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "action-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
},
- "metadata_sync" : {
- "$ref" : "#/components/schemas/metabase.util.cron.ScheduleMap"
+ "5XX" : {
+ "description" : "Server error response"
}
- }
+ },
+ "tags" : [ "/api/action" ]
},
- "metabase.task-history.api.RunEntity" : {
- "type" : "object",
- "properties" : {
- "entity_id" : {
- "description" : "value must be an integer greater than zero.",
+ "delete" : {
+ "summary" : "DELETE /api/action/{action-id}",
+ "description" : "Delete an Action.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "action-id",
+ "required" : true,
+ "schema" : {
"type" : "integer",
"minimum" : 1
},
- "entity_name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "entity_type" : {
- "type" : "string",
- "enum" : [ "dashboard", "card", "database" ]
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "entity_type", "entity_id" ]
- },
- "metabase.task-history.api.RunFilterParams" : {
- "type" : "object",
- "properties" : {
- "entity-id" : {
- "description" : "value must be an integer greater than zero.",
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/{action-id}/execute" : {
+ "get" : {
+ "summary" : "GET /api/action/{action-id}/execute",
+ "description" : "Fetches the values for filling in execution parameters. Pass PK parameters and values to select.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "action-id",
+ "required" : true,
+ "schema" : {
"type" : "integer",
"minimum" : 1
},
- "entity-type" : {
- "type" : "string",
- "enum" : [ "dashboard", "card", "database" ]
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "parameters",
+ "required" : true,
+ "schema" : {
+ "type" : "string"
},
- "run-type" : {
- "type" : "string",
- "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
+ "description" : "value must be a valid JSON string."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "started-at" : {
- "type" : "string",
- "minLength" : 1
+ "4XX" : {
+ "description" : "Client error response"
},
- "status" : {
- "type" : "string",
- "enum" : [ "started", "success", "failed", "abandoned" ]
+ "5XX" : {
+ "description" : "Server error response"
}
- }
- },
- "metabase.task-history.api.TaskHistory" : {
- "type" : "object",
- "properties" : {
- "task_details" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/{id}" : {
+ "put" : {
+ "summary" : "PUT /api/action/{id}",
+ "description" : "Update an Action.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "started_at" : { },
- "ended_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "status" : {
- "type" : "string",
- "enum" : [ "started", "success", "failed", "unknown" ]
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema..action.for-update"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/{id}/execute" : {
+ "post" : {
+ "summary" : "POST /api/action/{id}/execute",
+ "description" : "Execute the Action.\n\n `parameters` should be the mapped dashboard parameters with values.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "logs" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "task" : {
- "type" : "string"
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "parameters" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/action/{id}/public_link" : {
+ "post" : {
+ "summary" : "POST /api/action/{id}/public_link",
+ "description" : "Generate publicly-accessible links for this Action. Returns UUID to be used in public links. (If this\n Action has already been shared, it will return the existing public link rather than creating a new one.) Public\n sharing must be enabled.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "duration" : {
- "oneOf" : [ {
- "type" : "integer"
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "run_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "id", "task", "started_at", "ended_at", "duration", "status" ]
+ "tags" : [ "/api/action" ]
},
- "metabase.task-history.api.TaskRun" : {
- "type" : "object",
- "properties" : {
- "run_type" : {
- "type" : "string",
- "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
- },
- "entity_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "delete" : {
+ "summary" : "DELETE /api/action/{id}/public_link",
+ "description" : "Delete the publicly-accessible link to this Dashboard.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "4XX" : {
+ "description" : "Client error response"
},
- "started_at" : { },
- "failed_count" : {
- "type" : "integer"
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/action" ]
+ }
+ },
+ "/api/activity/most_recently_viewed_dashboard" : {
+ "get" : {
+ "summary" : "GET /api/activity/most_recently_viewed_dashboard",
+ "description" : "Get the most recently viewed dashboard for the current user. Returns a 204 if the user has not viewed any dashboards\n in the last 24 hours.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "ended_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "entity_name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/activity" ]
+ }
+ },
+ "/api/activity/popular_items" : {
+ "get" : {
+ "summary" : "GET /api/activity/popular_items",
+ "description" : "Get the list of 5 popular things on the instance. Query takes 8 and limits to 5 so that if it finds anything\n archived, deleted, etc it can usually still get 5. ",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "status" : {
- "type" : "string",
- "enum" : [ "started", "success", "failed", "abandoned" ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "task_count" : {
- "type" : "integer"
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/activity" ]
+ }
+ },
+ "/api/activity/recent_views" : {
+ "get" : {
+ "summary" : "GET /api/activity/recent_views",
+ "description" : "Get a list of 100 models (cards, models, tables, dashboards, and collections) that the current user has been viewing most\n recently. Return a maximum of 20 model of each, if they've looked at at least 20.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "success_count" : {
- "type" : "integer"
+ "4XX" : {
+ "description" : "Client error response"
},
- "entity_type" : {
- "type" : "string",
- "enum" : [ "dashboard", "card", "database" ]
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "id", "run_type", "entity_type", "entity_id", "started_at", "ended_at", "status" ]
- },
- "metabase.task-history.api.TaskRunWithTasks" : {
- "type" : "object",
- "properties" : {
- "run_type" : {
- "type" : "string",
- "enum" : [ "alert", "sync", "fingerprint", "subscription" ]
- },
- "tasks" : {
+ "deprecated" : true,
+ "tags" : [ "/api/activity" ]
+ }
+ },
+ "/api/activity/recents" : {
+ "get" : {
+ "summary" : "GET /api/activity/recents",
+ "description" : "Get a list of recent items the current user has been viewing most recently under the `:recents` key.\n Allows for filtering by context: views or selections",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "context",
+ "required" : true,
+ "schema" : {
"type" : "array",
"items" : {
- "$ref" : "#/components/schemas/metabase.task-history.api.TaskHistory"
+ "type" : "string",
+ "enum" : [ "selections", "views" ]
}
- },
- "entity_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "started_at" : { },
- "failed_count" : {
- "type" : "integer"
- },
- "ended_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
- "entity_name" : {
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_metadata",
+ "required" : true,
+ "schema" : {
+ "default" : false,
"oneOf" : [ {
- "type" : "string"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "status" : {
- "type" : "string",
- "enum" : [ "started", "success", "failed", "abandoned" ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "task_count" : {
- "type" : "integer"
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/activity" ]
+ },
+ "post" : {
+ "summary" : "POST /api/activity/recents",
+ "description" : "Adds a model to the list of recently selected items.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "success_count" : {
- "type" : "integer"
+ "4XX" : {
+ "description" : "Client error response"
},
- "entity_type" : {
- "type" : "string",
- "enum" : [ "dashboard", "card", "database" ]
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "id", "run_type", "entity_type", "entity_id", "started_at", "ended_at", "status", "tasks" ]
- },
- "metabase.task-history.api.TaskRunsResponse" : {
- "type" : "object",
- "properties" : {
- "data" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.task-history.api.TaskRun"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "context" : {
+ "type" : "string",
+ "enum" : [ "selection" ]
+ },
+ "model" : {
+ "type" : "string",
+ "enum" : [ "card", "dataset", "metric", "dashboard", "table", "collection", "document" ]
+ },
+ "model_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "model", "model_id", "context" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/activity" ]
+ }
+ },
+ "/api/agent/v1/construct-query" : {
+ "post" : {
+ "summary" : "POST /api/agent/v1/construct-query",
+ "description" : "Construct an MBQL query from a table or metric.\n\n Returns a base64-encoded MBQL query that can be used with the query API.\n\n For tables, supports: filters, fields, aggregations, group_by, order_by, limit.\n For metrics, supports: filters, group_by (aggregation is defined by the metric).",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.construct-query-response"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.construct-query-request"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/agent" ]
+ }
+ },
+ "/api/agent/v1/execute" : {
+ "post" : {
+ "summary" : "POST /api/agent/v1/execute",
+ "description" : "Execute an MBQL query and return results.\n\n Accepts a base64-encoded MBQL query (as returned by /v1/construct-query) and executes it,\n returning results with column metadata.\n\n Response format:\n - On success: {:data {:cols [...] :rows [...]} :row_count N :status :completed :running_time M}\n - On failure: {:status :failed :error \"message\" ...}\n\n Standard userspace query limits are enforced (2000 rows for simple queries, 10000 for aggregated).",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.execute-query-response"
+ }
+ }
}
},
- "limit" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "offset" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "total" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "total", "limit", "offset", "data" ]
- },
- "metabase.tiles.api.legacy-ref" : {
- "description" : "Form-encoded JSON-encoded legacy MBQL :field ref.",
- "$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field"
- },
- "metabase.tiles.api.parameters" : {
- "description" : "Form-encoded JSON-encoded array of parameter maps.",
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- },
- "metabase.tiles.api.query" : {
- "description" : "Form-encoded JSON-encoded MBQL query.",
- "$ref" : "#/components/schemas/metabase.lib.schema.query"
- },
- "metabase.timeline.api.timeline.Timeline" : {
- "type" : "object",
- "properties" : {
- "id" : {
- "type" : "integer",
- "minimum" : 1
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.execute-query-request"
+ }
+ }
}
},
- "required" : [ "id" ]
- },
- "metabase.timeline.api.timeline.include" : {
- "type" : "string",
- "enum" : [ "events" ]
- },
- "metabase.users-rest.api.user-group-membership" : {
- "description" : "Group Membership info of a User.\n In which :is_group_manager is only included if `advanced-permissions` is enabled.",
- "type" : "object",
- "properties" : {
- "id" : {
- "description" : "value must be an integer greater than zero.",
+ "tags" : [ "/api/agent" ]
+ }
+ },
+ "/api/agent/v1/metric/{id}" : {
+ "get" : {
+ "summary" : "GET /api/agent/v1/metric/{id}",
+ "description" : "Get details for a metric by ID.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
"type" : "integer",
"minimum" : 1
},
- "is_group_manager" : {
- "description" : "Only relevant if `advanced-permissions` is enabled. If it is, you should always include this key.",
- "type" : "boolean"
- }
- },
- "required" : [ "id" ]
- },
- "metabase.util.cron.CronHour" : {
- "type" : "integer",
- "minimum" : 0,
- "maximum" : 23
- },
- "metabase.util.cron.CronMinute" : {
- "type" : "integer",
- "minimum" : 0,
- "maximum" : 59
- },
- "metabase.util.cron.CronScheduleString" : {
- "description" : "value must be a valid Quartz cron schedule string.",
- "type" : "string",
- "minLength" : 1
- },
- "metabase.util.cron.ScheduleMap" : {
- "description" : "value must be a valid schedule map. See schema in metabase.util.cron for details.",
- "type" : "object",
- "properties" : {
- "schedule_day" : {
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "with-default-temporal-breakout",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "type" : "string",
- "enum" : [ "sun", "mon", "tue", "wed", "thu", "fri", "sat" ]
+ "type" : "boolean"
}, {
"type" : "null"
} ]
- },
- "schedule_frame" : {
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-field-values",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "type" : "string",
- "enum" : [ "first", "mid", "last" ]
+ "type" : "boolean"
}, {
"type" : "null"
} ]
- },
- "schedule_hour" : {
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-queryable-dimensions",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.util.cron.CronHour"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
- },
- "schedule_minute" : {
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-segments",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.util.cron.CronMinute"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
- },
- "schedule_type" : {
- "type" : "string",
- "enum" : [ "hourly", "daily", "weekly", "monthly" ]
}
- },
- "required" : [ "schedule_type" ]
- },
- "metabase.warehouse-schema-rest.api.table.data-authority-write" : {
- "description" : "Schema for writing a valid table data authority.",
- "type" : "string",
- "enum" : [ "computed", "authoritative", "unconfigured", "ingested" ]
- },
- "metabase.warehouse-schema-rest.api.table.data-layers" : {
- "type" : "string",
- "enum" : [ "copper", "bronze", "gold", "silver" ]
- },
- "metabase.warehouse-schema-rest.api.table.data-sources" : {
- "type" : "string",
- "enum" : [ "source-data", "transform", "unknown", "ingested", "metabase-transform", "upload" ]
- },
- "metabase.warehouses-rest.api.available-settings" : {
- "type" : "object",
- "additionalProperties" : {
- "type" : "object",
- "properties" : {
- "enabled" : {
- "type" : "boolean"
- },
- "reasons" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "key" : {
- "type" : "string"
- },
- "message" : {
- "anyOf" : [ {
- "type" : "string"
- }, { } ]
- },
- "type" : {
- "type" : "string",
- "enum" : [ "error", "warning" ]
- }
- },
- "required" : [ "key", "type", "message" ]
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.metric"
+ }
}
}
},
- "required" : [ "enabled" ]
- }
- },
- "metabase.xrays.api.automagic-dashboards.base-64-encoded-json" : {
- "description" : "form-encoded base-64-encoded JSON"
- },
- "metabase.xrays.api.automagic-dashboards.entity-id-or-query" : {
- "description" : "One of these:\n\n * A non-empty string with an Entity ID (including `card__<id>`-encoded Card IDs)\n\n * a form-encoded base-64-encoded JSON-encoded MBQL query\n\n * The name of a transform\n\n (Effectively since the names of transforms are unconstrained this parameter is allowed to be any form-encoded\n string.)",
- "type" : "string",
- "minLength" : 1
- },
- "metabot.reaction.redirect" : {
- "type" : "object",
- "properties" : {
- "type" : {
- "const" : "metabot.reaction/redirect"
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/agent" ]
+ }
+ },
+ "/api/agent/v1/metric/{id}/field/{field-id}/values" : {
+ "get" : {
+ "summary" : "GET /api/agent/v1/metric/{id}/field/{field-id}/values",
+ "description" : "Get statistics and sample values for a metric field.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "field-id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.field-values"
+ }
+ }
+ }
},
- "url" : {
- "type" : "string"
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "required" : [ "type", "url" ]
+ "tags" : [ "/api/agent" ]
}
- }
- },
- "paths" : {
- "/api/action/" : {
+ },
+ "/api/agent/v1/ping" : {
"get" : {
- "summary" : "GET /api/action/",
- "description" : "Returns actions that can be used for QueryActions. By default lists all viewable actions. Pass optional\n `?model-id=<model-id>` to limit to actions on a particular model.",
- "parameters" : [ {
- "in" : "query",
- "name" : "model-id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- }, {
- "type" : "null"
- } ]
- }
- } ],
+ "summary" : "GET /api/agent/v1/ping",
+ "description" : "Health check endpoint for the Agent API.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.action"
- }
+ "type" : "object",
+ "properties" : {
+ "message" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "message" ]
}
}
}
@@ -13671,11 +14800,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
- },
+ "tags" : [ "/api/agent" ]
+ }
+ },
+ "/api/agent/v1/search" : {
"post" : {
- "summary" : "POST /api/action/",
- "description" : "Create a new action.",
+ "summary" : "POST /api/agent/v1/search",
+ "description" : "Search for tables and metrics.\n\n Supports both term-based and semantic search queries. Results are ranked using\n Reciprocal Rank Fusion when both query types are provided.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -13683,7 +14814,7 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.search-response"
}
}
}
@@ -13699,29 +14830,125 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema..action.for-insert"
+ "type" : "object",
+ "properties" : {
+ "semantic_queries" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "term_queries" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
}
}
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/agent" ]
}
},
- "/api/action/public" : {
+ "/api/agent/v1/table/{id}" : {
"get" : {
- "summary" : "GET /api/action/public",
- "description" : "Fetch a list of Actions with public UUIDs. These actions are publicly-accessible *if* public sharing is enabled.",
- "parameters" : [ ],
+ "summary" : "GET /api/agent/v1/table/{id}",
+ "description" : "Get details for a table by ID.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "with-field-values",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-fields",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-related-tables",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-metrics",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-measures",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "with-segments",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.action"
- }
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.table"
}
}
}
@@ -13733,22 +14960,30 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/agent" ]
}
},
- "/api/action/{action-id}" : {
+ "/api/agent/v1/table/{id}/field/{field-id}/values" : {
"get" : {
- "summary" : "GET /api/action/{action-id}",
- "description" : "Fetch an Action.",
+ "summary" : "GET /api/agent/v1/table/{id}/field/{field-id}/values",
+ "description" : "Get statistics and sample values for a table field.",
"parameters" : [ {
"in" : "path",
- "name" : "action-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "field-id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
} ],
"responses" : {
"2XX" : {
@@ -13756,7 +14991,7 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.action"
+ "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.field-values"
}
}
}
@@ -13768,14 +15003,60 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
- },
- "delete" : {
- "summary" : "DELETE /api/action/{action-id}",
- "description" : "Delete an Action.",
+ "tags" : [ "/api/agent" ]
+ }
+ },
+ "/api/alert/" : {
+ "get" : {
+ "summary" : "GET /api/alert/",
+ "description" : "Fetch alerts which the current user has created or will receive, or all alerts if the user is an admin.\n The optional `user_id` will return alerts created by the corresponding user, but is ignored for non-admin users.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "archived",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "user_id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/alert" ]
+ }
+ },
+ "/api/alert/{id}" : {
+ "get" : {
+ "summary" : "GET /api/alert/{id}",
+ "description" : "Fetch an alert by ID",
"parameters" : [ {
"in" : "path",
- "name" : "action-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -13794,30 +15075,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/alert" ]
}
},
- "/api/action/{action-id}/execute" : {
- "get" : {
- "summary" : "GET /api/action/{action-id}/execute",
- "description" : "Fetches the values for filling in execution parameters. Pass PK parameters and values to select.",
+ "/api/alert/{id}/subscription" : {
+ "delete" : {
+ "summary" : "DELETE /api/alert/{id}/subscription",
+ "description" : "For users to unsubscribe themselves from the given alert.",
"parameters" : [ {
"in" : "path",
- "name" : "action-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "parameters",
- "required" : true,
- "schema" : {
- "type" : "string"
- },
- "description" : "value must be a valid JSON string."
} ],
"responses" : {
"2XX" : {
@@ -13830,21 +15103,33 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/alert" ]
}
},
- "/api/action/{id}" : {
- "put" : {
- "summary" : "PUT /api/action/{id}",
- "description" : "Update an Action.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ "/api/analytics/anonymous-stats" : {
+ "get" : {
+ "summary" : "GET /api/analytics/anonymous-stats",
+ "description" : "Anonymous usage stats. Endpoint for testing, and eventually exposing this to instance admins to let them see\n what is being phoned home.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- } ],
+ },
+ "tags" : [ "/api/analytics" ]
+ }
+ },
+ "/api/api-key/" : {
+ "post" : {
+ "summary" : "POST /api/api-key/",
+ "description" : "Create a new API key (and an associated `User`) with the provided name and group ID.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -13860,25 +15145,73 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema..action.for-update"
+ "type" : "object",
+ "properties" : {
+ "group_id" : {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "group_id", "name" ]
}
}
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/api-key" ]
+ },
+ "get" : {
+ "summary" : "GET /api/api-key/",
+ "description" : "Get a list of API keys with the default scope. Non-paginated.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/api-key" ]
}
},
- "/api/action/{id}/execute" : {
- "post" : {
- "summary" : "POST /api/action/{id}/execute",
- "description" : "Execute the Action.\n\n `parameters` should be the mapped dashboard parameters with values.",
+ "/api/api-key/count" : {
+ "get" : {
+ "summary" : "GET /api/api-key/count",
+ "description" : "Get the count of API keys in the DB with the default scope.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/api-key" ]
+ }
+ },
+ "/api/api-key/{id}" : {
+ "put" : {
+ "summary" : "PUT /api/api-key/{id}",
+ "description" : "Update an API key by changing its group and/or its name",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -13895,38 +15228,40 @@
"content" : {
"application/json" : {
"schema" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "parameters" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : { }
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "object",
+ "properties" : {
+ "group_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.name"
+ }, {
+ "type" : "null"
+ } ]
}
- }, {
- "type" : "null"
- } ]
+ }
}
}
}
},
- "tags" : [ "/api/action" ]
- }
- },
- "/api/action/{id}/public_link" : {
- "post" : {
- "summary" : "POST /api/action/{id}/public_link",
- "description" : "Generate publicly-accessible links for this Action. Returns UUID to be used in public links. (If this\n Action has already been shared, it will return the existing public link rather than creating a new one.) Public\n sharing must be enabled.",
+ "tags" : [ "/api/api-key" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/api-key/{id}",
+ "description" : "Delete an ApiKey",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
}
} ],
"responses" : {
@@ -13940,22 +15275,46 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
- },
- "delete" : {
- "summary" : "DELETE /api/action/{id}/public_link",
- "description" : "Delete the publicly-accessible link to this Dashboard.",
+ "tags" : [ "/api/api-key" ]
+ }
+ },
+ "/api/api-key/{id}/regenerate" : {
+ "put" : {
+ "summary" : "PUT /api/api-key/{id}/regenerate",
+ "description" : "Regenerate an API Key",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.actions.schema.id"
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
+ },
+ "masked_key" : {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema..key.masked"
+ },
+ "prefix" : {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema.prefix"
+ },
+ "unmasked_key" : {
+ "$ref" : "#/components/schemas/metabase.api-keys.schema..key.raw"
+ }
+ },
+ "required" : [ "id", "unmasked_key", "masked_key", "prefix" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -13964,14 +15323,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/action" ]
+ "tags" : [ "/api/api-key" ]
}
},
- "/api/activity/most_recently_viewed_dashboard" : {
+ "/api/automagic-dashboards/database/{id}/candidates" : {
"get" : {
- "summary" : "GET /api/activity/most_recently_viewed_dashboard",
- "description" : "Get the most recently viewed dashboard for the current user. Returns a 204 if the user has not viewed any dashboards\n in the last 24 hours.",
- "parameters" : [ ],
+ "summary" : "GET /api/automagic-dashboards/database/{id}/candidates",
+ "description" : "Return a list of candidates for automagic dashboards ordered by interestingness.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -13983,33 +15351,28 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/activity" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/activity/popular_items" : {
+ "/api/automagic-dashboards/model_index/{model-index-id}/primary_key/{pk-id}" : {
"get" : {
- "summary" : "GET /api/activity/popular_items",
- "description" : "Get the list of 5 popular things on the instance. Query takes 8 and limits to 5 so that if it finds anything\n archived, deleted, etc it can usually still get 5. ",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "summary" : "GET /api/automagic-dashboards/model_index/{model-index-id}/primary_key/{pk-id}",
+ "description" : "Return an automagic dashboard for an entity detail specified by `entity`\n with id `id` and a primary key of `indexed-value`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "model-index-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer"
+ }
+ }, {
+ "in" : "path",
+ "name" : "pk-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer"
}
- },
- "tags" : [ "/api/activity" ]
- }
- },
- "/api/activity/recent_views" : {
- "get" : {
- "summary" : "GET /api/activity/recent_views",
- "description" : "Get a list of 100 models (cards, models, tables, dashboards, and collections) that the current user has been viewing most\n recently. Return a maximum of 20 model of each, if they've looked at at least 20.",
- "parameters" : [ ],
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -14021,33 +15384,40 @@
"description" : "Server error response"
}
},
- "deprecated" : true,
- "tags" : [ "/api/activity" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/activity/recents" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}" : {
"get" : {
- "summary" : "GET /api/activity/recents",
- "description" : "Get a list of recent items the current user has been viewing most recently under the `:recents` key.\n Allows for filtering by context: views or selections",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}",
+ "description" : "Return an automagic dashboard for entity `entity` with id `id`.",
"parameters" : [ {
- "in" : "query",
- "name" : "context",
+ "in" : "path",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "selections", "views" ]
- }
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
}
}, {
- "in" : "query",
- "name" : "include_metadata",
+ "in" : "path",
+ "name" : "entity-id-or-query",
"required" : true,
"schema" : {
- "default" : false,
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ }
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "type" : "boolean"
+ "anyOf" : [ {
+ "const" : "all"
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
}, {
"type" : "null"
} ]
@@ -14064,101 +15434,57 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/activity" ]
- },
- "post" : {
- "summary" : "POST /api/activity/recents",
- "description" : "Adds a model to the list of recently selected items.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "context" : {
- "type" : "string",
- "enum" : [ "selection" ]
- },
- "model" : {
- "type" : "string",
- "enum" : [ "card", "dataset", "metric", "dashboard", "table", "collection", "document" ]
- },
- "model_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "model", "model_id", "context" ]
- }
- }
- }
- },
- "tags" : [ "/api/activity" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/agent/v1/construct-query" : {
- "post" : {
- "summary" : "POST /api/agent/v1/construct-query",
- "description" : "Construct an MBQL query from a table or metric.\n\n Returns a base64-encoded MBQL query that can be used with the query API.\n\n For tables, supports: filters, fields, aggregations, group_by, order_by, limit.\n For metrics, supports: filters, group_by (aggregation is defined by the metric).",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.construct-query-response"
- }
- }
- }
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}" : {
+ "get" : {
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}",
+ "description" : "Return an automagic dashboard analyzing cell in automagic dashboard for entity `entity` defined by query\n `cell-query`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "entity",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
}
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.construct-query-request"
- }
- }
+ }, {
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
- },
- "tags" : [ "/api/agent" ]
- }
- },
- "/api/agent/v1/execute" : {
- "post" : {
- "summary" : "POST /api/agent/v1/execute",
- "description" : "Execute an MBQL query and return results.\n\n Accepts a base64-encoded MBQL query (as returned by /v1/construct-query) and executes it,\n returning results with column metadata.\n\n Response format:\n - On success: {:data {:cols [...] :rows [...]} :row_count N :status :completed :running_time M}\n - On failure: {:status :failed :error \"message\" ...}\n\n Standard userspace query limits are enforced (2000 rows for simple queries, 10000 for aggregated).",
- "parameters" : [ ],
+ }, {
+ "in" : "path",
+ "name" : "cell-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
+ }
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "invalid show value"
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14167,86 +15493,73 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.execute-query-request"
- }
- }
- }
- },
- "tags" : [ "/api/agent" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/agent/v1/metric/{id}" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
"get" : {
- "summary" : "GET /api/agent/v1/metric/{id}",
- "description" : "Get details for a metric by ID.",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
+ "description" : "Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`\n with id `id` defined by query `cell-query`; compared with entity `comparison-entity` with id\n `comparison-entity-id-or-query.`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
+ }
}, {
- "in" : "query",
- "name" : "with-default-temporal-breakout",
- "required" : false,
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
}, {
- "in" : "query",
- "name" : "with-field-values",
- "required" : false,
+ "in" : "path",
+ "name" : "cell-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
}
}, {
- "in" : "query",
- "name" : "with-queryable-dimensions",
- "required" : false,
+ "in" : "path",
+ "name" : "comparison-entity",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "type" : "string",
+ "enum" : [ "adhoc", "segment", "table" ]
+ },
+ "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
+ }, {
+ "in" : "path",
+ "name" : "comparison-entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
}, {
"in" : "query",
- "name" : "with-segments",
+ "name" : "show",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "boolean"
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
}, {
"type" : "null"
} ]
- }
+ },
+ "description" : "invalid show value"
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.metric"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14255,99 +15568,68 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/agent" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/agent/v1/metric/{id}/field/{field-id}/values" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}" : {
"get" : {
- "summary" : "GET /api/agent/v1/metric/{id}/field/{field-id}/values",
- "description" : "Get statistics and sample values for a metric field.",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}",
+ "description" : "Return an automagic dashboard analyzing cell in question with id `id` defined by query `cell-query` using\n dashboard-template `dashboard-template`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
+ }
}, {
"in" : "path",
- "name" : "field-id",
+ "name" : "entity-id-or-query",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.field-values"
- }
- }
- }
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ }, {
+ "in" : "path",
+ "name" : "prefix",
+ "required" : true,
+ "schema" : { }
+ }, {
+ "in" : "path",
+ "name" : "dashboard-template",
+ "required" : true,
+ "schema" : { },
+ "description" : "invalid value for dashboard template name"
+ }, {
+ "in" : "path",
+ "name" : "cell-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
}
- },
- "tags" : [ "/api/agent" ]
- }
- },
- "/api/agent/v1/ping" : {
- "get" : {
- "summary" : "GET /api/agent/v1/ping",
- "description" : "Health check endpoint for the Agent API.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "message" : {
- "type" : "string"
- }
- },
- "required" : [ "message" ]
- }
- }
- }
- },
- "4XX" : {
- "description" : "Client error response"
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
+ }, {
+ "type" : "null"
+ } ]
},
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/agent" ]
- }
- },
- "/api/agent/v1/search" : {
- "post" : {
- "summary" : "POST /api/agent/v1/search",
- "description" : "Search for tables and metrics.\n\n Supports both term-based and semantic search queries. Results are ranked using\n Reciprocal Rank Fusion when both query types are provided.",
- "parameters" : [ ],
+ "description" : "invalid show value"
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.search-response"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14356,132 +15638,84 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "semantic_queries" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- }, {
- "type" : "null"
- } ]
- },
- "term_queries" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
- }
- },
- "tags" : [ "/api/agent" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/agent/v1/table/{id}" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
"get" : {
- "summary" : "GET /api/agent/v1/table/{id}",
- "description" : "Get details for a table by ID.",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
+ "description" : "Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`\n with id `id` defined by query `cell-query` using dashboard-template `dashboard-template`; compared with entity\n `comparison-entity` with id `comparison-entity-id-or-query.`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "with-field-values",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
}
}, {
- "in" : "query",
- "name" : "with-fields",
- "required" : false,
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
}, {
- "in" : "query",
- "name" : "with-related-tables",
- "required" : false,
+ "in" : "path",
+ "name" : "prefix",
+ "required" : true,
+ "schema" : { }
+ }, {
+ "in" : "path",
+ "name" : "dashboard-template",
+ "required" : true,
+ "schema" : { },
+ "description" : "invalid value for dashboard template name"
+ }, {
+ "in" : "path",
+ "name" : "cell-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
}
}, {
- "in" : "query",
- "name" : "with-metrics",
- "required" : false,
+ "in" : "path",
+ "name" : "comparison-entity",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "string",
+ "enum" : [ "adhoc", "segment", "table" ]
+ },
+ "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
}, {
- "in" : "query",
- "name" : "with-measures",
- "required" : false,
+ "in" : "path",
+ "name" : "comparison-entity-id-or-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
}, {
"in" : "query",
- "name" : "with-segments",
+ "name" : "show",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "boolean"
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
}, {
"type" : "null"
} ]
- }
+ },
+ "description" : "invalid show value"
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.table"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14490,41 +15724,66 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/agent" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/agent/v1/table/{id}/field/{field-id}/values" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
"get" : {
- "summary" : "GET /api/agent/v1/table/{id}/field/{field-id}/values",
- "description" : "Get statistics and sample values for a table field.",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
+ "description" : "Return an automagic comparison dashboard for entity `entity` with id `id` compared with entity `comparison-entity`\n with id `comparison-entity-id-or-query.`",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity-id-or-query",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ }
}, {
"in" : "path",
- "name" : "field-id",
+ "name" : "entity",
"required" : true,
"schema" : {
"type" : "string",
- "minLength" : 1
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
+ }
+ }, {
+ "in" : "path",
+ "name" : "comparison-entity",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "adhoc", "segment", "table" ]
+ },
+ "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
+ }, {
+ "in" : "path",
+ "name" : "comparison-entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "invalid show value"
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.agent-api.api.field-values"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14533,37 +15792,27 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/agent" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/alert/" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/query_metadata" : {
"get" : {
- "summary" : "GET /api/alert/",
- "description" : "Fetch alerts which the current user has created or will receive, or all alerts if the user is an admin.\n The optional `user_id` will return alerts created by the corresponding user, but is ignored for non-admin users.",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/query_metadata",
+ "description" : "Return all metadata for an automagic dashboard for entity `entity` with id `id`.",
"parameters" : [ {
- "in" : "query",
- "name" : "archived",
+ "in" : "path",
+ "name" : "entity",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
}
}, {
- "in" : "query",
- "name" : "user_id",
- "required" : false,
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
}
} ],
"responses" : {
@@ -14577,22 +15826,57 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/alert" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/alert/{id}" : {
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}" : {
"get" : {
- "summary" : "GET /api/alert/{id}",
- "description" : "Fetch an alert by ID",
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}",
+ "description" : "Return an automagic dashboard for entity `entity` with id `id` using dashboard-template `dashboard-template`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
+ }
+ }, {
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ }
+ }, {
+ "in" : "path",
+ "name" : "prefix",
+ "required" : true,
+ "schema" : { }
+ }, {
+ "in" : "path",
+ "name" : "dashboard-template",
+ "required" : true,
+ "schema" : { },
+ "description" : "invalid value for dashboard template name"
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
+ }, {
+ "type" : "null"
+ } ]
},
- "description" : "value must be an integer greater than zero."
+ "description" : "invalid show value"
} ],
"responses" : {
"2XX" : {
@@ -14605,22 +15889,73 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/alert" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/alert/{id}/subscription" : {
- "delete" : {
- "summary" : "DELETE /api/alert/{id}/subscription",
- "description" : "For users to unsubscribe themselves from the given alert.",
+ "/api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
+ "get" : {
+ "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
+ "description" : "Return an automagic comparison dashboard for entity `entity` with id `id` using dashboard-template\n `dashboard-template`; compared with entity `comparison-entity` with id `comparison-entity-id-or-query.`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "entity",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
+ }
+ }, {
+ "in" : "path",
+ "name" : "entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ }
+ }, {
+ "in" : "path",
+ "name" : "prefix",
+ "required" : true,
+ "schema" : { }
+ }, {
+ "in" : "path",
+ "name" : "dashboard-template",
+ "required" : true,
+ "schema" : { },
+ "description" : "invalid value for dashboard template name"
+ }, {
+ "in" : "path",
+ "name" : "comparison-entity",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "adhoc", "segment", "table" ]
},
- "description" : "value must be an integer greater than zero."
+ "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
+ }, {
+ "in" : "path",
+ "name" : "comparison-entity-id-or-query",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ }
+ }, {
+ "in" : "query",
+ "name" : "show",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "all" ]
+ }, {
+ "type" : "integer",
+ "minimum" : 0
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "invalid show value"
} ],
"responses" : {
"2XX" : {
@@ -14633,13 +15968,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/alert" ]
+ "tags" : [ "/api/automagic-dashboards" ]
}
},
- "/api/analytics/anonymous-stats" : {
+ "/api/bookmark/" : {
"get" : {
- "summary" : "GET /api/analytics/anonymous-stats",
- "description" : "Anonymous usage stats. Endpoint for testing, and eventually exposing this to instance admins to let them see\n what is being phoned home.",
+ "summary" : "GET /api/bookmark/",
+ "description" : "Fetch all bookmarks for the user",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -14652,13 +15987,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/analytics" ]
+ "tags" : [ "/api/bookmark" ]
}
},
- "/api/api-key/" : {
- "post" : {
- "summary" : "POST /api/api-key/",
- "description" : "Create a new API key (and an associated `User`) with the provided name and group ID.",
+ "/api/bookmark/ordering" : {
+ "put" : {
+ "summary" : "PUT /api/bookmark/ordering",
+ "description" : "Sets the order of bookmarks for user.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -14677,44 +16012,55 @@
"schema" : {
"type" : "object",
"properties" : {
- "group_id" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
+ "orderings" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "item_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "type" : {
+ "type" : "string",
+ "enum" : [ "card", "dashboard", "collection", "document" ]
+ }
+ },
+ "required" : [ "type", "item_id" ]
+ }
}
},
- "required" : [ "group_id", "name" ]
+ "required" : [ "orderings" ]
}
}
}
},
- "tags" : [ "/api/api-key" ]
- },
- "get" : {
- "summary" : "GET /api/api-key/",
- "description" : "Get a list of API keys with the default scope. Non-paginated.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/api-key" ]
+ "tags" : [ "/api/bookmark" ]
}
},
- "/api/api-key/count" : {
- "get" : {
- "summary" : "GET /api/api-key/count",
- "description" : "Get the count of API keys in the DB with the default scope.",
- "parameters" : [ ],
+ "/api/bookmark/{model}/{id}" : {
+ "post" : {
+ "summary" : "POST /api/bookmark/{model}/{id}",
+ "description" : "Create a new bookmark for user.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "model",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "card", "dashboard", "collection", "document" ]
+ }
+ }, {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -14726,14 +16072,20 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/api-key" ]
- }
- },
- "/api/api-key/{id}" : {
- "put" : {
- "summary" : "PUT /api/api-key/{id}",
- "description" : "Update an API key by changing its group and/or its name",
+ "tags" : [ "/api/bookmark" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/bookmark/{model}/{id}",
+ "description" : "Delete a bookmark. Will delete a bookmark assigned to the user making the request by model and id.",
"parameters" : [ {
+ "in" : "path",
+ "name" : "model",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "card", "dashboard", "collection", "document" ]
+ }
+ }, {
"in" : "path",
"name" : "id",
"required" : true,
@@ -14754,46 +16106,33 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "group_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.name"
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
+ "tags" : [ "/api/bookmark" ]
+ }
+ },
+ "/api/bug-reporting/connection-pool-details" : {
+ "get" : {
+ "summary" : "GET /api/bug-reporting/connection-pool-details",
+ "description" : "Returns database connection pool info for the current Metabase instance.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/api-key" ]
- },
- "delete" : {
- "summary" : "DELETE /api/api-key/{id}",
- "description" : "Delete an ApiKey",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
- }
- } ],
+ "tags" : [ "/api/bug-reporting" ]
+ }
+ },
+ "/api/bug-reporting/details" : {
+ "get" : {
+ "summary" : "GET /api/bug-reporting/details",
+ "description" : "Returns version and system information relevant to filing a bug report against Metabase.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -14805,46 +16144,76 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/api-key" ]
+ "tags" : [ "/api/bug-reporting" ]
}
},
- "/api/api-key/{id}/regenerate" : {
- "put" : {
- "summary" : "PUT /api/api-key/{id}/regenerate",
- "description" : "Regenerate an API Key",
+ "/api/cache/" : {
+ "get" : {
+ "summary" : "GET /api/cache/",
+ "description" : "Return cache configuration. Supports pagination via `limit` and `offset` query parameters,\n and sorting via `sort_column` and `sort_direction`.",
"parameters" : [ {
- "in" : "path",
+ "in" : "query",
+ "name" : "model",
+ "required" : true,
+ "schema" : {
+ "default" : [ "root" ],
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "root", "database", "dashboard", "question" ]
+ }
+ },
+ "description" : "Type of model"
+ }, {
+ "in" : "query",
+ "name" : "collection",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "Collection id to filter results. Returns everything if not supplied."
+ }, {
+ "in" : "query",
"name" : "id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "Model id to get configuration for."
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
+ "default" : "name",
+ "type" : "string",
+ "enum" : [ "name", "policy", "collection" ]
}
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "id" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.id"
- },
- "masked_key" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema..key.masked"
- },
- "prefix" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema.prefix"
- },
- "unmasked_key" : {
- "$ref" : "#/components/schemas/metabase.api-keys.schema..key.raw"
- }
- },
- "required" : [ "id", "unmasked_key", "masked_key", "prefix" ]
- }
- }
- }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : true,
+ "schema" : {
+ "default" : "asc",
+ "type" : "string",
+ "enum" : [ "asc", "desc" ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -14853,23 +16222,12 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/api-key" ]
- }
- },
- "/api/automagic-dashboards/database/{id}/candidates" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/database/{id}/candidates",
- "description" : "Return a list of candidates for automagic dashboards ordered by interestingness.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "tags" : [ "/api/cache" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/cache/",
+ "description" : "Store cache configuration.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -14881,28 +16239,36 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
- }
- },
- "/api/automagic-dashboards/model_index/{model-index-id}/primary_key/{pk-id}" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/model_index/{model-index-id}/primary_key/{pk-id}",
- "description" : "Return an automagic dashboard for an entity detail specified by `entity`\n with id `id` and a primary key of `indexed-value`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "model-index-id",
- "required" : true,
- "schema" : {
- "type" : "integer"
- }
- }, {
- "in" : "path",
- "name" : "pk-id",
- "required" : true,
- "schema" : {
- "type" : "integer"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "model" : {
+ "type" : "string",
+ "enum" : [ "root", "database", "dashboard", "question" ]
+ },
+ "model_id" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "strategy" : {
+ "$ref" : "#/components/schemas/metabase.cache.api.cache-strategy"
+ }
+ },
+ "required" : [ "model", "model_id", "strategy" ]
+ }
+ }
}
- } ],
+ },
+ "tags" : [ "/api/cache" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/cache/",
+ "description" : "Delete cache configurations.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -14914,178 +16280,100 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "model" : {
+ "type" : "string",
+ "enum" : [ "root", "database", "dashboard", "question" ]
+ },
+ "model_id" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ }
+ }
+ },
+ "required" : [ "model", "model_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/cache" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}",
- "description" : "Return an automagic dashboard for entity `entity` with id `id`.",
+ "/api/cache/invalidate" : {
+ "post" : {
+ "summary" : "POST /api/cache/invalidate",
+ "description" : "Invalidate cache entries.\n\n Use it like `/api/cache/invalidate?database=1&dashboard=15` (any number of database/dashboard/question can be\n supplied).\n\n `&include=overrides` controls whenever you want to invalidate cache for a specific cache configuration without\n touching all nested configurations, or you want your invalidation to trickle down to every card.",
"parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
"in" : "query",
- "name" : "show",
+ "name" : "include",
"required" : false,
"schema" : {
"oneOf" : [ {
- "anyOf" : [ {
- "const" : "all"
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
+ "const" : "overrides"
}, {
"type" : "null"
} ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
},
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/automagic-dashboards" ]
- }
- },
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}",
- "description" : "Return an automagic dashboard analyzing cell in automagic dashboard for entity `entity` defined by query\n `cell-query`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "cell-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
- }
+ "description" : "All cache configuration overrides should invalidate cache too"
}, {
"in" : "query",
- "name" : "show",
+ "name" : "database",
"required" : false,
"schema" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
"type" : "integer",
"minimum" : 0
- } ]
+ }
}, {
"type" : "null"
} ]
},
- "description" : "invalid show value"
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/automagic-dashboards" ]
- }
- },
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
- "description" : "Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`\n with id `id` defined by query `cell-query`; compared with entity `comparison-entity` with id\n `comparison-entity-id-or-query.`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "cell-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
- }
- }, {
- "in" : "path",
- "name" : "comparison-entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "segment", "table" ]
- },
- "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
+ "description" : "A list of database ids"
}, {
- "in" : "path",
- "name" : "comparison-entity-id-or-query",
- "required" : true,
+ "in" : "query",
+ "name" : "dashboard",
+ "required" : false,
"schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "A list of dashboard ids"
}, {
"in" : "query",
- "name" : "show",
+ "name" : "question",
"required" : false,
"schema" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
"type" : "integer",
"minimum" : 0
- } ]
+ }
}, {
"type" : "null"
} ]
},
- "description" : "invalid show value"
+ "description" : "A list of question ids"
} ],
"responses" : {
"2XX" : {
@@ -15098,64 +16386,35 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "tags" : [ "/api/cache" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}" : {
+ "/api/card/" : {
"get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}",
- "description" : "Return an automagic dashboard analyzing cell in question with id `id` defined by query `cell-query` using\n dashboard-template `dashboard-template`.",
+ "summary" : "GET /api/card/",
+ "description" : "Get all the Cards. Option filter param `f` can be used to change the set of Cards that are returned; default is\n `all`, but other options include `mine`, `bookmarked`, `database`, `table`, `using_model`, `using_segment`, and\n `archived`. See corresponding implementation functions above for the specific behavior of each filter\n option. :card_index:",
"parameters" : [ {
- "in" : "path",
- "name" : "entity",
+ "in" : "query",
+ "name" : "f",
"required" : true,
"schema" : {
+ "default" : "all",
"type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "prefix",
- "required" : true,
- "schema" : { }
- }, {
- "in" : "path",
- "name" : "dashboard-template",
- "required" : true,
- "schema" : { },
- "description" : "invalid value for dashboard template name"
- }, {
- "in" : "path",
- "name" : "cell-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
+ "enum" : [ "archived", "table", "using_model", "bookmarked", "using_segment", "all", "mine", "database" ]
}
}, {
"in" : "query",
- "name" : "show",
+ "name" : "model_id",
"required" : false,
"schema" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
- },
- "description" : "invalid show value"
+ }
} ],
"responses" : {
"2XX" : {
@@ -15168,81 +16427,156 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
- }
- },
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/cell/{cell-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
- "description" : "Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`\n with id `id` defined by query `cell-query` using dashboard-template `dashboard-template`; compared with entity\n `comparison-entity` with id `comparison-entity-id-or-query.`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "prefix",
- "required" : true,
- "schema" : { }
- }, {
- "in" : "path",
- "name" : "dashboard-template",
- "required" : true,
- "schema" : { },
- "description" : "invalid value for dashboard template name"
- }, {
- "in" : "path",
- "name" : "cell-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.base-64-encoded-json"
- }
- }, {
- "in" : "path",
- "name" : "comparison-entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "segment", "table" ]
+ "tags" : [ "/api/card" ]
+ },
+ "post" : {
+ "summary" : "POST /api/card/",
+ "description" : "Create a new `Card`. Card `type` can be `question`, `metric`, or `model`.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
- }, {
- "in" : "path",
- "name" : "comparison-entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "visualization_settings" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "dashboard_tab_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "entity_id" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dataset_query" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.queries.schema.card-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashboard_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
+ }
+ }
}
- }, {
- "in" : "query",
- "name" : "show",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : "invalid show value"
- } ],
+ },
+ "tags" : [ "/api/card" ]
+ }
+ },
+ "/api/card/collections" : {
+ "post" : {
+ "summary" : "POST /api/card/collections",
+ "description" : "Bulk update endpoint for Card Collections. Move a set of `Cards` with `card_ids` into a `Collection` with\n `collection_id`, or remove them from any Collections by passing a `null` `collection_id`.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15254,63 +16588,43 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "card_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "card_ids" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/card" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
+ "/api/card/embeddable" : {
"get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
- "description" : "Return an automagic comparison dashboard for entity `entity` with id `id` compared with entity `comparison-entity`\n with id `comparison-entity-id-or-query.`",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "comparison-entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "segment", "table" ]
- },
- "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
- }, {
- "in" : "path",
- "name" : "comparison-entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "query",
- "name" : "show",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : "invalid show value"
- } ],
+ "summary" : "GET /api/card/embeddable",
+ "description" : "Fetch a list of Cards where `enable_embedding` is `true`. The cards can be embedded using the embedding endpoints\n and a signed JWT.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15322,28 +16636,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/query_metadata" : {
- "get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/query_metadata",
- "description" : "Return all metadata for an automagic dashboard for entity `entity` with id `id`.",
+ "/api/card/pivot/{card-id}/query" : {
+ "post" : {
+ "summary" : "POST /api/card/pivot/{card-id}/query",
+ "description" : "Run the query associated with a Card.",
"parameters" : [ {
"in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
+ "name" : "card-id",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -15356,58 +16664,32 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "ignore_cache" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/card" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}" : {
+ "/api/card/public" : {
"get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}",
- "description" : "Return an automagic dashboard for entity `entity` with id `id` using dashboard-template `dashboard-template`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "prefix",
- "required" : true,
- "schema" : { }
- }, {
- "in" : "path",
- "name" : "dashboard-template",
- "required" : true,
- "schema" : { },
- "description" : "invalid value for dashboard template name"
- }, {
- "in" : "query",
- "name" : "show",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : "invalid show value"
- } ],
+ "summary" : "GET /api/card/public",
+ "description" : "Fetch a list of Cards with public UUIDs. These cards are publicly-accessible *if* public sharing is enabled.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15419,73 +16701,37 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}" : {
+ "/api/card/{card-id}/params/{param-key}/search/{query}" : {
"get" : {
- "summary" : "GET /api/automagic-dashboards/{entity}/{entity-id-or-query}/rule/{prefix}/{dashboard-template}/compare/{comparison-entity}/{comparison-entity-id-or-query}",
- "description" : "Return an automagic comparison dashboard for entity `entity` with id `id` using dashboard-template\n `dashboard-template`; compared with entity `comparison-entity` with id `comparison-entity-id-or-query.`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "entity",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "field", "model", "question", "segment", "table", "transform" ]
- }
- }, {
- "in" : "path",
- "name" : "entity-id-or-query",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
- }
- }, {
- "in" : "path",
- "name" : "prefix",
- "required" : true,
- "schema" : { }
- }, {
- "in" : "path",
- "name" : "dashboard-template",
- "required" : true,
- "schema" : { },
- "description" : "invalid value for dashboard template name"
- }, {
+ "summary" : "GET /api/card/{card-id}/params/{param-key}/search/{query}",
+ "description" : "Fetch possible values of the parameter whose ID is `:param-key` that contain `:query`.\n\n ;; fetch values for Card 1 parameter 'abc' that contain 'Orange';\n GET /api/queries/1/params/abc/search/Orange\n\n Currently limited to first 1000 results.",
+ "parameters" : [ {
"in" : "path",
- "name" : "comparison-entity",
+ "name" : "card-id",
"required" : true,
"schema" : {
- "type" : "string",
- "enum" : [ "adhoc", "segment", "table" ]
+ "type" : "integer",
+ "minimum" : 1
},
- "description" : "Invalid comparison entity type. Can only be one of \"table\", \"segment\", or \"adhoc\""
+ "description" : "value must be an integer greater than zero."
}, {
"in" : "path",
- "name" : "comparison-entity-id-or-query",
+ "name" : "param-key",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.xrays.api.automagic-dashboards.entity-id-or-query"
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
}
}, {
- "in" : "query",
- "name" : "show",
- "required" : false,
+ "in" : "path",
+ "name" : "query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "all" ]
- }, {
- "type" : "integer",
- "minimum" : 0
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : "invalid show value"
+ "type" : "string",
+ "minLength" : 1
+ }
} ],
"responses" : {
"2XX" : {
@@ -15498,14 +16744,30 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/automagic-dashboards" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/bookmark/" : {
+ "/api/card/{card-id}/params/{param-key}/values" : {
"get" : {
- "summary" : "GET /api/bookmark/",
- "description" : "Fetch all bookmarks for the user",
- "parameters" : [ ],
+ "summary" : "GET /api/card/{card-id}/params/{param-key}/values",
+ "description" : "Fetch possible values of the parameter whose ID is `:param-key`.\n\n ;; fetch values for Card 1 parameter 'abc' that are possible\n GET /api/queries/1/params/abc/values",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "card-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "param-key",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15517,14 +16779,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/bookmark" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/bookmark/ordering" : {
- "put" : {
- "summary" : "PUT /api/bookmark/ordering",
- "description" : "Sets the order of bookmarks for user.",
- "parameters" : [ ],
+ "/api/card/{card-id}/public_link" : {
+ "post" : {
+ "summary" : "POST /api/card/{card-id}/public_link",
+ "description" : "Generate publicly-accessible links for this Card. Returns UUID to be used in public links. (If this Card has\n already been shared, it will return the existing public link rather than creating a new one.) Public sharing must\n be enabled.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "card-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15536,54 +16807,14 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "orderings" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "item_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "type" : {
- "type" : "string",
- "enum" : [ "card", "dashboard", "collection", "document" ]
- }
- },
- "required" : [ "type", "item_id" ]
- }
- }
- },
- "required" : [ "orderings" ]
- }
- }
- }
- },
- "tags" : [ "/api/bookmark" ]
- }
- },
- "/api/bookmark/{model}/{id}" : {
- "post" : {
- "summary" : "POST /api/bookmark/{model}/{id}",
- "description" : "Create a new bookmark for user.",
+ "tags" : [ "/api/card" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/card/{card-id}/public_link",
+ "description" : "Delete the publicly-accessible link to this Card.",
"parameters" : [ {
"in" : "path",
- "name" : "model",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "card", "dashboard", "collection", "document" ]
- }
- }, {
- "in" : "path",
- "name" : "id",
+ "name" : "card-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -15602,28 +16833,28 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/bookmark" ]
- },
- "delete" : {
- "summary" : "DELETE /api/bookmark/{model}/{id}",
- "description" : "Delete a bookmark. Will delete a bookmark assigned to the user making the request by model and id.",
+ "tags" : [ "/api/card" ]
+ }
+ },
+ "/api/card/{card-id}/query" : {
+ "post" : {
+ "summary" : "POST /api/card/{card-id}/query",
+ "description" : "Run the query associated with a Card.",
"parameters" : [ {
"in" : "path",
- "name" : "model",
+ "name" : "card-id",
"required" : true,
"schema" : {
- "type" : "string",
- "enum" : [ "card", "dashboard", "collection", "document" ]
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
}
- }, {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -15636,14 +16867,62 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/bookmark" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "collection_preview" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashboard_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "ignore_cache" : {
+ "default" : false,
+ "type" : "boolean"
+ }
+ },
+ "required" : [ "ignore_cache" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/card" ]
}
},
- "/api/bug-reporting/connection-pool-details" : {
- "get" : {
- "summary" : "GET /api/bug-reporting/connection-pool-details",
- "description" : "Returns database connection pool info for the current Metabase instance.",
- "parameters" : [ ],
+ "/api/card/{card-id}/query/{export-format}" : {
+ "post" : {
+ "summary" : "POST /api/card/{card-id}/query/{export-format}",
+ "description" : "Run the query associated with a Card, and return its results as a file in the specified format.\n\n `parameters`, `pivot-results?` and `format-rows?` should be passed as application/x-www-form-urlencoded form content\n or json in the body. This is because this endpoint is normally used to power 'Download Results' buttons that use\n HTML `form` actions).",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "card-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "export-format",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15655,14 +16934,72 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/bug-reporting" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "format_rows" : {
+ "default" : false,
+ "type" : "boolean"
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "additionalProperties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "pivot_results" : {
+ "default" : false,
+ "type" : "boolean"
+ }
+ },
+ "required" : [ "format_rows", "pivot_results" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/card" ]
}
},
- "/api/bug-reporting/details" : {
+ "/api/card/{id}" : {
"get" : {
- "summary" : "GET /api/bug-reporting/details",
- "description" : "Returns version and system information relevant to filing a bug report against Metabase.",
- "parameters" : [ ],
+ "summary" : "GET /api/card/{id}",
+ "description" : "Get `Card` with ID.\n\n As of v57, returns the MBQL query (`dataset_query`) as MBQL 5; to return the query as MBQL 4 (aka legacy MBQL)\n instead, you can specify `?legacy-mbql=true`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "legacy-mbql",
+ "required" : false,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15674,72 +17011,226 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/bug-reporting" ]
- }
- },
- "/api/cache/" : {
- "get" : {
- "summary" : "GET /api/cache/",
- "description" : "Return cache configuration. Supports pagination via `limit` and `offset` query parameters,\n and sorting via `sort_column` and `sort_direction`.",
+ "tags" : [ "/api/card" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/card/{id}",
+ "description" : "Update a `Card`.",
"parameters" : [ {
- "in" : "query",
- "name" : "model",
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : [ "root" ],
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "root", "database", "dashboard", "question" ]
- }
+ "type" : "integer",
+ "minimum" : 1
},
- "description" : "Type of model"
+ "description" : "value must be an integer greater than zero."
}, {
"in" : "query",
- "name" : "collection",
+ "name" : "delete_old_dashcards",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "boolean"
}, {
"type" : "null"
} ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "Collection id to filter results. Returns everything if not supplied."
- }, {
- "in" : "query",
- "name" : "id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
},
- "description" : "Model id to get configuration for."
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : true,
- "schema" : {
- "default" : "name",
- "type" : "string",
- "enum" : [ "name", "policy", "collection" ]
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "enable_embedding" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "visualization_settings" : {
+ "oneOf" : [ {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashboard_tab_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_preview" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dataset_query" : {
+ "oneOf" : [ {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "embedding_type" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "archived" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "embedding_params" : {
+ "oneOf" : [ {
+ "description" : "value must be a valid embedding params map.",
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string",
+ "enum" : [ "disabled", "enabled", "locked" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.queries.schema.card-type"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashboard_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ }
}
- }, {
- "in" : "query",
- "name" : "sort_direction",
+ },
+ "tags" : [ "/api/card" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/card/{id}",
+ "description" : "Hard delete a Card. To soft delete, use `PUT /api/queries/:id`",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : "asc",
- "type" : "string",
- "enum" : [ "asc", "desc" ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -15752,12 +17243,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/cache" ]
- },
- "put" : {
- "summary" : "PUT /api/cache/",
- "description" : "Store cache configuration.",
- "parameters" : [ ],
+ "tags" : [ "/api/card" ]
+ }
+ },
+ "/api/card/{id}/copy" : {
+ "post" : {
+ "summary" : "POST /api/card/{id}/copy",
+ "description" : "Copy a `Card`, with the new name 'Copy of _name_'",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15769,36 +17271,23 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "model" : {
- "type" : "string",
- "enum" : [ "root", "database", "dashboard", "question" ]
- },
- "model_id" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "strategy" : {
- "$ref" : "#/components/schemas/metabase.cache.api.cache-strategy"
- }
- },
- "required" : [ "model", "model_id", "strategy" ]
- }
- }
- }
- },
- "tags" : [ "/api/cache" ]
- },
- "delete" : {
- "summary" : "DELETE /api/cache/",
- "description" : "Delete cache configurations.",
- "parameters" : [ ],
+ "tags" : [ "/api/card" ]
+ }
+ },
+ "/api/card/{id}/dashboards" : {
+ "get" : {
+ "summary" : "GET /api/card/{id}/dashboards",
+ "description" : "Get a list of `{:name ... :id ...}` pairs for all the dashboards this card appears in.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15810,100 +17299,68 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "model" : {
- "type" : "string",
- "enum" : [ "root", "database", "dashboard", "question" ]
- },
- "model_id" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }
- },
- "required" : [ "model", "model_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/cache" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/cache/invalidate" : {
- "post" : {
- "summary" : "POST /api/cache/invalidate",
- "description" : "Invalidate cache entries.\n\n Use it like `/api/cache/invalidate?database=1&dashboard=15` (any number of database/dashboard/question can be\n supplied).\n\n `&include=overrides` controls whenever you want to invalidate cache for a specific cache configuration without\n touching all nested configurations, or you want your invalidation to trickle down to every card.",
+ "/api/card/{id}/params/{param-key}/remapping" : {
+ "get" : {
+ "summary" : "GET /api/card/{id}/params/{param-key}/remapping",
+ "description" : "Fetch the remapped value for a given value of the parameter with ID `:param-key`.\n\n ;; fetch the remapped value for Card 1 parameter 'abc' for value 100\n GET /api/queries/1/params/abc/remapping?value=100",
"parameters" : [ {
- "in" : "query",
- "name" : "include",
- "required" : false,
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "const" : "overrides"
- }, {
- "type" : "null"
- } ]
- },
- "description" : "All cache configuration overrides should invalidate cache too"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
+ }
}, {
- "in" : "query",
- "name" : "database",
- "required" : false,
+ "in" : "path",
+ "name" : "param-key",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
- },
- "description" : "A list of database ids"
+ "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
+ }
}, {
"in" : "query",
- "name" : "dashboard",
- "required" : false,
+ "name" : "value",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
+ "type" : "string"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "A list of dashboard ids"
- }, {
- "in" : "query",
- "name" : "question",
- "required" : false,
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/card" ]
+ }
+ },
+ "/api/card/{id}/query_metadata" : {
+ "get" : {
+ "summary" : "GET /api/card/{id}/query_metadata",
+ "description" : "Get all of the required query metadata for a card.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
- "type" : "null"
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
} ]
- },
- "description" : "A list of question ids"
+ }
} ],
"responses" : {
"2XX" : {
@@ -15916,25 +17373,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/cache" ]
+ "tags" : [ "/api/card" ]
}
},
- "/api/card/" : {
+ "/api/card/{id}/series" : {
"get" : {
- "summary" : "GET /api/card/",
- "description" : "Get all the Cards. Option filter param `f` can be used to change the set of Cards that are returned; default is\n `all`, but other options include `mine`, `bookmarked`, `database`, `table`, `using_model`, `using_segment`, and\n `archived`. See corresponding implementation functions above for the specific behavior of each filter\n option. :card_index:",
+ "summary" : "GET /api/card/{id}/series",
+ "description" : "Fetches a list of compatible series with the card with id `card_id`.\n\n - `last_cursor` with value is the id of the last card from the previous page to fetch the next page.\n - `query` to search card by name.\n - `exclude_ids` to filter out a list of card ids",
"parameters" : [ {
- "in" : "query",
- "name" : "f",
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : "all",
- "type" : "string",
- "enum" : [ "archived", "table", "using_model", "bookmarked", "using_segment", "all", "mine", "database" ]
+ "type" : "integer"
}
}, {
"in" : "query",
- "name" : "model_id",
+ "name" : "last_cursor",
"required" : false,
"schema" : {
"oneOf" : [ {
@@ -15945,6 +17400,27 @@
"type" : "null"
} ]
}
+ }, {
+ "in" : "query",
+ "name" : "query",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "exclude_ids",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -15958,10 +17434,12 @@
}
},
"tags" : [ "/api/card" ]
- },
+ }
+ },
+ "/api/cards/dashboards" : {
"post" : {
- "summary" : "POST /api/card/",
- "description" : "Create a new `Card`. Card `type` can be `question`, `metric`, or `model`.",
+ "summary" : "POST /api/cards/dashboards",
+ "description" : "Get the dashboards that multiple cards appear in. The response is a sequence of maps, each of which has a `card_id`\n and `dashboards`. `dashboard` may include an `:error` key, either `:unreadable-dashboard` or\n `:unwritable-dashboard`. In the case of an `unreadable-dashboard` the dashboard details (name, ID) will NOT be\n present.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -15980,132 +17458,27 @@
"schema" : {
"type" : "object",
"properties" : {
- "visualization_settings" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "dashboard_tab_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "entity_id" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "dataset_query" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "result_metadata" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
- }, {
- "type" : "null"
- } ]
- },
- "collection_id" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema.card-type"
- }, {
- "type" : "null"
- } ]
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "dashboard_id" : {
- "oneOf" : [ {
+ "card_ids" : {
+ "type" : "array",
+ "items" : {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
- }, {
- "type" : "null"
- } ]
+ }
}
},
- "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
+ "required" : [ "card_ids" ]
}
}
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/cards" ]
}
},
- "/api/card/collections" : {
+ "/api/cards/move" : {
"post" : {
- "summary" : "POST /api/card/collections",
- "description" : "Bulk update endpoint for Card Collections. Move a set of `Cards` with `card_ids` into a `Collection` with\n `collection_id`, or remove them from any Collections by passing a `null` `collection_id`.",
+ "summary" : "POST /api/cards/move",
+ "description" : "Moves a number of Cards to a single collection or dashboard.\n\n For now, just either succeed or fail as a batch - we can think more about error handling later down the road.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -16140,6 +17513,15 @@
}, {
"type" : "null"
} ]
+ },
+ "dashboard_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
}
},
"required" : [ "card_ids" ]
@@ -16147,13 +17529,13 @@
}
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/cards" ]
}
},
- "/api/card/embeddable" : {
+ "/api/channel/" : {
"get" : {
- "summary" : "GET /api/card/embeddable",
- "description" : "Fetch a list of Cards where `enable_embedding` is `true`. The cards can be embedded using the embedding endpoints\n and a signed JWT.",
+ "summary" : "GET /api/channel/",
+ "description" : "Get all channels",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -16166,41 +17548,14 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/pivot/{card-id}/query" : {
- "post" : {
- "summary" : "POST /api/card/pivot/{card-id}/query",
- "description" : "Run the query associated with a Card.",
- "parameters" : [ {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
- "ignore_cache" : {
+ "include_inactive" : {
+ "default" : false,
"oneOf" : [ {
"type" : "boolean"
}, {
@@ -16212,57 +17567,12 @@
}
}
},
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/public" : {
- "get" : {
- "summary" : "GET /api/card/public",
- "description" : "Fetch a list of Cards with public UUIDs. These cards are publicly-accessible *if* public sharing is enabled.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/{card-id}/params/{param-key}/search/{query}" : {
- "get" : {
- "summary" : "GET /api/card/{card-id}/params/{param-key}/search/{query}",
- "description" : "Fetch possible values of the parameter whose ID is `:param-key` that contain `:query`.\n\n ;; fetch values for Card 1 parameter 'abc' that contain 'Orange';\n GET /api/queries/1/params/abc/search/Orange\n\n Currently limited to first 1000 results.",
- "parameters" : [ {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "param-key",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
- }
- }, {
- "in" : "path",
- "name" : "query",
- "required" : true,
- "schema" : {
- "type" : "string",
- "minLength" : 1
- }
- } ],
+ "tags" : [ "/api/channel" ]
+ },
+ "post" : {
+ "summary" : "POST /api/channel/",
+ "description" : "Create a channel",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -16274,30 +17584,53 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "active" : {
+ "default" : true,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "details" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "type" : {
+ "description" : "Must be a namespaced channel. E.g: channel/http"
+ }
+ },
+ "required" : [ "name", "type", "details" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/channel" ]
}
},
- "/api/card/{card-id}/params/{param-key}/values" : {
- "get" : {
- "summary" : "GET /api/card/{card-id}/params/{param-key}/values",
- "description" : "Fetch possible values of the parameter whose ID is `:param-key`.\n\n ;; fetch values for Card 1 parameter 'abc' that are possible\n GET /api/queries/1/params/abc/values",
- "parameters" : [ {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "param-key",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
- }
- } ],
+ "/api/channel/test" : {
+ "post" : {
+ "summary" : "POST /api/channel/test",
+ "description" : "Test a channel connection",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -16309,16 +17642,35 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "type" : {
+ "description" : "Must be a namespaced channel. E.g: channel/http"
+ }
+ },
+ "required" : [ "type", "details" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/channel" ]
}
},
- "/api/card/{card-id}/public_link" : {
- "post" : {
- "summary" : "POST /api/card/{card-id}/public_link",
- "description" : "Generate publicly-accessible links for this Card. Returns UUID to be used in public links. (If this Card has\n already been shared, it will return the existing public link rather than creating a new one.) Public sharing must\n be enabled.",
+ "/api/channel/{id}" : {
+ "get" : {
+ "summary" : "GET /api/channel/{id}",
+ "description" : "Get a channel",
"parameters" : [ {
"in" : "path",
- "name" : "card-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -16337,14 +17689,14 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/channel" ]
},
- "delete" : {
- "summary" : "DELETE /api/card/{card-id}/public_link",
- "description" : "Delete the publicly-accessible link to this Card.",
+ "put" : {
+ "summary" : "PUT /api/channel/{id}",
+ "description" : "Update a channel",
"parameters" : [ {
"in" : "path",
- "name" : "card-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -16363,96 +17715,80 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/{card-id}/query" : {
- "post" : {
- "summary" : "POST /api/card/{card-id}/query",
- "description" : "Run the query associated with a Card.",
- "parameters" : [ {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
- "collection_preview" : {
+ "active" : {
"oneOf" : [ {
"type" : "boolean"
}, {
"type" : "null"
} ]
},
- "dashboard_id" : {
+ "description" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
},
- "ignore_cache" : {
- "default" : false,
- "type" : "boolean"
+ "details" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "oneOf" : [ {
+ "description" : "Must be a namespaced channel. E.g: channel/http"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "required" : [ "ignore_cache" ]
+ }
}
}
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/channel" ]
}
},
- "/api/card/{card-id}/query/{export-format}" : {
+ "/api/cloud-migration/" : {
"post" : {
- "summary" : "POST /api/card/{card-id}/query/{export-format}",
- "description" : "Run the query associated with a Card, and return its results as a file in the specified format.\n\n `parameters`, `pivot-results?` and `format-rows?` should be passed as application/x-www-form-urlencoded form content\n or json in the body. This is because this endpoint is normally used to power 'Download Results' buttons that use\n HTML `form` actions).",
- "parameters" : [ {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "summary" : "POST /api/cloud-migration/",
+ "description" : "Initiate a new cloud migration.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "export-format",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- } ],
+ },
+ "tags" : [ "/api/cloud-migration" ]
+ },
+ "get" : {
+ "summary" : "GET /api/cloud-migration/",
+ "description" : "Get the latest cloud migration, if any.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -16464,63 +17800,72 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "format_rows" : {
- "default" : false,
- "type" : "boolean"
- },
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "object",
- "additionalProperties" : { }
- }
- }, {
- "type" : "null"
- } ]
- },
- "pivot_results" : {
- "default" : false,
- "type" : "boolean"
- }
- },
- "required" : [ "format_rows", "pivot_results" ]
- }
- }
+ "tags" : [ "/api/cloud-migration" ]
+ }
+ },
+ "/api/cloud-migration/cancel" : {
+ "put" : {
+ "summary" : "PUT /api/cloud-migration/cancel",
+ "description" : "Cancel any ongoing cloud migrations, if any.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/cloud-migration" ]
}
},
- "/api/card/{id}" : {
+ "/api/collection/" : {
"get" : {
- "summary" : "GET /api/card/{id}",
- "description" : "Get `Card` with ID.\n\n As of v57, returns the MBQL query (`dataset_query`) as MBQL 5; to return the query as MBQL 4 (aka legacy MBQL)\n instead, you can specify `?legacy-mbql=true`.",
+ "summary" : "GET /api/collection/",
+ "description" : "Fetch a list of all Collections that the current user has read permissions for (`:can_write` is returned as an\n additional property of each Collection so you can tell which of these you have write permissions for.)\n\n By default, this returns non-archived Collections, but instead you can show archived ones by passing\n `?archived=true`.\n\n By default, admin users will see all collections. To hide other user's collections pass in\n `?exclude-other-user-collections=true`.\n\n If personal-only is `true`, then return only personal collections where `personal_owner_id` is not `nil`.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
+ "in" : "query",
+ "name" : "archived",
"required" : true,
"schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
}, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ "type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "legacy-mbql",
+ "name" : "exclude-other-user-collections",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "namespace",
"required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "personal-only",
+ "required" : true,
"schema" : {
"default" : false,
"oneOf" : [ {
@@ -16541,32 +17886,12 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/collection" ]
},
- "put" : {
- "summary" : "PUT /api/card/{id}",
- "description" : "Update a `Card`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "delete_old_dashcards",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- } ],
+ "post" : {
+ "summary" : "POST /api/collection/",
+ "description" : "Create a new Collection.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -16584,62 +17909,15 @@
"schema" : {
"type" : "object",
"properties" : {
- "enable_embedding" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "visualization_settings" : {
- "oneOf" : [ {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "dashboard_tab_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "collection_preview" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "dataset_query" : {
- "oneOf" : [ {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "embedding_type" : {
+ "authority_level" : {
"oneOf" : [ {
- "type" : "string"
+ "type" : "string",
+ "enum" : [ "official" ]
}, {
"type" : "null"
} ]
},
- "name" : {
+ "description" : {
"oneOf" : [ {
"type" : "string",
"minLength" : 1
@@ -16647,71 +17925,11 @@
"type" : "null"
} ]
},
- "archived" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "embedding_params" : {
- "oneOf" : [ {
- "description" : "value must be a valid embedding params map.",
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "string",
- "enum" : [ "disabled", "enabled", "locked" ]
- }
- }, {
- "type" : "null"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "result_metadata" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
- }, {
- "type" : "null"
- } ]
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "type" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.queries.schema.card-type"
- }, {
- "type" : "null"
- } ]
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
},
- "display" : {
+ "namespace" : {
"oneOf" : [ {
"type" : "string",
"minLength" : 1
@@ -16719,21 +17937,7 @@
"type" : "null"
} ]
},
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "dashboard_id" : {
+ "parent_id" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
@@ -16742,25 +17946,31 @@
"type" : "null"
} ]
}
- }
+ },
+ "required" : [ "name" ]
}
}
}
},
- "tags" : [ "/api/card" ]
- },
- "delete" : {
- "summary" : "DELETE /api/card/{id}",
- "description" : "Hard delete a Card. To soft delete, use `PUT /api/queries/:id`",
+ "tags" : [ "/api/collection" ]
+ }
+ },
+ "/api/collection/graph" : {
+ "get" : {
+ "summary" : "GET /api/collection/graph",
+ "description" : "Fetch a graph of all Collection Permissions.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
+ "in" : "query",
+ "name" : "namespace",
+ "required" : false,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -16773,22 +17983,35 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/{id}/copy" : {
- "post" : {
- "summary" : "POST /api/card/{id}/copy",
- "description" : "Copy a `Card`, with the new name 'Copy of _name_'",
+ "tags" : [ "/api/collection" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/collection/graph",
+ "description" : "Do a batch update of Collections Permissions by passing in a modified graph. Will overwrite parts of the graph that\n are present in the request, and leave the rest unchanged.\n\n If the `force` query parameter is `true`, a `revision` number is not required. The provided graph will be persisted\n as-is, and has the potential to clobber other writes that happened since the last read.\n\n If the `skip_graph` query parameter is `true`, it will only return the current revision, not the entire permissions\n graph.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
+ "in" : "query",
+ "name" : "force",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "skip-graph",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -16801,22 +18024,57 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "groups" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "namespace" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "revision" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer.",
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "groups" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/collection" ]
}
},
- "/api/card/{id}/dashboards" : {
+ "/api/collection/root" : {
"get" : {
- "summary" : "GET /api/card/{id}/dashboards",
- "description" : "Get a list of `{:name ... :id ...}` pairs for all the dashboards this card appears in.",
+ "summary" : "GET /api/collection/root",
+ "description" : "Return the 'Root' Collection object with standard details added",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
+ "in" : "query",
+ "name" : "namespace",
+ "required" : false,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -16829,38 +18087,24 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/card/{id}/params/{param-key}/remapping" : {
+ "/api/collection/root/dashboard-question-candidates" : {
"get" : {
- "summary" : "GET /api/card/{id}/params/{param-key}/remapping",
- "description" : "Fetch the remapped value for a given value of the parameter with ID `:param-key`.\n\n ;; fetch the remapped value for Card 1 parameter 'abc' for value 100\n GET /api/queries/1/params/abc/remapping?value=100",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.card"
- }
- }, {
- "in" : "path",
- "name" : "param-key",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.parameter.id"
- }
- }, {
- "in" : "query",
- "name" : "value",
- "required" : true,
- "schema" : {
- "type" : "string"
- }
- } ],
+ "summary" : "GET /api/collection/root/dashboard-question-candidates",
+ "description" : "Find cards in the root collection that can be moved into dashboards in the root collection. (Same as the above\n endpoint, but for the root collection)",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidatesResponse"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -16869,85 +18113,141 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/card/{id}/query_metadata" : {
+ "/api/collection/root/items" : {
"get" : {
- "summary" : "GET /api/card/{id}/query_metadata",
- "description" : "Get all of the required query metadata for a card.",
+ "summary" : "GET /api/collection/root/items",
+ "description" : "Fetch objects that the current user should see at their root level. As mentioned elsewhere, the 'Root' Collection\n doesn't actually exist as a row in the application DB: it's simply a virtual Collection where things with no\n `collection_id` exist. It does, however, have its own set of Permissions.\n\n This endpoint will actually show objects with no `collection_id` for Users that have Root Collection\n permissions, but for people without Root Collection perms, we'll just show the objects that have an effective\n location of `/`.\n\n This endpoint is intended to power a 'Root Folder View' for the Current User, so regardless you'll see all the\n top-level objects you're allowed to access.\n\n By default, this will show the 'normal' Collections namespace; to view a different Collections namespace, such as\n `snippets`, you can pass the `?namespace=` parameter.\n\n By default, library collections are excluded from the results; to include them, pass `?include_library=true`.\n\n Note that this endpoint should return results in a similar shape to `/api/dashboard/:id/items`, so if this is\n changed, that should too.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
+ "in" : "query",
+ "name" : "models",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "table", "dataset", "no_models", "timeline", "snippet", "collection", "transform", "document", "pulse", "metric", "card" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "collection_type",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "remote-synced" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_can_run_adhoc_query",
"required" : true,
"schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
}, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ "type" : "null"
} ]
}
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ }, {
+ "in" : "query",
+ "name" : "archived",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "tags" : [ "/api/card" ]
- }
- },
- "/api/card/{id}/series" : {
- "get" : {
- "summary" : "GET /api/card/{id}/series",
- "description" : "Fetches a list of compatible series with the card with id `card_id`.\n\n - `last_cursor` with value is the id of the last card from the previous page to fetch the next page.\n - `query` to search card by name.\n - `exclude_ids` to filter out a list of card ids",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
+ }, {
+ "in" : "query",
+ "name" : "namespace",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_library",
"required" : true,
"schema" : {
- "type" : "integer"
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "pinned_state",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "is_not_pinned", "is_pinned", "all" ]
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "model", "name", "last_edited_by", "last_edited_at", "description" ]
+ }, {
+ "type" : "null"
+ } ]
}
}, {
"in" : "query",
- "name" : "last_cursor",
+ "name" : "sort_direction",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "query",
+ "name" : "official_collections_first",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "boolean",
+ "optional" : true
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "exclude_ids",
+ "name" : "show_dashboard_questions",
"required" : false,
"schema" : {
- "oneOf" : [ { }, {
+ "oneOf" : [ {
+ "type" : "boolean",
+ "optional" : true
+ }, {
"type" : "null"
} ]
}
@@ -16963,17 +18263,24 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/card" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/cards/dashboards" : {
+ "/api/collection/root/move-dashboard-question-candidates" : {
"post" : {
- "summary" : "POST /api/cards/dashboards",
- "description" : "Get the dashboards that multiple cards appear in. The response is a sequence of maps, each of which has a `card_id`\n and `dashboards`. `dashboard` may include an `:error` key, either `:unreadable-dashboard` or\n `:unwritable-dashboard`. In the case of an `unreadable-dashboard` the dashboard details (name, ID) will NOT be\n present.",
+ "summary" : "POST /api/collection/root/move-dashboard-question-candidates",
+ "description" : "Move candidate cards to the dashboards they appear in (for the root collection)",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -16986,29 +18293,33 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "card_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "card_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "uniqueItems" : true
}
}
- },
- "required" : [ "card_ids" ]
+ }, {
+ "type" : "null"
+ } ]
}
}
}
},
- "tags" : [ "/api/cards" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/cards/move" : {
- "post" : {
- "summary" : "POST /api/cards/move",
- "description" : "Moves a number of Cards to a single collection or dashboard.\n\n For now, just either succeed or fail as a batch - we can think more about error handling later down the road.",
+ "/api/collection/trash" : {
+ "get" : {
+ "summary" : "GET /api/collection/trash",
+ "description" : "Fetch the trash collection, as in `/api/collection/:trash-id`",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -17021,146 +18332,101 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "card_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "dashboard_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "card_ids" ]
- }
- }
- }
- },
- "tags" : [ "/api/cards" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/channel/" : {
+ "/api/collection/tree" : {
"get" : {
- "summary" : "GET /api/channel/",
- "description" : "Get all channels",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "summary" : "GET /api/collection/tree",
+ "description" : "Similar to `GET /`, but returns Collections in a tree structure, e.g.\n\n ```\n [{:name \"A\"\n :below #{:card :dataset}\n :children [{:name \"B\"}\n {:name \"C\"\n :here #{:dataset :card}\n :below #{:dataset :card}\n :children [{:name \"D\"\n :here #{:dataset}\n :children [{:name \"E\"}]}\n {:name \"F\"\n :here #{:card}\n :children [{:name \"G\"}]}]}]}\n {:name \"H\"}]\n ```\n\n The here and below keys indicate the types of items at this particular level of the tree (here) and in its\n subtree (below).\n\n TODO: for historical reasons this returns Saved Questions AS 'card' AND Models as 'dataset'; we should fix this at\n some point in the future.\n\n By default, looks at the `analytics` (if enabled) and regular (`nil`) namespaces. You can optionally pass a\n `namespace` argument, or one or many `namespaces`, to specify the particular collection namespaces you wish to look\n at. For example, `namespaces=analytics&namespaces=` would match the default behavior.\n\n When `shallow` is true, takes an optional `collection-id` and returns only the requested collection (or\n the root, if `collection-id` is `nil`).",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "exclude-archived",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "include_inactive" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
+ }, {
+ "in" : "query",
+ "name" : "exclude-other-user-collections",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "tags" : [ "/api/channel" ]
- },
- "post" : {
- "summary" : "POST /api/channel/",
- "description" : "Create a channel",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ }, {
+ "in" : "query",
+ "name" : "include-library",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "active" : {
- "default" : true,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "details" : {
- "type" : "object",
- "properties" : { }
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "type" : {
- "description" : "Must be a namespaced channel. E.g: channel/http"
- }
- },
- "required" : [ "name", "type", "details" ]
+ }, {
+ "in" : "query",
+ "name" : "namespace",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "namespaces",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string"
}
- }
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "tags" : [ "/api/channel" ]
- }
- },
- "/api/channel/test" : {
- "post" : {
- "summary" : "POST /api/channel/test",
- "description" : "Test a channel connection",
- "parameters" : [ ],
+ }, {
+ "in" : "query",
+ "name" : "shallow",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "collection-id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -17172,41 +18438,28 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "details" : {
- "type" : "object",
- "properties" : { }
- },
- "type" : {
- "description" : "Must be a namespaced channel. E.g: channel/http"
- }
- },
- "required" : [ "type", "details" ]
- }
- }
- }
- },
- "tags" : [ "/api/channel" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/channel/{id}" : {
+ "/api/collection/{id}" : {
"get" : {
- "summary" : "GET /api/channel/{id}",
- "description" : "Get a channel",
+ "summary" : "GET /api/collection/{id}",
+ "description" : "Fetch a specific Collection with standard details added",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -17219,11 +18472,11 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/channel" ]
+ "tags" : [ "/api/collection" ]
},
"put" : {
- "summary" : "PUT /api/channel/{id}",
- "description" : "Update a channel",
+ "summary" : "PUT /api/collection/{id}",
+ "description" : "Modify an existing Collection, including archiving or unarchiving it, or moving it.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -17251,25 +18504,26 @@
"schema" : {
"type" : "object",
"properties" : {
- "active" : {
+ "archived" : {
+ "default" : false,
"oneOf" : [ {
"type" : "boolean"
}, {
"type" : "null"
} ]
},
- "description" : {
+ "authority_level" : {
"oneOf" : [ {
"type" : "string",
- "minLength" : 1
+ "enum" : [ "official" ]
}, {
"type" : "null"
} ]
},
- "details" : {
+ "description" : {
"oneOf" : [ {
- "type" : "object",
- "properties" : { }
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
@@ -17282,43 +18536,44 @@
"type" : "null"
} ]
},
+ "parent_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
"type" : {
"oneOf" : [ {
- "description" : "Must be a namespaced channel. E.g: channel/http"
+ "type" : "string",
+ "enum" : [ "remote-synced" ]
}, {
"type" : "null"
} ]
}
- }
+ },
+ "required" : [ "archived" ]
}
}
}
},
- "tags" : [ "/api/channel" ]
- }
- },
- "/api/cloud-migration/" : {
- "post" : {
- "summary" : "POST /api/cloud-migration/",
- "description" : "Initiate a new cloud migration.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/cloud-migration" ]
+ "tags" : [ "/api/collection" ]
},
- "get" : {
- "summary" : "GET /api/cloud-migration/",
- "description" : "Get the latest cloud migration, if any.",
- "parameters" : [ ],
+ "delete" : {
+ "summary" : "DELETE /api/collection/{id}",
+ "description" : "Deletes a collection permanently",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -17330,17 +18585,33 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/cloud-migration" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/cloud-migration/cancel" : {
- "put" : {
- "summary" : "PUT /api/cloud-migration/cancel",
- "description" : "Cancel any ongoing cloud migrations, if any.",
- "parameters" : [ ],
+ "/api/collection/{id}/dashboard-question-candidates" : {
+ "get" : {
+ "summary" : "GET /api/collection/{id}/dashboard-question-candidates",
+ "description" : "Find cards in this collection that can be moved into dashboards in this collection.\n\n To be eligible, a card must only appear in one dashboard (which is also in this collection), and must not already be a\n dashboard question.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidatesResponse"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -17349,52 +18620,118 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/cloud-migration" ]
+ "tags" : [ "/api/collection" ]
}
},
- "/api/collection/" : {
+ "/api/collection/{id}/items" : {
"get" : {
- "summary" : "GET /api/collection/",
- "description" : "Fetch a list of all Collections that the current user has read permissions for (`:can_write` is returned as an\n additional property of each Collection so you can tell which of these you have write permissions for.)\n\n By default, this returns non-archived Collections, but instead you can show archived ones by passing\n `?archived=true`.\n\n By default, admin users will see all collections. To hide other user's collections pass in\n `?exclude-other-user-collections=true`.\n\n If personal-only is `true`, then return only personal collections where `personal_owner_id` is not `nil`.",
+ "summary" : "GET /api/collection/{id}/items",
+ "description" : "Fetch a specific Collection's items with the following options:\n\n * `models` - only include objects of a specific set of `models`. If unspecified, returns objects of all models\n * `archived` - when `true`, return archived objects *instead* of unarchived ones. Defaults to `false`.\n * `pinned_state` - when `is_pinned`, return pinned objects only.\n when `is_not_pinned`, return non pinned objects only.\n when `all`, return everything. By default returns everything.\n * `include_can_run_adhoc_query` - when this is true hydrates the `can_run_adhoc_query` flag on card models\n\n Note that this endpoint should return results in a similar shape to `/api/dashboard/:id/items`, so if this is\n changed, that should too.",
"parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "models",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "dashboard", "table", "dataset", "no_models", "timeline", "snippet", "collection", "transform", "document", "pulse", "metric", "card" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
"in" : "query",
"name" : "archived",
"required" : true,
"schema" : {
- "default" : false,
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_can_run_adhoc_query",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "pinned_state",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "is_not_pinned", "is_pinned", "all" ]
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
+ "schema" : {
"oneOf" : [ {
- "type" : "boolean"
+ "type" : "string",
+ "enum" : [ "model", "name", "last_edited_by", "last_edited_at", "description" ]
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "exclude-other-user-collections",
- "required" : true,
+ "name" : "sort_direction",
+ "required" : false,
"schema" : {
- "default" : false,
"oneOf" : [ {
- "type" : "boolean"
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "namespace",
+ "name" : "official_collections_first",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "boolean",
+ "optional" : true
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "personal-only",
+ "name" : "show_dashboard_questions",
"required" : true,
"schema" : {
"default" : false,
@@ -17417,10 +18754,105 @@
}
},
"tags" : [ "/api/collection" ]
+ }
+ },
+ "/api/collection/{id}/move-dashboard-question-candidates" : {
+ "post" : {
+ "summary" : "POST /api/collection/{id}/move-dashboard-question-candidates",
+ "description" : "Move candidate cards to the dashboards they appear in.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "card_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "uniqueItems" : true
+ }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/collection" ]
+ }
+ },
+ "/api/comment/" : {
+ "get" : {
+ "summary" : "GET /api/comment/",
+ "description" : "Get comments for an entity",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "target_type",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "document" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "target_id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/comment" ]
},
"post" : {
- "summary" : "POST /api/collection/",
- "description" : "Create a new Collection.",
+ "summary" : "POST /api/comment/",
+ "description" : "Create a new comment",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -17439,35 +18871,20 @@
"schema" : {
"type" : "object",
"properties" : {
- "authority_level" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "official" ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
+ "child_target_id" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "name" : {
- "type" : "string",
- "minLength" : 1
+ "content" : {
+ "type" : "object"
},
- "namespace" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "html" : {
+ "type" : "string"
},
- "parent_id" : {
+ "parent_comment_id" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
@@ -17475,33 +18892,30 @@
}, {
"type" : "null"
} ]
+ },
+ "target_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "target_type" : {
+ "type" : "string",
+ "enum" : [ "document" ]
}
},
- "required" : [ "name" ]
+ "required" : [ "target_type", "target_id", "content", "html" ]
}
}
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/comment" ]
}
},
- "/api/collection/graph" : {
+ "/api/comment/mentions" : {
"get" : {
- "summary" : "GET /api/collection/graph",
- "description" : "Fetch a graph of all Collection Permissions.",
- "parameters" : [ {
- "in" : "query",
- "name" : "namespace",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- } ],
+ "summary" : "GET /api/comment/mentions",
+ "description" : "Get a list of entities suitable for mentions. NOTE: only users for now.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -17513,35 +18927,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
- },
+ "tags" : [ "/api/comment" ]
+ }
+ },
+ "/api/comment/{comment-id}" : {
"put" : {
- "summary" : "PUT /api/collection/graph",
- "description" : "Do a batch update of Collections Permissions by passing in a modified graph. Will overwrite parts of the graph that\n are present in the request, and leave the rest unchanged.\n\n If the `force` query parameter is `true`, a `revision` number is not required. The provided graph will be persisted\n as-is, and has the potential to clobber other writes that happened since the last read.\n\n If the `skip_graph` query parameter is `true`, it will only return the current revision, not the entire permissions\n graph.",
+ "summary" : "PUT /api/comment/{comment-id}",
+ "description" : "Update a comment",
"parameters" : [ {
- "in" : "query",
- "name" : "force",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "skip-graph",
+ "in" : "path",
+ "name" : "comment-id",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -17560,51 +18961,34 @@
"schema" : {
"type" : "object",
"properties" : {
- "groups" : {
- "type" : "object",
- "properties" : { }
+ "content" : {
+ "type" : "object"
},
- "namespace" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "html" : {
+ "type" : "string"
},
- "revision" : {
- "oneOf" : [ {
- "description" : "value must be an integer.",
- "type" : "integer"
- }, {
- "type" : "null"
- } ]
+ "is_resolved" : {
+ "type" : "boolean"
}
- },
- "required" : [ "groups" ]
+ }
}
}
}
},
- "tags" : [ "/api/collection" ]
- }
- },
- "/api/collection/root" : {
- "get" : {
- "summary" : "GET /api/collection/root",
- "description" : "Return the 'Root' Collection object with standard details added",
+ "tags" : [ "/api/comment" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/comment/{comment-id}",
+ "description" : "Soft delete a comment",
"parameters" : [ {
- "in" : "query",
- "name" : "namespace",
- "required" : false,
+ "in" : "path",
+ "name" : "comment-id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -17617,24 +19001,26 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/comment" ]
}
},
- "/api/collection/root/dashboard-question-candidates" : {
- "get" : {
- "summary" : "GET /api/collection/root/dashboard-question-candidates",
- "description" : "Find cards in the root collection that can be moved into dashboards in the root collection. (Same as the above\n endpoint, but for the root collection)",
- "parameters" : [ ],
+ "/api/comment/{comment-id}/reaction" : {
+ "post" : {
+ "summary" : "POST /api/comment/{comment-id}/reaction",
+ "description" : "Toggle a reaction on a comment",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "comment-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidatesResponse"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -17643,140 +19029,38 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "emoji" : {
+ "type" : "string",
+ "minLength" : 1,
+ "maxLength" : 10
+ }
+ },
+ "required" : [ "emoji" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/comment" ]
}
},
- "/api/collection/root/items" : {
+ "/api/dashboard/" : {
"get" : {
- "summary" : "GET /api/collection/root/items",
- "description" : "Fetch objects that the current user should see at their root level. As mentioned elsewhere, the 'Root' Collection\n doesn't actually exist as a row in the application DB: it's simply a virtual Collection where things with no\n `collection_id` exist. It does, however, have its own set of Permissions.\n\n This endpoint will actually show objects with no `collection_id` for Users that have Root Collection\n permissions, but for people without Root Collection perms, we'll just show the objects that have an effective\n location of `/`.\n\n This endpoint is intended to power a 'Root Folder View' for the Current User, so regardless you'll see all the\n top-level objects you're allowed to access.\n\n By default, this will show the 'normal' Collections namespace; to view a different Collections namespace, such as\n `snippets`, you can pass the `?namespace=` parameter.\n\n By default, library collections are excluded from the results; to include them, pass `?include_library=true`.\n\n Note that this endpoint should return results in a similar shape to `/api/dashboard/:id/items`, so if this is\n changed, that should too.",
+ "summary" : "GET /api/dashboard/",
+ "description" : "This endpoint is currently unused by the Metabase frontend and may be out of date with the rest of the application.\n It only exists for backwards compatibility and may be removed in the future.\n\n Get `Dashboards`. With filter option `f` (default `all`), restrict results as follows:\n * `all` - Return all Dashboards.\n * `mine` - Return Dashboards created by the current user.\n * `archived` - Return Dashboards that have been archived. (By default, these are *excluded*.)",
"parameters" : [ {
"in" : "query",
- "name" : "models",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "dashboard", "table", "dataset", "no_models", "timeline", "snippet", "collection", "transform", "document", "pulse", "metric", "card" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "collection_type",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "remote-synced" ]
- }
- }, {
- "in" : "query",
- "name" : "include_can_run_adhoc_query",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "archived",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "namespace",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_library",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "pinned_state",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "is_not_pinned", "is_pinned", "all" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "model", "name", "last_edited_by", "last_edited_at", "description" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
+ "name" : "f",
"required" : false,
"schema" : {
"oneOf" : [ {
"type" : "string",
- "enum" : [ "desc", "asc" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "official_collections_first",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean",
- "optional" : true
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "show_dashboard_questions",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean",
- "optional" : true
+ "enum" : [ "all", "mine", "archived" ]
}, {
"type" : "null"
} ]
@@ -17793,24 +19077,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
- }
- },
- "/api/collection/root/move-dashboard-question-candidates" : {
+ "deprecated" : true,
+ "tags" : [ "/api/dashboard" ]
+ },
"post" : {
- "summary" : "POST /api/collection/root/move-dashboard-question-candidates",
- "description" : "Move candidate cards to the dashboards they appear in (for the root collection)",
+ "summary" : "POST /api/dashboard/",
+ "description" : "Create a new Dashboard.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -17823,33 +19099,66 @@
"content" : {
"application/json" : {
"schema" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "card_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "uniqueItems" : true
- }
+ "type" : "object",
+ "properties" : {
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
}
- }, {
- "type" : "null"
- } ]
+ },
+ "required" : [ "name" ]
}
}
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/trash" : {
+ "/api/dashboard/embeddable" : {
"get" : {
- "summary" : "GET /api/collection/trash",
- "description" : "Fetch the trash collection, as in `/api/collection/:trash-id`",
+ "summary" : "GET /api/dashboard/embeddable",
+ "description" : "Fetch a list of Dashboards where `enable_embedding` is `true`. The dashboards can be embedded using the embedding\n endpoints and a signed JWT.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -17862,100 +19171,37 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/tree" : {
+ "/api/dashboard/params/valid-filter-fields" : {
"get" : {
- "summary" : "GET /api/collection/tree",
- "description" : "Similar to `GET /`, but returns Collections in a tree structure, e.g.\n\n ```\n [{:name \"A\"\n :below #{:card :dataset}\n :children [{:name \"B\"}\n {:name \"C\"\n :here #{:dataset :card}\n :below #{:dataset :card}\n :children [{:name \"D\"\n :here #{:dataset}\n :children [{:name \"E\"}]}\n {:name \"F\"\n :here #{:card}\n :children [{:name \"G\"}]}]}]}\n {:name \"H\"}]\n ```\n\n The here and below keys indicate the types of items at this particular level of the tree (here) and in its\n subtree (below).\n\n TODO: for historical reasons this returns Saved Questions AS 'card' AND Models as 'dataset'; we should fix this at\n some point in the future.\n\n By default, looks at the `analytics` (if enabled) and regular (`nil`) namespaces. You can optionally pass a\n `namespace` argument, or one or many `namespaces`, to specify the particular collection namespaces you wish to look\n at. For example, `namespaces=analytics&namespaces=` would match the default behavior.\n\n When `shallow` is true, takes an optional `collection-id` and returns only the requested collection (or\n the root, if `collection-id` is `nil`).",
+ "summary" : "GET /api/dashboard/params/valid-filter-fields",
+ "description" : "Utility endpoint for powering Dashboard UI. Given some set of `filtered` Field IDs (presumably Fields used in\n parameters) and a set of `filtering` Field IDs that will be used to restrict values of `filtered` Fields, for each\n `filtered` Field ID return the subset of `filtering` Field IDs that would actually be used in a chain filter query\n with these Fields.\n\n e.g. in a chain filter query like\n\n GET /api/dashboard/10/params/PARAM_1/values?PARAM_2=100\n\n Assume `PARAM_1` maps to Field 1 and `PARAM_2` maps to Fields 2 and 3. The underlying MBQL query may or may not\n filter against Fields 2 and 3, depending on whether an FK relationship that lets us create a join against Field 1\n can be found. You can use this endpoint to determine which of those Fields is actually used:\n\n GET /api/dashboard/params/valid-filter-fields?filtered=1&filtering=2&filtering=3\n ;; ->\n {1 [2 3]}\n\n Results are returned as a map of\n\n `filtered` Field ID -> subset of `filtering` Field IDs that would be used in chain filter query",
"parameters" : [ {
"in" : "query",
- "name" : "exclude-archived",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "exclude-other-user-collections",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include-library",
+ "name" : "filtered",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "namespace",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
+ }
}
}, {
"in" : "query",
- "name" : "namespaces",
+ "name" : "filtering",
"required" : false,
"schema" : {
"oneOf" : [ {
"type" : "array",
"items" : {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
}
}, {
"type" : "null"
} ]
}
- }, {
- "in" : "query",
- "name" : "shallow",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "collection-id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
} ],
"responses" : {
"2XX" : {
@@ -17968,48 +19214,34 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/{id}" : {
- "get" : {
- "summary" : "GET /api/collection/{id}",
- "description" : "Fetch a specific Collection with standard details added",
+ "/api/dashboard/pivot/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/pivot/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query",
+ "description" : "Run a pivot table query for a specific DashCard.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "dashboard-id",
"required" : true,
"schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
+ "type" : "integer",
+ "minimum" : 1
},
- "4XX" : {
- "description" : "Client error response"
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "dashcard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
},
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/collection" ]
- },
- "put" : {
- "summary" : "PUT /api/collection/{id}",
- "description" : "Modify an existing Collection, including archiving or unarchiving it, or moving it.",
- "parameters" : [ {
+ "description" : "value must be an integer greater than zero."
+ }, {
"in" : "path",
- "name" : "id",
+ "name" : "card-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18034,76 +19266,61 @@
"schema" : {
"type" : "object",
"properties" : {
- "archived" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "authority_level" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "official" ]
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "parent_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "type" : {
+ "parameters" : {
"oneOf" : [ {
- "type" : "string",
- "enum" : [ "remote-synced" ]
+ "type" : "array",
+ "items" : {
+ "description" : "value must be a parameter map with an 'id' key",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "id" ]
+ }, {
+ "type" : "object",
+ "additionalProperties" : { }
+ } ]
+ }
}, {
"type" : "null"
} ]
}
- },
- "required" : [ "archived" ]
+ }
}
}
}
},
- "tags" : [ "/api/collection" ]
- },
- "delete" : {
- "summary" : "DELETE /api/collection/{id}",
- "description" : "Deletes a collection permanently",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "tags" : [ "/api/dashboard" ]
+ }
+ },
+ "/api/dashboard/public" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/public",
+ "description" : "Fetch a list of Dashboards with public UUIDs. These dashboards are publicly-accessible *if* public sharing is\n enabled.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "value must be an integer greater than zero."
- } ],
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/dashboard" ]
+ }
+ },
+ "/api/dashboard/save" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/save",
+ "description" : "Save a denormalized description of dashboard.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -18115,16 +19332,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/{id}/dashboard-question-candidates" : {
- "get" : {
- "summary" : "GET /api/collection/{id}/dashboard-question-candidates",
- "description" : "Find cards in this collection that can be moved into dashboards in this collection.\n\n To be eligible, a card must only appear in one dashboard (which is also in this collection), and must not already be a\n dashboard question.",
+ "/api/dashboard/save/collection/{parent-collection-id}" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/save/collection/{parent-collection-id}",
+ "description" : "Save a denormalized description of dashboard into collection with ID `:parent-collection-id`.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "parent-collection-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18134,14 +19351,7 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.collections-rest.api.DashboardQuestionCandidatesResponse"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -18150,127 +19360,40 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/{id}/items" : {
- "get" : {
- "summary" : "GET /api/collection/{id}/items",
- "description" : "Fetch a specific Collection's items with the following options:\n\n * `models` - only include objects of a specific set of `models`. If unspecified, returns objects of all models\n * `archived` - when `true`, return archived objects *instead* of unarchived ones. Defaults to `false`.\n * `pinned_state` - when `is_pinned`, return pinned objects only.\n when `is_not_pinned`, return non pinned objects only.\n when `all`, return everything. By default returns everything.\n * `include_can_run_adhoc_query` - when this is true hydrates the `can_run_adhoc_query` flag on card models\n\n Note that this endpoint should return results in a similar shape to `/api/dashboard/:id/items`, so if this is\n changed, that should too.",
+ "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query",
+ "description" : "Run the query associated with a Saved Question (`Card`) in the context of a `Dashboard` that includes it.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "models",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "dashboard", "table", "dataset", "no_models", "timeline", "snippet", "collection", "transform", "document", "pulse", "metric", "card" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "archived",
+ "name" : "dashboard-id",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
}, {
- "in" : "query",
- "name" : "include_can_run_adhoc_query",
+ "in" : "path",
+ "name" : "dashcard-id",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "pinned_state",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "is_not_pinned", "is_pinned", "all" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "model", "name", "last_edited_by", "last_edited_at", "description" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "desc", "asc" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "official_collections_first",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean",
- "optional" : true
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
}, {
- "in" : "query",
- "name" : "show_dashboard_questions",
+ "in" : "path",
+ "name" : "card-id",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -18283,33 +19406,93 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/collection" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "dashboard_load_id" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be a parameter map with an 'id' key",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "id" ]
+ }, {
+ "type" : "object",
+ "additionalProperties" : { }
+ } ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/collection/{id}/move-dashboard-question-candidates" : {
+ "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query/{export-format}" : {
"post" : {
- "summary" : "POST /api/collection/{id}/move-dashboard-question-candidates",
- "description" : "Move candidate cards to the dashboards they appear in.",
+ "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query/{export-format}",
+ "description" : "Run the query associated with a Saved Question (`Card`) in the context of a `Dashboard` that includes it, and return\n its results as a file in the specified format.\n\n `parameters` should be passed as query parameter encoded as a serialized JSON string (this is because this endpoint\n is normally used to power 'Download Results' buttons that use HTML `form` actions).",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "dashboard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "dashcard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "card-id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "export-format",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.collections-rest.api.MoveDashboardQuestionCandidatesResponse"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -18322,50 +19505,83 @@
"content" : {
"application/json" : {
"schema" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "card_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "uniqueItems" : true
- }
+ "type" : "object",
+ "properties" : {
+ "format_rows" : {
+ "default" : false,
+ "type" : "boolean"
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "anyOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be a parameter map with an 'id' key",
+ "allOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "id" ]
+ }, {
+ "type" : "object",
+ "additionalProperties" : { }
+ } ]
+ }
+ }, {
+ "description" : "value must be a valid JSON string.",
+ "type" : "string"
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "pivot_results" : {
+ "default" : false,
+ "type" : "boolean"
}
- }, {
- "type" : "null"
- } ]
+ },
+ "required" : [ "format_rows", "pivot_results" ]
}
}
}
},
- "tags" : [ "/api/collection" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/comment/" : {
+ "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute" : {
"get" : {
- "summary" : "GET /api/comment/",
- "description" : "Get comments for an entity",
+ "summary" : "GET /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute",
+ "description" : "Fetches the values for filling in execution parameters. Pass PK parameters and values to select.",
"parameters" : [ {
- "in" : "query",
- "name" : "target_type",
+ "in" : "path",
+ "name" : "dashboard-id",
"required" : true,
"schema" : {
- "type" : "string",
- "enum" : [ "document" ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
}, {
- "in" : "query",
- "name" : "target_id",
+ "in" : "path",
+ "name" : "dashcard-id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "parameters",
+ "required" : false,
+ "schema" : {
+ "type" : "string"
+ },
+ "description" : "value must be a valid JSON string."
} ],
"responses" : {
"2XX" : {
@@ -18378,12 +19594,30 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/comment" ]
+ "tags" : [ "/api/dashboard" ]
},
"post" : {
- "summary" : "POST /api/comment/",
- "description" : "Create a new comment",
- "parameters" : [ ],
+ "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute",
+ "description" : "Execute the associated Action in the context of a `Dashboard` and `DashboardCard` that includes it.\n\n `parameters` should be the mapped dashboard parameters with values.\n `extra_parameters` should be the extra, user entered parameter values.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "dashboard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "dashcard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -18401,51 +19635,36 @@
"schema" : {
"type" : "object",
"properties" : {
- "child_target_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "content" : {
- "type" : "object"
- },
- "html" : {
- "type" : "string"
- },
- "parent_comment_id" : {
+ "parameters" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "object",
+ "additionalProperties" : { }
}, {
"type" : "null"
} ]
- },
- "target_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "target_type" : {
- "type" : "string",
- "enum" : [ "document" ]
}
- },
- "required" : [ "target_type", "target_id", "content", "html" ]
+ }
}
}
}
},
- "tags" : [ "/api/comment" ]
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/comment/mentions" : {
- "get" : {
- "summary" : "GET /api/comment/mentions",
- "description" : "Get a list of entities suitable for mentions. NOTE: only users for now.",
- "parameters" : [ ],
+ "/api/dashboard/{dashboard-id}/public_link" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/{dashboard-id}/public_link",
+ "description" : "Generate publicly-accessible links for this Dashboard. Returns UUID to be used in public links. (If this\n Dashboard has already been shared, it will return the existing public link rather than creating a new one.) Public\n sharing must be enabled.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "dashboard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -18457,16 +19676,42 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/comment" ]
+ "tags" : [ "/api/dashboard" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/dashboard/{dashboard-id}/public_link",
+ "description" : "Delete the publicly-accessible link to this Dashboard.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "dashboard-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/dashboard" ]
}
},
- "/api/comment/{comment-id}" : {
- "put" : {
- "summary" : "PUT /api/comment/{comment-id}",
- "description" : "Update a comment",
+ "/api/dashboard/{from-dashboard-id}/copy" : {
+ "post" : {
+ "summary" : "POST /api/dashboard/{from-dashboard-id}/copy",
+ "description" : "Copy a Dashboard.",
"parameters" : [ {
"in" : "path",
- "name" : "comment-id",
+ "name" : "from-dashboard-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18491,34 +19736,75 @@
"schema" : {
"type" : "object",
"properties" : {
- "content" : {
- "type" : "object"
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
},
- "html" : {
- "type" : "string"
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
},
- "is_resolved" : {
- "type" : "boolean"
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "is_deep_copy" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
}
- }
+ },
+ "required" : [ "is_deep_copy" ]
}
}
}
},
- "tags" : [ "/api/comment" ]
- },
- "delete" : {
- "summary" : "DELETE /api/comment/{comment-id}",
- "description" : "Soft delete a comment",
+ "tags" : [ "/api/dashboard" ]
+ }
+ },
+ "/api/dashboard/{id}" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}",
+ "description" : "Get Dashboard with ID.",
"parameters" : [ {
"in" : "path",
- "name" : "comment-id",
+ "name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -18531,16 +19817,14 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/comment" ]
- }
- },
- "/api/comment/{comment-id}/reaction" : {
- "post" : {
- "summary" : "POST /api/comment/{comment-id}/reaction",
- "description" : "Toggle a reaction on a comment",
+ "tags" : [ "/api/dashboard" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/dashboard/{id}",
+ "description" : "Hard delete a Dashboard. To soft delete, use `PUT /api/dashboard/:id`\n\n This will remove also any questions/models/segments/metrics that use this database.",
"parameters" : [ {
"in" : "path",
- "name" : "comment-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18559,61 +19843,21 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "emoji" : {
- "type" : "string",
- "minLength" : 1,
- "maxLength" : 10
- }
- },
- "required" : [ "emoji" ]
- }
- }
- }
- },
- "tags" : [ "/api/comment" ]
- }
- },
- "/api/dashboard/" : {
- "get" : {
- "summary" : "GET /api/dashboard/",
- "description" : "This endpoint is currently unused by the Metabase frontend and may be out of date with the rest of the application.\n It only exists for backwards compatibility and may be removed in the future.\n\n Get `Dashboards`. With filter option `f` (default `all`), restrict results as follows:\n * `all` - Return all Dashboards.\n * `mine` - Return Dashboards created by the current user.\n * `archived` - Return Dashboards that have been archived. (By default, these are *excluded*.)",
+ "tags" : [ "/api/dashboard" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/dashboard/{id}",
+ "description" : "Update a Dashboard, and optionally the `dashcards` and `tabs` of a Dashboard. The request body should be a JSON object with the same\n structure as the response from `GET /api/dashboard/:id`.",
"parameters" : [ {
- "in" : "query",
- "name" : "f",
- "required" : false,
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "all", "mine", "archived" ]
- }, {
- "type" : "null"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
+ "type" : "integer",
+ "minimum" : 1
},
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "deprecated" : true,
- "tags" : [ "/api/dashboard" ]
- },
- "post" : {
- "summary" : "POST /api/dashboard/",
- "description" : "Create a new Dashboard.",
- "parameters" : [ ],
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -18631,7 +19875,63 @@
"schema" : {
"type" : "object",
"properties" : {
- "cache_ttl" : {
+ "points_of_interest" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "enable_embedding" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "width" : {
+ "type" : "string",
+ "enum" : [ "fixed", "full" ]
+ },
+ "embedding_type" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "show_in_getting_started" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "archived" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
@@ -18640,6 +19940,44 @@
"type" : "null"
} ]
},
+ "embedding_params" : {
+ "oneOf" : [ {
+ "description" : "value must be a valid embedding params map.",
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string",
+ "enum" : [ "disabled", "enabled", "locked" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "tabs" : {
+ "oneOf" : [ {
+ "description" : "value must be seq of maps in which ids are unique",
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "id", "name" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
"collection_id" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
@@ -18649,7 +19987,7 @@
"type" : "null"
} ]
},
- "collection_position" : {
+ "cache_ttl" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
@@ -18658,26 +19996,93 @@
"type" : "null"
} ]
},
+ "caveats" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dashcards" : {
+ "oneOf" : [ {
+ "description" : "value must be seq of maps in which ids are unique",
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "col" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "id" : {
+ "type" : "integer"
+ },
+ "inline_parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "row" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "series" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "object"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "size_x" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "size_y" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "id", "size_x", "size_y", "row", "col" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
"description" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
}
- },
- "required" : [ "name" ]
+ }
}
}
}
@@ -18685,93 +20090,13 @@
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/embeddable" : {
- "get" : {
- "summary" : "GET /api/dashboard/embeddable",
- "description" : "Fetch a list of Dashboards where `enable_embedding` is `true`. The dashboards can be embedded using the embedding\n endpoints and a signed JWT.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/dashboard" ]
- }
- },
- "/api/dashboard/params/valid-filter-fields" : {
- "get" : {
- "summary" : "GET /api/dashboard/params/valid-filter-fields",
- "description" : "Utility endpoint for powering Dashboard UI. Given some set of `filtered` Field IDs (presumably Fields used in\n parameters) and a set of `filtering` Field IDs that will be used to restrict values of `filtered` Fields, for each\n `filtered` Field ID return the subset of `filtering` Field IDs that would actually be used in a chain filter query\n with these Fields.\n\n e.g. in a chain filter query like\n\n GET /api/dashboard/10/params/PARAM_1/values?PARAM_2=100\n\n Assume `PARAM_1` maps to Field 1 and `PARAM_2` maps to Fields 2 and 3. The underlying MBQL query may or may not\n filter against Fields 2 and 3, depending on whether an FK relationship that lets us create a join against Field 1\n can be found. You can use this endpoint to determine which of those Fields is actually used:\n\n GET /api/dashboard/params/valid-filter-fields?filtered=1&filtering=2&filtering=3\n ;; ->\n {1 [2 3]}\n\n Results are returned as a map of\n\n `filtered` Field ID -> subset of `filtering` Field IDs that would be used in chain filter query",
- "parameters" : [ {
- "in" : "query",
- "name" : "filtered",
- "required" : true,
- "schema" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }
- }
- }, {
- "in" : "query",
- "name" : "filtering",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }
- }, {
- "type" : "null"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/dashboard" ]
- }
- },
- "/api/dashboard/pivot/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query" : {
- "post" : {
- "summary" : "POST /api/dashboard/pivot/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query",
- "description" : "Run a pivot table query for a specific DashCard.",
+ "/api/dashboard/{id}/cards" : {
+ "put" : {
+ "summary" : "PUT /api/dashboard/{id}/cards",
+ "description" : "(DEPRECATED -- Use the `PUT /api/dashboard/:id` endpoint instead.)\n Update `Cards` and `Tabs` on a Dashboard. Request body should have the form:\n\n {:cards [{:id ... ; DashboardCard ID\n :size_x ...\n :size_y ...\n :row ...\n :col ...\n :parameter_mappings ...\n :series [{:id 123\n ...}]}\n ...]\n :tabs [{:id ... ; DashboardTab ID\n :name ...}]}",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "dashcard-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "card-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18796,82 +20121,105 @@
"schema" : {
"type" : "object",
"properties" : {
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be a parameter map with an 'id' key",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "id" : {
+ "cards" : {
+ "description" : "value must be seq of maps in which ids are unique",
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "col" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "id" : {
+ "type" : "integer"
+ },
+ "inline_parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
"type" : "string",
"minLength" : 1
}
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "row" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "series" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "object"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "size_x" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "size_y" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "id", "size_x", "size_y", "row", "col" ]
+ }
+ },
+ "tabs" : {
+ "oneOf" : [ {
+ "description" : "value must be seq of maps in which ids are unique",
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
},
- "required" : [ "id" ]
- }, {
- "type" : "object",
- "additionalProperties" : { }
- } ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
- }
- },
- "tags" : [ "/api/dashboard" ]
- }
- },
- "/api/dashboard/public" : {
- "get" : {
- "summary" : "GET /api/dashboard/public",
- "description" : "Fetch a list of Dashboards with public UUIDs. These dashboards are publicly-accessible *if* public sharing is\n enabled.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/dashboard" ]
- }
- },
- "/api/dashboard/save" : {
- "post" : {
- "summary" : "POST /api/dashboard/save",
- "description" : "Save a denormalized description of dashboard.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "id", "name" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "cards" ]
+ }
+ }
}
},
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/save/collection/{parent-collection-id}" : {
- "post" : {
- "summary" : "POST /api/dashboard/save/collection/{parent-collection-id}",
- "description" : "Save a denormalized description of dashboard into collection with ID `:parent-collection-id`.",
+ "/api/dashboard/{id}/items" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}/items",
+ "description" : "Get Dashboard with ID.",
"parameters" : [ {
"in" : "path",
- "name" : "parent-collection-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18893,13 +20241,13 @@
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query" : {
- "post" : {
- "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query",
- "description" : "Run the query associated with a Saved Question (`Card`) in the context of a `Dashboard` that includes it.",
+ "/api/dashboard/{id}/params/{param-key}/remapping" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}/params/{param-key}/remapping",
+ "description" : "Fetch the remapped value for a given value of the parameter with ID `:param-key`.\n\n ;; fetch the remapped value for Dashboard 1 parameter 'abc' for value 100\n GET /api/dashboard/1/params/abc/remapping?value=100",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -18908,22 +20256,19 @@
"description" : "value must be an integer greater than zero."
}, {
"in" : "path",
- "name" : "dashcard-id",
+ "name" : "param-key",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "string",
+ "minLength" : 1
+ }
}, {
- "in" : "path",
- "name" : "card-id",
+ "in" : "query",
+ "name" : "value",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "string"
+ }
} ],
"responses" : {
"2XX" : {
@@ -18936,67 +20281,16 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "dashboard_load_id" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be a parameter map with an 'id' key",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "id" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "id" ]
- }, {
- "type" : "object",
- "additionalProperties" : { }
- } ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
- }
- },
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query/{export-format}" : {
- "post" : {
- "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/card/{card-id}/query/{export-format}",
- "description" : "Run the query associated with a Saved Question (`Card`) in the context of a `Dashboard` that includes it, and return\n its results as a file in the specified format.\n\n `parameters` should be passed as query parameter encoded as a serialized JSON string (this is because this endpoint\n is normally used to power 'Download Results' buttons that use HTML `form` actions).",
+ "/api/dashboard/{id}/params/{param-key}/search/{query}" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}/params/{param-key}/search/{query}",
+ "description" : "Fetch possible values of the parameter whose ID is `:param-key` that contain `:query`. Optionally restrict\n these values by passing query parameters like `other-parameter=value` e.g.\n\n ;; fetch values for Dashboard 1 parameter 'abc' that contain 'Cam' and are possible when parameter 'def' is set\n ;; to 100\n GET /api/dashboard/1/params/abc/search/Cam?def=100\n\n Currently limited to first 1000 results.",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "dashcard-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -19005,19 +20299,19 @@
"description" : "value must be an integer greater than zero."
}, {
"in" : "path",
- "name" : "card-id",
+ "name" : "param-key",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "string",
+ "minLength" : 1
+ }
}, {
"in" : "path",
- "name" : "export-format",
+ "name" : "query",
"required" : true,
"schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
+ "type" : "string",
+ "minLength" : 1
}
} ],
"responses" : {
@@ -19031,64 +20325,16 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "format_rows" : {
- "default" : false,
- "type" : "boolean"
- },
- "parameters" : {
- "oneOf" : [ {
- "anyOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be a parameter map with an 'id' key",
- "allOf" : [ {
- "type" : "object",
- "properties" : {
- "id" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "id" ]
- }, {
- "type" : "object",
- "additionalProperties" : { }
- } ]
- }
- }, {
- "description" : "value must be a valid JSON string.",
- "type" : "string"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "pivot_results" : {
- "default" : false,
- "type" : "boolean"
- }
- },
- "required" : [ "format_rows", "pivot_results" ]
- }
- }
- }
- },
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute" : {
+ "/api/dashboard/{id}/params/{param-key}/values" : {
"get" : {
- "summary" : "GET /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute",
- "description" : "Fetches the values for filling in execution parameters. Pass PK parameters and values to select.",
+ "summary" : "GET /api/dashboard/{id}/params/{param-key}/values",
+ "description" : "Fetch possible values of the parameter whose ID is `:param-key`. If the values come directly from a query, optionally\n restrict these values by passing query parameters like `other-parameter=value` e.g.\n\n ;; fetch values for Dashboard 1 parameter 'abc' that are possible when parameter 'def' is set to 100\n GET /api/dashboard/1/params/abc/values?def=100",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -19097,56 +20343,12 @@
"description" : "value must be an integer greater than zero."
}, {
"in" : "path",
- "name" : "dashcard-id",
+ "name" : "param-key",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "parameters",
- "required" : false,
- "schema" : {
- "type" : "string"
- },
- "description" : "value must be a valid JSON string."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "type" : "string",
+ "minLength" : 1
}
- },
- "tags" : [ "/api/dashboard" ]
- },
- "post" : {
- "summary" : "POST /api/dashboard/{dashboard-id}/dashcard/{dashcard-id}/execute",
- "description" : "Execute the associated Action in the context of a `Dashboard` and `DashboardCard` that includes it.\n\n `parameters` should be the mapped dashboard parameters with values.\n `extra_parameters` should be the extra, user entered parameter values.",
- "parameters" : [ {
- "in" : "path",
- "name" : "dashboard-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "dashcard-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -19159,41 +20361,28 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "parameters" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : { }
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
- }
- },
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/{dashboard-id}/public_link" : {
- "post" : {
- "summary" : "POST /api/dashboard/{dashboard-id}/public_link",
- "description" : "Generate publicly-accessible links for this Dashboard. Returns UUID to be used in public links. (If this\n Dashboard has already been shared, it will return the existing public link rather than creating a new one.) Public\n sharing must be enabled.",
+ "/api/dashboard/{id}/query_metadata" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}/query_metadata",
+ "description" : "Get all of the required query metadata for the cards on dashboard.",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
+ "name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "description" : "String must be a valid 21-character NanoID string.",
+ "type" : "string",
+ "pattern" : "^[A-Za-z0-9_\\-]{21}$"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -19207,13 +20396,15 @@
}
},
"tags" : [ "/api/dashboard" ]
- },
- "delete" : {
- "summary" : "DELETE /api/dashboard/{dashboard-id}/public_link",
- "description" : "Delete the publicly-accessible link to this Dashboard.",
+ }
+ },
+ "/api/dashboard/{id}/related" : {
+ "get" : {
+ "summary" : "GET /api/dashboard/{id}/related",
+ "description" : "Return related entities.",
"parameters" : [ {
"in" : "path",
- "name" : "dashboard-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -19235,19 +20426,117 @@
"tags" : [ "/api/dashboard" ]
}
},
- "/api/dashboard/{from-dashboard-id}/copy" : {
- "post" : {
- "summary" : "POST /api/dashboard/{from-dashboard-id}/copy",
- "description" : "Copy a Dashboard.",
+ "/api/database/" : {
+ "get" : {
+ "summary" : "GET /api/database/",
+ "description" : "Fetch all `Databases`.\n\n * `include=tables` means we should hydrate the Tables belonging to each DB. Default: `false`.\n\n * `saved` means we should include the saved questions virtual database. Default: `false`.\n\n * `include_editable_data_model` will only include DBs for which the current user has data model editing\n permissions. (If `include=tables`, this also applies to the list of tables in each DB). Should only be used if\n Enterprise Edition code is available the advanced-permissions feature is enabled.\n\n * `exclude_uneditable_details` will only include DBs for which the current user can edit the DB details. Has no\n effect unless Enterprise Edition code is available and the advanced-permissions feature is enabled.\n\n * `include_only_uploadable` will only include DBs into which Metabase can insert new data.\n\n * `can-query` will only include DBs for which the current user has query permissions. Default: `false`.\n\n * `can-write-metadata` will only include DBs for which the current user has data model editing permissions\n for at least one table in the database. Default: `false`.\n\n Independently of these flags, the implementation of [[metabase.models.interface/to-json]] for `:model/Database` in\n [[metabase.warehouses.models.database]] uses the implementation of [[metabase.models.interface/can-write?]] for\n `:model/Database` in [[metabase.warehouses.models.database]] to exclude the `details` field, if the requesting user\n lacks permission to change the database details.",
"parameters" : [ {
- "in" : "path",
- "name" : "from-dashboard-id",
- "required" : true,
+ "in" : "query",
+ "name" : "include",
+ "required" : false,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "oneOf" : [ {
+ "const" : "tables"
+ }, {
+ "type" : "null"
+ } ]
},
- "description" : "value must be an integer greater than zero."
+ "description" : "include must be either empty or the value 'tables'"
+ }, {
+ "in" : "query",
+ "name" : "include_analytics",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "saved",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_editable_data_model",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "exclude_uneditable_details",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_only_uploadable",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "router_database_id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-query",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-write-metadata",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -19260,22 +20549,49 @@
"description" : "Server error response"
}
},
+ "tags" : [ "/api/database" ]
+ },
+ "post" : {
+ "summary" : "POST /api/database/",
+ "description" : "Add a new `Database`.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
- "collection_id" : {
+ "provider_name" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "collection_position" : {
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "is_on_demand" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
"oneOf" : [ {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
@@ -19284,58 +20600,80 @@
"type" : "null"
} ]
},
- "description" : {
+ "engine" : {
+ "description" : "value must be a valid database engine.",
+ "type" : "string",
+ "minLength" : 1
+ },
+ "details" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "is_full_sync" : {
+ "default" : true,
"oneOf" : [ {
- "type" : "string"
+ "type" : "boolean"
}, {
"type" : "null"
} ]
},
- "is_deep_copy" : {
- "default" : false,
+ "connection_source" : {
+ "default" : "admin",
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "admin", "setup" ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "auto_run_queries" : {
"oneOf" : [ {
"type" : "boolean"
}, {
"type" : "null"
} ]
},
- "name" : {
+ "schedules" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "$ref" : "#/components/schemas/metabase.sync.schedules.ExpandedSchedulesMap"
}, {
"type" : "null"
} ]
}
},
- "required" : [ "is_deep_copy" ]
+ "required" : [ "name", "engine", "details", "is_full_sync", "is_on_demand", "connection_source" ]
}
}
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}" : {
- "get" : {
- "summary" : "GET /api/dashboard/{id}",
- "description" : "Get Dashboard with ID.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
+ "/api/database/sample_database" : {
+ "post" : {
+ "summary" : "POST /api/database/sample_database",
+ "description" : "Add the sample database as a new `Database`.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- } ],
+ },
+ "tags" : [ "/api/database" ]
+ }
+ },
+ "/api/database/validate" : {
+ "post" : {
+ "summary" : "POST /api/database/validate",
+ "description" : "Validate that we can connect to a database given a set of details.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -19347,11 +20685,40 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
- },
- "delete" : {
- "summary" : "DELETE /api/dashboard/{id}",
- "description" : "Hard delete a Dashboard. To soft delete, use `PUT /api/dashboard/:id`\n\n This will remove also any questions/models/segments/metrics that use this database.",
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "engine" : {
+ "description" : "value must be a valid database engine.",
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "engine", "details" ]
+ }
+ },
+ "required" : [ "details" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/database" ]
+ }
+ },
+ "/api/database/{id}" : {
+ "get" : {
+ "summary" : "GET /api/database/{id}",
+ "description" : "Get a single Database with `id`. Optionally pass `?include=tables` or `?include=tables.fields` to include the Tables\n belonging to this database, or the Tables and Fields, respectively. If the requestor has write permissions for the\n DB\n (i.e. is an admin or has data model permissions), then certain inferred secret values will also be included in the\n returned details (see [[metabase.secrets.models.secret/expand-db-details-inferred-secret-values]] for full details).\n\n Passing include_editable_data_model will only return tables for which the current user has data model editing\n permissions, if Enterprise Edition code is available and a token with the advanced-permissions feature is present.\n In addition, if the user has no data access for the DB (aka block permissions), it will return only the DB name, ID\n and tables, with no additional metadata.\n\n Independently of these flags, the implementation of [[metabase.models.interface/to-json]] for `:model/Database` in\n [[metabase.warehouses.models.database]] uses the implementation of [[metabase.models.interface/can-write?]] for `:model/Database`\n in [[metabase.warehouses.models.database]] to exclude the `details` field, if the requesting user lacks permission to change the\n database details.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19361,6 +20728,32 @@
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "include",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "tables", "tables.fields" ]
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_editable_data_model",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "exclude_uneditable_details",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
} ],
"responses" : {
"2XX" : {
@@ -19373,11 +20766,11 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
},
"put" : {
- "summary" : "PUT /api/dashboard/{id}",
- "description" : "Update a Dashboard, and optionally the `dashcards` and `tabs` of a Dashboard. The request body should be a JSON object with the same\n structure as the response from `GET /api/dashboard/:id`.",
+ "summary" : "PUT /api/database/{id}",
+ "description" : "Update a `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19412,36 +20805,18 @@
"type" : "null"
} ]
},
- "enable_embedding" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "width" : {
- "type" : "string",
- "enum" : [ "fixed", "full" ]
- },
- "embedding_type" : {
+ "provider_name" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "show_in_getting_started" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "position" : {
+ "settings" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
}, {
"type" : "null"
} ]
@@ -19451,156 +20826,60 @@
"type" : "string",
"minLength" : 1
}, {
- "type" : "null"
- } ]
- },
- "archived" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "embedding_params" : {
- "oneOf" : [ {
- "description" : "value must be a valid embedding params map.",
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "string",
- "enum" : [ "disabled", "enabled", "locked" ]
- }
- }, {
- "type" : "null"
- } ]
- }, {
- "type" : "null"
- } ]
- },
- "tabs" : {
- "oneOf" : [ {
- "description" : "value must be seq of maps in which ids are unique",
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "id" : {
- "description" : "value must be an integer.",
- "type" : "integer"
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "id", "name" ]
- }
- }, {
- "type" : "null"
- } ]
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "caveats" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "parameters" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameters"
- }, {
- "type" : "null"
- } ]
- },
- "dashcards" : {
- "oneOf" : [ {
- "description" : "value must be seq of maps in which ids are unique",
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "col" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "id" : {
- "type" : "integer"
- },
- "inline_parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- }, {
- "type" : "null"
- } ]
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "row" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "series" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "object"
- }
- }, {
- "type" : "null"
- } ]
- },
- "size_x" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "size_y" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "id", "size_x", "size_y", "row", "col" ]
- }
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "engine" : {
+ "oneOf" : [ {
+ "description" : "value must be a valid database engine.",
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "details" : {
+ "oneOf" : [ {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "auto_run_queries" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "caveats" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "refingerprint" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "schedules" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.sync.schedules.ExpandedSchedulesMap"
}, {
"type" : "null"
} ]
@@ -19617,13 +20896,11 @@
}
}
},
- "tags" : [ "/api/dashboard" ]
- }
- },
- "/api/dashboard/{id}/cards" : {
- "put" : {
- "summary" : "PUT /api/dashboard/{id}/cards",
- "description" : "(DEPRECATED -- Use the `PUT /api/dashboard/:id` endpoint instead.)\n Update `Cards` and `Tabs` on a Dashboard. Request body should have the form:\n\n {:cards [{:id ... ; DashboardCard ID\n :size_x ...\n :size_y ...\n :row ...\n :col ...\n :parameter_mappings ...\n :series [{:id 123\n ...}]}\n ...]\n :tabs [{:id ... ; DashboardTab ID\n :name ...}]}",
+ "tags" : [ "/api/database" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/database/{id}",
+ "description" : "Delete a `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19645,108 +20922,13 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "cards" : {
- "description" : "value must be seq of maps in which ids are unique",
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "col" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "id" : {
- "type" : "integer"
- },
- "inline_parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- }, {
- "type" : "null"
- } ]
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mappings"
- }, {
- "type" : "null"
- } ]
- },
- "row" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- },
- "series" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "object"
- }
- }, {
- "type" : "null"
- } ]
- },
- "size_x" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "size_y" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "id", "size_x", "size_y", "row", "col" ]
- }
- },
- "tabs" : {
- "oneOf" : [ {
- "description" : "value must be seq of maps in which ids are unique",
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "id" : {
- "description" : "value must be an integer.",
- "type" : "integer"
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "id", "name" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "cards" ]
- }
- }
- }
- },
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/items" : {
+ "/api/database/{id}/autocomplete_suggestions" : {
"get" : {
- "summary" : "GET /api/dashboard/{id}/items",
- "description" : "Get Dashboard with ID.",
+ "summary" : "GET /api/database/{id}/autocomplete_suggestions",
+ "description" : "Return a list of autocomplete suggestions for a given `prefix`, or `substring`. Should only specify one, but\n `substring` will have priority if both are present.\n\n This is intended for use with the ACE Editor when the User is typing raw SQL. Suggestions include matching `Tables`\n and `Fields` in this `Database`.\n\n Tables are returned in the format `[table_name \"Table\"]`;\n When Fields have a semantic_type, they are returned in the format `[field_name \"table_name base_type semantic_type\"]`\n When Fields lack a semantic_type, they are returned in the format `[field_name \"table_name base_type\"]`",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19756,6 +20938,30 @@
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "prefix",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "substring",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -19768,13 +20974,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/params/{param-key}/remapping" : {
+ "/api/database/{id}/card_autocomplete_suggestions" : {
"get" : {
- "summary" : "GET /api/dashboard/{id}/params/{param-key}/remapping",
- "description" : "Fetch the remapped value for a given value of the parameter with ID `:param-key`.\n\n ;; fetch the remapped value for Dashboard 1 parameter 'abc' for value 100\n GET /api/dashboard/1/params/abc/remapping?value=100",
+ "summary" : "GET /api/database/{id}/card_autocomplete_suggestions",
+ "description" : "Return a list of `Card` autocomplete suggestions for a given `query` in a given `Database`.\n\n This is intended for use with the ACE Editor when the User is typing in a template tag for a `Card`, e.g. {{#...}}.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19785,8 +20991,8 @@
},
"description" : "value must be an integer greater than zero."
}, {
- "in" : "path",
- "name" : "param-key",
+ "in" : "query",
+ "name" : "query",
"required" : true,
"schema" : {
"type" : "string",
@@ -19794,10 +21000,10 @@
}
}, {
"in" : "query",
- "name" : "value",
- "required" : true,
+ "name" : "include_dashboard_questions",
+ "required" : false,
"schema" : {
- "type" : "string"
+ "type" : "boolean"
}
} ],
"responses" : {
@@ -19811,13 +21017,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/params/{param-key}/search/{query}" : {
- "get" : {
- "summary" : "GET /api/dashboard/{id}/params/{param-key}/search/{query}",
- "description" : "Fetch possible values of the parameter whose ID is `:param-key` that contain `:query`. Optionally restrict\n these values by passing query parameters like `other-parameter=value` e.g.\n\n ;; fetch values for Dashboard 1 parameter 'abc' that contain 'Cam' and are possible when parameter 'def' is set\n ;; to 100\n GET /api/dashboard/1/params/abc/search/Cam?def=100\n\n Currently limited to first 1000 results.",
+ "/api/database/{id}/discard_values" : {
+ "post" : {
+ "summary" : "POST /api/database/{id}/discard_values",
+ "description" : "Discards all saved field values for this `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19827,22 +21033,34 @@
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "param-key",
- "required" : true,
- "schema" : {
- "type" : "string",
- "minLength" : 1
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
+ },
+ "tags" : [ "/api/database" ]
+ }
+ },
+ "/api/database/{id}/dismiss_spinner" : {
+ "post" : {
+ "summary" : "POST /api/database/{id}/dismiss_spinner",
+ "description" : "Manually set the initial sync status of the `Database` and corresponding\n tables to be `complete` (see #20863)",
+ "parameters" : [ {
"in" : "path",
- "name" : "query",
+ "name" : "id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -19855,13 +21073,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/params/{param-key}/values" : {
+ "/api/database/{id}/fields" : {
"get" : {
- "summary" : "GET /api/dashboard/{id}/params/{param-key}/values",
- "description" : "Fetch possible values of the parameter whose ID is `:param-key`. If the values come directly from a query, optionally\n restrict these values by passing query parameters like `other-parameter=value` e.g.\n\n ;; fetch values for Dashboard 1 parameter 'abc' that are possible when parameter 'def' is set to 100\n GET /api/dashboard/1/params/abc/values?def=100",
+ "summary" : "GET /api/database/{id}/fields",
+ "description" : "Get a list of all `Fields` in `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19871,14 +21089,6 @@
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "param-key",
- "required" : true,
- "schema" : {
- "type" : "string",
- "minLength" : 1
- }
} ],
"responses" : {
"2XX" : {
@@ -19891,28 +21101,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/query_metadata" : {
+ "/api/database/{id}/healthcheck" : {
"get" : {
- "summary" : "GET /api/dashboard/{id}/query_metadata",
- "description" : "Get all of the required query metadata for the cards on dashboard.",
+ "summary" : "GET /api/database/{id}/healthcheck",
+ "description" : "Reports whether the database can currently connect",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "description" : "String must be a valid 21-character NanoID string.",
- "type" : "string",
- "pattern" : "^[A-Za-z0-9_\\-]{21}$"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -19925,13 +21129,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/dashboard/{id}/related" : {
+ "/api/database/{id}/idfields" : {
"get" : {
- "summary" : "GET /api/dashboard/{id}/related",
- "description" : "Return related entities.",
+ "summary" : "GET /api/database/{id}/idfields",
+ "description" : "Get a list of all primary key `Fields` for `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -19953,40 +21157,25 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/dashboard" ]
+ "tags" : [ "/api/database" ]
}
},
- "/api/database/" : {
+ "/api/database/{id}/metadata" : {
"get" : {
- "summary" : "GET /api/database/",
- "description" : "Fetch all `Databases`.\n\n * `include=tables` means we should hydrate the Tables belonging to each DB. Default: `false`.\n\n * `saved` means we should include the saved questions virtual database. Default: `false`.\n\n * `include_editable_data_model` will only include DBs for which the current user has data model editing\n permissions. (If `include=tables`, this also applies to the list of tables in each DB). Should only be used if\n Enterprise Edition code is available the advanced-permissions feature is enabled.\n\n * `exclude_uneditable_details` will only include DBs for which the current user can edit the DB details. Has no\n effect unless Enterprise Edition code is available and the advanced-permissions feature is enabled.\n\n * `include_only_uploadable` will only include DBs into which Metabase can insert new data.\n\n * `can-query` will only include DBs for which the current user has query permissions. Default: `false`.\n\n * `can-write-metadata` will only include DBs for which the current user has data model editing permissions\n for at least one table in the database. Default: `false`.\n\n Independently of these flags, the implementation of [[metabase.models.interface/to-json]] for `:model/Database` in\n [[metabase.warehouses.models.database]] uses the implementation of [[metabase.models.interface/can-write?]] for\n `:model/Database` in [[metabase.warehouses.models.database]] to exclude the `details` field, if the requesting user\n lacks permission to change the database details.",
+ "summary" : "GET /api/database/{id}/metadata",
+ "description" : "Get metadata about a `Database`, including all of its `Tables` and `Fields`. Returns DB, fields, and field values.\n By default only non-hidden tables and fields are returned. Passing include_hidden=true includes them.\n\n Passing include_editable_data_model will only return tables for which the current user has data model editing\n permissions, if Enterprise Edition code is available and a token with the advanced-permissions feature is present.\n In addition, if the user has no data access for the DB (aka block permissions), it will return only the DB name, ID\n and tables, with no additional metadata.",
"parameters" : [ {
- "in" : "query",
- "name" : "include",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "const" : "tables"
- }, {
- "type" : "null"
- } ]
- },
- "description" : "include must be either empty or the value 'tables'"
- }, {
- "in" : "query",
- "name" : "include_analytics",
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
}, {
"in" : "query",
- "name" : "saved",
+ "name" : "include_hidden",
"required" : true,
"schema" : {
"default" : false,
@@ -20010,7 +21199,7 @@
}
}, {
"in" : "query",
- "name" : "exclude_uneditable_details",
+ "name" : "remove_inactive",
"required" : true,
"schema" : {
"default" : false,
@@ -20022,188 +21211,17 @@
}
}, {
"in" : "query",
- "name" : "include_only_uploadable",
+ "name" : "skip_fields",
"required" : true,
"schema" : {
"default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "router_database_id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "can-query",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "can-write-metadata",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/database" ]
- },
- "post" : {
- "summary" : "POST /api/database/",
- "description" : "Add a new `Database`.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "provider_name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "is_on_demand" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "engine" : {
- "description" : "value must be a valid database engine.",
- "type" : "string",
- "minLength" : 1
- },
- "details" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "is_full_sync" : {
- "default" : true,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "connection_source" : {
- "default" : "admin",
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "admin", "setup" ]
- }, {
- "type" : "null"
- } ]
- },
- "auto_run_queries" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "schedules" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.sync.schedules.ExpandedSchedulesMap"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "name", "engine", "details", "is_full_sync", "is_on_demand", "connection_source" ]
- }
- }
- }
- },
- "tags" : [ "/api/database" ]
- }
- },
- "/api/database/sample_database" : {
- "post" : {
- "summary" : "POST /api/database/sample_database",
- "description" : "Add the sample database as a new `Database`.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "tags" : [ "/api/database" ]
- }
- },
- "/api/database/validate" : {
- "post" : {
- "summary" : "POST /api/database/validate",
- "description" : "Validate that we can connect to a database given a set of details.",
- "parameters" : [ ],
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -20215,40 +21233,13 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "details" : {
- "type" : "object",
- "properties" : {
- "details" : {
- "type" : "object",
- "properties" : { }
- },
- "engine" : {
- "description" : "value must be a valid database engine.",
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "engine", "details" ]
- }
- },
- "required" : [ "details" ]
- }
- }
- }
- },
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}" : {
- "get" : {
- "summary" : "GET /api/database/{id}",
- "description" : "Get a single Database with `id`. Optionally pass `?include=tables` or `?include=tables.fields` to include the Tables\n belonging to this database, or the Tables and Fields, respectively. If the requestor has write permissions for the\n DB\n (i.e. is an admin or has data model permissions), then certain inferred secret values will also be included in the\n returned details (see [[metabase.secrets.models.secret/expand-db-details-inferred-secret-values]] for full details).\n\n Passing include_editable_data_model will only return tables for which the current user has data model editing\n permissions, if Enterprise Edition code is available and a token with the advanced-permissions feature is present.\n In addition, if the user has no data access for the DB (aka block permissions), it will return only the DB name, ID\n and tables, with no additional metadata.\n\n Independently of these flags, the implementation of [[metabase.models.interface/to-json]] for `:model/Database` in\n [[metabase.warehouses.models.database]] uses the implementation of [[metabase.models.interface/can-write?]] for `:model/Database`\n in [[metabase.warehouses.models.database]] to exclude the `details` field, if the requesting user lacks permission to change the\n database details.",
+ "/api/database/{id}/permission/workspace/check" : {
+ "post" : {
+ "summary" : "POST /api/database/{id}/permission/workspace/check",
+ "description" : "Check if database's connection has the required permissions to manage workspaces.\n By default it'll return the cached permission check.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20259,35 +21250,36 @@
},
"description" : "value must be an integer greater than zero."
}, {
- "in" : "query",
- "name" : "include",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "tables", "tables.fields" ]
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_editable_data_model",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "exclude_uneditable_details",
+ "in" : "path",
+ "name" : "cached",
"required" : false,
"schema" : {
+ "default" : true,
"type" : "boolean"
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "checked_at" : {
+ "type" : "string"
+ },
+ "error" : {
+ "type" : "string"
+ },
+ "status" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "status", "checked_at" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -20297,10 +21289,12 @@
}
},
"tags" : [ "/api/database" ]
- },
- "put" : {
- "summary" : "PUT /api/database/{id}",
- "description" : "Update a `Database`.",
+ }
+ },
+ "/api/database/{id}/rescan_values" : {
+ "post" : {
+ "summary" : "POST /api/database/{id}/rescan_values",
+ "description" : "Trigger a manual scan of the field values for this `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20322,124 +21316,68 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "points_of_interest" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "provider_name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "settings" : {
- "oneOf" : [ {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "engine" : {
- "oneOf" : [ {
- "description" : "value must be a valid database engine.",
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "details" : {
- "oneOf" : [ {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "auto_run_queries" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "caveats" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "refingerprint" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "schedules" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.sync.schedules.ExpandedSchedulesMap"
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
- }
- },
"tags" : [ "/api/database" ]
- },
- "delete" : {
- "summary" : "DELETE /api/database/{id}",
- "description" : "Delete a `Database`.",
+ }
+ },
+ "/api/database/{id}/schema/" : {
+ "get" : {
+ "summary" : "GET /api/database/{id}/schema/",
+ "description" : "Return a list of Tables for a Database whose `schema` is `nil` or an empty string.\n\n Optional filters:\n - `can-query=true` - filter to only tables the user can query\n - `can-write-metadata=true` - filter to only tables the user can edit metadata for",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "include_hidden",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_editable_data_model",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-query",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-write-metadata",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
} ],
"responses" : {
"2XX" : {
@@ -20455,10 +21393,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/autocomplete_suggestions" : {
+ "/api/database/{id}/schema/{schema}" : {
"get" : {
- "summary" : "GET /api/database/{id}/autocomplete_suggestions",
- "description" : "Return a list of autocomplete suggestions for a given `prefix`, or `substring`. Should only specify one, but\n `substring` will have priority if both are present.\n\n This is intended for use with the ACE Editor when the User is typing raw SQL. Suggestions include matching `Tables`\n and `Fields` in this `Database`.\n\n Tables are returned in the format `[table_name \"Table\"]`;\n When Fields have a semantic_type, they are returned in the format `[field_name \"table_name base_type semantic_type\"]`\n When Fields lack a semantic_type, they are returned in the format `[field_name \"table_name base_type\"]`",
+ "summary" : "GET /api/database/{id}/schema/{schema}",
+ "description" : "Returns a list of Tables for the given Database `id` and `schema`.\n\n Optional filters:\n - `can-query=true` - filter to only tables the user can query\n - `can-write-metadata=true` - filter to only tables the user can edit metadata for",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20468,26 +21406,56 @@
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "schema",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
}, {
"in" : "query",
- "name" : "prefix",
+ "name" : "include_hidden",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_editable_data_model",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-query",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "boolean"
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "substring",
+ "name" : "can-write-metadata",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "boolean"
}, {
"type" : "null"
} ]
@@ -20507,10 +21475,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/card_autocomplete_suggestions" : {
+ "/api/database/{id}/schemas" : {
"get" : {
- "summary" : "GET /api/database/{id}/card_autocomplete_suggestions",
- "description" : "Return a list of `Card` autocomplete suggestions for a given `query` in a given `Database`.\n\n This is intended for use with the ACE Editor when the User is typing in a template tag for a `Card`, e.g. {{#...}}.",
+ "summary" : "GET /api/database/{id}/schemas",
+ "description" : "Returns a list of all the schemas with tables found for the database `id`. Excludes schemas with no tables.\n\n Optional filters:\n - `can-query=true` - filter to only schemas containing tables the user can query\n - `can-write-metadata=true` - filter to only schemas containing tables the user can edit metadata for",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20522,23 +21490,76 @@
"description" : "value must be an integer greater than zero."
}, {
"in" : "query",
- "name" : "query",
+ "name" : "include_editable_data_model",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
}, {
"in" : "query",
- "name" : "include_dashboard_questions",
+ "name" : "include_hidden",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-query",
"required" : false,
"schema" : {
- "type" : "boolean"
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "can-write-metadata",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_workspace",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string"
+ }
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -20550,10 +21571,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/discard_values" : {
- "post" : {
- "summary" : "POST /api/database/{id}/discard_values",
- "description" : "Discards all saved field values for this `Database`.",
+ "/api/database/{id}/settings-available" : {
+ "get" : {
+ "summary" : "GET /api/database/{id}/settings-available",
+ "description" : "Get all database-local settings and their availability for the given database.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20566,7 +21587,20 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "settings" : {
+ "$ref" : "#/components/schemas/metabase.warehouses-rest.api.available-settings"
+ }
+ },
+ "required" : [ "settings" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -20578,10 +21612,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/dismiss_spinner" : {
+ "/api/database/{id}/sync_schema" : {
"post" : {
- "summary" : "POST /api/database/{id}/dismiss_spinner",
- "description" : "Manually set the initial sync status of the `Database` and corresponding\n tables to be `complete` (see #20863)",
+ "summary" : "POST /api/database/{id}/sync_schema",
+ "description" : "Trigger a manual update of the schema metadata for this `Database`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20606,10 +21640,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/fields" : {
+ "/api/database/{id}/syncable_schemas" : {
"get" : {
- "summary" : "GET /api/database/{id}/fields",
- "description" : "Get a list of all `Fields` in `Database`.",
+ "summary" : "GET /api/database/{id}/syncable_schemas",
+ "description" : "Returns a list of all syncable schemas found for the database `id`.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20634,10 +21668,10 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/healthcheck" : {
+ "/api/database/{id}/usage_info" : {
"get" : {
- "summary" : "GET /api/database/{id}/healthcheck",
- "description" : "Reports whether the database can currently connect",
+ "summary" : "GET /api/database/{id}/usage_info",
+ "description" : "Get usage info for a database.\n Returns a map with keys are models and values are the number of entities that use this database.",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -20662,20 +21696,11 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/idfields" : {
+ "/api/database/{virtual-db}/datasets" : {
"get" : {
- "summary" : "GET /api/database/{id}/idfields",
- "description" : "Get a list of all primary key `Fields` for `Database`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "summary" : "GET /api/database/{virtual-db}/datasets",
+ "description" : "Returns a list of all the datasets found for the saved questions virtual database.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -20690,68 +21715,30 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/metadata" : {
+ "/api/database/{virtual-db}/datasets/{schema}" : {
"get" : {
- "summary" : "GET /api/database/{id}/metadata",
- "description" : "Get metadata about a `Database`, including all of its `Tables` and `Fields`. Returns DB, fields, and field values.\n By default only non-hidden tables and fields are returned. Passing include_hidden=true includes them.\n\n Passing include_editable_data_model will only return tables for which the current user has data model editing\n permissions, if Enterprise Edition code is available and a token with the advanced-permissions feature is present.\n In addition, if the user has no data access for the DB (aka block permissions), it will return only the DB name, ID\n and tables, with no additional metadata.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "summary" : "GET /api/database/{virtual-db}/datasets/{schema}",
+ "description" : "Returns a list of Tables for the datasets virtual database.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "include_hidden",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_editable_data_model",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "remove_inactive",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "skip_fields",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- } ],
+ },
+ "tags" : [ "/api/database" ]
+ }
+ },
+ "/api/database/{virtual-db}/metadata" : {
+ "get" : {
+ "summary" : "GET /api/database/{virtual-db}/metadata",
+ "description" : "Endpoint that provides metadata for the Saved Questions 'virtual' database. Used for fooling the frontend\n and allowing it to treat the Saved Questions virtual DB just like any other database.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -20766,20 +21753,11 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/rescan_values" : {
- "post" : {
- "summary" : "POST /api/database/{id}/rescan_values",
- "description" : "Trigger a manual scan of the field values for this `Database`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "/api/database/{virtual-db}/schema/{schema}" : {
+ "get" : {
+ "summary" : "GET /api/database/{virtual-db}/schema/{schema}",
+ "description" : "Returns a list of Tables for the saved questions virtual database.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -20794,66 +21772,74 @@
"tags" : [ "/api/database" ]
}
},
- "/api/database/{id}/schema/" : {
+ "/api/database/{virtual-db}/schemas" : {
"get" : {
- "summary" : "GET /api/database/{id}/schema/",
- "description" : "Return a list of Tables for a Database whose `schema` is `nil` or an empty string.\n\n Optional filters:\n - `can-query=true` - filter to only tables the user can query\n - `can-write-metadata=true` - filter to only tables the user can edit metadata for",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "summary" : "GET /api/database/{virtual-db}/schemas",
+ "description" : "Returns a list of all the schemas found for the saved questions virtual database.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "include_hidden",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_editable_data_model",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "can-query",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ },
+ "tags" : [ "/api/database" ]
+ }
+ },
+ "/api/dataset/" : {
+ "post" : {
+ "summary" : "POST /api/dataset/",
+ "description" : "Execute a query and retrieve the results in the usual format. The query will not use the cache.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "can-write-metadata",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "oneOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ }
}
- } ],
+ },
+ "tags" : [ "/api/dataset" ]
+ }
+ },
+ "/api/dataset/native" : {
+ "post" : {
+ "summary" : "POST /api/dataset/native",
+ "description" : "Fetch a native version of an MBQL query.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -20865,75 +21851,90 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "pretty" : {
+ "default" : true,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "database", "pretty" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{id}/schema/{schema}" : {
- "get" : {
- "summary" : "GET /api/database/{id}/schema/{schema}",
- "description" : "Returns a list of Tables for the given Database `id` and `schema`.\n\n Optional filters:\n - `can-query=true` - filter to only tables the user can query\n - `can-write-metadata=true` - filter to only tables the user can edit metadata for",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "/api/dataset/parameter/remapping" : {
+ "post" : {
+ "summary" : "POST /api/dataset/parameter/remapping",
+ "description" : "Return the remapped parameter values for cards or dashboards that are being edited.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "schema",
- "required" : true,
- "schema" : {
- "type" : "string",
- "minLength" : 1
- }
- }, {
- "in" : "query",
- "name" : "include_hidden",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_editable_data_model",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "can-query",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "field_ids" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ },
+ "value" : { }
+ },
+ "required" : [ "parameter", "value" ]
+ }
+ }
}
- }, {
- "in" : "query",
- "name" : "can-write-metadata",
- "required" : false,
+ },
+ "tags" : [ "/api/dataset" ]
+ }
+ },
+ "/api/dataset/parameter/search/{query}" : {
+ "post" : {
+ "summary" : "POST /api/dataset/parameter/search/{query}",
+ "description" : "Return parameter values for cards or dashboards that are being edited. Expects a query string at `?query=foo`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "query",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "type" : "string",
+ "minLength" : 1
}
} ],
"responses" : {
@@ -20947,82 +21948,42 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "field_ids" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ }
+ },
+ "required" : [ "parameter" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{id}/schemas" : {
- "get" : {
- "summary" : "GET /api/database/{id}/schemas",
- "description" : "Returns a list of all the schemas with tables found for the database `id`. Excludes schemas with no tables.\n\n Optional filters:\n - `can-query=true` - filter to only schemas containing tables the user can query\n - `can-write-metadata=true` - filter to only schemas containing tables the user can edit metadata for",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "include_editable_data_model",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_hidden",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "can-query",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "can-write-metadata",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- } ],
+ "/api/dataset/parameter/values" : {
+ "post" : {
+ "summary" : "POST /api/dataset/parameter/values",
+ "description" : "Return parameter values for cards or dashboards that are being edited.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "array",
- "items" : {
- "type" : "string"
- }
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -21031,36 +21992,46 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "field_ids" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "parameter" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ }
+ },
+ "required" : [ "parameter" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{id}/settings-available" : {
- "get" : {
- "summary" : "GET /api/database/{id}/settings-available",
- "description" : "Get all database-local settings and their availability for the given database.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "/api/dataset/pivot" : {
+ "post" : {
+ "summary" : "POST /api/dataset/pivot",
+ "description" : "Generate a pivoted dataset for an ad-hoc query",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "settings" : {
- "$ref" : "#/components/schemas/metabase.warehouses-rest.api.available-settings"
- }
- },
- "required" : [ "settings" ]
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
}
}
}
@@ -21072,23 +22043,31 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "database" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{id}/sync_schema" : {
+ "/api/dataset/query_metadata" : {
"post" : {
- "summary" : "POST /api/database/{id}/sync_schema",
- "description" : "Trigger a manual update of the schema metadata for this `Database`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "summary" : "POST /api/dataset/query_metadata",
+ "description" : "Get all of the required query metadata for an ad-hoc query.\n\n You can pass `{:settings {:include-sensitive-fields true}}` in the query to include fields with\n visibility_type :sensitive in the response.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21100,26 +22079,60 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "settings" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "include_sensitive_fields" : {
+ "type" : "boolean"
+ }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "database" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{id}/syncable_schemas" : {
- "get" : {
- "summary" : "GET /api/database/{id}/syncable_schemas",
- "description" : "Returns a list of all syncable schemas found for the database `id`.",
+ "/api/dataset/{export-format}" : {
+ "post" : {
+ "summary" : "POST /api/dataset/{export-format}",
+ "description" : "Execute a query and download the result data as a file in the specified format.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "export-format",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -21128,41 +22141,42 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
- }
- },
- "/api/database/{id}/usage_info" : {
- "get" : {
- "summary" : "GET /api/database/{id}/usage_info",
- "description" : "Get usage info for a database.\n Returns a map with keys are models and values are the number of entities that use this database.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "format_rows" : {
+ "default" : false,
+ "type" : "boolean"
+ },
+ "pivot_results" : {
+ "default" : false,
+ "type" : "boolean"
+ },
+ "query" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "visualization_settings" : {
+ "default" : { },
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "required" : [ "query", "visualization_settings", "format_rows", "pivot_results" ]
+ }
+ }
}
},
- "tags" : [ "/api/database" ]
+ "tags" : [ "/api/dataset" ]
}
},
- "/api/database/{virtual-db}/datasets" : {
+ "/api/document/" : {
"get" : {
- "summary" : "GET /api/database/{virtual-db}/datasets",
- "description" : "Returns a list of all the datasets found for the saved questions virtual database.",
+ "summary" : "GET /api/document/",
+ "description" : "Gets existing `Documents`.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -21175,13 +22189,11 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
- }
- },
- "/api/database/{virtual-db}/datasets/{schema}" : {
- "get" : {
- "summary" : "GET /api/database/{virtual-db}/datasets/{schema}",
- "description" : "Returns a list of Tables for the datasets virtual database.",
+ "tags" : [ "/api/document" ]
+ },
+ "post" : {
+ "summary" : "POST /api/document/",
+ "description" : "Create a new `Document`.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -21194,17 +22206,171 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "cards" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "object",
+ "properties" : {
+ "visualization_settings" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "entity_id" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dataset_query" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "document" : { },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1,
+ "maxLength" : 254
+ }
+ },
+ "required" : [ "name", "document" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/document" ]
}
},
- "/api/database/{virtual-db}/metadata" : {
+ "/api/document/public" : {
"get" : {
- "summary" : "GET /api/database/{virtual-db}/metadata",
- "description" : "Endpoint that provides metadata for the Saved Questions 'virtual' database. Used for fooling the frontend\n and allowing it to treat the Saved Questions virtual DB just like any other database.",
+ "summary" : "GET /api/document/public",
+ "description" : "List all Documents that have public links.\n\n Returns a sequence of Documents that have been publicly shared. Each Document includes its `:id`, `:name`,\n and `:public_uuid`. Documents are only actually accessible via the public endpoint if public sharing is\n currently enabled. Archived Documents are excluded from the results.\n\n This endpoint is used to populate the public links listing in the Admin settings UI.\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "public_uuid" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ }
+ },
+ "required" : [ "name", "id", "public_uuid" ]
+ }
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -21213,33 +22379,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
+ "tags" : [ "/api/document" ]
}
},
- "/api/database/{virtual-db}/schema/{schema}" : {
+ "/api/document/{document-id}" : {
"get" : {
- "summary" : "GET /api/database/{virtual-db}/schema/{schema}",
- "description" : "Returns a list of Tables for the saved questions virtual database.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
+ "summary" : "GET /api/document/{document-id}",
+ "description" : "Returns an existing Document by ID.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "document-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
},
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/database" ]
- }
- },
- "/api/database/{virtual-db}/schemas" : {
- "get" : {
- "summary" : "GET /api/database/{virtual-db}/schemas",
- "description" : "Returns a list of all the schemas found for the saved questions virtual database.",
- "parameters" : [ ],
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21251,24 +22407,24 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/database" ]
- }
- },
- "/api/dataset/" : {
- "post" : {
- "summary" : "POST /api/dataset/",
- "description" : "Execute a query and retrieve the results in the usual format. The query will not use the cache.",
- "parameters" : [ ],
+ "tags" : [ "/api/document" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/document/{document-id}",
+ "description" : "Updates an existing `Document`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "document-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -21283,26 +22439,149 @@
"schema" : {
"type" : "object",
"properties" : {
- "database" : {
+ "archived" : {
"oneOf" : [ {
- "type" : "integer"
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cards" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "object",
+ "properties" : {
+ "visualization_settings" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "entity_id" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dataset_query" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "parameters" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
+ },
+ "document" : { },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1,
+ "maxLength" : 254
}
}
}
}
}
},
- "tags" : [ "/api/dataset" ]
- }
- },
- "/api/dataset/native" : {
- "post" : {
- "summary" : "POST /api/dataset/native",
- "description" : "Fetch a native version of an MBQL query.",
- "parameters" : [ ],
+ "tags" : [ "/api/document" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/document/{document-id}",
+ "description" : "Permanently deletes an archived Document.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "document-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21314,39 +22593,39 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "database" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "pretty" : {
- "default" : true,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "database", "pretty" ]
- }
- }
+ "tags" : [ "/api/document" ]
+ }
+ },
+ "/api/document/{document-id}/card/{card-id}/query/{export-format}" : {
+ "post" : {
+ "summary" : "POST /api/document/{document-id}/card/{card-id}/query/{export-format}",
+ "description" : "Download query results for a Card embedded in a Document.\n\n Returns query results in the requested format. The user must have read access to the document\n to download results. If the card's query fails, standard query error responses are returned.\n\n Route parameters:\n - document-id: ID of the document containing the card\n - card-id: ID of the card to download results from\n - export-format: Output format (csv, xlsx, json)\n\n Body parameters (snake_case):\n - parameters: Optional query parameters (array of maps or JSON string)\n - format_rows: Whether to apply formatting to results (boolean, default false)\n - pivot_results: Whether to pivot results (boolean, default false)",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "document-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "card-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "path",
+ "name" : "export-format",
+ "required" : true,
+ "schema" : {
+ "type" : "string"
}
- },
- "tags" : [ "/api/dataset" ]
- }
- },
- "/api/dataset/parameter/remapping" : {
- "post" : {
- "summary" : "POST /api/dataset/parameter/remapping",
- "description" : "Return the remapped parameter values for cards or dashboards that are being edited.",
- "parameters" : [ ],
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21364,45 +22643,72 @@
"schema" : {
"type" : "object",
"properties" : {
- "field_ids" : {
+ "format_rows" : {
+ "default" : false,
+ "type" : "boolean"
+ },
+ "parameters" : {
"oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }
+ "anyOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ }, {
+ "description" : "value must be a valid JSON string.",
+ "type" : "string"
+ } ]
}, {
"type" : "null"
} ]
},
- "parameter" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
- },
- "value" : { }
+ "pivot_results" : {
+ "default" : false,
+ "type" : "boolean"
+ }
},
- "required" : [ "parameter", "value" ]
+ "required" : [ "format_rows", "pivot_results" ]
}
}
}
},
- "tags" : [ "/api/dataset" ]
+ "tags" : [ "/api/document" ]
}
},
- "/api/dataset/parameter/search/{query}" : {
+ "/api/document/{document-id}/public-link" : {
"post" : {
- "summary" : "POST /api/dataset/parameter/search/{query}",
- "description" : "Return parameter values for cards or dashboards that are being edited. Expects a query string at `?query=foo`.",
+ "summary" : "POST /api/document/{document-id}/public-link",
+ "description" : "Generate a publicly-accessible UUID for a Document.\n\n Creates a public link that allows viewing the Document without authentication. If the Document already has\n a public UUID, returns the existing one rather than generating a new one. This enables sharing the Document\n via `GET /api/ee/public/document/:uuid`.\n\n Returns a map containing `:uuid` (the public UUID string).\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.",
"parameters" : [ {
"in" : "path",
- "name" : "query",
+ "name" : "document-id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "uuid" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ }
+ },
+ "required" : [ "uuid" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -21411,39 +22717,21 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "field_ids" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }
- }, {
- "type" : "null"
- } ]
- },
- "parameter" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
- }
- },
- "required" : [ "parameter" ]
- }
- }
- }
- },
- "tags" : [ "/api/dataset" ]
- }
- },
- "/api/dataset/parameter/values" : {
- "post" : {
- "summary" : "POST /api/dataset/parameter/values",
- "description" : "Return parameter values for cards or dashboards that are being edited.",
- "parameters" : [ ],
+ "tags" : [ "/api/document" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/document/{document-id}/public-link",
+ "description" : "Remove the public link for a Document.\n\n Deletes the public UUID from the Document, making it no longer accessible via the public sharing endpoint.\n This revokes public access to the Document - the existing public link will no longer work.\n\n Returns a 204 No Content response on success.\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.\n Throws a 404 if the Document doesn't exist, is archived, or doesn't have a public link.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "document-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21455,49 +22743,17 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "field_ids" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.field"
- }
- }, {
- "type" : "null"
- } ]
- },
- "parameter" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
- }
- },
- "required" : [ "parameter" ]
- }
- }
- }
- },
- "tags" : [ "/api/dataset" ]
+ "tags" : [ "/api/document" ]
}
},
- "/api/dataset/pivot" : {
+ "/api/ee/action-v2/execute" : {
"post" : {
- "summary" : "POST /api/dataset/pivot",
- "description" : "Generate a pivoted dataset for an ad-hoc query",
+ "summary" : "POST /api/ee/action-v2/execute",
+ "description" : "Execute an action with a single input.\n\n Takes:\n - `action` - an identifier or an expression for what we want to execute.\n - `scope` - where the action is being invoked from.\n - `input` - a single map. currently these are typically a database table row pk, or query result.\n - `params` (optional) - a map of values for the parameters taken by the action's mapping.\n\n The `input` and `params` are used by the relevant mapping to calculate a map argument to the underlying action fn.\n If there is no mapping, `params` are simply used as overrides for `input`.\n\n Returns the outputs from the performed action.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -21512,24 +22768,33 @@
"schema" : {
"type" : "object",
"properties" : {
- "database" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "action" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.action-v2.api.api-action-id-or-expression"
+ },
+ "input" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "params" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "scope" : {
+ "$ref" : "#/components/schemas/metabase.actions.types..scope.raw"
}
},
- "required" : [ "database" ]
+ "required" : [ "action", "scope" ]
}
}
}
},
- "tags" : [ "/api/dataset" ]
+ "tags" : [ "/api/ee/action-v2" ]
}
},
- "/api/dataset/query_metadata" : {
+ "/api/ee/action-v2/execute-bulk" : {
"post" : {
- "summary" : "POST /api/dataset/query_metadata",
- "description" : "Get all of the required query metadata for an ad-hoc query.\n\n You can pass `{:settings {:include-sensitive-fields true}}` in the query to include fields with\n visibility_type :sensitive in the response.",
+ "summary" : "POST /api/ee/action-v2/execute-bulk",
+ "description" : "Execute an action with multiple inputs.\n\n This is typically more efficient than calling execute with each input individually, for example by performing batch\n SQL operations.\n\n Takes:\n - `action` - an identifier or an expression for what we want to execute.\n - `scope` - where the action is being invoked from.\n - `inputs` - a list of maps. currently these are typically a database table row pk, or query result.\n - `params` (optional) - a map of values for the parameters taken by the action's mapping.\n\n The `inputs` and `params` are used by the relevant mapping to calculate a list of args for the underlying action fn.\n If there is no mapping, `params` are simply used as overrides for each map within `inputs`.\n\n Returns the outputs from the performed action.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -21548,54 +22813,41 @@
"schema" : {
"type" : "object",
"properties" : {
- "database" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "action" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.action-v2.api.api-action-id-or-expression"
},
- "settings" : {
- "oneOf" : [ {
+ "inputs" : {
+ "type" : "array",
+ "items" : {
"type" : "object",
- "properties" : {
- "include_sensitive_fields" : {
- "type" : "boolean"
- }
- }
- }, {
- "type" : "null"
- } ]
+ "properties" : { }
+ },
+ "minItems" : 1
+ },
+ "params" : {
+ "type" : "object",
+ "additionalProperties" : { }
+ },
+ "scope" : {
+ "$ref" : "#/components/schemas/metabase.actions.types..scope.raw"
}
},
- "required" : [ "database" ]
+ "required" : [ "action", "scope", "inputs" ]
}
}
}
},
- "tags" : [ "/api/dataset" ]
+ "tags" : [ "/api/ee/action-v2" ]
}
},
- "/api/dataset/{export-format}" : {
+ "/api/ee/action-v2/execute-form" : {
"post" : {
- "summary" : "POST /api/dataset/{export-format}",
- "description" : "Execute a query and download the result data as a file in the specified format.",
- "parameters" : [ {
- "in" : "path",
- "name" : "export-format",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.export-format"
- }
- } ],
+ "summary" : "POST /api/ee/action-v2/execute-form",
+ "description" : "Temporary endpoint for describing an actions parameters\n such that they can be presented correctly in a modal ahead of execution.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.query-result"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -21604,42 +22856,13 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "format_rows" : {
- "default" : false,
- "type" : "boolean"
- },
- "pivot_results" : {
- "default" : false,
- "type" : "boolean"
- },
- "query" : {
- "type" : "object",
- "properties" : { }
- },
- "visualization_settings" : {
- "default" : { },
- "type" : "object",
- "properties" : { }
- }
- },
- "required" : [ "query", "visualization_settings", "format_rows", "pivot_results" ]
- }
- }
- }
- },
- "tags" : [ "/api/dataset" ]
+ "tags" : [ "/api/ee/action-v2" ]
}
},
- "/api/document/" : {
+ "/api/ee/advanced-permissions/application/graph" : {
"get" : {
- "summary" : "GET /api/document/",
- "description" : "Gets existing `Documents`.",
+ "summary" : "GET /api/ee/advanced-permissions/application/graph",
+ "description" : "Fetch a graph of Application Permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -21652,12 +22875,36 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/advanced-permissions/application" ]
},
- "post" : {
- "summary" : "POST /api/document/",
- "description" : "Create a new `Document`.",
- "parameters" : [ ],
+ "put" : {
+ "summary" : "PUT /api/ee/advanced-permissions/application/graph",
+ "description" : "Do a batch update of Application Permissions by passing a modified graph.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "skip-graph",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "force",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21674,166 +22921,48 @@
"application/json" : {
"schema" : {
"type" : "object",
- "properties" : {
- "cards" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "object",
- "properties" : {
- "visualization_settings" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "entity_id" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "dataset_query" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "result_metadata" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "type" : "null"
- } ]
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
- }
- }, {
- "type" : "null"
- } ]
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "document" : { },
- "name" : {
- "type" : "string",
- "minLength" : 1,
- "maxLength" : 254
- }
- },
- "required" : [ "name", "document" ]
+ "properties" : { }
}
}
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/advanced-permissions/application" ]
}
},
- "/api/document/public" : {
+ "/api/ee/advanced-permissions/impersonation/" : {
"get" : {
- "summary" : "GET /api/document/public",
- "description" : "List all Documents that have public links.\n\n Returns a sequence of Documents that have been publicly shared. Each Document includes its `:id`, `:name`,\n and `:public_uuid`. Documents are only actually accessible via the public endpoint if public sharing is\n currently enabled. Archived Documents are excluded from the results.\n\n This endpoint is used to populate the public links listing in the Admin settings UI.\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "name" : {
- "type" : "string"
- },
- "public_uuid" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- }
- },
- "required" : [ "name", "id", "public_uuid" ]
- }
- }
- }
- }
+ "summary" : "GET /api/ee/advanced-permissions/impersonation/",
+ "description" : "Fetch a list of all Impersonation policies currently in effect, or a single policy if both `group_id` and `db_id`\n are provided.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "group_id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "db_id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -21842,16 +22971,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/advanced-permissions/impersonation" ]
}
},
- "/api/document/{document-id}" : {
- "get" : {
- "summary" : "GET /api/document/{document-id}",
- "description" : "Returns an existing Document by ID.",
+ "/api/ee/advanced-permissions/impersonation/{id}" : {
+ "delete" : {
+ "summary" : "DELETE /api/ee/advanced-permissions/impersonation/{id}",
+ "description" : "Delete a Connection Impersonation entry.",
"parameters" : [ {
"in" : "path",
- "name" : "document-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -21870,21 +22999,14 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
- },
- "put" : {
- "summary" : "PUT /api/document/{document-id}",
- "description" : "Updates an existing `Document`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "document-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "tags" : [ "/api/ee/advanced-permissions/impersonation" ]
+ }
+ },
+ "/api/ee/ai-entity-analysis/analyze-chart" : {
+ "post" : {
+ "summary" : "POST /api/ee/ai-entity-analysis/analyze-chart",
+ "description" : "Analyze a chart image using an AI vision model. This function sends the image data to a separate external AI service\n for analysis.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -21902,142 +23024,199 @@
"schema" : {
"type" : "object",
"properties" : {
- "archived" : {
+ "description" : {
"oneOf" : [ {
- "type" : "boolean"
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "cards" : {
+ "image_base64" : {
+ "type" : "string"
+ },
+ "name" : {
"oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "timeline_events" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
"type" : "object",
"properties" : {
- "visualization_settings" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "entity_id" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "dataset_query" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "parameter_mappings" : {
+ "description" : {
"oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
+ "type" : "string"
}, {
"type" : "null"
} ]
},
"name" : {
- "type" : "string",
- "minLength" : 1
- },
- "result_metadata" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "type" : "null"
- } ]
+ "type" : "string"
},
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "timestamp" : {
+ "type" : "string"
}
},
- "required" : [ "name", "dataset_query", "display", "visualization_settings" ]
+ "required" : [ "name", "timestamp" ]
}
}, {
"type" : "null"
} ]
+ }
+ },
+ "required" : [ "image_base64" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/ai-entity-analysis" ]
+ }
+ },
+ "/api/ee/ai-sql-fixer/fix" : {
+ "post" : {
+ "summary" : "POST /api/ee/ai-sql-fixer/fix",
+ "description" : "Suggest fixes for a SQL query.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "error_message" : {
+ "type" : "string"
},
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "query" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "database" ]
+ }
+ },
+ "required" : [ "query", "error_message" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/ai-sql-fixer" ]
+ }
+ },
+ "/api/ee/ai-sql-generation/generate" : {
+ "post" : {
+ "summary" : "POST /api/ee/ai-sql-generation/generate",
+ "description" : "Generate a SQL query.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "database_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
},
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "prompt" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "prompt", "database_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/ai-sql-generation" ]
+ }
+ },
+ "/api/ee/audit-app/analytics-dev/export" : {
+ "post" : {
+ "summary" : "POST /api/ee/audit-app/analytics-dev/export",
+ "description" : "Export analytics content as a .tar.gz file for local development.\n\n Only available when MB_ANALYTICS_DEV_MODE=true. Returns a tarball containing\n the analytics YAMLs in canonical format, ready to commit to source control.\n\n Requires superuser permissions.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "body" : { }
},
- "document" : { },
- "name" : {
- "type" : "string",
- "minLength" : 1,
- "maxLength" : 254
- }
+ "required" : [ "body" ]
}
}
}
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
- },
+ "tags" : [ "/api/ee/audit-app/analytics-dev" ]
+ }
+ },
+ "/api/ee/audit-app/user/audit-info" : {
+ "get" : {
+ "summary" : "GET /api/ee/audit-app/user/audit-info",
+ "description" : "Gets audit info for the current user if he has permissions to access the audit collection.\n Otherwise return an empty map.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/audit-app/user" ]
+ }
+ },
+ "/api/ee/audit-app/user/{id}/subscriptions" : {
"delete" : {
- "summary" : "DELETE /api/document/{document-id}",
- "description" : "Permanently deletes an archived Document.",
+ "summary" : "DELETE /api/ee/audit-app/user/{id}/subscriptions",
+ "description" : "Delete all Alert and DashboardSubscription subscriptions for a User (i.e., so they will no longer receive them).\n Archive all Alerts and DashboardSubscriptions created by the User. Only allowed for admins or for the current user.",
"parameters" : [ {
"in" : "path",
- "name" : "document-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -22056,39 +23235,14 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/audit-app/user" ]
}
},
- "/api/document/{document-id}/card/{card-id}/query/{export-format}" : {
+ "/api/ee/autodescribe/card/summarize" : {
"post" : {
- "summary" : "POST /api/document/{document-id}/card/{card-id}/query/{export-format}",
- "description" : "Download query results for a Card embedded in a Document.\n\n Returns query results in the requested format. The user must have read access to the document\n to download results. If the card's query fails, standard query error responses are returned.\n\n Route parameters:\n - document-id: ID of the document containing the card\n - card-id: ID of the card to download results from\n - export-format: Output format (csv, xlsx, json)\n\n Body parameters (snake_case):\n - parameters: Optional query parameters (array of maps or JSON string)\n - format_rows: Whether to apply formatting to results (boolean, default false)\n - pivot_results: Whether to pivot results (boolean, default false)",
- "parameters" : [ {
- "in" : "path",
- "name" : "document-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "card-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "path",
- "name" : "export-format",
- "required" : true,
- "schema" : {
- "type" : "string"
- }
- } ],
+ "summary" : "POST /api/ee/autodescribe/card/summarize",
+ "description" : "Summarize a question.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22106,47 +23260,105 @@
"schema" : {
"type" : "object",
"properties" : {
- "format_rows" : {
- "default" : false,
- "type" : "boolean"
+ "visualization_settings" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "dataset" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "dataset_query" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "parameter_mappings" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_position" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "result_metadata" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cache_ttl" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
},
"parameters" : {
"oneOf" : [ {
- "anyOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- }, {
- "description" : "value must be a valid JSON string.",
- "type" : "string"
- } ]
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ }
}, {
"type" : "null"
} ]
},
- "pivot_results" : {
- "default" : false,
- "type" : "boolean"
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "format_rows", "pivot_results" ]
+ "required" : [ "dataset_query", "display", "visualization_settings" ]
}
}
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/autodescribe" ]
}
},
- "/api/document/{document-id}/public-link" : {
+ "/api/ee/autodescribe/dashboard/summarize/{id}" : {
"post" : {
- "summary" : "POST /api/document/{document-id}/public-link",
- "description" : "Generate a publicly-accessible UUID for a Document.\n\n Creates a public link that allows viewing the Document without authentication. If the Document already has\n a public UUID, returns the existing one rather than generating a new one. This enables sharing the Document\n via `GET /api/ee/public/document/:uuid`.\n\n Returns a map containing `:uuid` (the public UUID string).\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.",
+ "summary" : "POST /api/ee/autodescribe/dashboard/summarize/{id}",
+ "description" : "Provide a summary of a dashboard.",
"parameters" : [ {
"in" : "path",
- "name" : "document-id",
+ "name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -22156,22 +23368,7 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "uuid" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- }
- },
- "required" : [ "uuid" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -22180,21 +23377,52 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
- },
- "delete" : {
- "summary" : "DELETE /api/document/{document-id}/public-link",
- "description" : "Remove the public link for a Document.\n\n Deletes the public UUID from the Document, making it no longer accessible via the public sharing endpoint.\n This revokes public access to the Document - the existing public link will no longer work.\n\n Returns a 204 No Content response on success.\n\n Requires superuser permissions. Public sharing must be enabled via the `enable-public-sharing` setting.\n Throws a 404 if the Document doesn't exist, is archived, or doesn't have a public link.",
- "parameters" : [ {
- "in" : "path",
- "name" : "document-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "tags" : [ "/api/ee/autodescribe" ]
+ }
+ },
+ "/api/ee/billing/" : {
+ "get" : {
+ "summary" : "GET /api/ee/billing/",
+ "description" : "Get billing information. This acts as a proxy between `metabase-billing-info-url` and the client,\n using the embedding token and signed in user's email to fetch the billing information.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/billing" ]
+ }
+ },
+ "/api/ee/cloud-add-ons/addons" : {
+ "get" : {
+ "summary" : "GET /api/ee/cloud-add-ons/addons",
+ "description" : "Get addons information from the Metabase Store API.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
},
- "description" : "value must be an integer greater than zero."
- } ],
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/cloud-add-ons" ]
+ }
+ },
+ "/api/ee/cloud-add-ons/plans" : {
+ "get" : {
+ "summary" : "GET /api/ee/cloud-add-ons/plans",
+ "description" : "Get plans information from the Metabase Store API.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22206,14 +23434,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/document" ]
+ "tags" : [ "/api/ee/cloud-add-ons" ]
}
},
- "/api/ee/action-v2/execute" : {
+ "/api/ee/cloud-add-ons/{product-type}" : {
"post" : {
- "summary" : "POST /api/ee/action-v2/execute",
- "description" : "Execute an action with a single input.\n\n Takes:\n - `action` - an identifier or an expression for what we want to execute.\n - `scope` - where the action is being invoked from.\n - `input` - a single map. currently these are typically a database table row pk, or query result.\n - `params` (optional) - a map of values for the parameters taken by the action's mapping.\n\n The `input` and `params` are used by the relevant mapping to calculate a map argument to the underlying action fn.\n If there is no mapping, `params` are simply used as overrides for `input`.\n\n Returns the outputs from the performed action.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/cloud-add-ons/{product-type}",
+ "description" : "Purchase an add-on.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "product-type",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "metabase-ai", "metabase-ai-tiered", "python-execution", "transforms" ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22231,34 +23467,41 @@
"schema" : {
"type" : "object",
"properties" : {
- "action" : {
- "$ref" : "#/components/schemas/metabase-enterprise.action-v2.api.api-action-id-or-expression"
- },
- "input" : {
- "type" : "object",
- "properties" : { }
- },
- "params" : {
- "type" : "object",
- "properties" : { }
+ "quantity" : {
+ "oneOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
},
- "scope" : {
- "$ref" : "#/components/schemas/metabase.actions.types..scope.raw"
+ "terms_of_service" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "required" : [ "action", "scope" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/action-v2" ]
+ "tags" : [ "/api/ee/cloud-add-ons" ]
}
},
- "/api/ee/action-v2/execute-bulk" : {
+ "/api/ee/cloud-proxy/{operation-id}" : {
"post" : {
- "summary" : "POST /api/ee/action-v2/execute-bulk",
- "description" : "Execute an action with multiple inputs.\n\n This is typically more efficient than calling execute with each input individually, for example by performing batch\n SQL operations.\n\n Takes:\n - `action` - an identifier or an expression for what we want to execute.\n - `scope` - where the action is being invoked from.\n - `inputs` - a list of maps. currently these are typically a database table row pk, or query result.\n - `params` (optional) - a map of values for the parameters taken by the action's mapping.\n\n The `inputs` and `params` are used by the relevant mapping to calculate a list of args for the underlying action fn.\n If there is no mapping, `params` are simply used as overrides for each map within `inputs`.\n\n Returns the outputs from the performed action.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/cloud-proxy/{operation-id}",
+ "description" : "Proxy a call to the Metabase Store API via harbormaster client.\n This endpoint is used only for hosted instances, and calls Harbormaster Store using a OpenAPI client.\n :operation-id is the operation-id of the Harbormaster Store endpoint.\n All parameters for the operation are taken in the POST body.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "operation-id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22274,39 +23517,23 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "action" : {
- "$ref" : "#/components/schemas/metabase-enterprise.action-v2.api.api-action-id-or-expression"
- },
- "inputs" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : { }
- },
- "minItems" : 1
- },
- "params" : {
- "type" : "object",
- "additionalProperties" : { }
- },
- "scope" : {
- "$ref" : "#/components/schemas/metabase.actions.types..scope.raw"
- }
- },
- "required" : [ "action", "scope", "inputs" ]
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : { }
+ }, {
+ "type" : "null"
+ } ]
}
}
}
},
- "tags" : [ "/api/ee/action-v2" ]
+ "tags" : [ "/api/ee/cloud-proxy" ]
}
},
- "/api/ee/action-v2/execute-form" : {
- "post" : {
- "summary" : "POST /api/ee/action-v2/execute-form",
- "description" : "Temporary endpoint for describing an actions parameters\n such that they can be presented correctly in a modal ahead of execution.",
+ "/api/ee/content-translation/csv" : {
+ "get" : {
+ "summary" : "GET /api/ee/content-translation/csv",
+ "description" : "Provides content translation dictionary in CSV",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -22319,17 +23546,54 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/action-v2" ]
+ "tags" : [ "/api/ee/content-translation" ]
}
},
- "/api/ee/advanced-permissions/application/graph" : {
+ "/api/ee/content-translation/dictionary" : {
"get" : {
- "summary" : "GET /api/ee/advanced-permissions/application/graph",
- "description" : "Fetch a graph of Application Permissions.",
- "parameters" : [ ],
+ "summary" : "GET /api/ee/content-translation/dictionary",
+ "description" : "Fetch the content translation dictionary for authenticated users (auth-based embedding flows).",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "locale",
+ "required" : true,
+ "schema" : {
+ "type" : "string"
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "locale" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "msgid" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "msgstr" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "locale", "msgid", "msgstr" ]
+ }
+ }
+ },
+ "required" : [ "data" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22338,34 +23602,20 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/advanced-permissions/application" ]
- },
- "put" : {
- "summary" : "PUT /api/ee/advanced-permissions/application/graph",
- "description" : "Do a batch update of Application Permissions by passing a modified graph.",
+ "tags" : [ "/api/ee/content-translation" ]
+ }
+ },
+ "/api/ee/content-translation/dictionary/{token}" : {
+ "get" : {
+ "summary" : "GET /api/ee/content-translation/dictionary/{token}",
+ "description" : "Fetch the content translation dictionary via a JSON Web Token signed with the `embedding-secret-key`.",
"parameters" : [ {
- "in" : "query",
- "name" : "skip-graph",
- "required" : true,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "force",
+ "in" : "path",
+ "name" : "token",
"required" : true,
"schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "type" : "string",
+ "minLength" : 1
}
} ],
"responses" : {
@@ -22379,50 +23629,14 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : { }
- }
- }
- }
- },
- "tags" : [ "/api/ee/advanced-permissions/application" ]
+ "tags" : [ "/api/ee/content-translation" ]
}
},
- "/api/ee/advanced-permissions/impersonation/" : {
- "get" : {
- "summary" : "GET /api/ee/advanced-permissions/impersonation/",
- "description" : "Fetch a list of all Impersonation policies currently in effect, or a single policy if both `group_id` and `db_id`\n are provided.",
- "parameters" : [ {
- "in" : "query",
- "name" : "group_id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "db_id",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- } ],
+ "/api/ee/content-translation/upload-dictionary" : {
+ "post" : {
+ "summary" : "POST /api/ee/content-translation/upload-dictionary",
+ "description" : "Upload a CSV of content translations",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22434,26 +23648,46 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/advanced-permissions/impersonation" ]
+ "requestBody" : {
+ "content" : {
+ "multipart/form-data" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "file" : {
+ "type" : "object",
+ "properties" : {
+ "filename" : {
+ "type" : "string"
+ },
+ "tempfile" : { }
+ },
+ "required" : [ "filename", "tempfile" ]
+ }
+ },
+ "required" : [ "file" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/content-translation" ]
}
},
- "/api/ee/advanced-permissions/impersonation/{id}" : {
- "delete" : {
- "summary" : "DELETE /api/ee/advanced-permissions/impersonation/{id}",
- "description" : "Delete a Connection Impersonation entry.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "/api/ee/data-studio/table/discard-values" : {
+ "post" : {
+ "summary" : "POST /api/ee/data-studio/table/discard-values",
+ "description" : "Batch version of /table/:id/discard_values. Takes an abstract table selection as /table/edit does.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22462,17 +23696,35 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/advanced-permissions/impersonation" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/data-studio/table" ]
}
},
- "/api/ee/ai-entity-analysis/analyze-chart" : {
+ "/api/ee/data-studio/table/edit" : {
"post" : {
- "summary" : "POST /api/ee/ai-entity-analysis/analyze-chart",
- "description" : "Analyze a chart image using an AI vision model. This function sends the image data to a separate external AI service\n for analysis.",
+ "summary" : "POST /api/ee/data-studio/table/edit",
+ "description" : "Bulk updating tables.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : { },
+ "additionalProperties" : false
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22487,66 +23739,94 @@
"schema" : {
"type" : "object",
"properties" : {
- "description" : {
+ "data_authority" : {
"oneOf" : [ {
- "type" : "string"
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-authorities"
}, {
"type" : "null"
} ]
},
- "image_base64" : {
- "type" : "string"
+ "data_layer" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-layers"
+ }, {
+ "type" : "null"
+ } ]
},
- "name" : {
+ "table_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "owner_email" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "timeline_events" : {
+ "owner_user_id" : {
"oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string"
- },
- "timestamp" : {
- "type" : "string"
- }
- },
- "required" : [ "name", "timestamp" ]
- }
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "data_source" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-sources"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "schema_ids" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string"
+ }
+ },
+ "entity_type" : {
+ "oneOf" : [ {
+ "type" : "string"
}, {
"type" : "null"
} ]
+ },
+ "database_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
}
},
- "required" : [ "image_base64" ]
+ "additionalProperties" : false
}
}
}
},
- "tags" : [ "/api/ee/ai-entity-analysis" ]
+ "tags" : [ "/api/ee/data-studio/table" ]
}
},
- "/api/ee/ai-sql-fixer/fix" : {
+ "/api/ee/data-studio/table/publish-tables" : {
"post" : {
- "summary" : "POST /api/ee/ai-sql-fixer/fix",
- "description" : "Suggest fixes for a SQL query.",
+ "summary" : "POST /api/ee/data-studio/table/publish-tables",
+ "description" : "Set collection for each of selected tables and all upstream dependencies recursively.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.publish-tables-response"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22559,39 +23839,99 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "error_message" : {
- "type" : "string"
- },
- "query" : {
- "type" : "object",
- "properties" : {
- "database" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "database" ]
- }
- },
- "required" : [ "query", "error_message" ]
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
}
}
}
},
- "tags" : [ "/api/ee/ai-sql-fixer" ]
+ "tags" : [ "/api/ee/data-studio/table" ]
}
},
- "/api/ee/ai-sql-generation/generate" : {
+ "/api/ee/data-studio/table/rescan-values" : {
"post" : {
- "summary" : "POST /api/ee/ai-sql-generation/generate",
- "description" : "Generate a SQL query.",
+ "summary" : "POST /api/ee/data-studio/table/rescan-values",
+ "description" : "Batch version of /table/:id/rescan_values. Takes an abstract table selection as /table/edit does.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/data-studio/table" ]
+ }
+ },
+ "/api/ee/data-studio/table/selection" : {
+ "post" : {
+ "summary" : "POST /api/ee/data-studio/table/selection",
+ "description" : "Gets information about selected tables",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.bulk-table-selection-info"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/data-studio/table" ]
+ }
+ },
+ "/api/ee/data-studio/table/sync-schema" : {
+ "post" : {
+ "summary" : "POST /api/ee/data-studio/table/sync-schema",
+ "description" : "Batch version of /table/:id/sync_schema. Takes an abstract table selection as /table/edit does.\n - Currently checks policy before returning (so you might receive a 4xx on e.g. AuthZ policy failure)\n - The sync itself is however, asynchronous. This call may return before all tables synced.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22604,30 +23944,18 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "database_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "prompt" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "prompt", "database_id" ]
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
}
}
}
},
- "tags" : [ "/api/ee/ai-sql-generation" ]
+ "tags" : [ "/api/ee/data-studio/table" ]
}
},
- "/api/ee/audit-app/analytics-dev/export" : {
+ "/api/ee/data-studio/table/unpublish-tables" : {
"post" : {
- "summary" : "POST /api/ee/audit-app/analytics-dev/export",
- "description" : "Export analytics content as a .tar.gz file for local development.\n\n Only available when MB_ANALYTICS_DEV_MODE=true. Returns a tarball containing\n the analytics YAMLs in canonical format, ready to commit to source control.\n\n Requires superuser permissions.",
+ "summary" : "POST /api/ee/data-studio/table/unpublish-tables",
+ "description" : "Unset collection for each of selected tables and all downstream dependents recursively.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -22635,11 +23963,7 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "body" : { }
- },
- "required" : [ "body" ]
+ "type" : "null"
}
}
}
@@ -22651,14 +23975,32 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/audit-app/analytics-dev" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/data-studio/table" ]
}
},
- "/api/ee/audit-app/user/audit-info" : {
- "get" : {
- "summary" : "GET /api/ee/audit-app/user/audit-info",
- "description" : "Gets audit info for the current user if he has permissions to access the audit collection.\n Otherwise return an empty map.",
- "parameters" : [ ],
+ "/api/ee/database-replication/connection/{database-id}" : {
+ "post" : {
+ "summary" : "POST /api/ee/database-replication/connection/{database-id}",
+ "description" : "Create a new PG replication connection for the specified database.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "database-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22670,16 +24012,38 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/audit-app/user" ]
- }
- },
- "/api/ee/audit-app/user/{id}/subscriptions" : {
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "replicationSchemaFilters" : {
+ "type" : "object",
+ "properties" : {
+ "schema-filters-patterns" : {
+ "type" : "string"
+ },
+ "schema-filters-type" : {
+ "type" : "string",
+ "enum" : [ "inclusion", "exclusion", "all" ]
+ }
+ },
+ "required" : [ "schema-filters-type", "schema-filters-patterns" ]
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/database-replication" ]
+ },
"delete" : {
- "summary" : "DELETE /api/ee/audit-app/user/{id}/subscriptions",
- "description" : "Delete all Alert and DashboardSubscription subscriptions for a User (i.e., so they will no longer receive them).\n Archive all Alerts and DashboardSubscriptions created by the User. Only allowed for admins or for the current user.",
+ "summary" : "DELETE /api/ee/database-replication/connection/{database-id}",
+ "description" : "Delete PG replication connection for the specified database.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "database-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -22698,14 +24062,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/audit-app/user" ]
+ "tags" : [ "/api/ee/database-replication" ]
}
},
- "/api/ee/autodescribe/card/summarize" : {
+ "/api/ee/database-replication/connection/{database-id}/preview" : {
"post" : {
- "summary" : "POST /api/ee/autodescribe/card/summarize",
- "description" : "Summarize a question.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/database-replication/connection/{database-id}/preview",
+ "description" : "Return info about pg-replication connection that is about to be created.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "database-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -22723,102 +24096,92 @@
"schema" : {
"type" : "object",
"properties" : {
- "visualization_settings" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "dataset" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "dataset_query" : {
- "description" : "Value must be a map.",
+ "replicationSchemaFilters" : {
"type" : "object",
- "properties" : { }
- },
- "parameter_mappings" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter-mapping"
- }
- }, {
- "type" : "null"
- } ]
- },
- "collection_position" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "result_metadata" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase.analyze.query-results.ResultsMetadata"
- }, {
- "type" : "null"
- } ]
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "cache_ttl" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "parameters" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase.parameters.schema.parameter"
+ "properties" : {
+ "schema-filters-patterns" : {
+ "type" : "string"
+ },
+ "schema-filters-type" : {
+ "type" : "string",
+ "enum" : [ "inclusion", "exclusion", "all" ]
}
- }, {
- "type" : "null"
- } ]
+ },
+ "required" : [ "schema-filters-type", "schema-filters-patterns" ]
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/database-replication" ]
+ }
+ },
+ "/api/ee/database-routing/destination-database" : {
+ "post" : {
+ "summary" : "POST /api/ee/database-routing/destination-database",
+ "description" : "Create new Destination Databases.\n\n Note that unlike the normal `POST /api/database` endpoint, does NOT check the details before adding the Database.\n\n This is OK, it's not an invariant that all database details are always valid, but it's something to note.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "check_connection_details",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "destinations" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "details" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "name", "details" ]
+ }
},
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "router_database_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "dataset_query", "display", "visualization_settings" ]
+ "required" : [ "router_database_id", "destinations" ]
}
}
}
},
- "tags" : [ "/api/ee/autodescribe" ]
+ "tags" : [ "/api/ee/database-routing" ]
}
},
- "/api/ee/autodescribe/dashboard/summarize/{id}" : {
- "post" : {
- "summary" : "POST /api/ee/autodescribe/dashboard/summarize/{id}",
- "description" : "Provide a summary of a dashboard.",
+ "/api/ee/database-routing/router-database/{id}" : {
+ "put" : {
+ "summary" : "PUT /api/ee/database-routing/router-database/{id}",
+ "description" : "Updates an existing Database with the `user_attribute` to route on. Will either:\n - turn an existing Database into a Router database\n - change the `user_attribute` used to route for an existing Router database, or\n - turn a Router database into a regular Database\n depending on the value of `user_attribute`",
"parameters" : [ {
"in" : "path",
"name" : "id",
@@ -22840,17 +24203,43 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/autodescribe" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "user_attribute" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/database-routing" ]
}
},
- "/api/ee/billing/" : {
- "get" : {
- "summary" : "GET /api/ee/billing/",
- "description" : "Get billing information. This acts as a proxy between `metabase-billing-info-url` and the client,\n using the embedding token and signed in user's email to fetch the billing information.",
+ "/api/ee/dependencies/check_card" : {
+ "post" : {
+ "summary" : "POST /api/ee/dependencies/check_card",
+ "description" : "Check a proposed edit to a card, and return the card IDs for those cards this edit will break.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22859,17 +24248,33 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/billing" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.card-body"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/cloud-add-ons/addons" : {
- "get" : {
- "summary" : "GET /api/ee/cloud-add-ons/addons",
- "description" : "Get addons information from the Metabase Store API.",
+ "/api/ee/dependencies/check_snippet" : {
+ "post" : {
+ "summary" : "POST /api/ee/dependencies/check_snippet",
+ "description" : "Check a proposed edit to a native snippet, and return the cards, etc. which will be broken.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22878,17 +24283,45 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/cloud-add-ons" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "content" : {
+ "type" : "string"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase.lib.schema.id.snippet"
+ },
+ "name" : {
+ "description" : "snippet names cannot include '}' or start with spaces"
+ }
+ },
+ "required" : [ "id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/cloud-add-ons/plans" : {
- "get" : {
- "summary" : "GET /api/ee/cloud-add-ons/plans",
- "description" : "Get plans information from the Metabase Store API.",
+ "/api/ee/dependencies/check_transform" : {
+ "post" : {
+ "summary" : "POST /api/ee/dependencies/check_transform",
+ "description" : "Check a proposed edit to a transform, and return the card, transform, etc. IDs for things that will break.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -22897,69 +24330,171 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/cloud-add-ons" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.transform-body"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/cloud-add-ons/{product-type}" : {
- "post" : {
- "summary" : "POST /api/ee/cloud-add-ons/{product-type}",
- "description" : "Purchase an add-on.",
+ "/api/ee/dependencies/graph" : {
+ "get" : {
+ "summary" : "GET /api/ee/dependencies/graph",
+ "description" : "This endpoint takes an :id and a supported entity :type, and returns a graph of all its upstream dependencies.\n The graph is represented by a list of :nodes and a list of :edges. Each node has an :id, :type, :data (which\n depends on the node type), and a map of :dependent_counts per entity type. Each edge is a :model/Dependency.\n\n Optional :archived parameter controls whether entities in archived collections are included:\n - false (default): Excludes entities in archived collections\n - true: Includes entities in archived collections",
"parameters" : [ {
- "in" : "path",
- "name" : "product-type",
- "required" : true,
+ "in" : "query",
+ "name" : "id",
+ "required" : false,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "type",
+ "required" : false,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ }, {
+ "in" : "query",
+ "name" : "archived",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.graph-response"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/dependencies" ]
+ }
+ },
+ "/api/ee/dependencies/graph/breaking" : {
+ "get" : {
+ "summary" : "GET /api/ee/dependencies/graph/breaking",
+ "description" : "Returns a list of entities that are breaking other entities (sources of errors).\n These are tables or cards that other entities depend on, where those dependents\n have validation errors traced back to this source entity.\n\n Accepts optional parameters for filtering:\n - `types`: List of source entity types - only `:card` or `:table` (default: both)\n - `card_types`: List of card types to include when filtering cards (e.g., `[:question :model :metric]`)\n - `query`: Search string to filter by name or location\n - `archived`: Controls whether archived entities are included\n - `include_personal_collections`: Controls whether items in personal collections are included (default: false)\n - `sort_column`: Sort column - `:name`, `:location`, `:dependents-errors`, or `:dependents-with-errors` (default: `:name`)\n - `sort_direction`: Sort direction - `:asc` or `:desc` (default: `:asc`)\n - `offset`: Default 0\n - `limit`: Default 50\n\n Returns a map with:\n - `data`: List of breaking source entities\n - `total`: Total count of matched items\n - `offset`: Applied offset\n - `limit`: Applied limit",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }, {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "card_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }, {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "query",
+ "required" : false,
+ "schema" : {
+ "type" : "string"
+ }
+ }, {
+ "in" : "query",
+ "name" : "archived",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_personal_collections",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
"schema" : {
"type" : "string",
- "enum" : [ "metabase-ai", "metabase-ai-tiered", "python-execution", "transforms" ]
+ "enum" : [ "dependents-with-errors", "dependents-errors", "name", "location" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "quantity" : {
- "oneOf" : [ {
- "type" : "integer"
- }, {
- "type" : "null"
- } ]
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
+ }
+ },
+ "limit" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "offset" : {
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "total" : {
+ "type" : "integer",
+ "minimum" : 0
+ }
},
- "terms_of_service" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
+ "required" : [ "data", "total", "offset", "limit" ]
}
}
}
- }
- },
- "tags" : [ "/api/ee/cloud-add-ons" ]
- }
- },
- "/api/ee/content-translation/csv" : {
- "get" : {
- "summary" : "GET /api/ee/content-translation/csv",
- "description" : "Provides content translation dictionary in CSV",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -22968,19 +24503,81 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/content-translation" ]
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/content-translation/dictionary" : {
+ "/api/ee/dependencies/graph/broken" : {
"get" : {
- "summary" : "GET /api/ee/content-translation/dictionary",
- "description" : "Fetch the content translation dictionary for authenticated users (auth-based embedding flows).",
+ "summary" : "GET /api/ee/dependencies/graph/broken",
+ "description" : "Returns the broken dependents for a specific source entity.\n These are entities that have validation errors traced back to the specified source.\n\n Required parameters:\n - `id`: The ID of the source entity\n - `type`: The type of the source entity (card, table)\n\n Optional parameters:\n - `dependent_types`: Dependency types to filter by. Can be single value or array.\n - `dependent_card_types`: Card types to filter by when dependent_types includes :card.\n - `include_personal_collections`: Include items in personal collections (default: false)\n - `sort_column`: Column to sort by - name, location, or view-count (default: name)\n - `sort_direction`: Sort direction - asc or desc (default: asc)",
"parameters" : [ {
"in" : "query",
- "name" : "locale",
+ "name" : "id",
"required" : true,
"schema" : {
- "type" : "string"
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "type",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ }, {
+ "in" : "query",
+ "name" : "dependent_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }, {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "dependent_card_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }, {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_personal_collections",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "name", "view-count", "location" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
}
} ],
"responses" : {
@@ -22989,30 +24586,10 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "data" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "locale" : {
- "type" : "string",
- "minLength" : 1
- },
- "msgid" : {
- "type" : "string",
- "minLength" : 1
- },
- "msgstr" : {
- "type" : "string"
- }
- },
- "required" : [ "locale", "msgid", "msgstr" ]
- }
- }
- },
- "required" : [ "data" ]
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-dependent-entity"
+ }
}
}
}
@@ -23023,26 +24600,118 @@
"5XX" : {
"description" : "Server error response"
}
- },
- "tags" : [ "/api/ee/content-translation" ]
- }
- },
- "/api/ee/content-translation/dictionary/{token}" : {
- "get" : {
- "summary" : "GET /api/ee/content-translation/dictionary/{token}",
- "description" : "Fetch the content translation dictionary via a JSON Web Token signed with the `embedding-secret-key`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "token",
- "required" : true,
+ },
+ "tags" : [ "/api/ee/dependencies" ]
+ }
+ },
+ "/api/ee/dependencies/graph/dependents" : {
+ "get" : {
+ "summary" : "GET /api/ee/dependencies/graph/dependents",
+ "description" : "Returns a list of dependents for the specified entity.\n\n Required parameters:\n - `id`: The ID of the entity\n - `type`: The type of the entity (card, table, dashboard, etc.)\n\n Optional parameters:\n - `dependent_types`: Dependency types to filter by. Can be single value or array.\n If not provided, returns all types. Example: ?dependent_types=card&dependent_types=dashboard\n - `dependent_card_types`: Card types to filter by when dependent_types includes :card.\n Ignored if dependent_types doesn't include :card. Example: ?dependent_card_types=question&dependent_card_types=model\n - `archived`: Include entities in archived collections (default: false)\n - `broken`: Return only broken entities (default: false)\n - `query`: Search string to filter results by name or location (case-insensitive)\n - `include_personal_collections`: Include items in personal collections (default: false)\n - `sort_column`: Column to sort by - name, location, or view-count (default: name)\n - `sort_direction`: Sort direction - asc or desc (default: asc)",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ }, {
+ "in" : "query",
+ "name" : "type",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ }, {
+ "in" : "query",
+ "name" : "dependent_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }, {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "dependent_card_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }, {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "archived",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "broken",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "query",
+ "required" : false,
+ "schema" : {
+ "type" : "string"
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_personal_collections",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
"schema" : {
"type" : "string",
- "minLength" : 1
+ "enum" : [ "name", "view-count", "location" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
+ }
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -23051,62 +24720,110 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/content-translation" ]
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/content-translation/upload-dictionary" : {
- "post" : {
- "summary" : "POST /api/ee/content-translation/upload-dictionary",
- "description" : "Upload a CSV of content translations",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "/api/ee/dependencies/graph/unreferenced" : {
+ "get" : {
+ "summary" : "GET /api/ee/dependencies/graph/unreferenced",
+ "description" : "Returns a list of all unreferenced items in the instance.\n An unreferenced item is one that is not a dependency of any other item.\n\n Accepts optional parameters for filtering:\n - `types`: List of entity types to include (e.g., [:card :transform :snippet :dashboard])\n - `card_types`: List of card types to include when filtering cards (e.g., [:question :model :metric])\n - `query`: Search string to filter by name or location\n - `archived`: Controls whether archived entities are included\n - `include_personal_collections`: Controls whether items in personal collections are included (default: false)\n - `sort_column`: Sort column - `:name`, `:location`, `:dependents-errors`, or `:dependents-with-errors` (default: `:name`)\n - `sort_direction`: Sort direction - `:asc` or `:desc` (default: `:asc`)\n - `offset`: Default 0\n - `limit`: Default 50\n\n Returns a map with:\n - `data`: List of unreferenced items, each with `:id`, `:type`, and `:data` fields\n - `total`: Total count of matched items\n - `offset`: Applied offset\n - `limit`: Applied limit",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }, {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
+ }
+ } ]
}
- },
- "requestBody" : {
- "content" : {
- "multipart/form-data" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "file" : {
- "type" : "object",
- "properties" : {
- "filename" : {
- "type" : "string"
- },
- "tempfile" : { }
- },
- "required" : [ "filename", "tempfile" ]
- }
- },
- "required" : [ "file" ]
+ }, {
+ "in" : "query",
+ "name" : "card_types",
+ "required" : false,
+ "schema" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
+ }, {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "question", "metric", "model" ]
}
- }
+ } ]
}
- },
- "tags" : [ "/api/ee/content-translation" ]
- }
- },
- "/api/ee/data-studio/table/discard-values" : {
- "post" : {
- "summary" : "POST /api/ee/data-studio/table/discard-values",
- "description" : "Batch version of /table/:id/discard_values. Takes an abstract table selection as /table/edit does.",
- "parameters" : [ ],
+ }, {
+ "in" : "query",
+ "name" : "query",
+ "required" : false,
+ "schema" : {
+ "type" : "string"
+ }
+ }, {
+ "in" : "query",
+ "name" : "archived",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "include_personal_collections",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "dependents-with-errors", "dependents-errors", "name", "location" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "desc", "asc" ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "type" : "null"
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
+ }
+ },
+ "limit" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "offset" : {
+ "type" : "integer",
+ "minimum" : 0
+ },
+ "total" : {
+ "type" : "integer",
+ "minimum" : 0
+ }
+ },
+ "required" : [ "data", "total", "offset", "limit" ]
}
}
}
@@ -23118,35 +24835,17 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
- }
- }
- }
- },
- "tags" : [ "/api/ee/data-studio/table" ]
+ "tags" : [ "/api/ee/dependencies" ]
}
},
- "/api/ee/data-studio/table/edit" : {
- "post" : {
- "summary" : "POST /api/ee/data-studio/table/edit",
- "description" : "Bulk updating tables.",
+ "/api/ee/email/override" : {
+ "put" : {
+ "summary" : "PUT /api/ee/email/override",
+ "description" : "Update multiple cloud email Settings. You must be a superuser or have `setting` permission to do this.\n Calling this automatically sets `cloud-smtp-enabled` to true if the settings are valid.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : { },
- "additionalProperties" : false
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -23161,94 +24860,55 @@
"schema" : {
"type" : "object",
"properties" : {
- "data_authority" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-authorities"
- }, {
- "type" : "null"
- } ]
- },
- "data_layer" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-layers"
+ "email-smtp-host-override" : {
+ "anyOf" : [ {
+ "type" : "string"
}, {
"type" : "null"
} ]
},
- "table_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "owner_email" : {
- "oneOf" : [ {
+ "email-smtp-password-override" : {
+ "anyOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "owner_user_id" : {
- "oneOf" : [ {
+ "email-smtp-port-override" : {
+ "anyOf" : [ {
"type" : "integer"
}, {
"type" : "null"
} ]
},
- "data_source" : {
- "oneOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.data-sources"
- }, {
- "type" : "null"
- } ]
- },
- "schema_ids" : {
- "type" : "array",
- "items" : {
- "type" : "string"
- }
- },
- "entity_type" : {
- "oneOf" : [ {
+ "email-smtp-security-override" : {
+ "anyOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "database_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
+ "email-smtp-username-override" : {
+ "anyOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "additionalProperties" : false
+ }
}
}
}
},
- "tags" : [ "/api/ee/data-studio/table" ]
- }
- },
- "/api/ee/data-studio/table/publish-tables" : {
- "post" : {
- "summary" : "POST /api/ee/data-studio/table/publish-tables",
- "description" : "Set collection for each of selected tables and all upstream dependencies recursively.",
+ "tags" : [ "/api/ee/email" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/email/override",
+ "description" : "Clear all cloud email related settings. You must be a superuser or have `setting` permission to do this.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.publish-tables-response"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -23257,22 +24917,32 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
- }
- }
+ "tags" : [ "/api/ee/email" ]
+ }
+ },
+ "/api/ee/embedding-hub/checklist" : {
+ "get" : {
+ "summary" : "GET /api/ee/embedding-hub/checklist",
+ "description" : "Get the embedding hub checklist status, indicating which setup steps have been completed.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/data-studio/table" ]
+ "tags" : [ "/api/ee/embedding-hub" ]
}
},
- "/api/ee/data-studio/table/rescan-values" : {
+ "/api/ee/gsheets/connection" : {
"post" : {
- "summary" : "POST /api/ee/data-studio/table/rescan-values",
- "description" : "Batch version of /table/:id/rescan_values. Takes an abstract table selection as /table/edit does.",
+ "summary" : "POST /api/ee/gsheets/connection",
+ "description" : "Hook up a new google drive folder or sheet that will be watched and have its content ETL'd into Metabase.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -23280,7 +24950,7 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "null"
+ "$ref" : "#/components/schemas/gsheets.response"
}
}
}
@@ -23296,18 +24966,23 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
+ "type" : "object",
+ "properties" : {
+ "url" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "url" ]
}
}
}
},
- "tags" : [ "/api/ee/data-studio/table" ]
- }
- },
- "/api/ee/data-studio/table/selection" : {
- "post" : {
- "summary" : "POST /api/ee/data-studio/table/selection",
- "description" : "Gets information about selected tables",
+ "tags" : [ "/api/ee/gsheets" ]
+ },
+ "get" : {
+ "summary" : "GET /api/ee/gsheets/connection",
+ "description" : "Check the status of a connection. This endpoint gets polled by FE to determine when to\n stop showing the setup widget.\n\n Returns the gsheets shape, with the attached datawarehouse db id at `:db_id`.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -23315,7 +24990,7 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.bulk-table-selection-info"
+ "$ref" : "#/components/schemas/gsheets.response"
}
}
}
@@ -23327,22 +25002,49 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
- }
- }
+ "tags" : [ "/api/ee/gsheets" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/gsheets/connection",
+ "description" : "Disconnect the google service account. There is only one (or zero) at the time of writing.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/data-studio/table" ]
+ "tags" : [ "/api/ee/gsheets" ]
}
},
- "/api/ee/data-studio/table/sync-schema" : {
+ "/api/ee/gsheets/connection/sync" : {
"post" : {
- "summary" : "POST /api/ee/data-studio/table/sync-schema",
- "description" : "Batch version of /table/:id/sync_schema. Takes an abstract table selection as /table/edit does.\n - Currently checks policy before returning (so you might receive a 4xx on e.g. AuthZ policy failure)\n - The sync itself is however, asynchronous. This call may return before all tables synced.",
+ "summary" : "POST /api/ee/gsheets/connection/sync",
+ "description" : "Force a sync of the connection now.\n\n Returns the gsheets shape, with the attached datawarehouse db id at `:db_id`.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/gsheets" ]
+ }
+ },
+ "/api/ee/gsheets/service-account" : {
+ "get" : {
+ "summary" : "GET /api/ee/gsheets/service-account",
+ "description" : "Checks to see if service-account is setup or not, delegates to HM only if we haven't set it from a metabase cluster\n before.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -23350,7 +25052,17 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "null"
+ "type" : "object",
+ "properties" : {
+ "email" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "email" ]
}
}
}
@@ -23362,22 +25074,30 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
- }
- }
- }
- },
- "tags" : [ "/api/ee/data-studio/table" ]
+ "tags" : [ "/api/ee/gsheets" ]
}
},
- "/api/ee/data-studio/table/unpublish-tables" : {
+ "/api/ee/library/" : {
"post" : {
- "summary" : "POST /api/ee/data-studio/table/unpublish-tables",
- "description" : "Unset collection for each of selected tables and all downstream dependents recursively.",
+ "summary" : "POST /api/ee/library/",
+ "description" : "Creates the Library if it doesn't exist. Returns the created collection.\n\n Requires data analyst or superuser permissions.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/library" ]
+ },
+ "get" : {
+ "summary" : "GET /api/ee/library/",
+ "description" : "Get the Library. If no library exists, it doesn't fail but returns an empty response",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -23385,7 +25105,17 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "null"
+ "anyOf" : [ {
+ "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItem"
+ }, {
+ "type" : "object",
+ "properties" : {
+ "data" : {
+ "type" : "null"
+ }
+ },
+ "required" : [ "data" ]
+ } ]
}
}
}
@@ -23397,35 +25127,87 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.data-studio.api.table.table-selectors"
- }
- }
+ "tags" : [ "/api/ee/library" ]
+ }
+ },
+ "/api/ee/library/tree" : {
+ "get" : {
+ "summary" : "GET /api/ee/library/tree",
+ "description" : "This matches /api/collection/tree but only returns the library collection.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/library" ]
+ }
+ },
+ "/api/ee/logs/query_execution/{yyyy-mm}" : {
+ "get" : {
+ "summary" : "GET /api/ee/logs/query_execution/{yyyy-mm}",
+ "description" : "Fetch rows for the month specified by `:yyyy-mm` from the query_execution logs table.\n Must be a superuser.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "yyyy-mm",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "pattern" : "\\d{4}-\\d{2}"
+ },
+ "description" : "Must be a string like 2020-04 or 2222-11."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/data-studio/table" ]
+ "tags" : [ "/api/ee/logs" ]
}
},
- "/api/ee/database-replication/connection/{database-id}" : {
+ "/api/ee/metabot-tools/answer-sources" : {
"post" : {
- "summary" : "POST /api/ee/database-replication/connection/{database-id}",
- "description" : "Create a new PG replication connection for the specified database.",
- "parameters" : [ {
- "in" : "path",
- "name" : "database-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "summary" : "POST /api/ee/metabot-tools/answer-sources",
+ "description" : "Return top level meta information about available information sources.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -23438,72 +25220,64 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "replicationSchemaFilters" : {
- "type" : "object",
- "properties" : {
- "schema-filters-patterns" : {
- "type" : "string"
- },
- "schema-filters-type" : {
- "type" : "string",
- "enum" : [ "inclusion", "exclusion", "all" ]
- }
- },
- "required" : [ "schema-filters-type", "schema-filters-patterns" ]
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.answer-sources-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
- }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/database-replication" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/database-replication/connection/{database-id}",
- "description" : "Delete PG replication connection for the specified database.",
- "parameters" : [ {
- "in" : "path",
- "name" : "database-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/database-replication" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/database-replication/connection/{database-id}/preview" : {
+ "/api/ee/metabot-tools/check-transform-dependencies" : {
"post" : {
- "summary" : "POST /api/ee/database-replication/connection/{database-id}/preview",
- "description" : "Return info about pg-replication connection that is about to be created.",
- "parameters" : [ {
- "in" : "path",
- "name" : "database-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "summary" : "POST /api/ee/metabot-tools/check-transform-dependencies",
+ "description" : "Check a proposed edit to a transform and return details of cards or transforms that would be broken by the change.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -23516,44 +25290,67 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "replicationSchemaFilters" : {
- "type" : "object",
- "properties" : {
- "schema-filters-patterns" : {
- "type" : "string"
- },
- "schema-filters-type" : {
- "type" : "string",
- "enum" : [ "inclusion", "exclusion", "all" ]
- }
- },
- "required" : [ "schema-filters-type", "schema-filters-patterns" ]
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.check-transform-dependencies-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
- }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/database-replication" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/database-routing/destination-database" : {
+ "/api/ee/metabot-tools/create-dashboard-subscription" : {
"post" : {
- "summary" : "POST /api/ee/database-routing/destination-database",
- "description" : "Create new Destination Databases.\n\n Note that unlike the normal `POST /api/database` endpoint, does NOT check the details before adding the Database.\n\n This is OK, it's not an invariant that all database details are always valid, but it's something to note.",
- "parameters" : [ {
- "in" : "query",
- "name" : "check_connection_details",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- } ],
+ "summary" : "POST /api/ee/metabot-tools/create-dashboard-subscription",
+ "description" : "Create a dashboard subscription.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "output" : {
+ "type" : "string"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "output", "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -23566,57 +25363,64 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "destinations" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "details" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "name", "details" ]
- }
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.create-dashboard-subscription-arguments"
},
- "router_database_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "router_database_id", "destinations" ]
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/database-routing" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/database-routing/router-database/{id}" : {
- "put" : {
- "summary" : "PUT /api/ee/database-routing/router-database/{id}",
- "description" : "Updates an existing Database with the `user_attribute` to route on. Will either:\n - turn an existing Database into a Router database\n - change the `user_attribute` used to route for an existing Router database, or\n - turn a Router database into a regular Database\n depending on the value of `user_attribute`",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
+ "/api/ee/metabot-tools/field-values" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/field-values",
+ "description" : "Return statistics and/or values for a given field of a given entity.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -23629,36 +25433,61 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "user_attribute" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.field-values-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
}, {
"type" : "null"
} ]
}
- }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/database-routing" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/dependencies/check_card" : {
+ "/api/ee/metabot-tools/filter-records" : {
"post" : {
- "summary" : "POST /api/ee/dependencies/check_card",
- "description" : "Check a proposed edit to a card, and return the card IDs for those cards this edit will break.",
+ "summary" : "POST /api/ee/metabot-tools/filter-records",
+ "description" : "Construct a query from a metric.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -23674,26 +25503,61 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.card-body"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.filter-records-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/dependencies" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/dependencies/check_snippet" : {
+ "/api/ee/metabot-tools/find-outliers" : {
"post" : {
- "summary" : "POST /api/ee/dependencies/check_snippet",
- "description" : "Check a proposed edit to a native snippet, and return the cards, etc. which will be broken.",
+ "summary" : "POST /api/ee/metabot-tools/find-outliers",
+ "description" : "Find outliers in the values provided by a data source for a given column.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -23709,38 +25573,70 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "content" : {
- "type" : "string"
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.find-outliers-arguments"
},
- "id" : {
- "$ref" : "#/components/schemas/metabase.lib.schema.id.snippet"
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "name" : {
- "description" : "snippet names cannot include '}' or start with spaces"
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "id" ]
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/dependencies" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/dependencies/check_transform" : {
+ "/api/ee/metabot-tools/generate-insights" : {
"post" : {
- "summary" : "POST /api/ee/dependencies/check_transform",
- "description" : "Check a proposed edit to a transform, and return the card, transform, etc. IDs for things that will break.",
+ "summary" : "POST /api/ee/metabot-tools/generate-insights",
+ "description" : "Generate insights.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-cards-response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "output" : {
+ "type" : "string"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "reactions" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabot.reaction.redirect"
+ }
+ }
+ },
+ "required" : [ "output", "reactions", "conversation_id" ]
}
}
}
@@ -23756,49 +25652,61 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.transform-body"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.generate-insights-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/dependencies" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/dependencies/graph" : {
- "get" : {
- "summary" : "GET /api/ee/dependencies/graph",
- "description" : "This endpoint takes an :id and a supported entity :type, and returns a graph of all its upstream dependencies.\n The graph is represented by a list of :nodes and a list of :edges. Each node has an :id, :type, :data (which\n depends on the node type), and a map of :dependent_counts per entity type. Each edge is a :model/Dependency.\n\n Optional :archived parameter controls whether entities in archived collections are included:\n - false (default): Excludes entities in archived collections\n - true: Includes entities in archived collections",
- "parameters" : [ {
- "in" : "query",
- "name" : "id",
- "required" : false,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "type",
- "required" : false,
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- }, {
- "in" : "query",
- "name" : "archived",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- } ],
+ "/api/ee/metabot-tools/get-current-user" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-current-user",
+ "description" : "Get information about user that started the conversation.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.graph-response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -23810,110 +25718,46 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/dependencies" ]
- }
- },
- "/api/ee/dependencies/graph/breaking" : {
- "get" : {
- "summary" : "GET /api/ee/dependencies/graph/breaking",
- "description" : "Returns a list of entities that are breaking other entities (sources of errors).\n These are tables or cards that other entities depend on, where those dependents\n have validation errors traced back to this source entity.\n\n Accepts optional parameters for filtering:\n - `types`: List of source entity types - only `:card` or `:table` (default: both)\n - `card_types`: List of card types to include when filtering cards (e.g., `[:question :model :metric]`)\n - `query`: Search string to filter by name or location\n - `archived`: Controls whether archived entities are included\n - `include_personal_collections`: Controls whether items in personal collections are included (default: false)\n - `sort_column`: Sort column - `:name`, `:location`, `:dependents-errors`, or `:dependents-with-errors` (default: `:name`)\n - `sort_direction`: Sort direction - `:asc` or `:desc` (default: `:asc`)\n - `offset`: Default 0\n - `limit`: Default 50\n\n Returns a map with:\n - `data`: List of breaking source entities\n - `total`: Total count of matched items\n - `offset`: Applied offset\n - `limit`: Applied limit",
- "parameters" : [ {
- "in" : "query",
- "name" : "types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }, {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- } ]
- }
- }, {
- "in" : "query",
- "name" : "card_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
- }, {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
}
- } ]
- }
- }, {
- "in" : "query",
- "name" : "query",
- "required" : false,
- "schema" : {
- "type" : "string"
- }
- }, {
- "in" : "query",
- "name" : "archived",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "include_personal_collections",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "dependents-with-errors", "dependents-errors", "name", "location" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "desc", "asc" ]
+ }
}
- } ],
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-dashboard-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-dashboard-details",
+ "description" : "Get information about a given dashboard.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "data" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
- }
- },
- "limit" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "offset" : {
- "type" : "integer",
- "minimum" : 0
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "total" : {
- "type" : "integer",
- "minimum" : 0
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "data", "total", "offset", "limit" ]
+ "required" : [ "conversation_id" ]
}
}
}
@@ -23925,93 +25769,65 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/dependencies" ]
- }
- },
- "/api/ee/dependencies/graph/broken" : {
- "get" : {
- "summary" : "GET /api/ee/dependencies/graph/broken",
- "description" : "Returns the broken dependents for a specific source entity.\n These are entities that have validation errors traced back to the specified source.\n\n Required parameters:\n - `id`: The ID of the source entity\n - `type`: The type of the source entity (card, table)\n\n Optional parameters:\n - `dependent_types`: Dependency types to filter by. Can be single value or array.\n - `dependent_card_types`: Card types to filter by when dependent_types includes :card.\n - `include_personal_collections`: Include items in personal collections (default: false)\n - `sort_column`: Column to sort by - name, location, or view-count (default: name)\n - `sort_direction`: Sort direction - asc or desc (default: asc)",
- "parameters" : [ {
- "in" : "query",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "type",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- }, {
- "in" : "query",
- "name" : "dependent_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }, {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- } ]
- }
- }, {
- "in" : "query",
- "name" : "dependent_card_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
- }, {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-dashboard-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
- } ]
- }
- }, {
- "in" : "query",
- "name" : "include_personal_collections",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "name", "view-count", "location" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "desc", "asc" ]
+ }
}
- } ],
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-document-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-document-details",
+ "description" : "Get information about a given document.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.broken-dependent-entity"
- }
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24023,114 +25839,65 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/dependencies" ]
- }
- },
- "/api/ee/dependencies/graph/dependents" : {
- "get" : {
- "summary" : "GET /api/ee/dependencies/graph/dependents",
- "description" : "Returns a list of dependents for the specified entity.\n\n Required parameters:\n - `id`: The ID of the entity\n - `type`: The type of the entity (card, table, dashboard, etc.)\n\n Optional parameters:\n - `dependent_types`: Dependency types to filter by. Can be single value or array.\n If not provided, returns all types. Example: ?dependent_types=card&dependent_types=dashboard\n - `dependent_card_types`: Card types to filter by when dependent_types includes :card.\n Ignored if dependent_types doesn't include :card. Example: ?dependent_card_types=question&dependent_card_types=model\n - `archived`: Include entities in archived collections (default: false)\n - `broken`: Return only broken entities (default: false)\n - `query`: Search string to filter results by name or location (case-insensitive)\n - `include_personal_collections`: Include items in personal collections (default: false)\n - `sort_column`: Column to sort by - name, location, or view-count (default: name)\n - `sort_direction`: Sort direction - asc or desc (default: asc)",
- "parameters" : [ {
- "in" : "query",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "type",
- "required" : true,
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- }, {
- "in" : "query",
- "name" : "dependent_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }, {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- } ]
- }
- }, {
- "in" : "query",
- "name" : "dependent_card_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
- }, {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-document-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
- } ]
- }
- }, {
- "in" : "query",
- "name" : "archived",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "broken",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "query",
- "required" : false,
- "schema" : {
- "type" : "string"
- }
- }, {
- "in" : "query",
- "name" : "include_personal_collections",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "name", "view-count", "location" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "desc", "asc" ]
+ }
}
- } ],
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-metric-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-metric-details",
+ "description" : "Get information about a given metric.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
- }
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24142,110 +25909,65 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/dependencies" ]
- }
- },
- "/api/ee/dependencies/graph/unreferenced" : {
- "get" : {
- "summary" : "GET /api/ee/dependencies/graph/unreferenced",
- "description" : "Returns a list of all unreferenced items in the instance.\n An unreferenced item is one that is not a dependency of any other item.\n\n Accepts optional parameters for filtering:\n - `types`: List of entity types to include (e.g., [:card :transform :snippet :dashboard])\n - `card_types`: List of card types to include when filtering cards (e.g., [:question :model :metric])\n - `query`: Search string to filter by name or location\n - `archived`: Controls whether archived entities are included\n - `include_personal_collections`: Controls whether items in personal collections are included (default: false)\n - `sort_column`: Sort column - `:name`, `:location`, `:dependents-errors`, or `:dependents-with-errors` (default: `:name`)\n - `sort_direction`: Sort direction - `:asc` or `:desc` (default: `:asc`)\n - `offset`: Default 0\n - `limit`: Default 50\n\n Returns a map with:\n - `data`: List of unreferenced items, each with `:id`, `:type`, and `:data` fields\n - `total`: Total count of matched items\n - `offset`: Applied offset\n - `limit`: Applied limit",
- "parameters" : [ {
- "in" : "query",
- "name" : "types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }, {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.dependency-types.dependency-types"
- }
- } ]
- }
- }, {
- "in" : "query",
- "name" : "card_types",
- "required" : false,
- "schema" : {
- "anyOf" : [ {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
- }, {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "question", "metric", "model" ]
- }
- } ]
- }
- }, {
- "in" : "query",
- "name" : "query",
- "required" : false,
- "schema" : {
- "type" : "string"
- }
- }, {
- "in" : "query",
- "name" : "archived",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "include_personal_collections",
- "required" : false,
- "schema" : {
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "dependents-with-errors", "dependents-errors", "name", "location" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "desc", "asc" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-metric-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
}
- } ],
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-query-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-query-details",
+ "description" : "Get information about a given query.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "data" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.dependencies.api.entity"
- }
- },
- "limit" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "offset" : {
- "type" : "integer",
- "minimum" : 0
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "total" : {
- "type" : "integer",
- "minimum" : 0
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "data", "total", "offset", "limit" ]
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24257,17 +25979,68 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/dependencies" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-query-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/email/override" : {
- "put" : {
- "summary" : "PUT /api/ee/email/override",
- "description" : "Update multiple cloud email Settings. You must be a superuser or have `setting` permission to do this.\n Calling this automatically sets `cloud-smtp-enabled` to true if the settings are valid.",
+ "/api/ee/metabot-tools/get-report-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-report-details",
+ "description" : "Get information about a given report.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -24280,57 +26053,143 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "email-smtp-host-override" : {
- "anyOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-report-details-arguments"
},
- "email-smtp-password-override" : {
- "anyOf" : [ {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-snippet-details" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-snippet-details",
+ "description" : "Get the content of a single SQL snippet.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "structured_output" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.full-snippet"
+ }
},
- "email-smtp-port-override" : {
- "anyOf" : [ {
- "type" : "integer"
- }, {
- "type" : "null"
- } ]
+ "required" : [ "structured_output", "conversation_id" ]
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-snippet-details-arguments"
},
- "email-smtp-security-override" : {
- "anyOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "email-smtp-username-override" : {
- "anyOf" : [ {
+ "profile_id" : {
+ "oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
}
- }
+ },
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/email" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/email/override",
- "description" : "Clear all cloud email related settings. You must be a superuser or have `setting` permission to do this.",
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-snippets" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-snippets",
+ "description" : "Get a list of all known SQL snippets.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "structured_output" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.basic-snippet"
+ }
+ }
+ },
+ "required" : [ "structured_output", "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -24339,40 +26198,46 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/email" ]
- }
- },
- "/api/ee/embedding-hub/checklist" : {
- "get" : {
- "summary" : "GET /api/ee/embedding-hub/checklist",
- "description" : "Get the embedding hub checklist status, indicating which setup steps have been completed.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
+ }
+ }
}
},
- "tags" : [ "/api/ee/embedding-hub" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/gsheets/connection" : {
+ "/api/ee/metabot-tools/get-table-details" : {
"post" : {
- "summary" : "POST /api/ee/gsheets/connection",
- "description" : "Hook up a new google drive folder or sheet that will be watched and have its content ETL'd into Metabase.",
+ "summary" : "POST /api/ee/metabot-tools/get-table-details",
+ "description" : "Get information about a given table or model.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/gsheets.response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24388,31 +26253,61 @@
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "url" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-table-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
"type" : "string",
- "minLength" : 1
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "url" ]
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
},
- "tags" : [ "/api/ee/gsheets" ]
- },
- "get" : {
- "summary" : "GET /api/ee/gsheets/connection",
- "description" : "Check the status of a connection. This endpoint gets polled by FE to determine when to\n stop showing the setup widget.\n\n Returns the gsheets shape, with the attached datawarehouse db id at `:db_id`.",
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-tools/get-tables" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-tables",
+ "description" : "Get information about the tables in a given database.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/gsheets.response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24424,59 +26319,57 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/gsheets" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/gsheets/connection",
- "description" : "Disconnect the google service account. There is only one (or zero) at the time of writing.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-tables-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
}
},
- "tags" : [ "/api/ee/gsheets" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/gsheets/connection/sync" : {
+ "/api/ee/metabot-tools/get-transform-details" : {
"post" : {
- "summary" : "POST /api/ee/gsheets/connection/sync",
- "description" : "Force a sync of the connection now.\n\n Returns the gsheets shape, with the attached datawarehouse db id at `:db_id`.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/gsheets" ]
- }
- },
- "/api/ee/gsheets/service-account" : {
- "get" : {
- "summary" : "GET /api/ee/gsheets/service-account",
- "description" : "Checks to see if service-account is setup or not, delegates to HM only if we haven't set it from a metabase cluster\n before.",
+ "summary" : "POST /api/ee/metabot-tools/get-transform-details",
+ "description" : "Get information about a transform.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "email" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
"oneOf" : [ {
"type" : "string"
}, {
@@ -24484,7 +26377,7 @@
} ]
}
},
- "required" : [ "email" ]
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24496,48 +26389,65 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/gsheets" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-transform-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/library/" : {
+ "/api/ee/metabot-tools/get-transform-python-library-details" : {
"post" : {
- "summary" : "POST /api/ee/library/",
- "description" : "Creates the Library if it doesn't exist. Returns the created collection.\n\n Requires data analyst or superuser permissions.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/library" ]
- },
- "get" : {
- "summary" : "GET /api/ee/library/",
- "description" : "Get the Library. If no library exists, it doesn't fail but returns an empty response",
+ "summary" : "POST /api/ee/metabot-tools/get-transform-python-library-details",
+ "description" : "Get information about a Python library by path.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"content" : {
"application/json" : {
"schema" : {
- "anyOf" : [ {
- "$ref" : "#/components/schemas/metabase.collections.schema.CollectionItem"
- }, {
- "type" : "object",
- "properties" : {
- "data" : {
- "type" : "null"
- }
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "required" : [ "data" ]
- } ]
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24549,17 +26459,68 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/library" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "arguments" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-transform-python-library-details-arguments"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "arguments", "conversation_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/library/tree" : {
- "get" : {
- "summary" : "GET /api/ee/library/tree",
- "description" : "This matches /api/collection/tree but only returns the library collection.",
+ "/api/ee/metabot-tools/get-transforms" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-tools/get-transforms",
+ "description" : "Get a list of all known transforms.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "type" : "object",
+ "properties" : {
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "profile_id" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -24568,41 +26529,22 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/library" ]
- }
- },
- "/api/ee/logs/query_execution/{yyyy-mm}" : {
- "get" : {
- "summary" : "GET /api/ee/logs/query_execution/{yyyy-mm}",
- "description" : "Fetch rows for the month specified by `:yyyy-mm` from the query_execution logs table.\n Must be a superuser.",
- "parameters" : [ {
- "in" : "path",
- "name" : "yyyy-mm",
- "required" : true,
- "schema" : {
- "type" : "string",
- "pattern" : "\\d{4}-\\d{2}"
- },
- "description" : "Must be a string like 2020-04 or 2222-11."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
+ }
+ }
}
},
- "tags" : [ "/api/ee/logs" ]
+ "tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/metabot-tools/answer-sources" : {
+ "/api/ee/metabot-tools/query-datasource" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/answer-sources",
- "description" : "Return top level meta information about available information sources.",
+ "summary" : "POST /api/ee/metabot-tools/query-datasource",
+ "description" : "Construct a query from a model or table data source.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -24646,7 +26588,7 @@
"type" : "object",
"properties" : {
"arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.answer-sources-arguments"
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-datasource-arguments"
},
"conversation_id" : {
"description" : "value must be a valid UUID.",
@@ -24661,7 +26603,7 @@
} ]
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "arguments", "conversation_id" ]
}
}
}
@@ -24669,10 +26611,10 @@
"tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/metabot-tools/check-transform-dependencies" : {
+ "/api/ee/metabot-tools/query-metric" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/check-transform-dependencies",
- "description" : "Check a proposed edit to a transform and return details of cards or transforms that would be broken by the change.",
+ "summary" : "POST /api/ee/metabot-tools/query-metric",
+ "description" : "Construct a query from a metric.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -24716,7 +26658,7 @@
"type" : "object",
"properties" : {
"arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.check-transform-dependencies-arguments"
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-metric-arguments"
},
"conversation_id" : {
"description" : "value must be a valid UUID.",
@@ -24739,10 +26681,10 @@
"tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/metabot-tools/create-dashboard-subscription" : {
+ "/api/ee/metabot-tools/query-model" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/create-dashboard-subscription",
- "description" : "Create a dashboard subscription.",
+ "summary" : "POST /api/ee/metabot-tools/query-model",
+ "description" : "Construct a query from a model.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -24758,9 +26700,6 @@
"type" : "string",
"pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
},
- "output" : {
- "type" : "string"
- },
"profile_id" : {
"oneOf" : [ {
"type" : "string"
@@ -24769,7 +26708,7 @@
} ]
}
},
- "required" : [ "output", "conversation_id" ]
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24789,7 +26728,7 @@
"type" : "object",
"properties" : {
"arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.create-dashboard-subscription-arguments"
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-model-arguments"
},
"conversation_id" : {
"description" : "value must be a valid UUID.",
@@ -24812,10 +26751,10 @@
"tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/metabot-tools/field-values" : {
+ "/api/ee/metabot-tools/search" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/field-values",
- "description" : "Return statistics and/or values for a given field of a given entity.",
+ "summary" : "POST /api/ee/metabot-tools/search",
+ "description" : "Enhanced search with term and semantic queries using Reciprocal Rank Fusion.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -24859,7 +26798,7 @@
"type" : "object",
"properties" : {
"arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.field-values-arguments"
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.search-arguments"
},
"conversation_id" : {
"description" : "value must be a valid UUID.",
@@ -24874,7 +26813,7 @@
} ]
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "required" : [ "conversation_id" ]
}
}
}
@@ -24882,10 +26821,10 @@
"tags" : [ "/api/ee/metabot-tools" ]
}
},
- "/api/ee/metabot-tools/filter-records" : {
+ "/api/ee/metabot-tools/search_v2" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/filter-records",
- "description" : "Construct a query from a metric.",
+ "summary" : "POST /api/ee/metabot-tools/search_v2",
+ "description" : "Enhanced search with term and semantic queries using Reciprocal Rank Fusion. This is identical to /search, but\n duplicated in order to add a new capability to AI service that indicates that Metabot can search transforms. The\n /search endpoint is kept around for backward compatibility.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -24929,7 +26868,7 @@
"type" : "object",
"properties" : {
"arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.filter-records-arguments"
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.search-arguments"
},
"conversation_id" : {
"description" : "value must be a valid UUID.",
@@ -24944,45 +26883,122 @@
} ]
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "required" : [ "conversation_id" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-tools" ]
+ }
+ },
+ "/api/ee/metabot-v3/agent-streaming" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-v3/agent-streaming",
+ "description" : "Send a chat message to the LLM via the AI Proxy.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "context" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.context.context"
+ },
+ "conversation_id" : {
+ "description" : "value must be a valid UUID.",
+ "type" : "string",
+ "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ },
+ "history" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.client.schema.messages"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "message" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "metabot_id" : {
+ "type" : "string"
+ },
+ "profile_id" : {
+ "type" : "string"
+ },
+ "state" : {
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "required" : [ "message", "context", "conversation_id", "history", "state" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/metabot-v3" ]
+ }
+ },
+ "/api/ee/metabot-v3/document/generate-content" : {
+ "post" : {
+ "summary" : "POST /api/ee/metabot-v3/document/generate-content",
+ "description" : "Create a new piece of content to insert into the document.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "instructions" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "references" : {
+ "description" : "Value must be a map.",
+ "type" : "object",
+ "properties" : { }
+ }
+ },
+ "required" : [ "instructions" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3/document" ]
}
},
- "/api/ee/metabot-tools/find-outliers" : {
+ "/api/ee/metabot-v3/feedback" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/find-outliers",
- "description" : "Find outliers in the values provided by a data source for a given column.",
+ "summary" : "POST /api/ee/metabot-v3/feedback",
+ "description" : "Proxy Metabot feedback to Harbormaster, adding the premium embedding token.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -24995,73 +27011,75 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.find-outliers-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
+ "properties" : { }
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3" ]
}
},
- "/api/ee/metabot-tools/generate-insights" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/generate-insights",
- "description" : "Generate insights.",
+ "/api/ee/metabot-v3/metabot/" : {
+ "get" : {
+ "summary" : "GET /api/ee/metabot-v3/metabot/",
+ "description" : "List configured metabot instances",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "output" : {
- "type" : "string"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "reactions" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabot.reaction.redirect"
- }
- }
- },
- "required" : [ "output", "reactions", "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ }
+ },
+ "/api/ee/metabot-v3/metabot/{id}" : {
+ "get" : {
+ "summary" : "GET /api/ee/metabot-v3/metabot/{id}",
+ "description" : "Retrieve one metabot instance",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/ee/metabot-v3/metabot/{id}",
+ "description" : "Update a metabot instance",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -25074,64 +27092,92 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.generate-insights-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
+ "collection_id" : {
"oneOf" : [ {
- "type" : "string"
+ "type" : "integer",
+ "minimum" : 1
}, {
"type" : "null"
} ]
+ },
+ "use_verified_content" : {
+ "type" : "boolean"
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "additionalProperties" : false
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
}
},
- "/api/ee/metabot-tools/get-current-user" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-current-user",
- "description" : "Get information about user that started the conversation.",
- "parameters" : [ ],
+ "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions" : {
+ "get" : {
+ "summary" : "GET /api/ee/metabot-v3/metabot/{id}/prompt-suggestions",
+ "description" : "Return the prompt suggestions for the metabot instance with `id`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ }, {
+ "in" : "query",
+ "name" : "sample",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "model",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "metric", "model" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "model_id",
+ "required" : false,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/metabot-v3/metabot/{id}/prompt-suggestions",
+ "description" : "Delete all prompt suggestions for the metabot instance with `id`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -25140,49 +27186,25 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
}
},
- "/api/ee/metabot-tools/get-dashboard-details" : {
+ "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions/regenerate" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/get-dashboard-details",
- "description" : "Get information about a given dashboard.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/metabot-v3/metabot/{id}/prompt-suggestions/regenerate",
+ "description" : "Remove any existing prompt suggestions for the Metabot instance with `id` and generate new ones.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -25191,68 +27213,33 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-dashboard-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
}
},
- "/api/ee/metabot-tools/get-document-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-document-details",
- "description" : "Get information about a given document.",
- "parameters" : [ ],
+ "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions/{prompt-id}" : {
+ "delete" : {
+ "summary" : "DELETE /api/ee/metabot-v3/metabot/{id}/prompt-suggestions/{prompt-id}",
+ "description" : "Delete the prompt suggestion with ID `prompt-id` for the metabot instance with `id`.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ }, {
+ "in" : "path",
+ "name" : "prompt-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -25261,135 +27248,79 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-document-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/metabot-v3/metabot" ]
}
},
- "/api/ee/metabot-tools/get-metric-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-metric-details",
- "description" : "Get information about a given metric.",
- "parameters" : [ ],
+ "/api/ee/permission_debug/" : {
+ "get" : {
+ "summary" : "GET /api/ee/permission_debug/",
+ "description" : "This endpoint expects a `user_id`, a `model_id` to debug permissions against, and `action_type`.\n The type of model we are debugging against is inferred by the `action_type`.\n\n It will return:\n - `decision`: The overall permission decision (\"allow\", \"denied\", or \"limited\")\n - `model-type`: The type of model being checked (e.g., \"question\")\n - `model-id`: The ID of the model being checked\n - `segment`: A set of segmentation types applied (e.g., \"sandboxed\", \"impersonated\", \"routed\")\n - `message`: A sequence of strings explaining the decision\n - `data`: A map containing details about permissions (table or collection names to group names)\n - `suggestions`: A map of group IDs to group names that could provide access\n\n Example requests:\n - Check if user can read a card: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/read`\n - Check if user can query a card: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/query`\n - Check if user can download data: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/download-data`\n\n Example responses:\n - Allowed access:\n ```json\n {\n \"decision\": \"allow\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User has permission to read this card\"],\n \"data\": {},\n \"suggestions\": {}\n }\n ```\n - Denied access with blocked table:\n ```json\n {\n \"decision\": \"denied\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User does not have permission to query this card\"],\n \"data\": {\"sample-db.PUBLIC.ORDERS\": [\"All Users\"]},\n \"suggestions\": {}\n }\n ```\n - Limited access:\n ```json\n {\n \"decision\": \"limited\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User has permission to download some data from this card\"],\n \"data\": {},\n \"suggestions\": {}\n }\n ```",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "user_id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ }
+ }, {
+ "in" : "query",
+ "name" : "model_id",
+ "required" : true,
+ "schema" : {
+ "type" : "string"
+ }
+ }, {
+ "in" : "query",
+ "name" : "action_type",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "card/read", "card/query", "card/download-data" ]
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
+ "$ref" : "#/components/schemas/metabase-enterprise.permission-debug.impl.perm-debug-info"
}
}
}
},
"4XX" : {
"description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-metric-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/permission_debug" ]
}
},
- "/api/ee/metabot-tools/get-query-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-query-details",
- "description" : "Get information about a given query.",
+ "/api/ee/remote-sync/branches" : {
+ "get" : {
+ "summary" : "GET /api/ee/remote-sync/branches",
+ "description" : "Get list of branches from the configured source.\n\n Returns a JSON object with branch names under the :items key.\n\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
+ "items" : {
+ "type" : "array",
+ "items" : {
"type" : "string"
- }, {
- "type" : "null"
- } ]
+ }
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "items" ]
}
}
}
@@ -25401,65 +27332,30 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-query-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-report-details" : {
+ "/api/ee/remote-sync/create-branch" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/get-report-details",
- "description" : "Get information about a given report.",
+ "summary" : "POST /api/ee/remote-sync/create-branch",
+ "description" : "Create a new branch from the current remote-sync branch and switches the current remote-sync branch to it.\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "message" : {
+ "type" : "string"
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "status" : {
+ "type" : "string"
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "status", "message" ]
}
}
}
@@ -25475,64 +27371,101 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-report-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "name" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "minLength" : 1
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "required" : [ "name" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-snippet-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-snippet-details",
- "description" : "Get the content of a single SQL snippet.",
+ "/api/ee/remote-sync/current-task" : {
+ "get" : {
+ "summary" : "GET /api/ee/remote-sync/current-task",
+ "description" : "Get the current sync task",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "progress" : {
+ "oneOf" : [ {
+ "type" : "number",
+ "minimum" : 0.0,
+ "maximum" : 1.0
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "last_progress_report_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "started_at" : { },
+ "ended_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "initiated_by" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cancelled" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "status" : {
+ "type" : "string",
+ "enum" : [ "running", "successful", "errored", "cancelled", "timed-out" ]
+ },
+ "error_message" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "sync_task_type" : {
+ "type" : "string",
+ "enum" : [ "import", "export" ]
+ },
+ "version" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
},
- "structured_output" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.full-snippet"
- }
- },
- "required" : [ "structured_output", "conversation_id" ]
+ "required" : [ "id", "sync_task_type", "progress", "started_at", "status" ]
+ }, {
+ "type" : "null"
+ } ]
}
}
}
@@ -25544,71 +27477,85 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-snippet-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-snippets" : {
+ "/api/ee/remote-sync/current-task/cancel" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/get-snippets",
- "description" : "Get a list of all known SQL snippets.",
+ "summary" : "POST /api/ee/remote-sync/current-task/cancel",
+ "description" : "Cancels the current task if one is running",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "progress" : {
+ "oneOf" : [ {
+ "type" : "number",
+ "minimum" : 0.0,
+ "maximum" : 1.0
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "last_progress_report_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "started_at" : { },
+ "ended_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "initiated_by" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "cancelled" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "status" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "enum" : [ "running", "successful", "errored", "cancelled", "timed-out" ]
},
- "profile_id" : {
+ "error_message" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "structured_output" : {
- "type" : "array",
- "items" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.basic-snippet"
- }
+ "sync_task_type" : {
+ "type" : "string",
+ "enum" : [ "import", "export" ]
+ },
+ "version" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "structured_output", "conversation_id" ]
+ "required" : [ "id", "sync_task_type", "progress", "started_at", "status" ]
}
}
}
@@ -25620,46 +27567,107 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-table-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-table-details",
- "description" : "Get information about a given table or model.",
+ "/api/ee/remote-sync/dirty" : {
+ "get" : {
+ "summary" : "GET /api/ee/remote-sync/dirty",
+ "description" : "Return all models with changes that have not been pushed to the remote sync source in any\n remote-synced collection.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "dirty" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "table_name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "model" : {
+ "type" : "string"
+ },
+ "authority_level" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "updated_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "table_id" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "query_type" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "created_at" : { },
+ "display" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "sync_status" : {
+ "type" : "string"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "id", "name", "model", "sync_status" ]
+ }
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "dirty" ]
}
}
}
@@ -25671,65 +27679,31 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-table-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-tables" : {
+ "/api/ee/remote-sync/export" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/get-tables",
- "description" : "Get information about the tables in a given database.",
+ "summary" : "POST /api/ee/remote-sync/export",
+ "description" : "Export the current state of the Remote Sync collection to a Source.\n\n This endpoint will:\n - Fetch the latest changes from the source\n - Create a branch or subdirectory (depending on source support)\n If no branch is supplied, use the configured export branch\n - Export the Remote Sync collection via serialization to the branch or subdirectory\n - Commit the changes if possible\n - Sync to the source if possible\n\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "message" : {
+ "type" : "string"
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "task_id" : {
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "message", "task_id" ]
}
}
}
@@ -25741,57 +27715,43 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-tables-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
+ "tags" : [ "/api/ee/remote-sync" ]
+ }
+ },
+ "/api/ee/remote-sync/has-remote-changes" : {
+ "get" : {
+ "summary" : "GET /api/ee/remote-sync/has-remote-changes",
+ "description" : "Check if there are new changes on the remote branch that can be pulled.\n Uses in-memory caching (configurable TTL via remote-sync-check-changes-cache-ttl-seconds setting).\n\n Returns:\n - has_changes: true if remote version differs from last imported version, or if never imported\n - remote_version: current Git SHA on remote branch\n - local_version: Git SHA of last successful import (nil if never imported)\n - cached: true if result was served from cache",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "force-refresh",
+ "required" : false,
+ "schema" : {
+ "type" : "boolean"
}
- },
- "tags" : [ "/api/ee/metabot-tools" ]
- }
- },
- "/api/ee/metabot-tools/get-transform-details" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-transform-details",
- "description" : "Get information about a transform.",
- "parameters" : [ ],
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "cached" : {
+ "type" : "boolean"
},
- "profile_id" : {
+ "has_changes" : {
+ "type" : "boolean"
+ },
+ "local_version" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "remote_version" : {
"oneOf" : [ {
"type" : "string"
}, {
@@ -25799,7 +27759,7 @@
} ]
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "has_changes", "remote_version", "local_version", "cached" ]
}
}
}
@@ -25811,65 +27771,42 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-transform-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "arguments", "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-transform-python-library-details" : {
+ "/api/ee/remote-sync/import" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/get-transform-python-library-details",
- "description" : "Get information about a Python library by path.",
+ "summary" : "POST /api/ee/remote-sync/import",
+ "description" : "Import Metabase content from configured Remote Sync source.\n\n This endpoint will:\n - Fetch the latest changes from the configured source\n - Load the updated content using the serialization/deserialization system\n\n If `force=false` (default) and there are unsaved changes in the Remote Sync collection,\n the import returns a 400 response.\n\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
+ "message" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
+ },
+ "status" : {
+ "const" : "success"
+ },
+ "task_id" : {
+ "oneOf" : [ {
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "status", "task_id" ]
}
}
}
@@ -25885,61 +27822,41 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.get-transform-python-library-details-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "branch" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "minLength" : 1
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "force" : {
+ "type" : "boolean"
}
- },
- "required" : [ "arguments", "conversation_id" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/get-transforms" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/get-transforms",
- "description" : "Get a list of all known transforms.",
+ "/api/ee/remote-sync/is-dirty" : {
+ "get" : {
+ "summary" : "GET /api/ee/remote-sync/is-dirty",
+ "description" : "Check if any remote-synced collection or collection item has local changes that have not been pushed\n to the remote sync source.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "is_dirty" : {
+ "type" : "boolean"
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "is_dirty" ]
}
}
}
@@ -25951,46 +27868,31 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.deftool.tool-request"
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/query-datasource" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/query-datasource",
- "description" : "Construct a query from a model or table data source.",
+ "/api/ee/remote-sync/settings" : {
+ "put" : {
+ "summary" : "PUT /api/ee/remote-sync/settings",
+ "description" : "Update Remote Sync related settings. You must be a superuser to do this.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "success" : {
+ "type" : "boolean"
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "task_id" : {
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "success" ]
}
}
}
@@ -26006,61 +27908,94 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-datasource-arguments"
+ "collections" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "boolean"
+ }
+ }, {
+ "type" : "null"
+ } ]
},
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "remote-sync-auto-import" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
},
- "profile_id" : {
+ "remote-sync-branch" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "remote-sync-token" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "remote-sync-transforms" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "remote-sync-type" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "read-only", "read-write" ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "remote-sync-url" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
}
- },
- "required" : [ "arguments", "conversation_id" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/query-metric" : {
+ "/api/ee/remote-sync/stash" : {
"post" : {
- "summary" : "POST /api/ee/metabot-tools/query-metric",
- "description" : "Construct a query from a metric.",
+ "summary" : "POST /api/ee/remote-sync/stash",
+ "description" : "Stashes changes to a new branch, and changes the current branch to it.\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
+ "description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "message" : {
+ "type" : "string"
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "status" : {
+ "type" : "string"
+ },
+ "task_id" : {
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "status", "message", "task_id" ]
}
}
}
@@ -26076,64 +28011,124 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-metric-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "message" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "minLength" : 1
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "new_branch" : {
+ "type" : "string",
+ "minLength" : 1
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "required" : [ "new_branch", "message" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/remote-sync" ]
}
},
- "/api/ee/metabot-tools/query-model" : {
+ "/api/ee/scim/api_key" : {
+ "get" : {
+ "summary" : "GET /api/ee/scim/api_key",
+ "description" : "Fetch the SCIM API key if one exists. Does *not* return an unmasked key, since we don't have access\n to that after it is created.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/scim" ]
+ },
"post" : {
- "summary" : "POST /api/ee/metabot-tools/query-model",
- "description" : "Construct a query from a model.",
+ "summary" : "POST /api/ee/scim/api_key",
+ "description" : "Create a new SCIM API key, or refresh one that already exists. When called for the first time,\n this is equivalent to enabling SCIM.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/scim" ]
+ }
+ },
+ "/api/ee/scim/v2/Groups" : {
+ "get" : {
+ "summary" : "GET /api/ee/scim/v2/Groups",
+ "description" : "Fetch a list of groups.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "startIndex",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "count",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "filter",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
+ "post" : {
+ "summary" : "POST /api/ee/scim/v2/Groups",
+ "description" : "Create a single group, and populates it if necessary.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -26146,64 +28141,82 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.query-model-arguments"
+ "displayName" : {
+ "type" : "string",
+ "minLength" : 1
},
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "id" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "minLength" : 1
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "members" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "$ref" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value" ]
+ }
+ },
+ "schemas" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
}
},
- "required" : [ "arguments", "conversation_id" ]
+ "required" : [ "schemas", "displayName" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/scim/v2" ]
}
},
- "/api/ee/metabot-tools/search" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/search",
- "description" : "Enhanced search with term and semantic queries using Reciprocal Rank Fusion.",
- "parameters" : [ ],
+ "/api/ee/scim/v2/Groups/{id}" : {
+ "get" : {
+ "summary" : "GET /api/ee/scim/v2/Groups/{id}",
+ "description" : "Fetch a single group.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/ee/scim/v2/Groups/{id}",
+ "description" : "Update a group.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -26216,64 +28229,63 @@
"content" : {
"application/json" : {
"schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
"type" : "object",
"properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.search-arguments"
+ "displayName" : {
+ "type" : "string",
+ "minLength" : 1
},
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "id" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "minLength" : 1
},
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "members" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "$ref" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value" ]
+ }
+ },
+ "schemas" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
}
},
- "required" : [ "conversation_id" ]
+ "required" : [ "schemas", "displayName" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-tools" ]
- }
- },
- "/api/ee/metabot-tools/search_v2" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-tools/search_v2",
- "description" : "Enhanced search with term and semantic queries using Reciprocal Rank Fusion. This is identical to /search, but\n duplicated in order to add a new capability to AI service that indicates that Metabot can search transforms. The\n /search endpoint is kept around for backward compatibility.",
- "parameters" : [ ],
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/scim/v2/Groups/{id}",
+ "description" : "Delete a group.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -26282,41 +28294,68 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "description" : "Base schema for all tool requests. Contains the conversation ID and optional profile ID.",
- "type" : "object",
- "properties" : {
- "arguments" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.tools.api.search-arguments"
- },
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
- "type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
- },
- "profile_id" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "conversation_id" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-tools" ]
+ "tags" : [ "/api/ee/scim/v2" ]
}
},
- "/api/ee/metabot-v3/agent-streaming" : {
+ "/api/ee/scim/v2/Users" : {
+ "get" : {
+ "summary" : "GET /api/ee/scim/v2/Users",
+ "description" : "Fetch a list of users.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "startIndex",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "count",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "filter",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
"post" : {
- "summary" : "POST /api/ee/metabot-v3/agent-streaming",
- "description" : "Send a chat message to the LLM via the AI Proxy.",
+ "summary" : "POST /api/ee/scim/v2/Users",
+ "description" : "Create a single user.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -26335,49 +28374,107 @@
"schema" : {
"type" : "object",
"properties" : {
- "context" : {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.context.context"
+ "active" : {
+ "type" : "boolean"
},
- "conversation_id" : {
- "description" : "value must be a valid UUID.",
+ "emails" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "primary" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value" ]
+ }
+ },
+ "groups" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "$ref" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value", "display" ]
+ }
+ },
+ "id" : {
"type" : "string",
- "pattern" : "[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}"
+ "minLength" : 1
},
- "history" : {
+ "locale" : {
"oneOf" : [ {
- "$ref" : "#/components/schemas/metabase-enterprise.metabot-v3.client.schema.messages"
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
},
- "message" : {
+ "name" : {
+ "type" : "object",
+ "properties" : {
+ "familyName" : {
+ "type" : "string"
+ },
+ "givenName" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "givenName", "familyName" ]
+ },
+ "schemas" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "userName" : {
"type" : "string",
"minLength" : 1
- },
- "metabot_id" : {
- "type" : "string"
- },
- "profile_id" : {
- "type" : "string"
- },
- "state" : {
- "type" : "object",
- "properties" : { }
}
},
- "required" : [ "message", "context", "conversation_id", "history", "state" ]
+ "required" : [ "schemas", "userName", "name", "emails" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-v3" ]
+ "tags" : [ "/api/ee/scim/v2" ]
}
},
- "/api/ee/metabot-v3/document/generate-content" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-v3/document/generate-content",
- "description" : "Create a new piece of content to insert into the document.",
- "parameters" : [ ],
+ "/api/ee/scim/v2/Users/{id}" : {
+ "get" : {
+ "summary" : "GET /api/ee/scim/v2/Users/{id}",
+ "description" : "Fetch a single user.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -26389,34 +28486,11 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "instructions" : {
- "type" : "string",
- "minLength" : 1
- },
- "references" : {
- "description" : "Value must be a map.",
- "type" : "object",
- "properties" : { }
- }
- },
- "required" : [ "instructions" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-v3/document" ]
- }
- },
- "/api/ee/metabot-v3/feedback" : {
- "post" : {
- "summary" : "POST /api/ee/metabot-v3/feedback",
- "description" : "Proxy Metabot feedback to Harbormaster, adding the premium embedding token.",
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/ee/scim/v2/Users/{id}",
+ "description" : "Update a user.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -26434,44 +28508,104 @@
"application/json" : {
"schema" : {
"type" : "object",
- "properties" : { }
+ "properties" : {
+ "active" : {
+ "type" : "boolean"
+ },
+ "emails" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "primary" : {
+ "type" : "boolean"
+ },
+ "type" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value" ]
+ }
+ },
+ "groups" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "$ref" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "display" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "value", "display" ]
+ }
+ },
+ "id" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "locale" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "object",
+ "properties" : {
+ "familyName" : {
+ "type" : "string"
+ },
+ "givenName" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "givenName", "familyName" ]
+ },
+ "schemas" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "userName" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "schemas", "userName", "name", "emails" ]
}
}
}
},
- "tags" : [ "/api/ee/metabot-v3" ]
- }
- },
- "/api/ee/metabot-v3/metabot/" : {
- "get" : {
- "summary" : "GET /api/ee/metabot-v3/metabot/",
- "description" : "List configured metabot instances",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
- }
- },
- "/api/ee/metabot-v3/metabot/{id}" : {
- "get" : {
- "summary" : "GET /api/ee/metabot-v3/metabot/{id}",
- "description" : "Retrieve one metabot instance",
+ "tags" : [ "/api/ee/scim/v2" ]
+ },
+ "patch" : {
+ "summary" : "PATCH /api/ee/scim/v2/Users/{id}",
+ "description" : "Activate or deactivate a user. Supports specific replace operations, but not arbitrary patches.",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "minLength" : 1
}
} ],
"responses" : {
@@ -26485,20 +28619,64 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
- },
- "put" : {
- "summary" : "PUT /api/ee/metabot-v3/metabot/{id}",
- "description" : "Update a metabot instance",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "Operations" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "op" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "value" : {
+ "anyOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "anyOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "boolean"
+ } ]
+ }
+ }, {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "boolean"
+ } ]
+ }
+ },
+ "required" : [ "op", "value" ]
+ }
+ },
+ "schemas" : {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ }
+ },
+ "required" : [ "schemas", "Operations" ]
+ }
+ }
}
- } ],
+ },
+ "tags" : [ "/api/ee/scim/v2" ]
+ }
+ },
+ "/api/ee/semantic-search/status" : {
+ "get" : {
+ "summary" : "GET /api/ee/semantic-search/status",
+ "description" : "Fetch the indexing status of the currently active semantic search index table.\n\n Returns a map with keys:\n :indexed_count <number of indexed items>\n :total_est <estimated total number of items to index>\n\n If no index is active, returns an empty map.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -26510,91 +28688,105 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "collection_id" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "use_verified_content" : {
- "type" : "boolean"
- }
- },
- "additionalProperties" : false
- }
- }
- }
- },
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ "tags" : [ "/api/ee/semantic-search" ]
}
},
- "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions" : {
- "get" : {
- "summary" : "GET /api/ee/metabot-v3/metabot/{id}/prompt-suggestions",
- "description" : "Return the prompt suggestions for the metabot instance with `id`.",
+ "/api/ee/serialization/export" : {
+ "post" : {
+ "summary" : "POST /api/ee/serialization/export",
+ "description" : "Serialize and retrieve Metabase instance.\n\n Outputs `.tar.gz` file with serialization results and an `export.log` file.\n On error outputs serialization logs directly.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
+ "in" : "query",
+ "name" : "dirname",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "name of directory and archive file (default: `<instance-name>-<YYYY-MM-dd_HH-mm>`)"
+ }, {
+ "in" : "query",
+ "name" : "collection",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "string",
+ "pattern" : "^.{21}$"
+ }, {
+ "type" : "string",
+ "pattern" : "^eid:.{21}$"
+ } ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : "collections' db ids/entity-ids to serialize"
+ }, {
+ "in" : "query",
+ "name" : "all_collections",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "default" : true,
+ "type" : "boolean"
}
}, {
"in" : "query",
- "name" : "sample",
- "required" : false,
+ "name" : "settings",
+ "required" : true,
"schema" : {
+ "default" : true,
"type" : "boolean"
}
}, {
"in" : "query",
- "name" : "model",
- "required" : false,
+ "name" : "data_model",
+ "required" : true,
"schema" : {
- "type" : "string",
- "enum" : [ "metric", "model" ]
+ "default" : true,
+ "type" : "boolean"
}
}, {
"in" : "query",
- "name" : "model_id",
- "required" : false,
+ "name" : "field_values",
+ "required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "default" : false,
+ "type" : "boolean"
}
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ }, {
+ "in" : "query",
+ "name" : "database_secrets",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "type" : "boolean"
}
- },
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/metabot-v3/metabot/{id}/prompt-suggestions",
- "description" : "Delete all prompt suggestions for the metabot instance with `id`.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
+ }, {
+ "in" : "query",
+ "name" : "continue_on_error",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "default" : false,
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "full_stacktrace",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "type" : "boolean"
}
} ],
"responses" : {
@@ -26608,20 +28800,36 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ "tags" : [ "/api/ee/serialization" ]
}
},
- "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions/regenerate" : {
+ "/api/ee/serialization/import" : {
"post" : {
- "summary" : "POST /api/ee/metabot-v3/metabot/{id}/prompt-suggestions/regenerate",
- "description" : "Remove any existing prompt suggestions for the Metabot instance with `id` and generate new ones.",
+ "summary" : "POST /api/ee/serialization/import",
+ "description" : "Deserialize Metabase instance from an archive generated by /export.\n\n Parameters:\n - `file`: archive encoded as `multipart/form-data` (required).\n\n Returns logs of deserialization.",
"parameters" : [ {
- "in" : "path",
- "name" : "id",
+ "in" : "query",
+ "name" : "continue_on_error",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "default" : false,
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "full_stacktrace",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "reindex",
+ "required" : true,
+ "schema" : {
+ "default" : true,
+ "type" : "boolean"
}
} ],
"responses" : {
@@ -26635,28 +28843,92 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ "requestBody" : {
+ "content" : {
+ "multipart/form-data" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "file" : {
+ "description" : ".tgz with serialization data",
+ "type" : "object",
+ "properties" : {
+ "content-type" : {
+ "type" : "string"
+ },
+ "filename" : {
+ "type" : "string"
+ },
+ "size" : {
+ "type" : "integer"
+ },
+ "tempfile" : { }
+ },
+ "required" : [ "content-type", "filename", "size", "tempfile" ],
+ "additionalProperties" : false
+ }
+ },
+ "required" : [ "file" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/serialization" ]
}
},
- "/api/ee/metabot-v3/metabot/{id}/prompt-suggestions/{prompt-id}" : {
- "delete" : {
- "summary" : "DELETE /api/ee/metabot-v3/metabot/{id}/prompt-suggestions/{prompt-id}",
- "description" : "Delete the prompt suggestion with ID `prompt-id` for the metabot instance with `id`.",
+ "/api/ee/stale/{id}" : {
+ "get" : {
+ "summary" : "GET /api/ee/stale/{id}",
+ "description" : "A flexible endpoint that returns stale entities, in the same shape as collections/items, with the following options:\n - `before_date` - only return entities that were last edited before this date (default: 6 months ago)\n - `is_recursive` - if true, return entities from all children of the collection, not just the direct children (default: false)\n - `sort_column` - the column to sort by (default: name)\n - `sort_direction` - the direction to sort by (default: asc)",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "anyOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "const" : "root"
+ } ]
}
}, {
- "in" : "path",
- "name" : "prompt-id",
+ "in" : "query",
+ "name" : "before_date",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "is_recursive",
+ "required" : true,
+ "schema" : {
+ "default" : false,
+ "type" : "boolean"
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_column",
+ "required" : true,
+ "schema" : {
+ "default" : "name",
+ "type" : "string",
+ "enum" : [ "name", "last_used_at" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
+ "default" : "asc",
+ "type" : "string",
+ "enum" : [ "asc", "desc" ]
}
} ],
"responses" : {
@@ -26670,44 +28942,21 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/metabot-v3/metabot" ]
+ "tags" : [ "/api/ee/stale" ]
}
},
- "/api/ee/permission_debug/" : {
- "get" : {
- "summary" : "GET /api/ee/permission_debug/",
- "description" : "This endpoint expects a `user_id`, a `model_id` to debug permissions against, and `action_type`.\n The type of model we are debugging against is inferred by the `action_type`.\n\n It will return:\n - `decision`: The overall permission decision (\"allow\", \"denied\", or \"limited\")\n - `model-type`: The type of model being checked (e.g., \"question\")\n - `model-id`: The ID of the model being checked\n - `segment`: A set of segmentation types applied (e.g., \"sandboxed\", \"impersonated\", \"routed\")\n - `message`: A sequence of strings explaining the decision\n - `data`: A map containing details about permissions (table or collection names to group names)\n - `suggestions`: A map of group IDs to group names that could provide access\n\n Example requests:\n - Check if user can read a card: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/read`\n - Check if user can query a card: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/query`\n - Check if user can download data: `GET /api/ee/permission_debug?user_id=123&model_id=456&action_type=card/download-data`\n\n Example responses:\n - Allowed access:\n ```json\n {\n \"decision\": \"allow\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User has permission to read this card\"],\n \"data\": {},\n \"suggestions\": {}\n }\n ```\n - Denied access with blocked table:\n ```json\n {\n \"decision\": \"denied\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User does not have permission to query this card\"],\n \"data\": {\"sample-db.PUBLIC.ORDERS\": [\"All Users\"]},\n \"suggestions\": {}\n }\n ```\n - Limited access:\n ```json\n {\n \"decision\": \"limited\",\n \"model-type\": \"question\",\n \"model-id\": \"456\",\n \"segment\": [],\n \"message\": [\"User has permission to download some data from this card\"],\n \"data\": {},\n \"suggestions\": {}\n }\n ```",
- "parameters" : [ {
- "in" : "query",
- "name" : "user_id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- }
- }, {
- "in" : "query",
- "name" : "model_id",
- "required" : true,
- "schema" : {
- "type" : "string"
- }
- }, {
- "in" : "query",
- "name" : "action_type",
- "required" : true,
- "schema" : {
- "type" : "string",
- "enum" : [ "card/read", "card/query", "card/download-data" ]
- }
- } ],
+ "/api/ee/support-access-grant/" : {
+ "post" : {
+ "summary" : "POST /api/ee/support-access-grant/",
+ "description" : "Create a new support access grant.\n\n Requires superuser permissions. Only one active grant can exist at a time.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.permission-debug.impl.perm-debug-info"
+ "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.grant-response"
}
}
}
@@ -26719,30 +28968,63 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/permission_debug" ]
- }
- },
- "/api/ee/remote-sync/branches" : {
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.create-grant-request"
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/support-access-grant" ]
+ },
"get" : {
- "summary" : "GET /api/ee/remote-sync/branches",
- "description" : "Get list of branches from the configured source.\n\n Returns a JSON object with branch names under the :items key.\n\n Requires superuser permissions.",
- "parameters" : [ ],
+ "summary" : "GET /api/ee/support-access-grant/",
+ "description" : "List support access grants with optional filtering and pagination.\n\n Requires superuser permissions.\n\n Query parameters:\n - ticket-number: Filter by ticket number\n - user-id: Filter by user who created the grant\n - include-revoked: Include revoked grants (default false)",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "ticket-number",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "user-id",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "include-revoked",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "items" : {
- "type" : "array",
- "items" : {
- "type" : "string"
- }
- }
- },
- "required" : [ "items" ]
+ "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.list-grants-response"
}
}
}
@@ -26754,13 +29036,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/support-access-grant" ]
}
},
- "/api/ee/remote-sync/create-branch" : {
- "post" : {
- "summary" : "POST /api/ee/remote-sync/create-branch",
- "description" : "Create a new branch from the current remote-sync branch and switches the current remote-sync branch to it.\n Requires superuser permissions.",
+ "/api/ee/support-access-grant/current" : {
+ "get" : {
+ "summary" : "GET /api/ee/support-access-grant/current",
+ "description" : "Get the currently active support access grant, if one exists.\n\n Requires superuser permissions.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -26768,16 +29050,7 @@
"content" : {
"application/json" : {
"schema" : {
- "type" : "object",
- "properties" : {
- "message" : {
- "type" : "string"
- },
- "status" : {
- "type" : "string"
- }
- },
- "required" : [ "status", "message" ]
+ "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.current-grant-response"
}
}
}
@@ -26789,105 +29062,30 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "name" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "name" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/support-access-grant" ]
}
},
- "/api/ee/remote-sync/current-task" : {
- "get" : {
- "summary" : "GET /api/ee/remote-sync/current-task",
- "description" : "Get the current sync task",
- "parameters" : [ ],
+ "/api/ee/support-access-grant/{id}/revoke" : {
+ "put" : {
+ "summary" : "PUT /api/ee/support-access-grant/{id}/revoke",
+ "description" : "Revoke an existing support access grant.\n\n Requires superuser permissions. Any admin can revoke any grant.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
"content" : {
"application/json" : {
"schema" : {
- "oneOf" : [ {
- "type" : "object",
- "properties" : {
- "progress" : {
- "oneOf" : [ {
- "type" : "number",
- "minimum" : 0.0,
- "maximum" : 1.0
- }, {
- "type" : "null"
- } ]
- },
- "last_progress_report_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
- "id" : {
- "type" : "integer",
- "minimum" : 1
- },
- "started_at" : { },
- "ended_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
- "initiated_by" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "cancelled" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "status" : {
- "type" : "string",
- "enum" : [ "running", "successful", "errored", "cancelled", "timed-out" ]
- },
- "error_message" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "sync_task_type" : {
- "type" : "string",
- "enum" : [ "import", "export" ]
- },
- "version" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "id", "sync_task_type", "progress", "started_at", "status" ]
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.grant-response"
}
}
}
@@ -26899,13 +29097,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/support-access-grant" ]
}
},
- "/api/ee/remote-sync/current-task/cancel" : {
+ "/api/ee/tenant/" : {
"post" : {
- "summary" : "POST /api/ee/remote-sync/current-task/cancel",
- "description" : "Cancels the current task if one is running",
+ "summary" : "POST /api/ee/tenant/",
+ "description" : "Create a new Tenant",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -26915,69 +29113,45 @@
"schema" : {
"type" : "object",
"properties" : {
- "progress" : {
+ "attributes" : {
"oneOf" : [ {
- "type" : "number",
- "minimum" : 0.0,
- "maximum" : 1.0
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string"
+ }
}, {
"type" : "null"
} ]
},
- "last_progress_report_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
"id" : {
+ "description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
},
- "started_at" : { },
- "ended_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
- "initiated_by" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "is_active" : {
+ "type" : "boolean"
},
- "cancelled" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
+ "member_count" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
},
- "status" : {
+ "name" : {
"type" : "string",
- "enum" : [ "running", "successful", "errored", "cancelled", "timed-out" ]
- },
- "error_message" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "minLength" : 1
},
- "sync_task_type" : {
+ "slug" : {
+ "description" : "invalid slug",
"type" : "string",
- "enum" : [ "import", "export" ]
+ "pattern" : "^[-_a-z0-9]{1,255}$"
},
- "version" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "tenant_collection_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "id", "sync_task_type", "progress", "started_at", "status" ]
+ "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
+ "additionalProperties" : false
}
}
}
@@ -26989,14 +29163,51 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
- }
- },
- "/api/ee/remote-sync/dirty" : {
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "attributes" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "slug" : {
+ "description" : "invalid slug",
+ "type" : "string",
+ "pattern" : "^[-_a-z0-9]{1,255}$"
+ }
+ },
+ "required" : [ "name", "slug" ],
+ "additionalProperties" : false
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/tenant" ]
+ },
"get" : {
- "summary" : "GET /api/ee/remote-sync/dirty",
- "description" : "Return all models with changes that have not been pushed to the remote sync source in any\n remote-synced collection.",
- "parameters" : [ ],
+ "summary" : "GET /api/ee/tenant/",
+ "description" : "Get all tenants",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "status",
+ "required" : true,
+ "schema" : {
+ "default" : "all",
+ "type" : "string",
+ "enum" : [ "all", "deactivated", "active" ]
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
@@ -27005,91 +29216,130 @@
"schema" : {
"type" : "object",
"properties" : {
- "dirty" : {
+ "data" : {
"type" : "array",
"items" : {
"type" : "object",
"properties" : {
- "table_name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "model" : {
- "type" : "string"
- },
- "authority_level" : {
+ "attributes" : {
"oneOf" : [ {
- "type" : "string"
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string"
+ }
}, {
"type" : "null"
} ]
},
"id" : {
+ "description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
},
- "name" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "updated_at" : {
- "oneOf" : [ { }, {
- "type" : "null"
- } ]
- },
- "table_id" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
- "query_type" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "is_active" : {
+ "type" : "boolean"
},
- "collection_id" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
+ "member_count" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
},
- "created_at" : { },
- "display" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
},
- "sync_status" : {
- "type" : "string"
+ "slug" : {
+ "description" : "invalid slug",
+ "type" : "string",
+ "pattern" : "^[-_a-z0-9]{1,255}$"
},
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "tenant_collection_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}
},
- "required" : [ "id", "name", "model", "sync_status" ]
+ "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
+ "additionalProperties" : false
}
}
},
- "required" : [ "dirty" ]
+ "required" : [ "data" ],
+ "additionalProperties" : false
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/tenant" ]
+ }
+ },
+ "/api/ee/tenant/{id}" : {
+ "put" : {
+ "summary" : "PUT /api/ee/tenant/{id}",
+ "description" : "Update a tenant, can set name, attributes, or whether this tenant is active.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "attributes" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "is_active" : {
+ "type" : "boolean"
+ },
+ "member_count" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "slug" : {
+ "description" : "invalid slug",
+ "type" : "string",
+ "pattern" : "^[-_a-z0-9]{1,255}$"
+ },
+ "tenant_collection_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
+ "additionalProperties" : false
}
}
}
@@ -27101,14 +29351,56 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
- }
- },
- "/api/ee/remote-sync/export" : {
- "post" : {
- "summary" : "POST /api/ee/remote-sync/export",
- "description" : "Export the current state of the Remote Sync collection to a Source.\n\n This endpoint will:\n - Fetch the latest changes from the source\n - Create a branch or subdirectory (depending on source support)\n If no branch is supplied, use the configured export branch\n - Export the Remote Sync collection via serialization to the branch or subdirectory\n - Commit the changes if possible\n - Sync to the source if possible\n\n Requires superuser permissions.",
- "parameters" : [ ],
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "attributes" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : { }
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "is_active" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "additionalProperties" : false
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/tenant" ]
+ },
+ "get" : {
+ "summary" : "GET /api/ee/tenant/{id}",
+ "description" : "Get info about a tenant",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
@@ -27117,15 +29409,45 @@
"schema" : {
"type" : "object",
"properties" : {
- "message" : {
- "type" : "string"
+ "attributes" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "string"
+ }
+ }, {
+ "type" : "null"
+ } ]
},
- "task_id" : {
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "is_active" : {
+ "type" : "boolean"
+ },
+ "member_count" : {
+ "description" : "value must be an integer.",
+ "type" : "integer"
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "slug" : {
+ "description" : "invalid slug",
+ "type" : "string",
+ "pattern" : "^[-_a-z0-9]{1,255}$"
+ },
+ "tenant_collection_id" : {
+ "description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
}
},
- "required" : [ "message", "task_id" ]
+ "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
+ "additionalProperties" : false
}
}
}
@@ -27137,54 +29459,130 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/tenant" ]
}
},
- "/api/ee/remote-sync/has-remote-changes" : {
+ "/api/ee/transform-job/" : {
+ "post" : {
+ "summary" : "POST /api/ee/transform-job/",
+ "description" : "Create a new transform job.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "schedule" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "tag_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "ui_display_type" : {
+ "default" : "cron/raw",
+ "type" : "string",
+ "enum" : [ "cron/raw", "cron/builder" ]
+ }
+ },
+ "required" : [ "name", "schedule", "ui_display_type" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/transform-job" ]
+ },
"get" : {
- "summary" : "GET /api/ee/remote-sync/has-remote-changes",
- "description" : "Check if there are new changes on the remote branch that can be pulled.\n Uses in-memory caching (configurable TTL via remote-sync-check-changes-cache-ttl-seconds setting).\n\n Returns:\n - has_changes: true if remote version differs from last imported version, or if never imported\n - remote_version: current Git SHA on remote branch\n - local_version: Git SHA of last successful import (nil if never imported)\n - cached: true if result was served from cache",
+ "summary" : "GET /api/ee/transform-job/",
+ "description" : "Get all transform jobs.",
"parameters" : [ {
"in" : "query",
- "name" : "force-refresh",
+ "name" : "last_run_start_time",
"required" : false,
"schema" : {
- "type" : "boolean"
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
}
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "cached" : {
- "type" : "boolean"
- },
- "has_changes" : {
- "type" : "boolean"
- },
- "local_version" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "remote_version" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "has_changes", "remote_version", "local_version", "cached" ]
- }
+ }, {
+ "in" : "query",
+ "name" : "next_run_start_time",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "last_run_statuses",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "started", "succeeded", "failed", "timeout" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "tag_ids",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
}
- }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -27193,45 +29591,26 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/transform-job" ]
}
},
- "/api/ee/remote-sync/import" : {
- "post" : {
- "summary" : "POST /api/ee/remote-sync/import",
- "description" : "Import Metabase content from configured Remote Sync source.\n\n This endpoint will:\n - Fetch the latest changes from the configured source\n - Load the updated content using the serialization/deserialization system\n\n If `force=false` (default) and there are unsaved changes in the Remote Sync collection,\n the import returns a 400 response.\n\n Requires superuser permissions.",
- "parameters" : [ ],
+ "/api/ee/transform-job/{job-id}" : {
+ "put" : {
+ "summary" : "PUT /api/ee/transform-job/{job-id}",
+ "description" : "Update a transform job.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "job-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "message" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "status" : {
- "const" : "success"
- },
- "task_id" : {
- "oneOf" : [ {
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "required" : [ "status", "task_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -27246,42 +29625,83 @@
"schema" : {
"type" : "object",
"properties" : {
- "branch" : {
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
"type" : "string",
"minLength" : 1
},
- "force" : {
- "type" : "boolean"
+ "schedule" : {
+ "type" : "string",
+ "minLength" : 1
+ },
+ "tag_ids" : {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "ui_display_type" : {
+ "type" : "string",
+ "enum" : [ "cron/raw", "cron/builder" ]
}
}
}
}
}
},
- "tags" : [ "/api/ee/remote-sync" ]
- }
- },
- "/api/ee/remote-sync/is-dirty" : {
+ "tags" : [ "/api/ee/transform-job" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/transform-job/{job-id}",
+ "description" : "Delete a transform job.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "job-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/transform-job" ]
+ },
"get" : {
- "summary" : "GET /api/ee/remote-sync/is-dirty",
- "description" : "Check if any remote-synced collection or collection item has local changes that have not been pushed\n to the remote sync source.",
- "parameters" : [ ],
+ "summary" : "GET /api/ee/transform-job/{job-id}",
+ "description" : "Get a transform job by ID.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "job-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "is_dirty" : {
- "type" : "boolean"
- }
- },
- "required" : [ "is_dirty" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -27290,34 +29710,26 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/transform-job" ]
}
},
- "/api/ee/remote-sync/settings" : {
- "put" : {
- "summary" : "PUT /api/ee/remote-sync/settings",
- "description" : "Update Remote Sync related settings. You must be a superuser to do this.",
- "parameters" : [ ],
+ "/api/ee/transform-job/{job-id}/run" : {
+ "post" : {
+ "summary" : "POST /api/ee/transform-job/{job-id}/run",
+ "description" : "Run a transform job manually.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "job-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "success" : {
- "type" : "boolean"
- },
- "task_id" : {
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "success" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -27326,101 +29738,45 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "collections" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "boolean"
- }
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-auto-import" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-branch" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-token" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-transforms" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-type" : {
- "oneOf" : [ {
- "type" : "string",
- "enum" : [ "read-only", "read-write" ]
- }, {
- "type" : "null"
- } ]
- },
- "remote-sync-url" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- }
- }
- }
+ "tags" : [ "/api/ee/transform-job" ]
+ }
+ },
+ "/api/ee/transform-job/{job-id}/transforms" : {
+ "get" : {
+ "summary" : "GET /api/ee/transform-job/{job-id}/transforms",
+ "description" : "Get the transforms of job specified by the job's ID.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "job-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/remote-sync" ]
+ "tags" : [ "/api/ee/transform-job" ]
}
},
- "/api/ee/remote-sync/stash" : {
+ "/api/ee/transform-tag/" : {
"post" : {
- "summary" : "POST /api/ee/remote-sync/stash",
- "description" : "Stashes changes to a new branch, and changes the current branch to it.\n Requires superuser permissions.",
+ "summary" : "POST /api/ee/transform-tag/",
+ "description" : "Create a new transform tag.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "message" : {
- "type" : "string"
- },
- "status" : {
- "type" : "string"
- },
- "task_id" : {
- "type" : "integer",
- "minimum" : 1
- }
- },
- "required" : [ "status", "message", "task_id" ]
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -27435,27 +29791,21 @@
"schema" : {
"type" : "object",
"properties" : {
- "message" : {
- "type" : "string",
- "minLength" : 1
- },
- "new_branch" : {
+ "name" : {
"type" : "string",
"minLength" : 1
}
},
- "required" : [ "new_branch", "message" ]
+ "required" : [ "name" ]
}
}
}
},
- "tags" : [ "/api/ee/remote-sync" ]
- }
- },
- "/api/ee/scim/api_key" : {
+ "tags" : [ "/api/ee/transform-tag" ]
+ },
"get" : {
- "summary" : "GET /api/ee/scim/api_key",
- "description" : "Fetch the SCIM API key if one exists. Does *not* return an unmasked key, since we don't have access\n to that after it is created.",
+ "summary" : "GET /api/ee/transform-tag/",
+ "description" : "Get a list of all transform tags.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -27468,12 +29818,65 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/scim" ]
+ "tags" : [ "/api/ee/transform-tag" ]
+ }
+ },
+ "/api/ee/transform-tag/{tag-id}" : {
+ "put" : {
+ "summary" : "PUT /api/ee/transform-tag/{tag-id}",
+ "description" : "Update a transform tag.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "tag-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "name" : {
+ "type" : "string",
+ "minLength" : 1
+ }
+ },
+ "required" : [ "name" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/transform-tag" ]
},
- "post" : {
- "summary" : "POST /api/ee/scim/api_key",
- "description" : "Create a new SCIM API key, or refresh one that already exists. When called for the first time,\n this is equivalent to enabling SCIM.",
- "parameters" : [ ],
+ "delete" : {
+ "summary" : "DELETE /api/ee/transform-tag/{tag-id}",
+ "description" : "Delete a transform tag. Removes it from all transforms and jobs.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "tag-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -27485,138 +29888,68 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/scim" ]
+ "tags" : [ "/api/ee/transform-tag" ]
}
},
- "/api/ee/scim/v2/Groups" : {
+ "/api/ee/transform/" : {
"get" : {
- "summary" : "GET /api/ee/scim/v2/Groups",
- "description" : "Fetch a list of groups.",
+ "summary" : "GET /api/ee/transform/",
+ "description" : "Get a list of transforms.",
"parameters" : [ {
"in" : "query",
- "name" : "startIndex",
+ "name" : "last_run_start_time",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "count",
+ "name" : "last_run_statuses",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "started", "succeeded", "failed", "timeout" ]
+ }
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "filter",
+ "name" : "tag_ids",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ }
}, {
"type" : "null"
} ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/scim/v2" ]
- },
- "post" : {
- "summary" : "POST /api/ee/scim/v2/Groups",
- "description" : "Create a single group, and populates it if necessary.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "displayName" : {
- "type" : "string",
- "minLength" : 1
- },
- "id" : {
- "type" : "string",
- "minLength" : 1
- },
- "members" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "$ref" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value" ]
- }
- },
- "schemas" : {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- }
- },
- "required" : [ "schemas", "displayName" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/scim/v2" ]
- }
- },
- "/api/ee/scim/v2/Groups/{id}" : {
- "get" : {
- "summary" : "GET /api/ee/scim/v2/Groups/{id}",
- "description" : "Fetch a single group.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
+ }
+ }, {
+ "in" : "query",
+ "name" : "database_id",
+ "required" : false,
"schema" : {
- "type" : "string",
- "minLength" : 1
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
}
} ],
"responses" : {
@@ -27630,11 +29963,11 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/scim/v2" ]
+ "tags" : [ "/api/ee/transform" ]
},
- "put" : {
- "summary" : "PUT /api/ee/scim/v2/Groups/{id}",
- "description" : "Update a group.",
+ "post" : {
+ "summary" : "POST /api/ee/transform/",
+ "description" : "Create a new transform.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -27653,58 +29986,126 @@
"schema" : {
"type" : "object",
"properties" : {
- "displayName" : {
- "type" : "string",
- "minLength" : 1
+ "owner_email" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
},
- "id" : {
- "type" : "string",
- "minLength" : 1
+ "owner_user_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
},
- "members" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "$ref" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value" ]
- }
+ "name" : {
+ "type" : "string"
},
- "schemas" : {
+ "tag_ids" : {
"type" : "array",
"items" : {
- "type" : "string",
- "minLength" : 1
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "source" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-source"
+ },
+ "target" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-target"
+ },
+ "run_trigger" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.api.run-trigger"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
},
- "required" : [ "schemas", "displayName" ]
+ "required" : [ "name", "source", "target" ]
}
}
}
},
- "tags" : [ "/api/ee/scim/v2" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/scim/v2/Groups/{id}",
- "description" : "Delete a group.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "string",
- "minLength" : 1
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/extract-columns" : {
+ "post" : {
+ "summary" : "POST /api/ee/transform/extract-columns",
+ "description" : "Extract column names suitable for incremental transform checkpoint filtering.\n\n This endpoint is specifically for populating the checkpoint column dropdown in\n incremental transforms. It only returns columns with types supported for checkpoint\n filtering: temporal (timestamp/tz) and numeric (int/float) types.\n\n Text, boolean, and other unsupported column types are filtered out.\n\n The query is compiled to native SQL using [[qp.compile/compile-with-inline-parameters]],\n which handles parameterized queries with template tags. Then extracts column names\n and types using PreparedStatement metadata.\n\n Returns a map with a :columns key containing a vector of column names (strings).\n If extraction fails, returns nil for :columns.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "columns" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string"
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "columns" ]
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- } ],
+ },
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "query" : {
+ "$ref" : "#/components/schemas/metabase.query-processor.schema.any-query"
+ }
+ },
+ "required" : [ "query" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/is-simple-query" : {
+ "post" : {
+ "summary" : "POST /api/ee/transform/is-simple-query",
+ "description" : "Checks if a native SQL query string is simple enough for automatic checkpoint insertion",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -27716,47 +30117,126 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/scim/v2" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "query" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "query" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/transform" ]
}
},
- "/api/ee/scim/v2/Users" : {
+ "/api/ee/transform/run" : {
"get" : {
- "summary" : "GET /api/ee/scim/v2/Users",
- "description" : "Fetch a list of users.",
+ "summary" : "GET /api/ee/transform/run",
+ "description" : "Get transform runs based on a set of filter params.",
"parameters" : [ {
"in" : "query",
- "name" : "startIndex",
+ "name" : "sort_column",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "transform-name", "start-time", "end-time", "status", "run-method", "transform-tags" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "sort_direction",
+ "required" : false,
+ "schema" : {
+ "type" : "string",
+ "enum" : [ "asc", "desc" ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "transform_ids",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "statuses",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "started", "succeeded", "failed", "timeout" ]
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "transform_tag_ids",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "array",
+ "items" : {
+ "description" : "value must be an integer greater or equal to than zero.",
+ "type" : "integer",
+ "minimum" : 0
+ }
+ }, {
+ "type" : "null"
+ } ]
+ }
+ }, {
+ "in" : "query",
+ "name" : "start_time",
+ "required" : false,
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "count",
+ "name" : "end_time",
"required" : false,
"schema" : {
"oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "type" : "string",
+ "minLength" : 1
}, {
"type" : "null"
} ]
}
}, {
"in" : "query",
- "name" : "filter",
+ "name" : "run_methods",
"required" : false,
"schema" : {
"oneOf" : [ {
- "type" : "string",
- "minLength" : 1
+ "type" : "array",
+ "items" : {
+ "type" : "string",
+ "enum" : [ "manual", "cron" ]
+ }
}, {
"type" : "null"
} ]
@@ -27773,147 +30253,23 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/scim/v2" ]
- },
- "post" : {
- "summary" : "POST /api/ee/scim/v2/Users",
- "description" : "Create a single user.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "active" : {
- "type" : "boolean"
- },
- "emails" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "primary" : {
- "type" : "boolean"
- },
- "type" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value" ]
- }
- },
- "groups" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "$ref" : {
- "type" : "string",
- "minLength" : 1
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value", "display" ]
- }
- },
- "id" : {
- "type" : "string",
- "minLength" : 1
- },
- "locale" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "object",
- "properties" : {
- "familyName" : {
- "type" : "string"
- },
- "givenName" : {
- "type" : "string"
- }
- },
- "required" : [ "givenName", "familyName" ]
- },
- "schemas" : {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "userName" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "schemas", "userName", "name", "emails" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/scim/v2" ]
+ "tags" : [ "/api/ee/transform" ]
}
},
- "/api/ee/scim/v2/Users/{id}" : {
+ "/api/ee/transform/{id}" : {
"get" : {
- "summary" : "GET /api/ee/scim/v2/Users/{id}",
- "description" : "Fetch a single user.",
+ "summary" : "GET /api/ee/transform/{id}",
+ "description" : "Get a specific transform.",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
+ "type" : "integer",
+ "minimum" : 1
},
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/scim/v2" ]
- },
- "put" : {
- "summary" : "PUT /api/ee/scim/v2/Users/{id}",
- "description" : "Update a user.",
- "parameters" : [ ],
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -27925,110 +30281,20 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "active" : {
- "type" : "boolean"
- },
- "emails" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "primary" : {
- "type" : "boolean"
- },
- "type" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value" ]
- }
- },
- "groups" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "$ref" : {
- "type" : "string",
- "minLength" : 1
- },
- "display" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "value", "display" ]
- }
- },
- "id" : {
- "type" : "string",
- "minLength" : 1
- },
- "locale" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "object",
- "properties" : {
- "familyName" : {
- "type" : "string"
- },
- "givenName" : {
- "type" : "string"
- }
- },
- "required" : [ "givenName", "familyName" ]
- },
- "schemas" : {
- "type" : "array",
- "items" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "userName" : {
- "type" : "string",
- "minLength" : 1
- }
- },
- "required" : [ "schemas", "userName", "name", "emails" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/scim/v2" ]
- },
- "patch" : {
- "summary" : "PATCH /api/ee/scim/v2/Users/{id}",
- "description" : "Activate or deactivate a user. Supports specific replace operations, but not arbitrary patches.",
+ "tags" : [ "/api/ee/transform" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/ee/transform/{id}",
+ "description" : "Update a transform.",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -28047,58 +30313,78 @@
"schema" : {
"type" : "object",
"properties" : {
- "Operations" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "op" : {
- "type" : "string",
- "minLength" : 1
- },
- "value" : {
- "anyOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "anyOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "boolean"
- } ]
- }
- }, {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "boolean"
- } ]
- }
- },
- "required" : [ "op", "value" ]
- }
+ "owner_email" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
},
- "schemas" : {
+ "owner_user_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "tag_ids" : {
"type" : "array",
"items" : {
- "type" : "string",
- "minLength" : 1
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
}
+ },
+ "collection_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "source" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-source"
+ },
+ "target" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-target"
+ },
+ "run_trigger" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.transforms.api.run-trigger"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
}
- },
- "required" : [ "schemas", "Operations" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/scim/v2" ]
- }
- },
- "/api/ee/semantic-search/status" : {
- "get" : {
- "summary" : "GET /api/ee/semantic-search/status",
- "description" : "Fetch the indexing status of the currently active semantic search index table.\n\n Returns a map with keys:\n :indexed_count <number of indexed items>\n :total_est <estimated total number of items to index>\n\n If no index is active, returns an empty map.",
- "parameters" : [ ],
+ "tags" : [ "/api/ee/transform" ]
+ },
+ "delete" : {
+ "summary" : "DELETE /api/ee/transform/{id}",
+ "description" : "Delete a transform.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -28110,106 +30396,178 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/semantic-search" ]
+ "tags" : [ "/api/ee/transform" ]
}
},
- "/api/ee/serialization/export" : {
+ "/api/ee/transform/{id}/cancel" : {
"post" : {
- "summary" : "POST /api/ee/serialization/export",
- "description" : "Serialize and retrieve Metabase instance.\n\n Outputs `.tar.gz` file with serialization results and an `export.log` file.\n On error outputs serialization logs directly.",
+ "summary" : "POST /api/ee/transform/{id}/cancel",
+ "description" : "Cancel the current run for a given transform.",
"parameters" : [ {
- "in" : "query",
- "name" : "dirname",
- "required" : false,
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "type" : "integer",
+ "minimum" : 1
},
- "description" : "name of directory and archive file (default: `<instance-name>-<YYYY-MM-dd_HH-mm>`)"
- }, {
- "in" : "query",
- "name" : "collection",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "string",
- "pattern" : "^.{21}$"
- }, {
- "type" : "string",
- "pattern" : "^eid:.{21}$"
- } ]
- }
- }, {
- "type" : "null"
- } ]
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
},
- "description" : "collections' db ids/entity-ids to serialize"
- }, {
- "in" : "query",
- "name" : "all_collections",
- "required" : true,
- "schema" : {
- "default" : true,
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "settings",
- "required" : true,
- "schema" : {
- "default" : true,
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "data_model",
- "required" : true,
- "schema" : {
- "default" : true,
- "type" : "boolean"
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "field_values",
+ },
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/{id}/dependencies" : {
+ "get" : {
+ "summary" : "GET /api/ee/transform/{id}/dependencies",
+ "description" : "Get the dependencies of a specific transform.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : false,
- "type" : "boolean"
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "database_secrets",
+ },
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/{id}/merge-history" : {
+ "get" : {
+ "summary" : "GET /api/ee/transform/{id}/merge-history",
+ "description" : "Get merge history for a transform. Returns all merge events that affected this transform,\n ordered by created_at descending (newest first).",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : false,
- "type" : "boolean"
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "commit_message" : {
+ "type" : "string"
+ },
+ "created_at" : { },
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "merging_user_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "workspace_id" : {
+ "oneOf" : [ {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "workspace_merge_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "workspace_name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "id", "workspace_merge_id", "commit_message", "workspace_id", "workspace_name", "merging_user_id", "created_at" ]
+ }
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "continue_on_error",
+ },
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/{id}/run" : {
+ "post" : {
+ "summary" : "POST /api/ee/transform/{id}/run",
+ "description" : "Run a transform.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : false,
- "type" : "boolean"
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "full_stacktrace",
+ },
+ "tags" : [ "/api/ee/transform" ]
+ }
+ },
+ "/api/ee/transform/{id}/table" : {
+ "delete" : {
+ "summary" : "DELETE /api/ee/transform/{id}/table",
+ "description" : "Delete a transform's output table.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "id",
"required" : true,
"schema" : {
- "default" : false,
- "type" : "boolean"
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -28222,36 +30580,45 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/serialization" ]
+ "tags" : [ "/api/ee/transform" ]
}
},
- "/api/ee/serialization/import" : {
- "post" : {
- "summary" : "POST /api/ee/serialization/import",
- "description" : "Deserialize Metabase instance from an archive generated by /export.\n\n Parameters:\n - `file`: archive encoded as `multipart/form-data` (required).\n\n Returns logs of deserialization.",
+ "/api/ee/transforms-python/library/{path}" : {
+ "get" : {
+ "summary" : "GET /api/ee/transforms-python/library/{path}",
+ "description" : "Get the Python library for user modules.",
"parameters" : [ {
- "in" : "query",
- "name" : "continue_on_error",
+ "in" : "path",
+ "name" : "path",
"required" : true,
"schema" : {
- "default" : false,
- "type" : "boolean"
+ "type" : "string",
+ "minLength" : 1
}
- }, {
- "in" : "query",
- "name" : "full_stacktrace",
- "required" : true,
- "schema" : {
- "default" : false,
- "type" : "boolean"
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response"
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
- }, {
- "in" : "query",
- "name" : "reindex",
+ },
+ "tags" : [ "/api/ee/transforms-python" ]
+ },
+ "put" : {
+ "summary" : "PUT /api/ee/transforms-python/library/{path}",
+ "description" : "Update the Python library source code for user modules.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "path",
"required" : true,
"schema" : {
- "default" : true,
- "type" : "boolean"
+ "type" : "string",
+ "minLength" : 1
}
} ],
"responses" : {
@@ -28267,95 +30634,75 @@
},
"requestBody" : {
"content" : {
- "multipart/form-data" : {
+ "application/json" : {
"schema" : {
"type" : "object",
"properties" : {
- "file" : {
- "description" : ".tgz with serialization data",
- "type" : "object",
- "properties" : {
- "content-type" : {
- "type" : "string"
- },
- "filename" : {
- "type" : "string"
- },
- "size" : {
- "type" : "integer"
- },
- "tempfile" : { }
- },
- "required" : [ "content-type", "filename", "size", "tempfile" ],
- "additionalProperties" : false
+ "source" : {
+ "type" : "string"
}
},
- "required" : [ "file" ]
+ "required" : [ "source" ],
+ "additionalProperties" : false
}
}
}
},
- "tags" : [ "/api/ee/serialization" ]
+ "tags" : [ "/api/ee/transforms-python" ]
}
},
- "/api/ee/stale/{id}" : {
- "get" : {
- "summary" : "GET /api/ee/stale/{id}",
- "description" : "A flexible endpoint that returns stale entities, in the same shape as collections/items, with the following options:\n - `before_date` - only return entities that were last edited before this date (default: 6 months ago)\n - `is_recursive` - if true, return entities from all children of the collection, not just the direct children (default: false)\n - `sort_column` - the column to sort by (default: name)\n - `sort_direction` - the direction to sort by (default: asc)",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "anyOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "const" : "root"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "before_date",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "is_recursive",
- "required" : true,
- "schema" : {
- "default" : false,
- "type" : "boolean"
- }
- }, {
- "in" : "query",
- "name" : "sort_column",
- "required" : true,
- "schema" : {
- "default" : "name",
- "type" : "string",
- "enum" : [ "name", "last_used_at" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : true,
- "schema" : {
- "default" : "asc",
- "type" : "string",
- "enum" : [ "asc", "desc" ]
- }
- } ],
+ "/api/ee/transforms-python/test-run" : {
+ "post" : {
+ "summary" : "POST /api/ee/transforms-python/test-run",
+ "description" : "Evaluate an ad-hoc python transform on a sample of input data.\n Intended for short runs for early feedback. Input/output/timeout limits apply.",
+ "parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "error" : {
+ "type" : "object",
+ "properties" : {
+ "message" : {
+ "anyOf" : [ { }, { } ]
+ }
+ },
+ "required" : [ "message" ]
+ },
+ "logs" : {
+ "type" : "string"
+ },
+ "output" : {
+ "type" : "object",
+ "properties" : {
+ "cols" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "name" ]
+ }
+ },
+ "rows" : {
+ "type" : "array",
+ "items" : { }
+ }
+ },
+ "required" : [ "cols", "rows" ]
+ }
+ },
+ "required" : [ "logs" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -28364,24 +30711,61 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/stale" ]
+ "requestBody" : {
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "code" : {
+ "type" : "string"
+ },
+ "output_row_limit" : {
+ "allOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "number",
+ "exclusiveMinimum" : 1
+ }, {
+ "type" : "number",
+ "maximum" : 100
+ } ]
+ },
+ "per_input_row_limit" : {
+ "allOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "number",
+ "exclusiveMinimum" : 1
+ }, {
+ "type" : "number",
+ "maximum" : 100
+ } ]
+ },
+ "source_tables" : {
+ "type" : "object",
+ "additionalProperties" : {
+ "type" : "integer"
+ },
+ "minProperties" : 1
+ }
+ },
+ "required" : [ "code", "source_tables" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/transforms-python" ]
}
},
- "/api/ee/support-access-grant/" : {
- "post" : {
- "summary" : "POST /api/ee/support-access-grant/",
- "description" : "Create a new support access grant.\n\n Requires superuser permissions. Only one active grant can exist at a time.",
+ "/api/ee/upload-management/tables" : {
+ "get" : {
+ "summary" : "GET /api/ee/upload-management/tables",
+ "description" : "Get all `Tables` visible to the current user which were created by uploading a file.",
"parameters" : [ ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.grant-response"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -28390,49 +30774,28 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.create-grant-request"
- }
- }
- }
- },
- "tags" : [ "/api/ee/support-access-grant" ]
- },
- "get" : {
- "summary" : "GET /api/ee/support-access-grant/",
- "description" : "List support access grants with optional filtering and pagination.\n\n Requires superuser permissions.\n\n Query parameters:\n - ticket-number: Filter by ticket number\n - user-id: Filter by user who created the grant\n - include-revoked: Include revoked grants (default false)",
+ "tags" : [ "/api/ee/upload-management" ]
+ }
+ },
+ "/api/ee/upload-management/tables/{id}" : {
+ "delete" : {
+ "summary" : "DELETE /api/ee/upload-management/tables/{id}",
+ "description" : "Delete the uploaded table from the database, optionally archiving cards for which it is the primary source.",
"parameters" : [ {
- "in" : "query",
- "name" : "ticket-number",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "user-id",
- "required" : false,
+ "in" : "path",
+ "name" : "id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
}, {
"in" : "query",
- "name" : "include-revoked",
+ "name" : "archive-cards",
"required" : false,
"schema" : {
+ "default" : false,
"oneOf" : [ {
"type" : "boolean"
}, {
@@ -28442,14 +30805,7 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.list-grants-response"
- }
- }
- }
+ "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -28458,13 +30814,13 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/support-access-grant" ]
+ "tags" : [ "/api/ee/upload-management" ]
}
},
- "/api/ee/support-access-grant/current" : {
+ "/api/ee/workspace/" : {
"get" : {
- "summary" : "GET /api/ee/support-access-grant/current",
- "description" : "Get the currently active support access grant, if one exists.\n\n Requires superuser permissions.",
+ "summary" : "GET /api/ee/workspace/",
+ "description" : "Get a list of all workspaces",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -28472,42 +30828,51 @@
"content" : {
"application/json" : {
"schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.current-grant-response"
- }
- }
- }
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/support-access-grant" ]
- }
- },
- "/api/ee/support-access-grant/{id}/revoke" : {
- "put" : {
- "summary" : "PUT /api/ee/support-access-grant/{id}/revoke",
- "description" : "Revoke an existing support access grant.\n\n Requires superuser permissions. Any admin can revoke any grant.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response",
- "content" : {
- "application/json" : {
- "schema" : {
- "$ref" : "#/components/schemas/metabase-enterprise.support-access-grants.schema.grant-response"
+ "type" : "object",
+ "properties" : {
+ "items" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
+ },
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
+ }
+ },
+ "required" : [ "id", "database_id", "name", "status", "updated_at" ],
+ "additionalProperties" : false
+ }
+ },
+ "limit" : {
+ "oneOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "offset" : {
+ "oneOf" : [ {
+ "type" : "integer"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "items", "limit", "offset" ],
+ "additionalProperties" : false
}
}
}
@@ -28519,13 +30884,11 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/support-access-grant" ]
- }
- },
- "/api/ee/tenant/" : {
+ "tags" : [ "/api/ee/workspace" ]
+ },
"post" : {
- "summary" : "POST /api/ee/tenant/",
- "description" : "Create a new Tenant",
+ "summary" : "POST /api/ee/workspace/",
+ "description" : "Create a new workspace\n\n Potential payload:\n {:name \"a\" :database_id 2}}",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -28535,45 +30898,31 @@
"schema" : {
"type" : "object",
"properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "string"
- }
- }, {
- "type" : "null"
- } ]
+ "collection_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "created_at" : {
+ "type" : "string",
+ "format" : "date-time"
},
- "is_active" : {
- "type" : "boolean"
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "member_count" : {
- "description" : "value must be an integer.",
- "type" : "integer"
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
},
- "slug" : {
- "description" : "invalid slug",
- "type" : "string",
- "pattern" : "^[-_a-z0-9]{1,255}$"
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
},
- "tenant_collection_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
}
},
- "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
- "additionalProperties" : false
+ "required" : [ "id", "name", "collection_id", "database_id", "status", "created_at", "updated_at" ]
}
}
}
@@ -28591,44 +30940,34 @@
"schema" : {
"type" : "object",
"properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : { }
- }, {
- "type" : "null"
- } ]
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
"type" : "string",
"minLength" : 1
- },
- "slug" : {
- "description" : "invalid slug",
- "type" : "string",
- "pattern" : "^[-_a-z0-9]{1,255}$"
}
- },
- "required" : [ "name", "slug" ],
- "additionalProperties" : false
+ }
}
}
}
},
- "tags" : [ "/api/ee/tenant" ]
- },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/checkout" : {
"get" : {
- "summary" : "GET /api/ee/tenant/",
- "description" : "Get all tenants",
+ "summary" : "GET /api/ee/workspace/checkout",
+ "description" : "Get checkout status for a global transform.\n\n Returns:\n - checkout_disabled: Why this transform cannot be checked out (nil if allowed)\n - workspaces: All workspaces for this transform's database, with checkout status\n - transforms: (DEPRECATED) Use :workspaces instead",
"parameters" : [ {
"in" : "query",
- "name" : "status",
+ "name" : "transform-id",
"required" : true,
"schema" : {
- "default" : "all",
- "type" : "string",
- "enum" : [ "all", "deactivated", "active" ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
@@ -28638,55 +30977,143 @@
"schema" : {
"type" : "object",
"properties" : {
- "data" : {
+ "checkout_disabled" : {
+ "oneOf" : [ {
+ "type" : "string",
+ "enum" : [ "mbql", "card-reference", "unknown-type" ]
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "transforms" : {
"type" : "array",
"items" : {
"type" : "object",
"properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "workspace" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "name" : {
"type" : "string"
}
+ },
+ "required" : [ "id", "name" ]
+ }
+ },
+ "required" : [ "id", "name", "workspace" ]
+ }
+ },
+ "workspaces" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "existing" : {
+ "oneOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "name" : {
+ "type" : "string"
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ },
+ "required" : [ "ref_id", "name" ]
}, {
"type" : "null"
} ]
},
"id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- },
- "is_active" : {
- "type" : "boolean"
- },
- "member_count" : {
- "description" : "value must be an integer.",
- "type" : "integer"
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
},
- "slug" : {
- "description" : "invalid slug",
- "type" : "string",
- "pattern" : "^[-_a-z0-9]{1,255}$"
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
+ }
+ },
+ "required" : [ "id", "name", "status", "existing" ]
+ }
+ }
+ },
+ "required" : [ "checkout_disabled", "workspaces", "transforms" ]
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/database" : {
+ "get" : {
+ "summary" : "GET /api/ee/workspace/database",
+ "description" : "Get a list supported databases, and whether they're enabled and have required permissions.",
+ "parameters" : [ ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "databases" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "enabled" : {
+ "type" : "boolean"
},
- "tenant_collection_id" : {
+ "id" : {
"description" : "value must be an integer greater than zero.",
"type" : "integer",
"minimum" : 1
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "permissions_status" : {
+ "type" : "object",
+ "properties" : {
+ "checked_at" : {
+ "type" : "string"
+ },
+ "error" : {
+ "type" : "string"
+ },
+ "status" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "status", "checked_at" ]
}
},
- "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
- "additionalProperties" : false
+ "required" : [ "id", "name", "enabled" ]
}
}
},
- "required" : [ "data" ],
- "additionalProperties" : false
+ "required" : [ "databases" ]
}
}
}
@@ -28698,16 +31125,60 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/tenant" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/tenant/{id}" : {
- "put" : {
- "summary" : "PUT /api/ee/tenant/{id}",
- "description" : "Update a tenant, can set name, attributes, or whether this tenant is active.",
+ "/api/ee/workspace/enabled" : {
+ "get" : {
+ "summary" : "GET /api/ee/workspace/enabled",
+ "description" : "Test whether the current user can use Workspaces. Optionally takes a specific database.\n Factors include: driver support, database user privileges, metabase permissions.",
+ "parameters" : [ {
+ "in" : "query",
+ "name" : "database-id",
+ "required" : false,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "reason" : {
+ "type" : "string"
+ },
+ "supported" : {
+ "type" : "boolean"
+ }
+ },
+ "required" : [ "supported" ]
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}" : {
+ "get" : {
+ "summary" : "GET /api/ee/workspace/{ws-id}",
+ "description" : "Get a single workspace by ID",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -28723,45 +31194,31 @@
"schema" : {
"type" : "object",
"properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "string"
- }
- }, {
- "type" : "null"
- } ]
+ "collection_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "created_at" : {
+ "type" : "string",
+ "format" : "date-time"
},
- "is_active" : {
- "type" : "boolean"
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "member_count" : {
- "description" : "value must be an integer.",
- "type" : "integer"
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
},
- "slug" : {
- "description" : "invalid slug",
- "type" : "string",
- "pattern" : "^[-_a-z0-9]{1,255}$"
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
},
- "tenant_collection_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
}
},
- "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
- "additionalProperties" : false
+ "required" : [ "id", "name", "collection_id", "database_id", "status", "created_at", "updated_at" ]
}
}
}
@@ -28770,52 +31227,17 @@
"description" : "Client error response"
},
"5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : { }
- }, {
- "type" : "null"
- } ]
- },
- "is_active" : {
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- },
- "additionalProperties" : false
- }
- }
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/tenant" ]
+ "tags" : [ "/api/ee/workspace" ]
},
- "get" : {
- "summary" : "GET /api/ee/tenant/{id}",
- "description" : "Get info about a tenant",
+ "put" : {
+ "summary" : "PUT /api/ee/workspace/{ws-id}",
+ "description" : "Update simple workspace properties.\n\n Can set database_id only on uninitialized workspaces.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -28831,45 +31253,31 @@
"schema" : {
"type" : "object",
"properties" : {
- "attributes" : {
- "oneOf" : [ {
- "type" : "object",
- "additionalProperties" : {
- "type" : "string"
- }
- }, {
- "type" : "null"
- } ]
+ "collection_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "created_at" : {
+ "type" : "string",
+ "format" : "date-time"
},
- "is_active" : {
- "type" : "boolean"
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
- "member_count" : {
- "description" : "value must be an integer.",
- "type" : "integer"
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
- "type" : "string",
- "minLength" : 1
+ "type" : "string"
},
- "slug" : {
- "description" : "invalid slug",
- "type" : "string",
- "pattern" : "^[-_a-z0-9]{1,255}$"
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
},
- "tenant_collection_id" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
}
},
- "required" : [ "id", "name", "slug", "is_active", "member_count", "attributes", "tenant_collection_id" ],
- "additionalProperties" : false
+ "required" : [ "id", "name", "collection_id", "database_id", "status", "created_at", "updated_at" ]
}
}
}
@@ -28881,130 +31289,56 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/tenant" ]
- }
- },
- "/api/ee/transform-job/" : {
- "post" : {
- "summary" : "POST /api/ee/transform-job/",
- "description" : "Create a new transform job.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
- "description" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
},
"name" : {
"type" : "string",
"minLength" : 1
- },
- "schedule" : {
- "type" : "string",
- "minLength" : 1
- },
- "tag_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "ui_display_type" : {
- "default" : "cron/raw",
- "type" : "string",
- "enum" : [ "cron/raw", "cron/builder" ]
}
},
- "required" : [ "name", "schedule", "ui_display_type" ]
+ "additionalProperties" : false
}
}
}
},
- "tags" : [ "/api/ee/transform-job" ]
+ "tags" : [ "/api/ee/workspace" ]
},
- "get" : {
- "summary" : "GET /api/ee/transform-job/",
- "description" : "Get all transform jobs.",
+ "delete" : {
+ "summary" : "DELETE /api/ee/workspace/{ws-id}",
+ "description" : "Delete a workspace and all its contents, including mirrored entities.",
"parameters" : [ {
- "in" : "query",
- "name" : "last_run_start_time",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "next_run_start_time",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "last_run_statuses",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "started", "succeeded", "failed", "timeout" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "tag_ids",
- "required" : false,
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
- }
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "ok" : {
+ "const" : true
+ }
+ },
+ "required" : [ "ok" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29013,16 +31347,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-job" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform-job/{job-id}" : {
- "put" : {
- "summary" : "PUT /api/ee/transform-job/{job-id}",
- "description" : "Update a transform job.",
+ "/api/ee/workspace/{ws-id}/archive" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/archive",
+ "description" : "Archive a workspace. Deletes the isolated schema and tables, but preserves mirrored entities.",
"parameters" : [ {
"in" : "path",
- "name" : "job-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -29032,72 +31366,40 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "description" : {
- "oneOf" : [ {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "collection_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "created_at" : {
"type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- },
- "name" : {
- "type" : "string",
- "minLength" : 1
- },
- "schedule" : {
- "type" : "string",
- "minLength" : 1
- },
- "tag_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
+ "format" : "date-time"
+ },
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
+ },
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
}
},
- "ui_display_type" : {
- "type" : "string",
- "enum" : [ "cron/raw", "cron/builder" ]
- }
+ "required" : [ "id", "name", "collection_id", "database_id", "status", "created_at", "updated_at" ]
}
}
}
- }
- },
- "tags" : [ "/api/ee/transform-job" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/transform-job/{job-id}",
- "description" : "Delete a transform job.",
- "parameters" : [ {
- "in" : "path",
- "name" : "job-id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
@@ -29106,24 +31408,66 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-job" ]
- },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}/external/transform" : {
"get" : {
- "summary" : "GET /api/ee/transform-job/{job-id}",
- "description" : "Get a transform job by ID.",
+ "summary" : "GET /api/ee/workspace/{ws-id}/external/transform",
+ "description" : "Get transforms that are external to the workspace, i.e. no matching workspace_transform row exists.",
"parameters" : [ {
"in" : "path",
- "name" : "job-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "query",
+ "name" : "database-id",
+ "required" : false,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "transforms" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "checkout_disabled" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "source_type" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "id", "name", "source_type", "checkout_disabled" ]
+ }
+ }
+ },
+ "required" : [ "transforms" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29132,16 +31476,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-job" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform-job/{job-id}/run" : {
- "post" : {
- "summary" : "POST /api/ee/transform-job/{job-id}/run",
- "description" : "Run a transform job manually.",
+ "/api/ee/workspace/{ws-id}/graph" : {
+ "get" : {
+ "summary" : "GET /api/ee/workspace/{ws-id}/graph",
+ "description" : "Display the dependency graph between the Changeset and the (potentially external) entities that they depend on.",
"parameters" : [ {
"in" : "path",
- "name" : "job-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -29151,7 +31495,29 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "edges" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.graph-edge"
+ }
+ },
+ "nodes" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.graph-node"
+ }
+ }
+ },
+ "required" : [ "nodes", "edges" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29160,16 +31526,16 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-job" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform-job/{job-id}/transforms" : {
+ "/api/ee/workspace/{ws-id}/log" : {
"get" : {
- "summary" : "GET /api/ee/transform-job/{job-id}/transforms",
- "description" : "Get the transforms of job specified by the job's ID.",
+ "summary" : "GET /api/ee/workspace/{ws-id}/log",
+ "description" : "Get workspace creation status and recent log entries for polling during async setup",
"parameters" : [ {
"in" : "path",
- "name" : "job-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -29179,7 +31545,70 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "last_completed_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "logs" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "completed_at" : {
+ "oneOf" : [ { }, {
+ "type" : "null"
+ } ]
+ },
+ "description" : { },
+ "id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "message" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "started_at" : { },
+ "status" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "task" : {
+ "type" : "string"
+ },
+ "updated_at" : { }
+ },
+ "required" : [ "id", "task", "description", "started_at", "updated_at", "completed_at", "status", "message" ]
+ }
+ },
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
+ },
+ "updated_at" : { },
+ "workspace_id" : {
+ "description" : "value must be an integer greater than zero.",
+ "type" : "integer",
+ "minimum" : 1
+ }
+ },
+ "required" : [ "workspace_id", "status", "updated_at", "last_completed_at", "logs" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29188,17 +31617,102 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-job" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform-tag/" : {
+ "/api/ee/workspace/{ws-id}/merge" : {
"post" : {
- "summary" : "POST /api/ee/transform-tag/",
- "description" : "Create a new transform tag.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/workspace/{ws-id}/merge",
+ "description" : "This will:\n 1. Update original transforms with workspace versions\n 2. Archive the workspace and clean up isolated resources\n Returns a report of merged entities, or error in errors key.\n\n Request body may include:\n - commit-message: A description of what changes are being merged (optional, will be required in future)",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "anyOf" : [ {
+ "type" : "object",
+ "properties" : {
+ "errors" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "op" : {
+ "type" : "string",
+ "enum" : [ "create", "delete", "update", "noop" ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ },
+ "required" : [ "op", "ref_id" ]
+ }
+ },
+ "merged" : {
+ "type" : "object",
+ "properties" : {
+ "transforms" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "op" : {
+ "type" : "string",
+ "enum" : [ "create", "delete", "update", "noop" ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ },
+ "required" : [ "op", "ref_id" ]
+ }
+ }
+ },
+ "required" : [ "transforms" ]
+ },
+ "workspace" : {
+ "type" : "object",
+ "properties" : {
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "id", "name" ]
+ }
+ },
+ "required" : [ "merged", "errors", "workspace" ]
+ }, {
+ "type" : "string"
+ } ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29213,25 +31727,45 @@
"schema" : {
"type" : "object",
"properties" : {
- "name" : {
+ "commit-message" : {
"type" : "string",
"minLength" : 1
}
- },
- "required" : [ "name" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/transform-tag" ]
- },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}/problem" : {
"get" : {
- "summary" : "GET /api/ee/transform-tag/",
- "description" : "Get a list of all transform tags.",
- "parameters" : [ ],
+ "summary" : "GET /api/ee/workspace/{ws-id}/problem",
+ "description" : "Detect problems in the workspace that would affect downstream transforms after merge.\n\n Returns a list of problems, each with:\n - category: the problem category (e.g. 'unused', 'internal-downstream', 'external-downstream')\n - problem: the specific problem (e.g. 'not-run', 'stale', 'removed-field')\n - severity: :error, :warning, or :info\n - block-merge: whether this problem prevents merging\n - data: extra information, shape depends on the problem type\n\n See `metabase-enterprise.workspaces.types/problem-types` for the full list.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "type" : "integer",
+ "minimum" : 1
+ },
+ "description" : "value must be an integer greater than zero."
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.problem"
+ }
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29240,26 +31774,52 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-tag" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform-tag/{tag-id}" : {
- "put" : {
- "summary" : "PUT /api/ee/transform-tag/{tag-id}",
- "description" : "Update a transform tag.",
+ "/api/ee/workspace/{ws-id}/run" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/run",
+ "description" : "Execute all transforms in the workspace in dependency order.\n Returns which transforms succeeded, failed, and were not run.",
"parameters" : [ {
"in" : "path",
- "name" : "tag-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "failed" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ },
+ "not_run" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ },
+ "succeeded" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ }
+ },
+ "required" : [ "succeeded", "failed", "not_run" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29274,24 +31834,28 @@
"schema" : {
"type" : "object",
"properties" : {
- "name" : {
- "type" : "string",
- "minLength" : 1
+ "stale_only" : {
+ "anyOf" : [ {
+ "const" : 1
+ }, {
+ "type" : "boolean"
+ } ]
}
- },
- "required" : [ "name" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/transform-tag" ]
- },
- "delete" : {
- "summary" : "DELETE /api/ee/transform-tag/{tag-id}",
- "description" : "Delete a transform tag. Removes it from all transforms and jobs.",
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}/table" : {
+ "get" : {
+ "summary" : "GET /api/ee/workspace/{ws-id}/table",
+ "description" : "Get workspace tables",
"parameters" : [ {
"in" : "path",
- "name" : "tag-id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
@@ -29301,7 +31865,30 @@
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "inputs" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.input-table"
+ }
+ },
+ "outputs" : {
+ "type" : "array",
+ "items" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.output-table"
+ }
+ }
+ },
+ "required" : [ "inputs", "outputs" ],
+ "additionalProperties" : false
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29310,77 +31897,97 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform-tag" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform/" : {
- "get" : {
- "summary" : "GET /api/ee/transform/",
- "description" : "Get a list of transforms.",
+ "/api/ee/workspace/{ws-id}/transform" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform",
+ "description" : "Add another transform to the Changeset. This could be a fork of an existing global transform, or something new.",
"parameters" : [ {
- "in" : "query",
- "name" : "last_run_start_time",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "last_run_statuses",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "started", "succeeded", "failed", "timeout" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "tag_ids",
- "required" : false,
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/transform" ]
- },
- "post" : {
- "summary" : "POST /api/ee/transform/",
- "description" : "Create a new transform.",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "last_run_at" : { },
+ "target_stale" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "last_run_status" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "workspace_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "updated_at" : { },
+ "archived_at" : { },
+ "source" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "last_run_message" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "target" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "created_at" : { },
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "creator_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "ref_id", "global_id", "name", "description", "source", "target", "target_stale", "workspace_id", "creator_id", "archived_at", "created_at", "updated_at", "last_run_at", "last_run_status", "last_run_message" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29395,72 +32002,118 @@
"schema" : {
"type" : "object",
"properties" : {
- "owner_email" : {
+ "description" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "owner_user_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
"name" : {
"type" : "string"
},
- "tag_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
"source" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-source"
- },
- "target" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-target"
- },
- "run_trigger" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.api.run-trigger"
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.transform-source"
}
},
- "required" : [ "name", "source", "target" ]
+ "required" : [ "name", "source" ]
+ }
+ }
+ }
+ },
+ "tags" : [ "/api/ee/workspace" ]
+ },
+ "get" : {
+ "summary" : "GET /api/ee/workspace/{ws-id}/transform",
+ "description" : "Get all transforms in a workspace.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "transforms" : {
+ "type" : "array",
+ "items" : {
+ "type" : "object",
+ "properties" : {
+ "creator_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ },
+ "source_type" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "ref_id", "global_id", "name", "source_type", "creator_id" ],
+ "additionalProperties" : false
+ }
+ }
+ },
+ "required" : [ "transforms" ]
+ }
}
}
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform/extract-columns" : {
+ "/api/ee/workspace/{ws-id}/transform/validate/target" : {
"post" : {
- "summary" : "POST /api/ee/transform/extract-columns",
- "description" : "Extract column names suitable for incremental transform checkpoint filtering.\n\n This endpoint is specifically for populating the checkpoint column dropdown in\n incremental transforms. It only returns columns with types supported for checkpoint\n filtering: temporal (timestamp/tz) and numeric (int/float) types.\n\n Text, boolean, and other unsupported column types are filtered out.\n\n The query is compiled to native SQL using [[qp.compile/compile-with-inline-parameters]],\n which handles parameterized queries with template tags. Then extracts column names\n and types using PreparedStatement metadata.\n\n Returns a map with a :columns key containing a vector of column names (strings).\n If extraction fails, returns nil for :columns.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/validate/target",
+ "description" : "Validate the target table for a workspace transform",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "query",
+ "name" : "transform-id",
+ "required" : false,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
@@ -29469,18 +32122,18 @@
"schema" : {
"type" : "object",
"properties" : {
- "columns" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string"
- }
+ "body" : {
+ "anyOf" : [ {
+ "type" : "string"
}, {
- "type" : "null"
+ "anyOf" : [ { }, { } ]
} ]
+ },
+ "status" : {
+ "type" : "integer"
}
},
- "required" : [ "columns" ]
+ "required" : [ "status", "body" ]
}
}
}
@@ -29498,190 +32151,135 @@
"schema" : {
"type" : "object",
"properties" : {
- "query" : {
- "$ref" : "#/components/schemas/metabase.query-processor.schema.any-query"
- }
- },
- "required" : [ "query" ]
- }
- }
- }
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/is-simple-query" : {
- "post" : {
- "summary" : "POST /api/ee/transform/is-simple-query",
- "description" : "Checks if a native SQL query string is simple enough for automatic checkpoint insertion",
- "parameters" : [ ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "query" : {
- "type" : "string"
+ "db_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "target" : {
+ "type" : "object",
+ "properties" : {
+ "database" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "schema" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "type" : {
+ "type" : "string"
+ }
+ },
+ "required" : [ "type", "schema", "name" ]
}
},
- "required" : [ "query" ]
+ "required" : [ "target" ]
}
}
}
},
- "tags" : [ "/api/ee/transform" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transform/run" : {
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}" : {
"get" : {
- "summary" : "GET /api/ee/transform/run",
- "description" : "Get transform runs based on a set of filter params.",
+ "summary" : "GET /api/ee/workspace/{ws-id}/transform/{tx-id}",
+ "description" : "Get a specific transform in a workspace.",
"parameters" : [ {
- "in" : "query",
- "name" : "sort_column",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "transform-name", "start-time", "end-time", "status", "run-method", "transform-tags" ]
- }
- }, {
- "in" : "query",
- "name" : "sort_direction",
- "required" : false,
- "schema" : {
- "type" : "string",
- "enum" : [ "asc", "desc" ]
- }
- }, {
- "in" : "query",
- "name" : "transform_ids",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "statuses",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "started", "succeeded", "failed", "timeout" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "transform_tag_ids",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater or equal to than zero.",
- "type" : "integer",
- "minimum" : 0
- }
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "start_time",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
- }
- }, {
- "in" : "query",
- "name" : "end_time",
- "required" : false,
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
"schema" : {
- "oneOf" : [ {
- "type" : "string",
- "minLength" : 1
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
}
}, {
- "in" : "query",
- "name" : "run_methods",
- "required" : false,
- "schema" : {
- "oneOf" : [ {
- "type" : "array",
- "items" : {
- "type" : "string",
- "enum" : [ "manual", "cron" ]
- }
- }, {
- "type" : "null"
- } ]
- }
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/{id}" : {
- "get" : {
- "summary" : "GET /api/ee/transform/{id}",
- "description" : "Get a specific transform.",
- "parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "tx-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "last_run_at" : { },
+ "target_stale" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "last_run_status" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "workspace_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "updated_at" : { },
+ "archived_at" : { },
+ "source" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "last_run_message" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "target" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "created_at" : { },
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "creator_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "ref_id", "global_id", "name", "description", "source", "target", "target_stale", "workspace_id", "creator_id", "archived_at", "created_at", "updated_at", "last_run_at", "last_run_status", "last_run_message" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29690,24 +32288,102 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform" ]
+ "tags" : [ "/api/ee/workspace" ]
},
"put" : {
- "summary" : "PUT /api/ee/transform/{id}",
- "description" : "Update a transform.",
+ "summary" : "PUT /api/ee/workspace/{ws-id}/transform/{tx-id}",
+ "description" : "Update a transform in a workspace.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "last_run_at" : { },
+ "target_stale" : {
+ "oneOf" : [ {
+ "type" : "boolean"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "last_run_status" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "workspace_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "updated_at" : { },
+ "archived_at" : { },
+ "source" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "last_run_message" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "target" : {
+ "type" : "object",
+ "properties" : { }
+ },
+ "created_at" : { },
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "creator_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ },
+ "description" : {
+ "oneOf" : [ {
+ "type" : "string"
+ }, {
+ "type" : "null"
+ } ]
+ }
+ },
+ "required" : [ "ref_id", "global_id", "name", "description", "source", "target", "target_stale", "workspace_id", "creator_id", "archived_at", "created_at", "updated_at", "last_run_at", "last_run_status", "last_run_message" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29722,193 +32398,57 @@
"schema" : {
"type" : "object",
"properties" : {
- "owner_email" : {
+ "description" : {
"oneOf" : [ {
"type" : "string"
}, {
"type" : "null"
} ]
},
- "owner_user_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
"name" : {
"type" : "string"
},
- "tag_ids" : {
- "type" : "array",
- "items" : {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }
- },
- "collection_id" : {
- "oneOf" : [ {
- "description" : "value must be an integer greater than zero.",
- "type" : "integer",
- "minimum" : 1
- }, {
- "type" : "null"
- } ]
- },
"source" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-source"
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.transform-source"
},
"target" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.schema.transform-target"
- },
- "run_trigger" : {
- "$ref" : "#/components/schemas/metabase-enterprise.transforms.api.run-trigger"
- },
- "description" : {
- "oneOf" : [ {
- "type" : "string"
- }, {
- "type" : "null"
- } ]
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.transform-target"
}
}
}
}
}
},
- "tags" : [ "/api/ee/transform" ]
+ "tags" : [ "/api/ee/workspace" ]
},
"delete" : {
- "summary" : "DELETE /api/ee/transform/{id}",
- "description" : "Delete a transform.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/{id}/cancel" : {
- "post" : {
- "summary" : "POST /api/ee/transform/{id}/cancel",
- "description" : "Cancel the current run for a given transform.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
- }
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/{id}/dependencies" : {
- "get" : {
- "summary" : "GET /api/ee/transform/{id}/dependencies",
- "description" : "Get the dependencies of a specific transform.",
+ "summary" : "DELETE /api/ee/workspace/{ws-id}/transform/{tx-id}",
+ "description" : "Discard a transform from the changeset.\n Equivalent to resetting a checked-out transform to its global definition, or deleting a provisional transform.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
}
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/{id}/run" : {
- "post" : {
- "summary" : "POST /api/ee/transform/{id}/run",
- "description" : "Run a transform.",
- "parameters" : [ {
+ }, {
"in" : "path",
- "name" : "id",
+ "name" : "tx-id",
"required" : true,
"schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
- } ],
- "responses" : {
- "2XX" : {
- "description" : "Successful response"
- },
- "4XX" : {
- "description" : "Client error response"
- },
- "5XX" : {
- "description" : "Server error response"
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
}
- },
- "tags" : [ "/api/ee/transform" ]
- }
- },
- "/api/ee/transform/{id}/table" : {
- "delete" : {
- "summary" : "DELETE /api/ee/transform/{id}/table",
- "description" : "Delete a transform's output table.",
- "parameters" : [ {
- "in" : "path",
- "name" : "id",
- "required" : true,
- "schema" : {
- "type" : "integer",
- "minimum" : 1
- },
- "description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29917,25 +32457,38 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transform" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transforms-python/library/{path}" : {
- "get" : {
- "summary" : "GET /api/ee/transforms-python/library/{path}",
- "description" : "Get the Python library for user modules.",
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}/archive" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/{tx-id}/archive",
+ "description" : "Mark the given transform to be archived when the workspace is merged.\n For provisional transforms we will skip even creating it in the first place.",
"parameters" : [ {
"in" : "path",
- "name" : "path",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29944,23 +32497,38 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/transforms-python" ]
- },
- "put" : {
- "summary" : "PUT /api/ee/transforms-python/library/{path}",
- "description" : "Update the Python library source code for user modules.",
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}/dry-run" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/{tx-id}/dry-run",
+ "description" : "Dry-run a transform in a workspace without persisting to the target table.\n\n Returns the first 2000 rows of transform output for preview purposes.\n Does not update last_run_at or create any database tables.",
"parameters" : [ {
"in" : "path",
- "name" : "path",
+ "name" : "ws-id",
"required" : true,
"schema" : {
- "type" : "string",
- "minLength" : 1
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
}
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.dry-run-result"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -29969,30 +32537,28 @@
"description" : "Server error response"
}
},
- "requestBody" : {
- "content" : {
- "application/json" : {
- "schema" : {
- "type" : "object",
- "properties" : {
- "source" : {
- "type" : "string"
- }
- },
- "required" : [ "source" ],
- "additionalProperties" : false
- }
- }
- }
- },
- "tags" : [ "/api/ee/transforms-python" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/transforms-python/test-run" : {
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}/merge" : {
"post" : {
- "summary" : "POST /api/ee/transforms-python/test-run",
- "description" : "Evaluate an ad-hoc python transform on a sample of input data.\n Intended for short runs for early feedback. Input/output/timeout limits apply.",
- "parameters" : [ ],
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/{tx-id}/merge",
+ "description" : "Merge single transform from workspace back to the core. If workspace transform is archived\n the corresponding core transform is deleted.\n\n Request body may include:\n - commit-message: A description of what changes are being merged (optional, will be required in future)",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ } ],
"responses" : {
"2XX" : {
"description" : "Successful response",
@@ -30001,42 +32567,25 @@
"schema" : {
"type" : "object",
"properties" : {
- "error" : {
- "type" : "object",
- "properties" : {
- "message" : {
- "anyOf" : [ { }, { } ]
- }
- },
- "required" : [ "message" ]
+ "global_id" : {
+ "oneOf" : [ {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }, {
+ "type" : "null"
+ } ]
},
- "logs" : {
+ "message" : {
"type" : "string"
},
- "output" : {
- "type" : "object",
- "properties" : {
- "cols" : {
- "type" : "array",
- "items" : {
- "type" : "object",
- "properties" : {
- "name" : {
- "type" : "string"
- }
- },
- "required" : [ "name" ]
- }
- },
- "rows" : {
- "type" : "array",
- "items" : { }
- }
- },
- "required" : [ "cols", "rows" ]
+ "op" : {
+ "type" : "string",
+ "enum" : [ "create", "delete", "update", "noop" ]
+ },
+ "ref_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
}
},
- "required" : [ "logs" ]
+ "required" : [ "op", "global_id", "ref_id" ]
}
}
}
@@ -30054,55 +32603,47 @@
"schema" : {
"type" : "object",
"properties" : {
- "code" : {
- "type" : "string"
- },
- "output_row_limit" : {
- "allOf" : [ {
- "type" : "integer"
- }, {
- "type" : "number",
- "exclusiveMinimum" : 1
- }, {
- "type" : "number",
- "maximum" : 100
- } ]
- },
- "per_input_row_limit" : {
- "allOf" : [ {
- "type" : "integer"
- }, {
- "type" : "number",
- "exclusiveMinimum" : 1
- }, {
- "type" : "number",
- "maximum" : 100
- } ]
- },
- "source_tables" : {
- "type" : "object",
- "additionalProperties" : {
- "type" : "integer"
- },
- "minProperties" : 1
+ "commit-message" : {
+ "type" : "string",
+ "minLength" : 1
}
- },
- "required" : [ "code", "source_tables" ]
+ }
}
}
}
},
- "tags" : [ "/api/ee/transforms-python" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/upload-management/tables" : {
- "get" : {
- "summary" : "GET /api/ee/upload-management/tables",
- "description" : "Get all `Tables` visible to the current user which were created by uploading a file.",
- "parameters" : [ ],
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}/run" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/{tx-id}/run",
+ "description" : "Run a transform in a workspace.\n\n App DB changes are rolled back. Warehouse DB changes persist.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ } ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.execution-result"
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -30111,38 +32652,99 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/upload-management" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
- "/api/ee/upload-management/tables/{id}" : {
- "delete" : {
- "summary" : "DELETE /api/ee/upload-management/tables/{id}",
- "description" : "Delete the uploaded table from the database, optionally archiving cards for which it is the primary source.",
+ "/api/ee/workspace/{ws-id}/transform/{tx-id}/unarchive" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/transform/{tx-id}/unarchive",
+ "description" : "Unmark the given transform for archival. This will recall the last definition it had within the workspace.",
"parameters" : [ {
"in" : "path",
- "name" : "id",
+ "name" : "ws-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ }
+ }, {
+ "in" : "path",
+ "name" : "tx-id",
+ "required" : true,
+ "schema" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.ref-id"
+ }
+ } ],
+ "responses" : {
+ "2XX" : {
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "null"
+ }
+ }
+ }
+ },
+ "4XX" : {
+ "description" : "Client error response"
+ },
+ "5XX" : {
+ "description" : "Server error response"
+ }
+ },
+ "tags" : [ "/api/ee/workspace" ]
+ }
+ },
+ "/api/ee/workspace/{ws-id}/unarchive" : {
+ "post" : {
+ "summary" : "POST /api/ee/workspace/{ws-id}/unarchive",
+ "description" : "Restore an archived workspace. Recreates the isolated schema and tables.",
+ "parameters" : [ {
+ "in" : "path",
+ "name" : "ws-id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
- }, {
- "in" : "query",
- "name" : "archive-cards",
- "required" : false,
- "schema" : {
- "default" : false,
- "oneOf" : [ {
- "type" : "boolean"
- }, {
- "type" : "null"
- } ]
- }
} ],
"responses" : {
"2XX" : {
- "description" : "Successful response"
+ "description" : "Successful response",
+ "content" : {
+ "application/json" : {
+ "schema" : {
+ "type" : "object",
+ "properties" : {
+ "collection_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "created_at" : {
+ "type" : "string",
+ "format" : "date-time"
+ },
+ "database_id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "id" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.types.appdb-id"
+ },
+ "name" : {
+ "type" : "string"
+ },
+ "status" : {
+ "$ref" : "#/components/schemas/metabase-enterprise.workspaces.api.status"
+ },
+ "updated_at" : {
+ "type" : "string",
+ "format" : "date-time"
+ }
+ },
+ "required" : [ "id", "name", "collection_id", "database_id", "status", "created_at", "updated_at" ]
+ }
+ }
+ }
},
"4XX" : {
"description" : "Client error response"
@@ -30151,7 +32753,7 @@
"description" : "Server error response"
}
},
- "tags" : [ "/api/ee/upload-management" ]
+ "tags" : [ "/api/ee/workspace" ]
}
},
"/api/eid-translation/translate" : {