Get the definition of a dataset
GET {{baseUrl}}/api/datasets/:datasetId
Get the definition of a specific MTDI dataset; this can be either a single-table dataset or a dataset with multiple tables. You obtain the authorization token needed to execute the request using POST /auth/login; you obtain the project ID using GET /projects. You pass the authorization token and the project ID in the request header. You specify the dataset ID in the path of the request; you obtain the dataset ID from POST /datasets or POST /datasets/models. You specify the kind of data to return using the 'fields' query parameter in the request; possible values include tables, columns, attributes, and metrics. You can specify multiple values for the 'fields' parameter by adding each value in a new line in the 'fields' value textbox; if you don't specify any value, attributes and metrics will be returned.
Body
PARAM
Key | Datatype | Required | Description |
fields
|
null | Specifies object types to be returned. Possible values include tables, columns, attributes, and metrics. If no value is set, attributes and metrics are returned. |
HEADERS
Key | Datatype | Required | Description |
X-MSTR-AuthToken
|
string | (Required) Authorization token | |
X-MSTR-ProjectID
|
string | (Required) Project ID |
RESPONSES
status OK
{
"id": "D8EFAA410C48C99EE2B9A194BEA71031",
"name": "SALES_TABLE_V1",
"result": {
"definition": {
"availableObjects": {
"attributes": [
{
"id": "BC51194AB44FB25D206D8188A06134E9",
"name": "ID",
"type": 12,
"subType": 3072
}
],
"metrics": [
{
"id": "397BF7051D47A0F5621815A267F79F41",
"name": "Sales",
"type": 4
}
]
}
}
}
} |
ENDPOINTS