Wiki

Clone wiki

ieeg / WsResourceDatasets

Create a recording (dev)

Right now the only types of datasets you can create are recordings, that is, studies and experiments. Studies have human subjects, Experiments have non-human subjects. The method is

POST /services/datasets

When the creation succeeds an HTTP response code of 201 is returned and the Location header is set pointing to the newly created recording. The response body contains information about the newly created recording.

Example request body:

<dataset
    type="study"
    organization="Some Hospital">
</dataset>

Example response body:

<dataset
    type="study"
    organization="Some Hospital"
    name="I555_P023_D01"
    subject="P023"
    id="1772c0f3-dad1-4a0c-b702-d8393fdd0db9">
</dataset>

If you want to add a recording to an existing subject, include the subject in your request:

<dataset
    type="experiment"
    organization="Some Lab"
        subject="A0067">
</dataset>
If the named subject does not exist a 400 response will be returned.

For a study you can also include the subject's age at admission in your request:

<dataset
    type="study"
    organization="Some Hospital"
        ageAtAdmission="45">
</dataset>
If you specify and age at admission this will also be part of the response.

Delete a dataset

The method is

DELETE /services/datasets/{dataset id}
The response to a successful deletion has status code 204 and no body. If someone has derived a new dataset from the specified dataset then the request will fail with a 409 response.

Get a dataset's ACL (dev)

Any user with read permission on a dataset can view its acl. The method is

GET /services/datasets/{dataset id}/aces

Returns a list of ace's wrapped in an <acl> element. For more information about operations on individual aces see the Aces resource.

Get a list of a recording's objects

GET /services/datasets/{dataset id}/objects

Upload a new object to a recording

Creates an object without a description or user defined metadata.

POST /services/datasets/{dataset id}/objects
For more information about operations on individual objects see the Objects resource.

Back to manual

Updated