Create a multi-table dataset upload session
POST {{baseUrl}}/api/datasets/:datasetId/uploadSessions
Create a multi-table dataset upload session and provide formatting information for data that is to be uploaded to the Intelligence Server. Formatting information is used by the Intelligence Server to parse data from a subsequent PUT /datasets/{datasetId}/uploadSessions/{uploadSessionId} request. 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/models. In the body of the request, you must provide the name and update policy for each table in the dataset. The update policy refers to how updates are applied to existing data in the dataset; valid values are 'add', 'update', 'upsert', and 'replace'. Optionally, you can also provide the orientation and column headers for each table in the body of the request; these parameters define how data is arranged in subsequent PUT /datasets/{datasetId}/uploadSessions/{uploadSessionId} requests and processed by the Intelligence Server. The orientation parameter specifies whether the array of data provided in subsequent PUT /datasets/{datasetId}/uploadSessions/{uploadSessionId} requests is arranged by rows or columns. Valid orientations are 'ROW' and 'COLUMN'; if the orientation parameter is not provided, 'ROW' is used. Refer to documentation within PUT /datasets/{datasetId}/uploadSessions/{uploadSessionId} for an example of 'ROW' and 'COLUMN' orientation. The columnHeaders parameter accepts an optional list of column names; data provided in subsequent PUT /datasets/{datasetId}/uploadSessions/{uploadSessionId} requests should have the same order as the column names in columnHeaders. If the columnHeaders parameter is not provided, the order of column names in the response of GET datasets/{datasetId}?fields=columns is used.
Body
PARAM
Key | Datatype | Required | Description |
fields
|
null | Comma-separated, top-level field whitelist that allows the client to selectively retrieve part of the response model. If specified, extra filtering is applied, and for top-level object (if root model is an array, each array element), only the listed fields are kept in the response. For example, "id,elements" keeps only the "id" field and whole "elements" array field, omitting all other fields in the top-level response model. |
HEADERS
Key | Datatype | Required | Description |
X-MSTR-AuthToken
|
string | (Required) Authorization token | |
X-MSTR-ProjectID
|
string | (Required) Project ID | |
Content-Type
|
string |
RESPONSES
ENDPOINTS