-
Notifications
You must be signed in to change notification settings - Fork 44
/
index_openapi.json
2277 lines (2277 loc) · 83.4 KB
/
index_openapi.json
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.1.0",
"info": {
"title": "OPTIMADE API - Index meta-database",
"description": "The [Open Databases Integration for Materials Design (OPTIMADE) consortium](https://www.optimade.org/) aims to make materials databases interoperational by developing a common REST API.\nThis is the \"special\" index meta-database.\n\nThis specification is generated using [`optimade-python-tools`](https://github.com/Materials-Consortia/optimade-python-tools/tree/v1.1.6) v1.1.6.",
"version": "1.1.0"
},
"paths": {
"/info": {
"get": {
"tags": [
"Info"
],
"summary": "Get Info",
"operationId": "get_info_info_get",
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/IndexInfoResponse"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"422": {
"description": "Unprocessable Entity",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"500": {
"description": "Internal Server Error",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"501": {
"description": "Not Implemented",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"553": {
"description": "Version Not Supported",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
}
}
},
"/links": {
"get": {
"tags": [
"Links"
],
"summary": "Get Links",
"operationId": "get_links_links_get",
"parameters": [
{
"name": "filter",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "A filter string, in the format described in section API Filtering Format Specification of the specification.",
"default": "",
"title": "Filter"
},
"description": "A filter string, in the format described in section API Filtering Format Specification of the specification."
},
{
"name": "response_format",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "The output format requested (see section Response Format).\nDefaults to the format string 'json', which specifies the standard output format described in this specification.\nExample: `http://example.com/v1/structures?response_format=xml`",
"default": "json",
"title": "Response Format"
},
"description": "The output format requested (see section Response Format).\nDefaults to the format string 'json', which specifies the standard output format described in this specification.\nExample: `http://example.com/v1/structures?response_format=xml`"
},
{
"name": "email_address",
"in": "query",
"required": false,
"schema": {
"anyOf": [
{
"type": "string",
"format": "email"
},
{
"type": "null"
}
],
"description": "An email address of the user making the request.\nThe email SHOULD be that of a person and not an automatic system.\nExample: `http://example.com/v1/[email protected]`",
"title": "Email Address"
},
"description": "An email address of the user making the request.\nThe email SHOULD be that of a person and not an automatic system.\nExample: `http://example.com/v1/[email protected]`"
},
{
"name": "response_fields",
"in": "query",
"required": false,
"schema": {
"type": "string",
"pattern": "([a-z_][a-z_0-9]*(,[a-z_][a-z_0-9]*)*)?",
"description": "A comma-delimited set of fields to be provided in the output.\nIf provided, these fields MUST be returned along with the REQUIRED fields.\nOther OPTIONAL fields MUST NOT be returned when this parameter is present.\nExample: `http://example.com/v1/structures?response_fields=last_modified,nsites`",
"default": "",
"title": "Response Fields"
},
"description": "A comma-delimited set of fields to be provided in the output.\nIf provided, these fields MUST be returned along with the REQUIRED fields.\nOther OPTIONAL fields MUST NOT be returned when this parameter is present.\nExample: `http://example.com/v1/structures?response_fields=last_modified,nsites`"
},
{
"name": "sort",
"in": "query",
"required": false,
"schema": {
"type": "string",
"pattern": "([a-z_][a-z_0-9]*(,[a-z_][a-z_0-9]*)*)?",
"description": "If supporting sortable queries, an implementation MUST use the `sort` query parameter with format as specified by [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-sorting).\n\nAn implementation MAY support multiple sort fields for a single query.\nIf it does, it again MUST conform to the JSON API 1.0 specification.\n\nIf an implementation supports sorting for an entry listing endpoint, then the `/info/<entries>` endpoint MUST include, for each field name `<fieldname>` in its `data.properties.<fieldname>` response value that can be used for sorting, the key `sortable` with value `true`.\nIf a field name under an entry listing endpoint supporting sorting cannot be used for sorting, the server MUST either leave out the `sortable` key or set it equal to `false` for the specific field name.\nThe set of field names, with `sortable` equal to `true` are allowed to be used in the \"sort fields\" list according to its definition in the JSON API 1.0 specification.\nThe field `sortable` is in addition to each property description and other OPTIONAL fields.\nAn example is shown in the section Entry Listing Info Endpoints.",
"default": "",
"title": "Sort"
},
"description": "If supporting sortable queries, an implementation MUST use the `sort` query parameter with format as specified by [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-sorting).\n\nAn implementation MAY support multiple sort fields for a single query.\nIf it does, it again MUST conform to the JSON API 1.0 specification.\n\nIf an implementation supports sorting for an entry listing endpoint, then the `/info/<entries>` endpoint MUST include, for each field name `<fieldname>` in its `data.properties.<fieldname>` response value that can be used for sorting, the key `sortable` with value `true`.\nIf a field name under an entry listing endpoint supporting sorting cannot be used for sorting, the server MUST either leave out the `sortable` key or set it equal to `false` for the specific field name.\nThe set of field names, with `sortable` equal to `true` are allowed to be used in the \"sort fields\" list according to its definition in the JSON API 1.0 specification.\nThe field `sortable` is in addition to each property description and other OPTIONAL fields.\nAn example is shown in the section Entry Listing Info Endpoints."
},
{
"name": "page_limit",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"minimum": 0,
"description": "Sets a numerical limit on the number of entries returned.\nSee [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-pagination).\nThe API implementation MUST return no more than the number specified.\nIt MAY return fewer.\nThe database MAY have a maximum limit and not accept larger numbers (in which case an error code -- 403 Forbidden -- MUST be returned).\nThe default limit value is up to the API implementation to decide.\nExample: `http://example.com/optimade/v1/structures?page_limit=100`",
"default": 20,
"title": "Page Limit"
},
"description": "Sets a numerical limit on the number of entries returned.\nSee [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-pagination).\nThe API implementation MUST return no more than the number specified.\nIt MAY return fewer.\nThe database MAY have a maximum limit and not accept larger numbers (in which case an error code -- 403 Forbidden -- MUST be returned).\nThe default limit value is up to the API implementation to decide.\nExample: `http://example.com/optimade/v1/structures?page_limit=100`"
},
{
"name": "page_offset",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"minimum": 0,
"description": "RECOMMENDED for use with _offset-based_ pagination: using `page_offset` and `page_limit` is RECOMMENDED.\nExample: Skip 50 structures and fetch up to 100: `/structures?page_offset=50&page_limit=100`.",
"default": 0,
"title": "Page Offset"
},
"description": "RECOMMENDED for use with _offset-based_ pagination: using `page_offset` and `page_limit` is RECOMMENDED.\nExample: Skip 50 structures and fetch up to 100: `/structures?page_offset=50&page_limit=100`."
},
{
"name": "page_number",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"description": "RECOMMENDED for use with _page-based_ pagination: using `page_number` and `page_limit` is RECOMMENDED.\nIt is RECOMMENDED that the first page has number 1, i.e., that `page_number` is 1-based.\nExample: Fetch page 2 of up to 50 structures per page: `/structures?page_number=2&page_limit=50`.",
"title": "Page Number"
},
"description": "RECOMMENDED for use with _page-based_ pagination: using `page_number` and `page_limit` is RECOMMENDED.\nIt is RECOMMENDED that the first page has number 1, i.e., that `page_number` is 1-based.\nExample: Fetch page 2 of up to 50 structures per page: `/structures?page_number=2&page_limit=50`."
},
{
"name": "page_cursor",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"minimum": 0,
"description": "RECOMMENDED for use with _cursor-based_ pagination: using `page_cursor` and `page_limit` is RECOMMENDED.",
"default": 0,
"title": "Page Cursor"
},
"description": "RECOMMENDED for use with _cursor-based_ pagination: using `page_cursor` and `page_limit` is RECOMMENDED."
},
{
"name": "page_above",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "RECOMMENDED for use with _value-based_ pagination: using `page_above`/`page_below` and `page_limit` is RECOMMENDED.\nExample: Fetch up to 100 structures above sort-field value 4000 (in this example, server chooses to fetch results sorted by increasing `id`, so `page_above` value refers to an `id` value): `/structures?page_above=4000&page_limit=100`.",
"title": "Page Above"
},
"description": "RECOMMENDED for use with _value-based_ pagination: using `page_above`/`page_below` and `page_limit` is RECOMMENDED.\nExample: Fetch up to 100 structures above sort-field value 4000 (in this example, server chooses to fetch results sorted by increasing `id`, so `page_above` value refers to an `id` value): `/structures?page_above=4000&page_limit=100`."
},
{
"name": "page_below",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "RECOMMENDED for use with _value-based_ pagination: using `page_above`/`page_below` and `page_limit` is RECOMMENDED.",
"title": "Page Below"
},
"description": "RECOMMENDED for use with _value-based_ pagination: using `page_above`/`page_below` and `page_limit` is RECOMMENDED."
},
{
"name": "include",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "A server MAY implement the JSON API concept of returning [compound documents](https://jsonapi.org/format/1.0/#document-compound-documents) by utilizing the `include` query parameter as specified by [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-includes).\n\nAll related resource objects MUST be returned as part of an array value for the top-level `included` field, see the section JSON Response Schema: Common Fields.\n\nThe value of `include` MUST be a comma-separated list of \"relationship paths\", as defined in the [JSON API](https://jsonapi.org/format/1.0/#fetching-includes).\nIf relationship paths are not supported, or a server is unable to identify a relationship path a `400 Bad Request` response MUST be made.\n\nThe **default value** for `include` is `references`.\nThis means `references` entries MUST always be included under the top-level field `included` as default, since a server assumes if `include` is not specified by a client in the request, it is still specified as `include=references`.\nNote, if a client explicitly specifies `include` and leaves out `references`, `references` resource objects MUST NOT be included under the top-level field `included`, as per the definition of `included`, see section JSON Response Schema: Common Fields.\n\n> **Note**: A query with the parameter `include` set to the empty string means no related resource objects are to be returned under the top-level field `included`.",
"default": "references",
"title": "Include"
},
"description": "A server MAY implement the JSON API concept of returning [compound documents](https://jsonapi.org/format/1.0/#document-compound-documents) by utilizing the `include` query parameter as specified by [JSON API 1.0](https://jsonapi.org/format/1.0/#fetching-includes).\n\nAll related resource objects MUST be returned as part of an array value for the top-level `included` field, see the section JSON Response Schema: Common Fields.\n\nThe value of `include` MUST be a comma-separated list of \"relationship paths\", as defined in the [JSON API](https://jsonapi.org/format/1.0/#fetching-includes).\nIf relationship paths are not supported, or a server is unable to identify a relationship path a `400 Bad Request` response MUST be made.\n\nThe **default value** for `include` is `references`.\nThis means `references` entries MUST always be included under the top-level field `included` as default, since a server assumes if `include` is not specified by a client in the request, it is still specified as `include=references`.\nNote, if a client explicitly specifies `include` and leaves out `references`, `references` resource objects MUST NOT be included under the top-level field `included`, as per the definition of `included`, see section JSON Response Schema: Common Fields.\n\n> **Note**: A query with the parameter `include` set to the empty string means no related resource objects are to be returned under the top-level field `included`."
},
{
"name": "api_hint",
"in": "query",
"required": false,
"schema": {
"type": "string",
"pattern": "(v[0-9]+(\\.[0-9]+)?)?",
"description": "If the client provides the parameter, the value SHOULD have the format `vMAJOR` or `vMAJOR.MINOR`, where MAJOR is a major version and MINOR is a minor version of the API. For example, if a client appends `api_hint=v1.0` to the query string, the hint provided is for major version 1 and minor version 0.",
"default": "",
"title": "Api Hint"
},
"description": "If the client provides the parameter, the value SHOULD have the format `vMAJOR` or `vMAJOR.MINOR`, where MAJOR is a major version and MINOR is a minor version of the API. For example, if a client appends `api_hint=v1.0` to the query string, the hint provided is for major version 1 and minor version 0."
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/LinksResponse"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"422": {
"description": "Unprocessable Entity",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"500": {
"description": "Internal Server Error",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"501": {
"description": "Not Implemented",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
},
"553": {
"description": "Version Not Supported",
"content": {
"application/vnd.api+json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
}
}
},
"/versions": {
"get": {
"tags": [
"Versions"
],
"summary": "Get Versions",
"description": "Respond with the text/csv representation for the served versions.",
"operationId": "get_versions_versions_get",
"responses": {
"200": {
"description": "Successful Response",
"content": {
"text/csv; header=present": {
"schema": {
"type": "string"
}
}
}
}
}
}
}
},
"components": {
"schemas": {
"Aggregate": {
"type": "string",
"enum": [
"ok",
"test",
"staging",
"no"
],
"title": "Aggregate",
"description": "Enumeration of aggregate values"
},
"Attributes": {
"properties": {},
"additionalProperties": true,
"type": "object",
"title": "Attributes",
"description": "Members of the attributes object (\"attributes\") represent information about the resource object in which it's defined.\nThe keys for Attributes MUST NOT be:\n relationships\n links\n id\n type"
},
"AvailableApiVersion": {
"properties": {
"url": {
"type": "string",
"minLength": 1,
"pattern": "^.+/v[0-1](\\.[0-9]+)*/?$",
"format": "uri",
"title": "Url",
"description": "A string specifying a versioned base URL that MUST adhere to the rules in section Base URL"
},
"version": {
"type": "string",
"pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$",
"title": "Version",
"description": "A string containing the full version number of the API served at that versioned base URL.\nThe version number string MUST NOT be prefixed by, e.g., 'v'.\nExamples: `1.0.0`, `1.0.0-rc.2`.",
"examples": [
"0.10.1",
"1.0.0-rc.2",
"1.2.3-rc.5+develop"
]
}
},
"type": "object",
"required": [
"url",
"version"
],
"title": "AvailableApiVersion",
"description": "A JSON object containing information about an available API version"
},
"BaseRelationshipMeta": {
"properties": {
"description": {
"type": "string",
"title": "Description",
"description": "OPTIONAL human-readable description of the relationship."
}
},
"additionalProperties": true,
"type": "object",
"required": [
"description"
],
"title": "BaseRelationshipMeta",
"description": "Specific meta field for base relationship resource"
},
"BaseRelationshipResource": {
"properties": {
"id": {
"type": "string",
"title": "Id",
"description": "Resource ID"
},
"type": {
"type": "string",
"title": "Type",
"description": "Resource type"
},
"meta": {
"anyOf": [
{
"$ref": "#/components/schemas/BaseRelationshipMeta"
},
{
"type": "null"
}
],
"description": "Relationship meta field. MUST contain 'description' if supplied."
}
},
"type": "object",
"required": [
"id",
"type"
],
"title": "BaseRelationshipResource",
"description": "Minimum requirements to represent a relationship resource"
},
"EntryRelationships": {
"properties": {
"references": {
"anyOf": [
{
"$ref": "#/components/schemas/ReferenceRelationship"
},
{
"type": "null"
}
],
"description": "Object containing links to relationships with entries of the `references` type."
},
"structures": {
"anyOf": [
{
"$ref": "#/components/schemas/StructureRelationship"
},
{
"type": "null"
}
],
"description": "Object containing links to relationships with entries of the `structures` type."
}
},
"type": "object",
"title": "EntryRelationships",
"description": "This model wraps the JSON API Relationships to include type-specific top level keys."
},
"EntryResource": {
"properties": {
"id": {
"type": "string",
"title": "Id",
"description": "An entry's ID as defined in section Definition of Terms.\n\n- **Type**: string.\n\n- **Requirements/Conventions**:\n - **Support**: MUST be supported by all implementations, MUST NOT be `null`.\n - **Query**: MUST be a queryable property with support for all mandatory filter features.\n - **Response**: REQUIRED in the response.\n\n- **Examples**:\n - `\"db/1234567\"`\n - `\"cod/2000000\"`\n - `\"cod/2000000@1234567\"`\n - `\"nomad/L1234567890\"`\n - `\"42\"`",
"x-optimade-queryable": "must",
"x-optimade-support": "must"
},
"type": {
"type": "string",
"title": "Type",
"description": "The name of the type of an entry.\n\n- **Type**: string.\n\n- **Requirements/Conventions**:\n - **Support**: MUST be supported by all implementations, MUST NOT be `null`.\n - **Query**: MUST be a queryable property with support for all mandatory filter features.\n - **Response**: REQUIRED in the response.\n - MUST be an existing entry type.\n - The entry of type `<type>` and ID `<id>` MUST be returned in response to a request for `/<type>/<id>` under the versioned base URL.\n\n- **Example**: `\"structures\"`",
"x-optimade-queryable": "must",
"x-optimade-support": "must"
},
"links": {
"anyOf": [
{
"$ref": "#/components/schemas/ResourceLinks"
},
{
"type": "null"
}
],
"description": "a links object containing links related to the resource."
},
"meta": {
"anyOf": [
{
"$ref": "#/components/schemas/Meta"
},
{
"type": "null"
}
],
"description": "a meta object containing non-standard meta-information about a resource that can not be represented as an attribute or relationship."
},
"attributes": {
"$ref": "#/components/schemas/EntryResourceAttributes",
"description": "A dictionary, containing key-value pairs representing the entry's properties, except for `type` and `id`.\nDatabase-provider-specific properties need to include the database-provider-specific prefix (see section on Database-Provider-Specific Namespace Prefixes)."
},
"relationships": {
"anyOf": [
{
"$ref": "#/components/schemas/EntryRelationships"
},
{
"type": "null"
}
],
"description": "A dictionary containing references to other entries according to the description in section Relationships encoded as [JSON API Relationships](https://jsonapi.org/format/1.0/#document-resource-object-relationships).\nThe OPTIONAL human-readable description of the relationship MAY be provided in the `description` field inside the `meta` dictionary of the JSON API resource identifier object."
}
},
"type": "object",
"required": [
"id",
"type",
"attributes"
],
"title": "EntryResource",
"description": "The base model for an entry resource."
},
"EntryResourceAttributes": {
"properties": {
"immutable_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Immutable Id",
"description": "The entry's immutable ID (e.g., an UUID). This is important for databases having preferred IDs that point to \"the latest version\" of a record, but still offer access to older variants. This ID maps to the version-specific record, in case it changes in the future.\n\n- **Type**: string.\n\n- **Requirements/Conventions**:\n - **Support**: OPTIONAL support in implementations, i.e., MAY be `null`.\n - **Query**: MUST be a queryable property with support for all mandatory filter features.\n\n- **Examples**:\n - `\"8bd3e750-b477-41a0-9b11-3a799f21b44f\"`\n - `\"fjeiwoj,54;@=%<>#32\"` (Strings that are not URL-safe are allowed.)",
"x-optimade-queryable": "must",
"x-optimade-support": "optional"
},
"last_modified": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Last Modified",
"description": "Date and time representing when the entry was last modified.\n\n- **Type**: timestamp.\n\n- **Requirements/Conventions**:\n - **Support**: SHOULD be supported by all implementations, i.e., SHOULD NOT be `null`.\n - **Query**: MUST be a queryable property with support for all mandatory filter features.\n - **Response**: REQUIRED in the response unless the query parameter `response_fields` is present and does not include this property.\n\n- **Example**:\n - As part of JSON response format: `\"2007-04-05T14:30:20Z\"` (i.e., encoded as an [RFC 3339 Internet Date/Time Format](https://tools.ietf.org/html/rfc3339#section-5.6) string.)",
"x-optimade-queryable": "must",
"x-optimade-support": "should"
}
},
"additionalProperties": true,
"type": "object",
"required": [
"last_modified"
],
"title": "EntryResourceAttributes",
"description": "Contains key-value pairs representing the entry's properties."
},
"Error": {
"properties": {
"id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Id",
"description": "A unique identifier for this particular occurrence of the problem."
},
"links": {
"anyOf": [
{
"$ref": "#/components/schemas/ErrorLinks"
},
{
"type": "null"
}
],
"description": "A links object storing about"
},
"status": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Status",
"description": "the HTTP status code applicable to this problem, expressed as a string value."
},
"code": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Code",
"description": "an application-specific error code, expressed as a string value."
},
"title": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Title",
"description": "A short, human-readable summary of the problem. It **SHOULD NOT** change from occurrence to occurrence of the problem, except for purposes of localization."
},
"detail": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Detail",
"description": "A human-readable explanation specific to this occurrence of the problem."
},
"source": {
"anyOf": [
{
"$ref": "#/components/schemas/ErrorSource"
},
{
"type": "null"
}
],
"description": "An object containing references to the source of the error"
},
"meta": {
"anyOf": [
{
"$ref": "#/components/schemas/Meta"
},
{
"type": "null"
}
],
"description": "a meta object containing non-standard meta-information about the error."
}
},
"type": "object",
"title": "Error",
"description": "An error response"
},
"ErrorLinks": {
"properties": {
"about": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"format": "uri"
},
{
"$ref": "#/components/schemas/Link"
},
{
"type": "null"
}
],
"title": "About",
"description": "A link that leads to further details about this particular occurrence of the problem."
}
},
"type": "object",
"title": "ErrorLinks",
"description": "A Links object specific to Error objects"
},
"ErrorResponse": {
"properties": {
"data": {
"anyOf": [
{
"$ref": "#/components/schemas/Resource"
},
{
"items": {
"$ref": "#/components/schemas/Resource"
},
"type": "array"
},
{
"type": "null"
}
],
"uniqueItems": true,
"title": "Data",
"description": "Outputted Data"
},
"meta": {
"$ref": "#/components/schemas/ResponseMeta",
"description": "A meta object containing non-standard information."
},
"errors": {
"items": {
"$ref": "#/components/schemas/OptimadeError"
},
"type": "array",
"uniqueItems": true,
"title": "Errors",
"description": "A list of OPTIMADE-specific JSON API error objects, where the field detail MUST be present."
},
"included": {
"anyOf": [
{
"items": {
"$ref": "#/components/schemas/Resource"
},
"type": "array"
},
{
"type": "null"
}
],
"uniqueItems": true,
"title": "Included",
"description": "A list of unique included resources"
},
"links": {
"anyOf": [
{
"$ref": "#/components/schemas/ToplevelLinks"
},
{
"type": "null"
}
],
"description": "Links associated with the primary data or errors"
},
"jsonapi": {
"anyOf": [
{
"$ref": "#/components/schemas/JsonApi"
},
{
"type": "null"
}
],
"description": "Information about the JSON API used"
}
},
"type": "object",
"required": [
"meta",
"errors"
],
"title": "ErrorResponse",
"description": "errors MUST be present and data MUST be skipped"
},
"ErrorSource": {
"properties": {
"pointer": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Pointer",
"description": "a JSON Pointer [RFC6901] to the associated entity in the request document [e.g. \"/data\" for a primary data object, or \"/data/attributes/title\" for a specific attribute]."
},
"parameter": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Parameter",
"description": "a string indicating which URI query parameter caused the error."
}
},
"type": "object",
"title": "ErrorSource",
"description": "an object containing references to the source of the error"
},
"Implementation": {
"properties": {
"name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name",
"description": "name of the implementation"
},
"version": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Version",
"description": "version string of the current implementation"
},
"homepage": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"format": "uri"
},
{
"$ref": "#/components/schemas/Link"
},
{
"type": "null"
}
],
"title": "Homepage",
"description": "A [JSON API links object](http://jsonapi.org/format/1.0/#document-links) pointing to the homepage of the implementation."
},
"source_url": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"format": "uri"
},
{
"$ref": "#/components/schemas/Link"
},
{
"type": "null"
}
],
"title": "Source Url",
"description": "A [JSON API links object](http://jsonapi.org/format/1.0/#document-links) pointing to the implementation source, either downloadable archive or version control system."
},
"maintainer": {
"anyOf": [
{
"$ref": "#/components/schemas/ImplementationMaintainer"
},
{
"type": "null"
}
],
"description": "A dictionary providing details about the maintainer of the implementation."
},
"issue_tracker": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"format": "uri"
},
{
"$ref": "#/components/schemas/Link"
},
{
"type": "null"
}
],
"title": "Issue Tracker",
"description": "A [JSON API links object](http://jsonapi.org/format/1.0/#document-links) pointing to the implementation's issue tracker."
}
},
"type": "object",
"title": "Implementation",
"description": "Information on the server implementation"
},
"ImplementationMaintainer": {
"properties": {
"email": {
"type": "string",
"format": "email",
"title": "Email",
"description": "the maintainer's email address"
}
},
"type": "object",
"required": [
"email"
],
"title": "ImplementationMaintainer",
"description": "Details about the maintainer of the implementation"
},
"IndexInfoAttributes": {
"properties": {
"api_version": {
"type": "string",
"pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$",
"title": "Api Version",
"description": "Presently used full version of the OPTIMADE API.\nThe version number string MUST NOT be prefixed by, e.g., \"v\".\nExamples: `1.0.0`, `1.0.0-rc.2`.",
"examples": [
"0.10.1",
"1.0.0-rc.2",
"1.2.3-rc.5+develop"
]
},
"available_api_versions": {
"items": {
"$ref": "#/components/schemas/AvailableApiVersion"
},
"type": "array",
"title": "Available Api Versions",
"description": "A list of dictionaries of available API versions at other base URLs"
},
"formats": {
"items": {
"type": "string"
},
"type": "array",
"title": "Formats",
"description": "List of available output formats.",
"default": [
"json"
]
},
"available_endpoints": {
"items": {
"type": "string"
},
"type": "array",
"title": "Available Endpoints",
"description": "List of available endpoints (i.e., the string to be appended to the versioned base URL)."
},
"entry_types_by_format": {
"additionalProperties": {
"items": {
"type": "string"