-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathrnaget-openapi.yaml
1478 lines (1407 loc) · 58.4 KB
/
rnaget-openapi.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.0
servers:
- url: /rnaget
info:
title: RNAget API
description: |
## Design principles
This API provides a means of retrieving data from several types of RNA experiments including:
* Feature-level expression data from RNA-seq type measurements
* Coordinate-based signal/intensity data similar to a bigwig representation
via a client/server model.
Features of this API include:
* Support for a hierarchical data model which provides the option for servers to associate expression data for discovery and retrieval
* Support for accessing subsets of expression data through slicing operations on the expression matrix and/or query filters to specify features to be included
* Support for accessing signal/intensity data by specifying a range of genomic coordinates to be included
Out of the scope of this API are:
* A means of retrieving primary (raw) read sequence data. Input samples are identified in expression output and data servers should implement additional API(s) to allow for search and retrieval of raw reads. The [htsget API](https://samtools.github.io/hts-specs/htsget.html) is designed for retrieval of read data.
* A means of retrieving reference sequences. Servers should implement additional API(s) to allow for search and retrieval of reference base sequences. The [refget API](https://samtools.github.io/hts-specs/refget.html) is designed for retrieval of references sequences.
* A means of retrieving feature annotation details. Expression matrices provide the identity of each mapped feature. Servers should implement additional API(s) to allow for search and retrieval of genomic feature annotation details.
## OpenAPI Description
An OpenAPI description of this specification is available and [describes the 1.2.0 version](https://github.com/ga4gh-rnaseq/schema/blob/master/rnaget-openapi.yaml). OpenAPI is an independent API description format for describing REST services and is compatible with a number of [third party tools](http://openapi.tools/).
## Compliance
Implementors can check if their RNAget implementations conform to the
specification by using our [compliance suite](https://github.com/ga4gh-rnaseq/rnaget-compliance-suite).
## Protocol essentials
All API invocations are made to a configurable HTTPS endpoint, receive URL-encoded query string parameters and HTTP headers, and return text or other allowed formatting as requested by the user. Queries containing [unsafe or reserved](https://www.ietf.org/rfc/rfc1738.txt) characters in the URL, including but not limited to "&", "/", "#", MUST encode all such characters. Successful requests result with HTTP status code 200 and have the appropriate text encoding in the response body as defined for each endpoint. The server may provide responses with chunked transfer encoding. The client and server may mutually negotiate HTTP/2 upgrade using the standard mechanism.
HTTP responses may be compressed using [RFC 2616](https://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html) transfer-coding, not content-coding.
HTTP response may include a 3XX response code and Location header redirecting the client to retrieve expression data from an alternate location as specified by [RFC 7231](https://tools.ietf.org/html/rfc7231), clients SHOULD be configured to follow redirects. `302`, `303` and `307` are all valid response codes to use.
Responses from the server MUST include a Content-Type header containing the encoding for the invoked method and protocol version. Unless negotiated with the client and allowed by the server, the default encoding is:
```
Content-Type: application/vnd.ga4gh.rnaget.v1.2.0+json; charset=us-ascii
```
All response objects from the server are expected to be in JSON format, regardless of the response status code, unless otherwise negotiated with the client and allowed by the server.
Object IDs are intended for persistent retrieval of their respective objects. An object ID MUST uniquely identify an object within the scope of a single data server. It is beyond the scope of this API to enforce uniqueness of ID among different data servers. IDs are strings made up of uppercase and lowercase letters, decimal digits, hypen, period, underscore and tilde [A-Za-z0-9.-_~]. See [RFC 3986 § 2.3](https://tools.ietf.org/html/rfc3986#section-2.3).
Endpoints are described as HTTPS GET methods which will be sufficient for most queries. Queries containing multiple metadata filters may approach or exceed the URL length limits. To handle these types of queries it is recommended that servers SHOULD implement parallel HTTPS POST endpoints accepting the same URL parameters as a UTF8-encoded JSON key-value dictionary.
When processing requests containing multiple filters and filters with lists of items, the data provider MUST use a logical `AND` for selecting the results to return.
## Internet Media Types Handling
When responding to a request a server MUST use the fully specified media type for that endpoint. When determining if a request is well-formed, a server MUST allow a internet type to degrade like so
- `application/vnd.ga4gh.rnaget.v1.2.0+json; charset=us-ascii`
- `application/vnd.ga4gh.rnaget.v1.2.0+json`
- `application/json`
## Errors
The server MUST respond with an appropriate HTTP status code (4xx or 5xx) when an error condition is detected. In the case of transient server errors (e.g., 503 and other 5xx status codes), the client SHOULD implement appropriate retry logic. For example, if a client sends an alphanumeric string for a parameter that is specified as unsigned integer the server MUST reply with `Bad Request`.
| Error type | HTTP status code | Description
|-------------------|------------------|-------------|
| `Bad Request` | 400 | Cannot process due to malformed request, the requested parameters do not adhere to the specification |
| `Unauthorized` | 401 | Authorization provided is invalid |
| `Not Found` | 404 | The resource requested was not found |
| `Not Acceptable` | 406 | The requested formatting is not supported by the server |
| `Not Implemented` | 501 | The specified request is not supported by the server |
## Security
The RNAget API can be used to retrieve potentially sensitive genomic data and is dependent on the implementation. Effective security measures are essential to protect the integrity and confidentiality of these data.
Sensitive information transmitted on public networks, such as access tokens and human genomic data, MUST be protected using Transport Level Security (TLS) version 1.2 or later, as specified in [RFC 5246](https://tools.ietf.org/html/rfc5246).
If the data holder requires client authentication and/or authorization, then the client's HTTPS API request MUST present an OAuth 2.0 bearer access token as specified in [RFC 6750](https://tools.ietf.org/html/rfc6750), in the Authorization request header field with the Bearer authentication scheme:
```
Authorization: Bearer [access_token]
```
Data providers SHOULD verify user identity and credentials. The policies and processes used to perform user authentication and authorization, and the means through which access tokens are issued, are beyond the scope of this API specification. GA4GH recommends the use of the OAuth 2.0 framework ([RFC 6749](https://tools.ietf.org/html/rfc6749)) for authentication and authorization. It is also recommended that implementations of this standard also implement and follow the GA4GH [Authentication and Authorization Infrastructure (AAI) standard](https://docs.google.com/document/d/1zzsuNtbNY7agPRjfTe6gbWJ3BU6eX19JjWRKvkFg1ow).
## CORS
Cross-origin resource sharing (CORS) is an essential technique used to overcome the same origin content policy seen in browsers. This policy restricts a webpage from making a request to another website and leaking potentially sensitive information. However the same origin policy is a barrier to using open APIs. GA4GH open API implementers should enable CORS to an acceptable level as defined by their internal policy. For any public API implementations should allow requests from any server.
GA4GH is publishing a [CORS best practices document](https://docs.google.com/document/d/1Ifiik9afTO-CEpWGKEZ5TlixQ6tiKcvug4XLd9GNcqo/edit?usp=sharing), which implementers should refer to for guidance when enabling CORS on public API instances.
## Filtering Results
Some endpoints describe optional filters to select and limit the results returned. Requests supplying none of the filters may return large amounts of data and expose the data provider to the risk of Distributed Denial of Service (DDoS) attacks. Implementors SHOULD limit the size of return matrices to an appropriate value which their server can support.
## Possible Future API Enhancements
- Allow OR for search filters
- Report size of download file
- Matrix slicing with bool array or list of indices
## API specification change log
1.2.0 Adds parameters and endpoint to specify matrix units
Add sample filtering by min and/or max values
1.1.0 Adds /service-info endpoint
1.0.0 Initial release version
version: 1.2.0
contact:
name: GA4GH RNA-seq Working Group
email: [email protected]
license:
name: Apache 2.0
url: https://github.com/ga4gh-rnaseq/schema/blob/master/LICENSE
externalDocs:
description: Find out more about GA4GH
url: http://ga4gh.org
tags:
- name: projects
description: |
The project is the top level of the model hierarchy and contains a set of related studies. Example projects include:
* all data submitted by contributor X
* the local mirror of the European Nucleotide Archive data
externalDocs:
description: Find out more
url: https://github.com/ga4gh-rnaseq/schema
- name: studies
description: |
The study is a set of related RNA expression values. It is assumed all samples in a study have been processed uniformly. Example studies include:
* multiple tissues from all patients enrolled in clinical trial X
* a collection of liver samples from several sources which have been uniformly reprocessed for differential analysis
externalDocs:
description: Find out more
url: https://github.com/ga4gh-rnaseq/schema
- name: expressions
description: |
The expression is a matrix of calculated expression values.
##### Expression metadata
This describes a set of minimal metadata appropriate for several types of RNA experiments. The purpose is to define a common naming scheme for metadata to enable client software to have some expectation of data fields for improved interoperability. These definitions are not intended to be a comprehensive set of metadata and defining such a universal set is beyond the scope of this effort.
Where possible details are incorporated by reference. This is to reduce the final size of matrix files, support existing metadata standards and support server-defined metadata fields.
All field names are presented here in camel case. Parsers should treat field names as case-insensitive and any white space contained in the field names should be ignored:
sampleID == sampleid == Sample ID != sample_id
All fields are optional. Fields that utilize an ontology term assume both an id and a label. Later implementations will utilize schemablocks and/or Phenopackets as referenced entities.
| Metadata Field | Description
|------------------|-------------|
| sampleID | an identifier for the biological specimen the experiment was conducted on. This id MUST uniquely identify the sample within the scope of the server |
| assayType | the type of experiment performed (ex. RNA-seq, ATAC-seq, ChIP-seq, DNase-Hypersensitivity, methylation profiling, histone profiling, microRNA profiling, transcription profiling, WGS) |
| samplePrepProtocol | reference to a resource or webpage describing the protocol used to obtain and prepare the sample |
| libraryPrepProtocol | reference to a resource or webpage describing the protocol used to prepare the library for sequencing |
| annotation | a reference to the specific annotation used for quantifying the reads |
| analysisPipeline | reference to a resource or webpage describing the analysis protocol. This description should include a full listing of all software used including the exact version and command line options used. If containerized software is used a reference to the specific containers should be included. The GA4GH [Tool Registry Service](https://github.com/ga4gh/tool-registry-service-schemas) is a resource for discovering and registering genomic tools and workflows. |
| cellTypeID | a cell type term ID |
| cellTypeLabel | a cell type term label from the [CL ontology](http://www.ontobee.org/ontology/CL) |
| phenotypeID | phenotype ID applicable to the sample |
| phenotypeLabel | phenotype term (recommended ontologies: [Human Phenotype Ontology](http://www.human-phenotype-ontology.org/), [NCIT](http://www.obofoundry.org/ontology/ncit.html), or [ICD](https://www.icd10data.com/)) |
| sexID | sex ID of the organism providing the sample |
| sexTerm | sex label of the organism providing the sample [PATO 47 term](http://purl.obolibrary.org/obo/PATO_0000047) |
| organismID | organism ID for the sample origin |
| organismlabel | organism label for the sample origin [NCBITaxon](http://www.obofoundry.org/ontology/ncbitaxon.html) |
| tissueID | tissue ID of origin or organism part of origin |
| tissueLabel | tissue Label of origin or organism part of origin (recommended to use [Uberon](http://www.obofoundry.org/ontology/uberon.html) |
| cellLineID | ID of cell line |
| cellLineLabel | Label of [cell line](http://www.ontobee.org/ontology/CLO) |
For metadata ID values it is recommended that implementors use the `id:label` CURIE notation as described in [Identifiers and CURIEs](https://schemablocks.org/standards/identifiers-curies.html)
#### Example metadata using CURIE
| Metadata Field | Value
|------------------|------------------|
| `organismID` | `NCBITaxon:9606` |
| `organismLabel` | `human` |
##### The meaning of zero
Microarray and image-based RNA-seq (Seq-FISH etc.) have a dependency on probes which may not have 100% coverage of the annotation reference. The consequence is that some features which show zero expression may not necessarily have a truly zero expression. This idea can be extended further in the context of submitted data as well as potentially access restricted data. The result is that a zero value can indicate one of several states:
1. _Not measured_ - not measured at all and value is not available
2. _Not supplied_ - measured but not provided to the data repository
3. _Restricted access_ - measured but require further authentication to view
4. _Not applicable_ - measurement does not apply to the sample
If applicable, the `NaN` value MUST be used to indicate these states.
externalDocs:
description: Find out more
url: https://github.com/ga4gh-rnaseq/schema
- name: continuous
description: Continuous is a matrix of coordinate range based signal data
externalDocs:
description: Find out more
url: https://github.com/ga4gh-rnaseq/schema
- name: Service Info
description: |
The GA4GH Service Info specification provides a GA4GH-wide, structured format
for describing web services implementing GA4GH API specifications. RNAget
implements service info through the standard `/service-info` API endpoint,
and also extends the base model with additional attributes.
RNAget services MUST indicate that they support the RNAget protocol by
using an `artifact` value of `rnaget` in the service info `type` property.
```
{
...
"type": {
"group": "org.ga4gh",
"artifact": "rnaget",
"version": "1.2.0"
}
...
}
```
externalDocs:
description: View the Service Info specification
url: https://github.com/ga4gh-discovery/ga4gh-service-info
- name: projectModel
x-displayName: The Project Model
description: |
<SchemaDefinition schemaRef="#/components/schemas/project" />
- name: studyModel
x-displayName: The Study Model
description: |
<SchemaDefinition schemaRef="#/components/schemas/study" />
- name: filterModel
x-displayName: The Filter Model
description: |
<SchemaDefinition schemaRef="#/components/schemas/filter" />
- name: ticketModel
x-displayName: The Ticket Model
description: |
<SchemaDefinition schemaRef="#/components/schemas/ticket" />
x-tagGroups:
- name: Interface
tags:
- projects
- studies
- expressions
- continuous
- Service Info
- name: Models
tags:
- projectModel
- studyModel
- filterModel
- ticketModel
paths:
"/projects/{projectId}":
get:
tags:
- projects
summary: Get a single project by ID
description: Returns the project matching the provided ID
operationId: getProjectById
parameters:
- name: projectId
in: path
description: ID of project to return
required: true
schema:
type: string
responses:
"200":
description: successful operation
content:
application/json:
schema:
$ref: "#/components/schemas/project"
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Project not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:project
/projects:
get:
tags:
- projects
summary: Returns a list of projects matching filters
description: Get a list of projects matching filters
operationId: getProjects
parameters:
- $ref: "#/components/parameters/versionParam"
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/project"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:project
/projects/filters:
get:
tags:
- projects
summary: Returns filters for project searches
description: To support flexible search this provides a means of discovering the search filters supported by the data provider.
operationId: getProjectFilters
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/filter"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:project
"/studies/{studyId}":
get:
tags:
- studies
summary: Get a single study by ID
description: Returns the study matching the provided ID
operationId: getStudyById
parameters:
- name: studyId
in: path
description: ID of study to return
required: true
schema:
type: string
responses:
"200":
description: successful operation
content:
application/json:
schema:
$ref: "#/components/schemas/study"
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Study not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:study
/studies:
get:
tags:
- studies
summary: Returns a list of studies matching filters
description: Get a list of studies matching filters
operationId: getStudies
parameters:
- $ref: "#/components/parameters/versionParam"
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/study"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:study
/studies/filters:
get:
tags:
- studies
summary: Returns filters for study searches
description: To support flexible search this provides a means of discovering the search filters supported by the data provider.
operationId: getStudyFilters
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/filter"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:study
"/expressions/{expressionId}/ticket":
get:
tags:
- expressions
summary: Get specific expression data ticket
description: Returns a ticket to download a single specified expression matrix
operationId: getExpressionTicketById
parameters:
- name: expressionId
in: path
description: ID of expression to return
required: true
schema:
type: string
- $ref: "#/components/parameters/sampleIDListParam"
- $ref: "#/components/parameters/featureIDListParam"
- $ref: "#/components/parameters/featureNameListParam"
- $ref: "#/components/parameters/featureMinParam"
- $ref: "#/components/parameters/featureMaxParam"
- $ref: "#/components/parameters/unitsParam"
responses:
"200":
description: successful operation
content:
application/json:
schema:
$ref: "#/components/schemas/ticket"
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Expression not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
"/expressions/{expressionId}/bytes":
get:
tags:
- expressions
summary: Get specific expression data file
description: Returns a single specified expression matrix
operationId: getExpressionFileById
parameters:
- name: expressionId
in: path
description: ID of expression to return
required: true
schema:
type: string
- $ref: "#/components/parameters/sampleIDListParam"
- $ref: "#/components/parameters/featureIDListParam"
- $ref: "#/components/parameters/featureNameListParam"
- $ref: "#/components/parameters/featureMinParam"
- $ref: "#/components/parameters/featureMaxParam"
- $ref: "#/components/parameters/unitsParam"
responses:
"200":
description: successful operation
content:
application/octet-stream:
schema:
type: string
format: binary
application/vnd.loom:
schema:
type: string
format: binary
text/tab-separated-values:
schema:
type: string
format: binary
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Expression not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
/expressions/ticket:
get:
tags:
- expressions
summary: Get a ticket to download expression data
description: Returns a download ticket for expression data matching filters
operationId: getExpressionTicket
parameters:
- name: format
in: query
description: Data format to return
required: true
schema:
type: string
- $ref: "#/components/parameters/projectIDParam"
- $ref: "#/components/parameters/studyIDParam"
- $ref: "#/components/parameters/versionParam"
- $ref: "#/components/parameters/sampleIDListParam"
- $ref: "#/components/parameters/featureIDListParam"
- $ref: "#/components/parameters/featureNameListParam"
- $ref: "#/components/parameters/featureMinParam"
- $ref: "#/components/parameters/featureMaxParam"
- $ref: "#/components/parameters/unitsParam"
responses:
"200":
description: Successful operation
content:
application/json:
schema:
$ref: "#/components/schemas/ticket"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
/expressions/bytes:
get:
tags:
- expressions
summary: Download expression data matching filters
description: Returns an expression data file matching filters
operationId: getExpressionFile
parameters:
- name: format
in: query
description: Data format to return
required: true
schema:
type: string
- $ref: "#/components/parameters/projectIDParam"
- $ref: "#/components/parameters/studyIDParam"
- $ref: "#/components/parameters/versionParam"
- $ref: "#/components/parameters/sampleIDListParam"
- $ref: "#/components/parameters/featureIDListParam"
- $ref: "#/components/parameters/featureNameListParam"
- $ref: "#/components/parameters/featureMinParam"
- $ref: "#/components/parameters/featureMaxParam"
- $ref: "#/components/parameters/unitsParam"
responses:
"200":
description: Successful operation
content:
application/octet-stream:
schema:
type: string
format: binary
application/vnd.loom:
schema:
type: string
format: binary
text/tab-separated-values:
schema:
type: string
format: binary
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
/expressions/formats:
get:
tags:
- expressions
summary: Get output formats
description: |
The response is a list of the supported data formats as a JSON formatted object unless an alternative formatting supported by the server is requested. A data provider may use any internal storage format that they wish with no restrictions from this API. To support development of interoperable clients, it is recommended that data providers MUST support at least 1 of the following common output formats:
* Tab delimited text (tsv)
* [Loom](https://linnarssonlab.org/loompy/format/index.html) (loom)
* [anndata](https://anndata.readthedocs.io/en/latest/) (anndata)
A Tab delimited file can have any number of comment lines beginning with `#` for storing metadata. There should be one header row following the comments. Feature (genes/transcripts) names and/or ID fields should be the first columns of the header row and have the `string` type. All following columns are for the samples and will have 32-bit `float` values in each row.
##### Example .tsv file
```
# Example tsv file
geneID geneName sample1 sample2
ENSG00000000003 TSPAN6 12.4 15.6
```
A Loom format file will have a 32-bit `float` matrix for the expression values with samples on the column axis and features on the row axis. Associated metadata can be stored as row and column attributes as described by the loom specification.
An anndata format file will have a 32-bit `float` matrix for the expression values with samples on the column axis and features on the row axis. Associated metadata can be stored as row and column attributes as described by the anndata specification.
operationId: getExpressionFormats
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
type: string
"404":
description: Format list not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
/expressions/filters:
get:
tags:
- expressions
summary: Returns filters for expression searches
description: To support flexible search this provides a means of discovering the search filters supported by the data provider.
operationId: getExpressionFilters
parameters:
- name: type
in: query
description: one of `feature` or `sample` reflecting which axis to request
filters for. If blank, both will be returned
required: false
schema:
type: string
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
$ref: "#/components/schemas/filter"
"400":
description: The requested data format is not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
/expressions/units:
get:
tags:
- expressions
summary: Get output units
description: The response is a list of the supported expression units as a JSON formatted object unless an alternative formatting supported by the server is requested. This request is intended to be implemented by data providers who wish to support delivery of expression data in multiple units such as TPM, FPKM and/or counts.
operationId: getExpressionUnits
responses:
"200":
description: successful operation
content:
application/json:
schema:
type: array
items:
type: string
"404":
description: Unit list not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:expression
"/continuous/{continuousId}/ticket":
get:
tags:
- continuous
summary: Get specific continuous data ticket
description: Returns a ticket to download a single specified continuous matrix
operationId: getContinuousTicketById
parameters:
- name: continuousId
in: path
description: ID of continuous matrix to return
required: true
schema:
type: string
- $ref: "#/components/parameters/chrParam"
- $ref: "#/components/parameters/startParam"
- $ref: "#/components/parameters/endParam"
responses:
"200":
description: successful operation
content:
application/json:
schema:
$ref: "#/components/schemas/ticket"
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Continuous matrix not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:continuous
"/continuous/{continuousId}/bytes":
get:
tags:
- continuous
summary: Get specific continuous data file
description: Returns a single specified continuous matrix
operationId: getContinuousFileById
parameters:
- name: continuousId
in: path
description: ID of continuous matrix to return
required: true
schema:
type: string
- $ref: "#/components/parameters/chrParam"
- $ref: "#/components/parameters/startParam"
- $ref: "#/components/parameters/endParam"
responses:
"200":
description: successful operation
content:
application/octet-stream:
schema:
type: string
format: binary
application/vnd.loom:
schema:
type: string
format: binary
text/tab-separated-values:
schema:
type: string
format: binary
"400":
description: Invalid ID supplied
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"404":
description: Continuous matrix not found
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"406":
description: Requested formatting not supported
content:
application/json:
schema:
$ref: "#/components/schemas/error"
"501":
description: The specified request is not supported by the server
content:
application/json:
schema:
$ref: "#/components/schemas/error"
security:
- rnaget_auth:
- read:continuous
/continuous/ticket:
get:
tags:
- continuous
summary: Get a ticket to download continuous data
description: Returns a download ticket for continuous data matching filters
operationId: getContinuousTicket
parameters:
- name: format
in: query
description: Data format to return
required: true
schema: