GET V1 ems/resultsExport/{datasetId}

Initiates a download of the export CSV.

Request Information

Parameters

Name Description Additional information
datasetId
The ID of the dataset containing the results export.

Define this parameter in the request URI.

Example Request

To retrieve the export of results from an EMS experiment, make the following API call: GET /ems/resultsExport/1234

This method uses the ID provided by a call to GetResults in order to initiate a download of the results export CSV. If the export does not complete in a reasonable amount of time, please check the EMS error logs for details.

This endpoint requires the api-username and api-usertoken headers to be present. If these headers are not present, a 401 (Unauthorized) response will be returned.

Response Information

HTTP Status Codes

Status Code Meaning
200 (OK) Success
The request has completed successfully.
The download has been initiated and successfully completed.
400 (Bad Request) The provided dataset ID is not a valid number.
401 (Unauthorized) The user has not been authorised due to the below reasons which will be displayed in the response content.
API Key is not found. Data received apiKey
Secret Key is wrong. Data received apiKey
Username not found. Data received apiKey
Received token not found in EMS issuer. Data received username, version
Lifetime validation failed. The token is expired. ValidTo (UTC): expiry, Current time (UTC): UTC DateTime
Token creation failed. Reason: The given username or password is wrong. For input: username, version
Please ensure that the client provides the api-username and api-usertoken headers.
403 (Forbidden) The user does not have permission to access the experiment with which the results set is associated.
Please use EMS to add the user to the experiment access control list.
404 (Not Found) The dataset with the specified ID could not be found. The dataset ID may also be associated with a type that is not an experiment, for example a study or project.
Ensure the ID has been correctly specified.
410 (Gone) Dataset expired
The request dataset has expired or the server have has been removed.
Please ensure that the dataset you have requested has not expired. If it has not expired, contact your system administrator to determine why the server file has been removed.
412 (PreconditionFailed) Request not completed
The request has not completed.
Please wait for the CSV to finish exporting.
503 (ServiceUnavailable) EMS is currently unavailable.
Please try again later or contact a system administrator to ask when EMS will be back online.