diff --git a/docs/param-search/data-query-download-example.md b/docs/param-search/data-query-download-example.md index 44b96cf..74770dc 100644 --- a/docs/param-search/data-query-download-example.md +++ b/docs/param-search/data-query-download-example.md @@ -13,17 +13,17 @@ This example uses the command line tool `curl` to execute queries. The [Example ### Example Query and Download -The following query will return all Histology (`dataset_type=Histology`) Datasets run on a Keyence BZ-X800 machine (`ingest_metadata.metadata.acquisition_instrument_model=BZ-X800`) where tissue from a heart was used (`origin_sample.organ=HT`). See the [RESTful parameterized search page](index.html) for further information on querying dataset, organ (`origin_sample.organ` represents the organ in the query and `HT` is the organ code (organ code list available [here](schema-sample.html#organ-attribute-values)) and dataset metadata fields. +The following query will return all Histology (`dataset_type=Histology`) Datasets run on a Keyence BZ-X800 machine (`ingest_metadata.metadata.acquisition_instrument_model=BZ-X800`) where tissue from a heart was used (`origin_samples.organ=HT`). See the [RESTful parameterized search page](index.html) for further information on querying dataset, organ (`origin_samples.organ` represents the organ in the query and `HT` is the organ code (organ code list available [here](schema-sample.html#organ-attribute-values)) and dataset metadata fields. ``` - GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_sample.organ=HT + GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_samples.organ=HT ``` As is, if this query is submitted via HTTP GET it will produce a json Response with an array of dataset objects which match the query. Adding the `produce-clt-manifest=true` option to this query will instead produce a list of Dataset IDs pointing to the Datasets that match this query in a format that will be directly usable by the [SenNet Command Line Transfer Tool](/libraries/clt/). To run this from the command line and save the results to a file run: ``` -curl "https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_sample.organ=HT&produce-clt-manifest=true" > dataset-manifest-for-download.out +curl "https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_samples.organ=HT&produce-clt-manifest=true" > dataset-manifest-for-download.out ``` This results in a file that looks like: diff --git a/docs/param-search/example-data-query-and-download-jupyter-notebook.ipynb b/docs/param-search/example-data-query-and-download-jupyter-notebook.ipynb index 8e0847e..9b3e9c0 100644 --- a/docs/param-search/example-data-query-and-download-jupyter-notebook.ipynb +++ b/docs/param-search/example-data-query-and-download-jupyter-notebook.ipynb @@ -32,10 +32,10 @@ "\n", "### Example Query and Download\n", "\n", - "The following query will return all Histology (`dataset_type=Histology`) Datasets run on a Keyence BZ-X800 machine (`ingest_metadata.metadata.acquisition_instrument_model=BZ-X800`) where tissue from a heart was used (`origin_sample.organ=HT`). See the [RESTful parameterized search page](https://docs.sennetconsortium.org/index.html) for further information on querying dataset, organ (`origin_sample.organ`) represents the organ in the query and `HT` is the organ code (organ code list available [here](https://docs.sennetconsortium.org/param-search/schema-sample.html#organ-attribute-values)) and dataset metadata fields.\n", + "The following query will return all Histology (`dataset_type=Histology`) Datasets run on a Keyence BZ-X800 machine (`ingest_metadata.metadata.acquisition_instrument_model=BZ-X800`) where tissue from a heart was used (`origin_samples.organ=HT`). See the [RESTful parameterized search page](https://docs.sennetconsortium.org/index.html) for further information on querying dataset, organ (`origin_samples.organ`) represents the organ in the query and `HT` is the organ code (organ code list available [here](https://docs.sennetconsortium.org/param-search/schema-sample.html#organ-attribute-values)) and dataset metadata fields.\n", "\n", "```\n", - "GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_sample.organ=HT\n", + "GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_samples.organ=HT\n", "```\n", "\n", "#### Producing a CLT manifest file\n", @@ -43,7 +43,7 @@ "As is, if this query is submitted via HTTP GET it will produce a json Response with an array of dataset objects which match the query. Adding the `produce-clt-manifest=true` option to this query will instead prduce a list of Dataset IDs pointing to the Datasets that match this query in a format that will be directly usable by the [SenNet Command Line Transfer Tool](https://docs.sennetconsortium.org/libraries/clt/).\n", "\n", "```\n", - "GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_sample.organ=HT&produce-clt-manifest=true\n", + "GET https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_samples.organ=HT&produce-clt-manifest=true\n", "```\n", "\n", "#### Make the query request and get the manifest information\n", @@ -62,7 +62,7 @@ "import requests\n", "\n", "#run the query, get the results, report any errors\n", - "query_url = 'https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_sample.organ=HT&produce-clt-manifest=true'\n", + "query_url = 'https://search.api.sennetconsortium.org/param-search/datasets?dataset_type=Histology&ingest_metadata.metadata.acquisition_instrument_model=BZ-X800&origin_samples.organ=HT&produce-clt-manifest=true'\n", "try:\n", " manifest_text = None\n", " \n", diff --git a/docs/param-search/index.md b/docs/param-search/index.md index abe3bca..9080d29 100644 --- a/docs/param-search/index.md +++ b/docs/param-search/index.md @@ -51,9 +51,9 @@ A json array containing Dataset objects will be returned. --- -To find all Histology datasets (`dataset_type=Histology`) that were run on tissue from a right lung (`origin_sample.organ=RL`): +To find all Histology datasets (`dataset_type=Histology`) that were run on tissue from a right lung (`origin_samples.organ=RL`): ``` - GET https://search.api.sennetconsortium.org/param-search/datasets?origin_sample.organ=RL&dataset_type=Histology + GET https://search.api.sennetconsortium.org/param-search/datasets?origin_samples.organ=RL&dataset_type=Histology ``` A json array containing Dataset objects will be returned. @@ -61,12 +61,12 @@ A json array containing Dataset objects will be returned. To run the same query finding all Histology datasets, but produce a manifest file to download all of the data instead of producing the json of all dataset information, add the `produce-clt-manifest=true` option ``` - GET https://search.api.sennetconsortium.org/param-search/datasets?origin_sample.organ=RL&dataset_type=Histology&produce-clt-manifest=true + GET https://search.api.sennetconsortium.org/param-search/datasets?origin_samples.organ=RL&dataset_type=Histology&produce-clt-manifest=true ``` This will produce a list of dataset ids in a format usable by the [SenNet Command Line Transfer Tool](/libraries/clt/) to download the data. A Linux/MAC command line example of how to produce a manifest file: ``` -curl "https://search.api.sennetconsortium.org/param-search/datasets?origin_sample.organ=RL&dataset_type=Histology&produce-clt-manifest=true" > manifest.out +curl "https://search.api.sennetconsortium.org/param-search/datasets?origin_samples.organ=RL&dataset_type=Histology&produce-clt-manifest=true" > manifest.out ``` diff --git a/docs/param-search/schema-dataset.md b/docs/param-search/schema-dataset.md index 284c086..21f1650 100644 --- a/docs/param-search/schema-dataset.md +++ b/docs/param-search/schema-dataset.md @@ -34,7 +34,7 @@ This example finds all Datasets of type `RNAseq` where specific molecules are no | ingest_metadata.metadata | JSON-encoded string for a supported [assay type schema](#assay-type-schemas) | The assay level metadata submitted by data providers with data. Provided as json. Metadata schemas per dataset_type are linked from the [dataset type allowable values section](#dataset_type-allowable-values).| | dataset_type | string [dataset type allowable values](#dataset_type-allowable-values) | The type of data contained in the dataset (as derived from a specific assay type | | source | Source Object | The source from which the tissue was taken for the assay. The sub-attributes under source are specified in the [Source Schema](schema-source.html) | -| origin_sample | Sample Object Array | The organ from which the tissue was taken for the assay. The sub-attributes under origin_samples are specified in the [Sample Schema](schema-sample.html). This is modeled as an array because it is possible for data to be derived from multiple organs, but currently SenNet only has data derived from a single organ. | +| origin_samples | Sample Object Array | The organ from which the tissue was taken for the assay. The sub-attributes under origin_sampless are specified in the [Sample Schema](schema-sample.html). This is modeled as an array because it is possible for data to be derived from multiple organs, but currently SenNet only has data derived from a single organ. | ### `data_access_level` attribute values diff --git a/docs/param-search/schema-sample.md b/docs/param-search/schema-sample.md index 6cf978e..6efaa34 100644 --- a/docs/param-search/schema-sample.md +++ b/docs/param-search/schema-sample.md @@ -17,7 +17,7 @@ A query string is built by combining schema elements documented below with match Query terms may be composited from attributes deeper in the schema type of an attribute. For example, the Sample Schema attribute ```metadata``` is has a type of [Sample Metadata Schema](/libraries/ingest-validation-tools/schemas/), and Sample `Block` Metadata Schema has an attribute ```preparation_condition```. Querying Samples supports a term to search for sample blocks with a preparation condition, such as ```metadata.preparation_condition=Frozen%20on%20ice```, and a query like: ``` -GET https://search.api.sennetconsortium.org/param-search/samples?metadata.preparation_condition=Frozen%20on%20ice&origin_sample.organ=HT +GET https://search.api.sennetconsortium.org/param-search/samples?metadata.preparation_condition=Frozen%20on%20ice&origin_samples.organ=HT ``` | Attribute | Type | Description |