Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 28 Next »

Introduction

See Service API Design for the rationale and design details for this api.

See Developer Bootstrap#DeveloperBootstrap-ServiceDevelopment for instructions on how to run a local instance of this service.

Encoding

The primary request and response encoding for the service is JSON. Here's a handy tool to make a blob of JSON more readable: http://jsonformatter.curiousconcept.com/

In responses from the service, dates are serialized as long integers expressing epoch time - the number of seconds elapsed since midnight Coordinated Universal Time (UTC) of January 1, 1970, not counting leap seconds. Here's a handy tool to convert from epoch time to human readable dates: http://www.epochconverter.com/

In requests to the service, dates can be serialized either as long integers expressing epoch time or human readable dates in http://www.ietf.org/rfc/rfc3339.txt format such as '2011-01-31' or '2011-01-31T22:00:00'

Security

Eventually these services will be HTTPS only and disallow HTTP. Users will pass something like ?access_token=... as a query parameter for every request to the service

Query API Examples

'Select *' Query

Right now only a subset of query functionality is supported

SELECT * FROM <data type> [LIMIT <#>] [OFFSET <#>]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+dataset+limit+3+offset+1'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:57 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "results": [
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Asian Cancer Research Group, Inc., (ACRG)"],
      "dataset.Internal Name": ["ACRG_gastric"],
      "dataset.Number of Samples": [2000],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Stomach"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/gastric_cancer_acrg.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/gastric_cancer_acrg.txt"],
      "dataset.creationDate": 1299030228171,
      "dataset.creator": "Asian Cancer Research Group, Inc., (ACRG)",
      "dataset.db_id": [1],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "0",
      "dataset.name": "Gastric Cancer ACRG",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/gastric_cancer_acrg.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/gastric_cancer_acrg.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Asian Cancer Research Group, Inc., (ACRG)"],
      "dataset.Internal Name": ["ACRG_lung"],
      "dataset.Number of Samples": [2000],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Lung"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/lung_cancer_acrg.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/lung_cancer_acrg.txt"],
      "dataset.creationDate": 1299030229345,
      "dataset.creator": "Asian Cancer Research Group, Inc., (ACRG)",
      "dataset.db_id": [2],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "1",
      "dataset.name": "Lung Cancer ACRG",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/lung_cancer_acrg.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/lung_cancer_acrg.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Fred Hutchinson Cancer Research Center /SKCCC at Johns Hopkins"],
      "dataset.Internal Name": ["AML-Ped_TARGET"],
      "dataset.Number of Samples": [200],
      "dataset.Posting Restriction": ["Link to data source"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Blood"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/pediatric_aml_target.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/pediatric_aml_target.txt"],
      "dataset.creationDate": 1299030230283,
      "dataset.creator": "Soheil Meshinchi/ Bob Arceci",
      "dataset.db_id": [3],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "2",
      "dataset.name": "Pediatric AML TARGET",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/pediatric_aml_target.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Pending",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/pediatric_aml_target.txt"],
      "dataset.version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 114
}

'Order By' Query

Right now only a subset of query functionality is supported

SELECT * FROM <data type> ORDER BY "<field name>" [ASC|DESC] [LIMIT <#>] [OFFSET #]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+dataset+order+by+"name"+limit+3+offset+1'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:57 GMT
Server: Apache-Coyote/1.1
Content-Length: 3383
Connection: keep-alive

{
  "results": [
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Sage Bionetworks"],
      "dataset.Internal Name": ["Nonresponders_AML"],
      "dataset.Number of Samples": [300],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Blood"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/aml_nonresponders_cohort.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/aml_nonresponders_cohort.txt"],
      "dataset.creationDate": 1299030290588,
      "dataset.creator": "Stephen Friend",
      "dataset.db_id": [74],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "73",
      "dataset.name": "AML Nonresponders Cohort",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/aml_nonresponders_cohort.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/aml_nonresponders_cohort.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["TCGA"],
      "dataset.Internal Name": ["TCGA_AML"],
      "dataset.Number of Samples": [500],
      "dataset.Posting Restriction": ["Embargo"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Blood"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/aml_tcga.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/aml_tcga.txt"],
      "dataset.creationDate": 1299030307514,
      "dataset.creator": "TCGA",
      "dataset.db_id": [96],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "95",
      "dataset.name": "AML TCGA",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/aml_tcga.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/aml_tcga.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Asthma"],
      "dataset.Institution": ["Imperial College London"],
      "dataset.Internal Name": ["Cookson_LCLs"],
      "dataset.Number of Samples": [404],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Lymphoblastoid Cell Line"],
      "dataset.Type": ["Other"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/asthma_human_lymphoblastoid_cell_lines.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/asthma_human_lymphoblastoid_cell_lines.txt"],
      "dataset.creationDate": 1299030249448,
      "dataset.creator": "Cookson",
      "dataset.db_id": [25],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "24",
      "dataset.name": "Asthma Human Lymphoblastoid Cell Lines",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/asthma_human_lymphoblastoid_cell_lines.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/asthma_human_lymphoblastoid_cell_lines.txt"],
      "dataset.version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 114
}

'Where Equal To' Query

Right now only a subset of query functionality is supported

SELECT * FROM <data type> WHERE "<field name>" == "<value>" [LIMIT <#>] [OFFSET #]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+dataset+where+name+==+"Human+Liver+Cohort"'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:57 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "results": [{
    "dataset.Disease": ["CVD"],
    "dataset.Institution": ["Vanderbilt University/ University of Pittsburg/ StJudes Hospital"],
    "dataset.Internal Name": ["Deliver"],
    "dataset.Number of Samples": [517],
    "dataset.Posting Restriction": ["Link to data source"],
    "dataset.Species": ["Human"],
    "dataset.Tissue/Tumor": ["Liver"],
    "dataset.Type": ["GCD"],
    "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/human_liver_cohort.txt"],
    "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/human_liver_cohort.txt"],
    "dataset.creationDate": 1299030252841,
    "dataset.creator": "Fred Guengrich/Steve Strom/ Erin Schuetz",
    "dataset.db_id": [29],
    "dataset.description": null,
    "dataset.hasClinicalData": true,
    "dataset.hasExpressionData": true,
    "dataset.hasGeneticData": true,
    "dataset.id": "28",
    "dataset.name": "Human Liver Cohort",
    "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/human_liver_cohort.txt"],
    "dataset.releaseDate": null,
    "dataset.status": "Current",
    "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/human_liver_cohort.txt"],
    "dataset.version": "0.0.1"
  }],
  "totalNumberOfResults": 114
}

'Where Equal To' Query with a Limit

Right now only a subset of query functionality is supported

SELECT * FROM <data type> WHERE "<field name>" == "<value>" [LIMIT <#>] [OFFSET #]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+dataset+where+"Species"+==+"Human"+limit+3+offset+1'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:57 GMT
Server: Apache-Coyote/1.1
Content-Length: 3481
Connection: keep-alive

{
  "results": [
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Asian Cancer Research Group, Inc., (ACRG)"],
      "dataset.Internal Name": ["ACRG_gastric"],
      "dataset.Number of Samples": [2000],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Stomach"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/gastric_cancer_acrg.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/gastric_cancer_acrg.txt"],
      "dataset.creationDate": 1299030228171,
      "dataset.creator": "Asian Cancer Research Group, Inc., (ACRG)",
      "dataset.db_id": [1],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "0",
      "dataset.name": "Gastric Cancer ACRG",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/gastric_cancer_acrg.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/gastric_cancer_acrg.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Asian Cancer Research Group, Inc., (ACRG)"],
      "dataset.Internal Name": ["ACRG_lung"],
      "dataset.Number of Samples": [2000],
      "dataset.Posting Restriction": ["unspecified"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Lung"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/lung_cancer_acrg.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/lung_cancer_acrg.txt"],
      "dataset.creationDate": 1299030229345,
      "dataset.creator": "Asian Cancer Research Group, Inc., (ACRG)",
      "dataset.db_id": [2],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "1",
      "dataset.name": "Lung Cancer ACRG",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/lung_cancer_acrg.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Future",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/lung_cancer_acrg.txt"],
      "dataset.version": "0.0.1"
    },
    {
      "dataset.Disease": ["Cancer"],
      "dataset.Institution": ["Fred Hutchinson Cancer Research Center /SKCCC at Johns Hopkins"],
      "dataset.Internal Name": ["AML-Ped_TARGET"],
      "dataset.Number of Samples": [200],
      "dataset.Posting Restriction": ["Link to data source"],
      "dataset.Species": ["Human"],
      "dataset.Tissue/Tumor": ["Blood"],
      "dataset.Type": ["GCD"],
      "dataset.abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/pediatric_aml_target.txt"],
      "dataset.citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/pediatric_aml_target.txt"],
      "dataset.creationDate": 1299030230283,
      "dataset.creator": "Soheil Meshinchi/ Bob Arceci",
      "dataset.db_id": [3],
      "dataset.description": null,
      "dataset.hasClinicalData": false,
      "dataset.hasExpressionData": false,
      "dataset.hasGeneticData": false,
      "dataset.id": "2",
      "dataset.name": "Pediatric AML TARGET",
      "dataset.readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/pediatric_aml_target.txt"],
      "dataset.releaseDate": null,
      "dataset.status": "Pending",
      "dataset.user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/pediatric_aml_target.txt"],
      "dataset.version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 114
}

'Select *' Query for the Layers of a Dataset

Right now only a subset of query functionality is supported

SELECT * FROM layer WHERE dataset.id == <datasetId> [LIMIT <#>] [OFFSET <#>]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+layer+where+dataset.id+==+"28"'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "results": [
    {
      "layer.creationDate": 1299030322486,
      "layer.description": null,
      "layer.id": "3",
      "layer.locations": null,
      "layer.name": "clinical data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "C",
      "layer.version": "0.0.1"
    },
    {
      "layer.creationDate": 1299030323444,
      "layer.description": null,
      "layer.id": "4",
      "layer.locations": null,
      "layer.name": "expression data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "E",
      "layer.version": "0.0.1"
    },
    {
      "layer.creationDate": 1299030324416,
      "layer.description": null,
      "layer.id": "5",
      "layer.locations": null,
      "layer.name": "genetic data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "G",
      "layer.version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 3
}

'Order By' Query for the Layers of a Dataset

Right now only a subset of query functionality is supported

SELECT * FROM layer WHERE dataset.id == <datasetId> ORDER BY "<field name>" [ASC|DESC] [LIMIT <#>] [OFFSET <#>]

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/query?query=select+*+from+layer+where+dataset.id+==+"28"+ORDER+BY+"type"'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
Content-Length: 1125
Connection: keep-alive

{
  "results": [
    {
      "layer.creationDate": 1299030322486,
      "layer.description": null,
      "layer.id": "3",
      "layer.locations": null,
      "layer.name": "clinical data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "C",
      "layer.version": "0.0.1"
    },
    {
      "layer.creationDate": 1299030323444,
      "layer.description": null,
      "layer.id": "4",
      "layer.locations": null,
      "layer.name": "expression data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "E",
      "layer.version": "0.0.1"
    },
    {
      "layer.creationDate": 1299030324416,
      "layer.description": null,
      "layer.id": "5",
      "layer.locations": null,
      "layer.name": "genetic data",
      "layer.platform": null,
      "layer.preview": null,
      "layer.processingFacility": null,
      "layer.publicationDate": null,
      "layer.qcBy": null,
      "layer.qcDate": null,
      "layer.releaseNotes": null,
      "layer.tissueType": null,
      "layer.type": "G",
      "layer.version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 3
}

REST API Examples (Read Only)

Sanity check request

This is just a 'hello world' type request that you can make to ensure that the service is running.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/test'

Response

HTTP/1.1 200 OK
Cache-Control: no-cache, no-store, max-age=0
Content-Language: en-US
Content-Type: application/json;charset=UTF-8
Date: Wed, 02 Mar 2011 02:00:58 GMT
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Pragma: no-cache
Server: Apache-Coyote/1.1
Content-Length: 35
Connection: keep-alive

{"hello": "REST for Datasets rocks"}

Get All Datasets

Optional Parameters

  • offset - integer - 1-based pagination offset
  • limit - integer - maximum number of results to return
  • sort - string - the name of the field upon which to sort
  • ascending - boolean - whether or not to sort ascending

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset?sort=name&limit=3'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
Content-Length: 1239
Connection: keep-alive

{
  "paging": {"next": "/repo/v1/dataset?offset=4&limit=3&sort=name&ascending=true"},
  "results": [
    {
      "annotations": "/repo/v1/dataset/73/annotations",
      "creationDate": 1299030290588,
      "creator": "Stephen Friend",
      "description": null,
      "etag": "1368472154",
      "hasClinicalData": false,
      "hasExpressionData": false,
      "hasGeneticData": false,
      "id": "73",
      "layer": "/repo/v1/dataset/73/layer",
      "name": "AML Nonresponders Cohort",
      "releaseDate": null,
      "status": "Future",
      "uri": "/repo/v1/dataset/73",
      "version": "0.0.1"
    },
    {
      "annotations": "/repo/v1/dataset/95/annotations",
      "creationDate": 1299030307514,
      "creator": "TCGA",
      "description": null,
      "etag": "298472858",
      "hasClinicalData": false,
      "hasExpressionData": false,
      "hasGeneticData": false,
      "id": "95",
      "layer": "/repo/v1/dataset/95/layer",
      "name": "AML TCGA",
      "releaseDate": null,
      "status": "Future",
      "uri": "/repo/v1/dataset/95",
      "version": "0.0.1"
    },
    {
      "annotations": "/repo/v1/dataset/24/annotations",
      "creationDate": 1299030249448,
      "creator": "Cookson",
      "description": null,
      "etag": "4094715",
      "hasClinicalData": false,
      "hasExpressionData": false,
      "hasGeneticData": false,
      "id": "24",
      "layer": "/repo/v1/dataset/24/layer",
      "name": "Asthma Human Lymphoblastoid Cell Lines",
      "releaseDate": null,
      "status": "Future",
      "uri": "/repo/v1/dataset/24",
      "version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 114
}

Get a Dataset

This returns the primary fields of a dataset and links to get additional info.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
ETag: -1569654852
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "annotations": "/repo/v1/dataset/28/annotations",
  "creationDate": 1299030252841,
  "creator": "Fred Guengrich/Steve Strom/ Erin Schuetz",
  "description": null,
  "etag": "-1569654852",
  "hasClinicalData": true,
  "hasExpressionData": true,
  "hasGeneticData": true,
  "id": "28",
  "layer": "/repo/v1/dataset/28/layer",
  "name": "Human Liver Cohort",
  "releaseDate": null,
  "status": "Current",
  "uri": "/repo/v1/dataset/28",
  "version": "0.0.1"
}

Get Annotations for a Dataset

This returns the annotations for a dataset.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/annotations'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
ETag: 413002292
Server: Apache-Coyote/1.1
Content-Length: 878
Connection: keep-alive

{
  "creationDate": null,
  "dateAnnotations": {},
  "doubleAnnotations": {},
  "etag": "413002292",
  "id": "28",
  "longAnnotations": {
    "Number of Samples": [517],
    "db_id": [29]
  },
  "stringAnnotations": {
    "Disease": ["CVD"],
    "Institution": ["Vanderbilt University/ University of Pittsburg/ StJudes Hospital"],
    "Internal Name": ["Deliver"],
    "Posting Restriction": ["Link to data source"],
    "Species": ["Human"],
    "Tissue/Tumor": ["Liver"],
    "Type": ["GCD"],
    "abstract_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/abstract_files/human_liver_cohort.txt"],
    "citation_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/citation_files/human_liver_cohort.txt"],
    "readme_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/readme_files/human_liver_cohort.txt"],
    "user_agreement_file_path": ["/srv/www/htdocs/Foswiki/downloads/data/v2/user_agreement_files/human_liver_cohort.txt"]
  },
  "uri": "/repo/v1/dataset/28/annotations"
}

Get all the Layers for a Dataset

This returns the primary fields for all the layers of a dataset.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
Content-Length: 1811
Connection: keep-alive

{
  "paging": {},
  "results": [
    {
      "annotations": "/repo/v1/dataset/28/layer/3/annotations",
      "creationDate": 1299030322486,
      "description": null,
      "etag": "-1165894652",
      "id": "3",
      "locations": [
        "/repo/v1/dataset/28/layer/3/awsEBSLocation",
        "/repo/v1/dataset/28/layer/3/locations",
        "/repo/v1/dataset/28/layer/3/sageLocation",
        "/repo/v1/dataset/28/layer/3/awsS3Location"
      ],
      "name": "clinical data",
      "platform": null,
      "preview": "/repo/v1/dataset/28/layer/3/preview",
      "processingFacility": null,
      "publicationDate": null,
      "qcBy": null,
      "qcDate": null,
      "releaseNotes": null,
      "tissueType": null,
      "type": "C",
      "uri": "/repo/v1/dataset/28/layer/3",
      "version": "0.0.1"
    },
    {
      "annotations": "/repo/v1/dataset/28/layer/4/annotations",
      "creationDate": 1299030323444,
      "description": null,
      "etag": "1556416517",
      "id": "4",
      "locations": [
        "/repo/v1/dataset/28/layer/4/awsS3Location",
        "/repo/v1/dataset/28/layer/4/sageLocation",
        "/repo/v1/dataset/28/layer/4/awsEBSLocation",
        "/repo/v1/dataset/28/layer/4/locations"
      ],
      "name": "expression data",
      "platform": null,
      "preview": "/repo/v1/dataset/28/layer/4/preview",
      "processingFacility": null,
      "publicationDate": null,
      "qcBy": null,
      "qcDate": null,
      "releaseNotes": null,
      "tissueType": null,
      "type": "E",
      "uri": "/repo/v1/dataset/28/layer/4",
      "version": "0.0.1"
    },
    {
      "annotations": "/repo/v1/dataset/28/layer/5/annotations",
      "creationDate": 1299030324416,
      "description": null,
      "etag": "-1318090576",
      "id": "5",
      "locations": [
        "/repo/v1/dataset/28/layer/5/awsEBSLocation",
        "/repo/v1/dataset/28/layer/5/awsS3Location",
        "/repo/v1/dataset/28/layer/5/sageLocation",
        "/repo/v1/dataset/28/layer/5/locations"
      ],
      "name": "genetic data",
      "platform": null,
      "preview": "/repo/v1/dataset/28/layer/5/preview",
      "processingFacility": null,
      "publicationDate": null,
      "qcBy": null,
      "qcDate": null,
      "releaseNotes": null,
      "tissueType": null,
      "type": "G",
      "uri": "/repo/v1/dataset/28/layer/5",
      "version": "0.0.1"
    }
  ],
  "totalNumberOfResults": 3
}

Get a Clinical Dataset Layer

This returns the metadata for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
ETag: -1165894652
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "annotations": "/repo/v1/dataset/28/layer/3/annotations",
  "creationDate": 1299030322486,
  "description": null,
  "etag": "-1165894652",
  "id": "3",
  "locations": [
    "/repo/v1/dataset/28/layer/3/awsEBSLocation",
    "/repo/v1/dataset/28/layer/3/locations",
    "/repo/v1/dataset/28/layer/3/sageLocation",
    "/repo/v1/dataset/28/layer/3/awsS3Location"
  ],
  "name": "clinical data",
  "platform": null,
  "preview": "/repo/v1/dataset/28/layer/3/preview",
  "processingFacility": null,
  "publicationDate": null,
  "qcBy": null,
  "qcDate": null,
  "releaseNotes": null,
  "tissueType": null,
  "type": "C",
  "uri": "/repo/v1/dataset/28/layer/3",
  "version": "0.0.1"
}

Get Annotations for a Clinical Dataset Layer

This returns the annotations for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3/annotations'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
ETag: 923521
Server: Apache-Coyote/1.1
Content-Length: 182
Connection: keep-alive

{
  "creationDate": null,
  "dateAnnotations": {},
  "doubleAnnotations": {},
  "etag": "923521",
  "id": "3",
  "longAnnotations": {},
  "stringAnnotations": {},
  "uri": "/repo/v1/dataset/28/layer/3/annotations"
}

Get preview data for a Clinical Dataset Layer

This returns the preview data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3/preview'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
ETag: 345556318
Server: Apache-Coyote/1.1
Content-Length: 107
Connection: keep-alive

{
  "etag": "345556318",
  "id": "3",
  "preview": "clinical data preview",
  "uri": "/repo/v1/dataset/28/layer/3/preview"
}

Get the awsEBSLocation for a Clinical Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3/awsEBSLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
Content-Length: 50
Connection: keep-alive

{
  "path": "snap-29d33a42 (US West)",
  "type": "awsebs"
}

Get the sageLocation for a Clinical Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3/sageLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:58 GMT
Server: Apache-Coyote/1.1
Content-Length: 74
Connection: keep-alive

{
  "path": "/Shares/external-data/DAT_030__human_liver_cohort",
  "type": "sage"
}

Get the awsS3Location for a Clinical Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/3/awsS3Location'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "path": "https://data01.sagebase.org.s3.amazonaws.com/human_liver_cohort.tar.gz?Expires=1299031859&AWSAccessKeyId=AKIAIVJZPLJB5JWSFEYA&Signature=X7cWuvkYfeKGMRzEYQY9uURw6q0%3D",
  "type": "awss3"
}

Get a Expression Dataset Layer

This returns the metadata for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: 1556416517
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "annotations": "/repo/v1/dataset/28/layer/4/annotations",
  "creationDate": 1299030323444,
  "description": null,
  "etag": "1556416517",
  "id": "4",
  "locations": [
    "/repo/v1/dataset/28/layer/4/awsS3Location",
    "/repo/v1/dataset/28/layer/4/sageLocation",
    "/repo/v1/dataset/28/layer/4/awsEBSLocation",
    "/repo/v1/dataset/28/layer/4/locations"
  ],
  "name": "expression data",
  "platform": null,
  "preview": "/repo/v1/dataset/28/layer/4/preview",
  "processingFacility": null,
  "publicationDate": null,
  "qcBy": null,
  "qcDate": null,
  "releaseNotes": null,
  "tissueType": null,
  "type": "E",
  "uri": "/repo/v1/dataset/28/layer/4",
  "version": "0.0.1"
}

Get Annotations for a Expression Dataset Layer

This returns the annotations for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4/annotations'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: 923521
Server: Apache-Coyote/1.1
Content-Length: 182
Connection: keep-alive

{
  "creationDate": null,
  "dateAnnotations": {},
  "doubleAnnotations": {},
  "etag": "923521",
  "id": "4",
  "longAnnotations": {},
  "stringAnnotations": {},
  "uri": "/repo/v1/dataset/28/layer/4/annotations"
}

Get preview data for a Expression Dataset Layer

This returns the preview data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4/preview'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: 945969657
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "etag": "945969657",
  "id": "4",
  "preview": "expression data preview",
  "uri": "/repo/v1/dataset/28/layer/4/preview"
}

Get the awsS3Location for a Expression Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4/awsS3Location'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
Content-Length: 192
Connection: keep-alive

{
  "path": "https://data01.sagebase.org.s3.amazonaws.com/human_liver_cohort.tar.gz?Expires=1299031859&AWSAccessKeyId=AKIAIVJZPLJB5JWSFEYA&Signature=X7cWuvkYfeKGMRzEYQY9uURw6q0%3D",
  "type": "awss3"
}

Get the sageLocation for a Expression Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4/sageLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "path": "/Shares/external-data/DAT_030__human_liver_cohort",
  "type": "sage"
}

Get the awsEBSLocation for a Expression Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/4/awsEBSLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
Content-Length: 50
Connection: keep-alive

{
  "path": "snap-29d33a42 (US West)",
  "type": "awsebs"
}

Get a Genetic Dataset Layer

This returns the metadata for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: -1318090576
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "annotations": "/repo/v1/dataset/28/layer/5/annotations",
  "creationDate": 1299030324416,
  "description": null,
  "etag": "-1318090576",
  "id": "5",
  "locations": [
    "/repo/v1/dataset/28/layer/5/awsEBSLocation",
    "/repo/v1/dataset/28/layer/5/awsS3Location",
    "/repo/v1/dataset/28/layer/5/sageLocation",
    "/repo/v1/dataset/28/layer/5/locations"
  ],
  "name": "genetic data",
  "platform": null,
  "preview": "/repo/v1/dataset/28/layer/5/preview",
  "processingFacility": null,
  "publicationDate": null,
  "qcBy": null,
  "qcDate": null,
  "releaseNotes": null,
  "tissueType": null,
  "type": "G",
  "uri": "/repo/v1/dataset/28/layer/5",
  "version": "0.0.1"
}

Get Annotations for a Genetic Dataset Layer

This returns the annotations for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/annotations'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: 923521
Server: Apache-Coyote/1.1
Content-Length: 182
Connection: keep-alive

{
  "creationDate": null,
  "dateAnnotations": {},
  "doubleAnnotations": {},
  "etag": "923521",
  "id": "5",
  "longAnnotations": {},
  "stringAnnotations": {},
  "uri": "/repo/v1/dataset/28/layer/5/annotations"
}

Get preview data for a Genetic Dataset Layer

This returns the preview data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/preview'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
ETag: 246848728
Server: Apache-Coyote/1.1
Content-Length: 106
Connection: keep-alive

{
  "etag": "246848728",
  "id": "5",
  "preview": "genetic data preview",
  "uri": "/repo/v1/dataset/28/layer/5/preview"
}

Get the awsEBSLocation for a Genetic Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/awsEBSLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
Content-Length: 50
Connection: keep-alive

{
  "path": "snap_29d33a42 (US West)",
  "type": "awsebs"
}

Get the awsS3Location for a Genetic Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/awsS3Location'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:00:59 GMT
Server: Apache-Coyote/1.1
Content-Length: 194
Connection: keep-alive

{
  "path": "https://data01.sagebase.org.s3.amazonaws.com/human_liver_cohort.tar.gz?Expires=1299031860&AWSAccessKeyId=AKIAIVJZPLJB5JWSFEYA&Signature=bBwj%2B5Q149Xo6bXylBSxFrzZUn0%3D",
  "type": "awss3"
}

Get the sageLocation for a Genetic Dataset Layer

This returns the location data for a dataset layer.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/sageLocation'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 74
Connection: keep-alive

{
  "path": "/Shares/external-data/DAT_030__human_liver_cohort",
  "type": "sage"
}

REST API Schemas

Datasets List Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 231
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "paging": {
      "optional": true,
      "type": "object"
    },
    "results": {
      "items": {
        "optional": true,
        "type": "any"
      },
      "optional": true,
      "type": "array"
    },
    "totalNumberOfResults": {
      "optional": true,
      "type": "integer"
    }
  },
  "type": "object"
}

Dataset Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 735
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "annotations": {
      "optional": true,
      "type": "string"
    },
    "creationDate": {
      "optional": true,
      "type": "number"
    },
    "creator": {
      "optional": true,
      "type": "string"
    },
    "description": {
      "optional": true,
      "type": "string"
    },
    "etag": {
      "optional": true,
      "type": "string"
    },
    "hasClinicalData": {
      "optional": true,
      "type": "boolean"
    },
    "hasExpressionData": {
      "optional": true,
      "type": "boolean"
    },
    "hasGeneticData": {
      "optional": true,
      "type": "boolean"
    },
    "id": {
      "optional": true,
      "type": "string"
    },
    "layer": {
      "optional": true,
      "type": "string"
    },
    "name": {
      "optional": true,
      "type": "string"
    },
    "releaseDate": {
      "optional": true,
      "type": "number"
    },
    "status": {
      "optional": true,
      "type": "string"
    },
    "uri": {
      "optional": true,
      "type": "string"
    },
    "version": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Dataset Annotations Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/annotations/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 429
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "creationDate": {
      "optional": true,
      "type": "number"
    },
    "dateAnnotations": {
      "optional": true,
      "type": "object"
    },
    "doubleAnnotations": {
      "optional": true,
      "type": "object"
    },
    "etag": {
      "optional": true,
      "type": "string"
    },
    "id": {
      "optional": true,
      "type": "string"
    },
    "longAnnotations": {
      "optional": true,
      "type": "object"
    },
    "stringAnnotations": {
      "optional": true,
      "type": "object"
    },
    "uri": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Dataset Layers List Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 231
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "paging": {
      "optional": true,
      "type": "object"
    },
    "results": {
      "items": {
        "optional": true,
        "type": "any"
      },
      "optional": true,
      "type": "array"
    },
    "totalNumberOfResults": {
      "optional": true,
      "type": "integer"
    }
  },
  "type": "object"
}

Layer Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 902
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "annotations": {
      "optional": true,
      "type": "string"
    },
    "creationDate": {
      "optional": true,
      "type": "number"
    },
    "description": {
      "optional": true,
      "type": "string"
    },
    "etag": {
      "optional": true,
      "type": "string"
    },
    "id": {
      "optional": true,
      "type": "string"
    },
    "locations": {
      "items": {
        "optional": true,
        "type": "string"
      },
      "optional": true,
      "type": "array"
    },
    "name": {
      "optional": true,
      "type": "string"
    },
    "platform": {
      "optional": true,
      "type": "string"
    },
    "preview": {
      "optional": true,
      "type": "string"
    },
    "processingFacility": {
      "optional": true,
      "type": "string"
    },
    "publicationDate": {
      "optional": true,
      "type": "number"
    },
    "qcBy": {
      "optional": true,
      "type": "string"
    },
    "qcDate": {
      "optional": true,
      "type": "number"
    },
    "releaseNotes": {
      "optional": true,
      "type": "string"
    },
    "tissueType": {
      "optional": true,
      "type": "string"
    },
    "type": {
      "optional": true,
      "type": "string"
    },
    "uri": {
      "optional": true,
      "type": "string"
    },
    "version": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Layer Preview Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/preview/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "etag": {
      "optional": true,
      "type": "string"
    },
    "id": {
      "optional": true,
      "type": "string"
    },
    "preview": {
      "optional": true,
      "type": "string"
    },
    "uri": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Layer Locations Schema

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/locations/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 352
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "etag": {
      "optional": true,
      "type": "string"
    },
    "id": {
      "optional": true,
      "type": "string"
    },
    "locations": {
      "items": {
        "optional": true,
        "properties": {
          "path": {
            "optional": true,
            "type": "string"
          },
          "type": {
            "optional": true,
            "type": "string"
          }
        },
        "type": "object"
      },
      "optional": true,
      "type": "array"
    },
    "uri": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Get the awsEBSLocation for a Dataset Layer

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/awsEBSLocation/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "path": {
      "optional": true,
      "type": "string"
    },
    "type": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Get the awsS3Location for a Dataset Layer

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/awsS3Location/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
transfer-encoding:chunked
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "path": {
      "optional": true,
      "type": "string"
    },
    "type": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

Get the sageLocation for a Dataset Layer

The JsonSchema is an emerging standard similar to DTDs for XML.

Request

curl -i -H Accept:application/json 'http://repositoryservice.elasticbeanstalk.com/repo/v1/dataset/28/layer/5/sageLocation/schema'

Response

HTTP/1.1 200 OK
Content-Type: application/json
Date: Wed, 02 Mar 2011 02:01:00 GMT
Server: Apache-Coyote/1.1
Content-Length: 130
Connection: keep-alive

{
  "optional": true,
  "properties": {
    "path": {
      "optional": true,
      "type": "string"
    },
    "type": {
      "optional": true,
      "type": "string"
    }
  },
  "type": "object"
}

REST API Usage Examples (Read/Write and slightly out of date)

This is a REST api (see Service API Design for more details as to what this means). You can create entities, updated entities, read entities, and delete entities. More advanced querying will be implemented as a separate API. Partial updates (e.g., just updating two fields in a dataset) are not supported. In a nutshell, when you update something like a dataset, you GET the dataset first, modify the properties you want to change, and then send the entire object back to the service so that this revised entity overwrites the previously stored entity.

Create a Dataset

Request:

curl -i -H Accept:application/json -H Content-Type:application/json
-d '{"name":"test dataset", "creator":"fake creator", "releaseDate":"2009-10-01", "status":"not curated"}'
http://localhost:8080/repo/v1/dataset

Response

HTTP/1.1 201 Created
ETag: 1736839268
Location: /repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYBAw
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "name":"test dataset",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "version":"0.0.1",
   "creator":"fake creator",
   "description":null,
   "creationDate":1296595870715,
   "status":"not curated",
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "etag":"1309185941",
   "releaseDate":1254355200000,
   "layers":[]
}

Update a Dataset

Note that in the example below the creator and description fields have been changed but all others remain the same.

Request:

curl -i -H Accept:application/json -H Content-Type:application/json -X PUT -H ETag:1309185941 -d '{
   "name":"test dataset",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "version":"0.0.1",
   "creator":"updated creator",
   "description":"I just added a description",
   "creationDate":1296595870715,
   "status":"not curated",
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "etag":"1309185941",
   "releaseDate":1254355200000,
   "layers":[]
}
' http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw

Response

HTTP/1.1 200 OK
ETag: -852418664
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "name":"test dataset",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "version":"0.0.1",
   "creator":"updated creator",
   "description":"I just added a description",
   "creationDate":1296595870715,
   "status":"not curated",
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "etag":"-852418664",
   "releaseDate":1254355200000,
   "layers":[]
}

Add Annotations to a Dataset

First get the empty annotations container for your newly created dataset

Request

curl -i -H Accept:application/json http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations

Response

HTTP/1.1 200 OK
ETag: 923521
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations",
   "etag":"923521",
   "stringAnnotations":{

   },
   "floatAnnotations":{

   },
   "dateAnnotations":{

   }
}

Then you add/modify the annotations of interest and do a PUT. Note that annotation values must always be list values even if the list is only of length one.

Request

curl -i -H Accept:application/json -H Content-Type:application/json -X PUT -H ETag:923521 -d '{
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations",
   "etag":"923521",
   "stringAnnotations":{
        "Experimental Design Templates":["exp-122887", "exp-97765"]
   },
   "floatAnnotations":{
        "Number of Samples":[500]
   },
   "dateAnnotations":{
        "Publication Date":["2011-01-15"]
   }
}' http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw/annotations

Response

HTTP/1.1 200 OK
ETag: -1638393853
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYBww",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYBww/annotations",
   "etag":"-1638393853",
   "stringAnnotations":{
      "Experimental Design Templates":[
         "exp-122887",
         "exp-97765"
      ]
   },
   "floatAnnotations":{
      "Number of Samples":[
         500.0
      ]
   },
   "dateAnnotations":{
      "Publication Date":[
         1295049600000
      ]
   }
}

Delete a Dataset

Request

curl -i -X DELETE http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYAQw

Response

HTTP/1.1 204 No Content
Server: Jetty(6.1.x)

Get a Layers for a Dataset

Request

curl -i -H Accept:application/json http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer

Response

HTTP/1.1 200 OK
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "results":[
      {
         "name":"Flint HS Mice Affy",
         "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
         "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
         "type":"E",
         "version":"0.0.1",
         "description":"this is a description",
         "creationDate":1296690778880,
         "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
         "etag":"1424771925",
         "publicationDate":null,
         "releaseNotes":"this is a release note",
         "tissueType":"liver",
         "platform":null,
         "processingFacility":null,
         "qcBy":null,
         "qcDate":null
      },
      {
         "name":"Flint HS Mice Phenotypes",
         "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjpBww/annotations",
         "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjpBww",
         "type":"C",
         "version":"0.0.1",
         "description":"this is a description",
         "creationDate":1296693007167,
         "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjpBww",
         "etag":"1445062754",
         "publicationDate":null,
         "releaseNotes":"this is a release note",
         "tissueType":null,
         "platform":null,
         "processingFacility":null,
         "qcBy":null,
         "qcDate":null
      }
   ],
   "totalNumberOfResults":2,
   "paging":{

   }
}

Get a Layer

Request

curl -i -H Accept:application/json http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww

Response

HTTP/1.1 200 OK
ETag: 1240467407
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "name":"Flint HS Mice Affy",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "type":"E",
   "version":"0.0.1",
   "description":"this is a description",
   "creationDate":1296690778880,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "etag":"1240467407",
   "publicationDate":null,
   "releaseNotes":"this is a release note",
   "tissueType":null,
   "platform":null,
   "processingFacility":null,
   "qcBy":null,
   "qcDate":null
}

Get annotations for a layer

Request

curl -i -H Accept:application/json http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations

Response

HTTP/1.1 200 OK
ETag: 923521
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "etag":"923521",
   "stringAnnotations":{

   },
   "floatAnnotations":{

   },
   "dateAnnotations":{

   }
}

Create a layer

Request

curl -i -H Accept:application/json -H Content-Type:application/json -d '{"name":"Flint HS Mice Affy", "type":"E", "description":"this is a description", "releaseNotes":"this is a release note"}' http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer

Response

HTTP/1.1 201 Created
ETag: 1240467407
Location: /repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "name":"Flint HS Mice Affy",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "type":"E",
   "version":"0.0.1",
   "description":"this is a description",
   "creationDate":1296690778880,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "etag":"1240467407",
   "publicationDate":null,
   "releaseNotes":"this is a release note",
   "tissueType":null,
   "platform":null,
   "processingFacility":null,
   "qcBy":null,
   "qcDate":null
}

Now ask for the owning dataset and you can see the preview of the layer

Request

curl -i -H Accept:application/json http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww

Response

HTTP/1.1 200 OK
ETag: -801135512
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
"name":"Flint HS Mice",
"annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/annotations",
"id":"agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww",
"version":"0.0.1",
"creator":"Jonathan Flint",
"description":null,
"creationDate":1296690549675,
"status":"Future",
"uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww",
"etag":"-801135512",
"releaseDate":null,
"layers":[
{
         "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
         "type":"E",
         "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww"
      },{
         "id":"use this uri to make a new layer",
         "type":"hack",
         "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer"
      }
]
}

Update a Layer

In the example below we updated the tissue type.

Request

curl -i -H Accept:application/json -H Content-Type:application/json -X PUT -H ETag:1240467407 -d '
{
   "name":"Flint HS Mice Affy",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "type":"E",
   "version":"0.0.1",
   "description":"this is a description",
   "creationDate":1296690778880,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "etag":"1240467407",
   "publicationDate":null,
   "releaseNotes":"this is a release note",
   "tissueType":"liver",
   "platform":null,
   "processingFacility":null,
   "qcBy":null,
   "qcDate":null
}' http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww

Response

HTTP/1.1 200 OK
ETag: 1424771925
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "name":"Flint HS Mice Affy",
   "annotations":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "type":"E",
   "version":"0.0.1",
   "description":"this is a description",
   "creationDate":1296690778880,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "etag":"1424771925",
   "publicationDate":null,
   "releaseNotes":"this is a release note",
   "tissueType":"liver",
   "platform":null,
   "processingFacility":null,
   "qcBy":null,
   "qcDate":null
}

Delete a layer

Request

curl -i -X DELETE http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww

Response

HTTP/1.1 204 No Content
Server: Jetty(6.1.x)

Add annotations to a layer

Request

curl -i -H Accept:application/json -H Content-Type:application/json -X PUT -H ETag:923521 -d '
{
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "etag":"923521",
   "stringAnnotations":{
      "notes":["I threw away 6 samples during the curation process due to gender chromosome mismatches"]
   },
   "floatAnnotations":{

   },
   "dateAnnotations":{

   }
}' http://localhost:8080/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations

Response

HTTP/1.1 200 OK
ETag: -1897035229
Content-Type: application/json
Transfer-Encoding: chunked
Server: Jetty(6.1.x)

{
   "id":"agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww",
   "creationDate":null,
   "uri":"/repo/v1/dataset/agxkZWZsYXV4LXRlc3RyEwsSDUdBRUpET0RhdGFzZXQYUww/layer/agxkZWZsYXV4LXRlc3RyLgsSDUdBRUpET0RhdGFzZXQYUwwLEhRHQUVKRE9JbnB1dERhdGFMYXllchjoBww/annotations",
   "etag":"-1897035229",
   "stringAnnotations":{
      "notes":[
         "I threw away 6 samples during the curation process due to gender chromosome mismatches"
      ]
   },
   "floatAnnotations":{

   },
   "dateAnnotations":{

   }
}
  • No labels