Search via the Datasets API

šŸš§

On this page:

Overview

Search through datasets using the Datasets API by issuing GET requests. On this page, we'll introduce the structure of two types of search requests: search by term and search by Unique Resource Identifier (URI). First, search by term to find all exact matches for your free-text search across all databases. Then, use the URIs obtained in the initial search to obtain further details, including individual members matching the designated resource.

Search by term

This is a free-text search by term for exact matches in the metadata across all databases. Use search terms fro metadata for this request. Learn more about metadata for datasets.

Path

http://datasets-api.sbgenomics.com/search

Header fields

NameDescription
X-SBG-Auth-Token
required
Your authentication token

Query parameters

NameDatatypeDescription
termstringData matching this search term will be returned. Note that the term must be an exact complete string for the results to match.

Example request

GET /search?term=brca HTTP/1.1
Host: datasets-api.sbgenomics.com
X-SBG-Auth-Token: 7942f56901534434a054dafc3813bc96

Example response

This will return a list of results from datasets accessible through the Platform, grouped by the dataset to which they belong, as shown below.

{
  "tcga": [
    {
      "type": "http://www.w3.org/2002/07/owl#NamedIndividual",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/tcga/disease_type/brca"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2014/11/tcga#Utility",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/tcga/disease_type/brca"
    },
    {
      "type": "http://www.w3.org/2000/01/rdf-schema#Resource",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/tcga/disease_type/brca"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2014/11/tcga#Diagnosis",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/tcga/disease_type/brca"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2014/11/tcga#DiseaseType",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/tcga/disease_type/brca"
    },
    {
      "type": "http://www.w3.org/2002/07/owl#NamedIndividual",
      "label": "TCGA-BRCA",
      "uri": "https://www.sbgenomics.com/tcga/investigation/tcga-brca"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2014/11/tcga#Utility",
      "label": "TCGA-BRCA",
      "uri": "https://www.sbgenomics.com/tcga/investigation/tcga-brca"
    },
    {
      "type": "http://www.w3.org/2000/01/rdf-schema#Resource",
      "label": "TCGA-BRCA",
      "uri": "https://www.sbgenomics.com/tcga/investigation/tcga-brca"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2014/11/tcga#Investigation",
      "label": "TCGA-BRCA",
      "uri": "https://www.sbgenomics.com/tcga/investigation/tcga-brca"
    }
  ],
  "ccle": [
    {
      "type": "http://www.w3.org/2002/07/owl#NamedIndividual",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/ccle/disease_type_abbr/03"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2016/5/ccle#Clinical",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/ccle/disease_type_abbr/03"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2016/5/ccle#DiseaseTypeAbbreviation",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/ccle/disease_type_abbr/03"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2016/5/ccle#Utility",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/ccle/disease_type_abbr/03"
    },
    {
      "type": "http://www.w3.org/2000/01/rdf-schema#Resource",
      "label": "BRCA",
      "uri": "https://www.sbgenomics.com/ccle/disease_type_abbr/03"
    },
    {
      "type": "http://www.w3.org/2002/07/owl#NamedIndividual",
      "label": "CCLE-BRCA",
      "uri": "https://www.sbgenomics.com/ccle/investigation/03"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2016/5/ccle#Investigation",
      "label": "CCLE-BRCA",
      "uri": "https://www.sbgenomics.com/ccle/investigation/03"
    },
    {
      "type": "https://www.sbgenomics.com/ontologies/2016/5/ccle#Utility",
      "label": "CCLE-BRCA",
      "uri": "https://www.sbgenomics.com/ccle/investigation/03"
    },
    {
      "type": "http://www.w3.org/2000/01/rdf-schema#Resource",
      "label": "CCLE-BRCA",
      "uri": "https://www.sbgenomics.com/ccle/investigation/03"
    }
  ]
}

For each result, the response lists:

  • Its type: This is an URI assigned to a property within a hosted database's namespace or within the RDF Schema namespace defined by W3C which contains the result.
  • Its label: This is a human-readable form of a result.
  • Its uri: This is an URI assigned to an entity and its ID within a hosted database's namespace.

Note if your search term does not match any results, empty brackets [] are returned.

Search by URI

Start from a free-text search by term request, as described above. Use an uri obtained in the response as the starting point to obtain further details, including individual members matching the designated resource. Note that this uri must be in a URL-encoded format.

Path

http://datasets-api.sbgenomics.com/describe

Header fields

NameDescription
X-SBG-Auth-Token
required
Your authentication token

Query parameters

NameDatatypeDescription
uristringUse an uri obtained via a search by term request. Note that only exact results will be returned. This uri must be in a URL-encoded format.

Example request

GET /describe?uri=https%3A%2F%2Fwww.sbgenomics.com%2Fccle%2Finvestigation%2F03 HTTP/1.1
Host: datasets-api.sbgenomics.com
X-SBG-Auth-Token: 7942f56901534434a054dafc3813bc96

Example response

This will return a list of results from datasets accessible through the Platform, as shown below.

{
  "tcga": {},
  "uri": "https://www.sbgenomics.com/ccle/investigation/03",
  "ccle": {
    "http://www.w3.org/2000/01/rdf-schema#label": [
      "CCLE-BRCA"
    ],
    "https://www.sbgenomics.com/ontologies/2016/5/ccle#hasInvestigation": [
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-AU565",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-BT-20",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-BT-474",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-BT-483",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-BT-549",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-CAL-120",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-CAL-148",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-CAL-51",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-CAL-85-1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-CAMA-1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-DU4475",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-EFM-19",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-EFM-192A",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1143",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1143BL",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1187",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1395",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1419",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1428",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1500",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1569",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1599",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1806",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1937",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1954",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC1954BL",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC202",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC2157",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC2218",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC38",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HCC70",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HDQ-P1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-HMC-1-8",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs274.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs281.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs343.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs578T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs606.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs739.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-Hs742.T",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-JIMT-1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-KPL-1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MCF7",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-134-VI",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-157",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-175-VII",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-231",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-361",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-415",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-435S",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-436",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-453",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-MDA-MB-468",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-SK-BR-3",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-T-47D",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-UACC-812",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-UACC-893",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-ZR-75-1",
      "https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-ZR-75-30"
    ],
    "http://www.w3.org/1999/02/22-rdf-syntax-ns#type": [
      "http://www.w3.org/2002/07/owl#NamedIndividual",
      "https://www.sbgenomics.com/ontologies/2016/5/ccle#Investigation",
      "https://www.sbgenomics.com/ontologies/2016/5/ccle#Utility",
      "http://www.w3.org/2000/01/rdf-schema#Resource"
    ]
  }
}

For each result, the response lists the URIs for the individual members of each property which matches your search terms. For instance, the cell line https://www.sbgenomics.com/ccle/ccle_cell_line/CCLE-AU565 is returned for https://www.sbgenomics.com/ontologies/2016/5/ccle#hasInvestigation.

Note if your search term does not match any results, empty brackets {} are returned.