lazar-rest 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,54 @@
1
+ # lazar-rest
2
+
3
+ REST API webservice for lazar and nano-lazar.
4
+ lazar (lazy structure–activity relationships) is a modular framework for read across predictions of chemical toxicities. Within the European Union’s FP7 eNanoMapper project lazar was extended with capabilities to handle nanomaterial data, interfaces to other eNanoMapper services (databases and ontologies) and a stable and user-friendly graphical interface for nanoparticle read-across predictions. **lazar-rest** provides a new Restful webservice to this developments.
5
+
6
+ ## Installation
7
+
8
+ Download the code from github.
9
+
10
+ ```
11
+ git clone https://github.com/opentox/lazar-rest.git
12
+ ```
13
+ Install the required library gems with bundler
14
+ ```
15
+ cd lazar-gem
16
+ bundle install
17
+ ```
18
+
19
+ In development environment use lazar and qsar-report library from source
20
+
21
+ ```ruby
22
+ require "../lazar/lib/lazar.rb"
23
+ require "../qsar-report/lib/qsar-report.rb"
24
+ ```
25
+
26
+ In production environment change this to the following to have lazar and qsar-report library from ruby gem
27
+
28
+ ```ruby
29
+ require "../lazar/lib/lazar.rb"
30
+ require "../qsar-report/lib/qsar-report.rb"
31
+ ```
32
+
33
+ start the service with unicorn on an assigned port
34
+ ```
35
+ unicorn -p 8080 -D
36
+ ```
37
+ (satrt without daemonize option *-D* for debugging)
38
+
39
+ ## Documentation
40
+
41
+ * For full Swagger API documentation open /api/api.json with Swagger UI.
42
+ * [RubyDoc.info Code documentation](http://www.rubydoc.info/gems/lazar-rest)
43
+
44
+
45
+ ## See also
46
+ * [eNanoMapper at github](https://github.com/enanomapper)
47
+ * [eNanoMapper webpage](http://enanomapper.net)
48
+ * [lazar at github](https://github.com/opentox/lazar)
49
+ * [QSAR-report gem at github](https://github.com/opentox/qsar-report)
50
+
51
+
52
+ ## Copyright
53
+
54
+ Copyright (c) 2015-2016 Christoph Helma, Micha Rautenberg, Denis Gebele. See LICENSE for details.
data/VERSION ADDED
@@ -0,0 +1 @@
1
+ 1.0.0
@@ -0,0 +1,1209 @@
1
+ {
2
+ "swagger": "2.0",
3
+ "info": {
4
+ "description": "REST API webservice for lazar and nano-lazar. \n*lazar* (lazy structure–activity relationships) is a modular framework for predictive toxicology. With activated Authentication & Authorization, subjectid authorization token are obligatory for designated services.\n",
5
+ "version": "1.0.0",
6
+ "title": "Lazar & Nano-Lazar REST Service",
7
+ "contact": {
8
+ "name": "in silico toxicology gmbh",
9
+ "email": "service@in-silico.ch",
10
+ "url": "www.in-silico.ch"
11
+ },
12
+ "license": {
13
+ "name": "GNU GENERAL PUBLIC LICENSE",
14
+ "url": "https://github.com/opentox/lazar-rest/blob/master/LICENSE"
15
+ }
16
+ },
17
+ "host": "enm.in-silico.ch",
18
+ "basePath": "/",
19
+ "schemes": [
20
+ "https"
21
+ ],
22
+ "paths": {
23
+ "/model": {
24
+ "get": {
25
+ "tags": [
26
+ "model"
27
+ ],
28
+ "description": "Get a list of all prediction models",
29
+ "parameters": [
30
+ {
31
+ "name": "accept",
32
+ "in": "header",
33
+ "description": "requested Content-Type",
34
+ "required": true,
35
+ "type": "string",
36
+ "enum": [
37
+ "text/uri-list",
38
+ "application/json"
39
+ ]
40
+ },
41
+ {
42
+ "$ref": "#/parameters/subjectid"
43
+ }
44
+ ],
45
+ "produces": [
46
+ "text/uri-list",
47
+ "application/json"
48
+ ],
49
+ "responses": {
50
+ "200": {
51
+ "$ref": "#/responses/200"
52
+ },
53
+ "400": {
54
+ "$ref": "#/responses/400"
55
+ },
56
+ "401": {
57
+ "$ref": "#/responses/401"
58
+ },
59
+ "404": {
60
+ "$ref": "#/responses/404"
61
+ },
62
+ "500": {
63
+ "$ref": "#/responses/500"
64
+ }
65
+ }
66
+ }
67
+ },
68
+ "/model/{id}": {
69
+ "get": {
70
+ "tags": [
71
+ "model"
72
+ ],
73
+ "description": "Get model representation",
74
+ "parameters": [
75
+ {
76
+ "name": "accept",
77
+ "in": "header",
78
+ "description": "requested Content-Type",
79
+ "required": true,
80
+ "type": "string",
81
+ "enum": [
82
+ "application/json"
83
+ ]
84
+ },
85
+ {
86
+ "$ref": "#/parameters/id"
87
+ },
88
+ {
89
+ "$ref": "#/parameters/subjectid"
90
+ }
91
+ ],
92
+ "produces": [
93
+ "application/json"
94
+ ],
95
+ "responses": {
96
+ "200": {
97
+ "$ref": "#/responses/200"
98
+ },
99
+ "400": {
100
+ "$ref": "#/responses/400"
101
+ },
102
+ "401": {
103
+ "$ref": "#/responses/401"
104
+ },
105
+ "403": {
106
+ "$ref": "#/responses/403"
107
+ },
108
+ "404": {
109
+ "$ref": "#/responses/404"
110
+ }
111
+ }
112
+ },
113
+ "post": {
114
+ "tags": [
115
+ "model"
116
+ ],
117
+ "description": "Predict a compound or a nanoparticle",
118
+ "parameters": [
119
+ {
120
+ "name": "identifier",
121
+ "in": "formData",
122
+ "description": "SMILES identifier or Nanoparticle URI or comma separated list of SMILES identifiers or Nanoparticle URI",
123
+ "required": true,
124
+ "type": "string"
125
+ },
126
+ {
127
+ "$ref": "#/parameters/id"
128
+ },
129
+ {
130
+ "$ref": "#/parameters/subjectid"
131
+ }
132
+ ],
133
+ "produces": [
134
+ "application/json"
135
+ ],
136
+ "responses": {
137
+ "200": {
138
+ "$ref": "#/responses/200"
139
+ },
140
+ "400": {
141
+ "$ref": "#/responses/400"
142
+ },
143
+ "401": {
144
+ "$ref": "#/responses/401"
145
+ },
146
+ "403": {
147
+ "$ref": "#/responses/403"
148
+ },
149
+ "404": {
150
+ "$ref": "#/responses/404"
151
+ }
152
+ }
153
+ }
154
+ },
155
+ "/report": {
156
+ "get": {
157
+ "tags": [
158
+ "report"
159
+ ],
160
+ "description": "Get a list of QMRF reports",
161
+ "parameters": [
162
+ {
163
+ "name": "accept",
164
+ "in": "header",
165
+ "description": "requested Content-Type",
166
+ "required": true,
167
+ "type": "string",
168
+ "enum": [
169
+ "text/uri-list",
170
+ "application/json"
171
+ ]
172
+ },
173
+ {
174
+ "$ref": "#/parameters/subjectid"
175
+ }
176
+ ],
177
+ "produces": [
178
+ "text/uri-list",
179
+ "application/json"
180
+ ],
181
+ "responses": {
182
+ "200": {
183
+ "$ref": "#/responses/200"
184
+ },
185
+ "400": {
186
+ "$ref": "#/responses/400"
187
+ },
188
+ "401": {
189
+ "$ref": "#/responses/401"
190
+ },
191
+ "404": {
192
+ "$ref": "#/responses/404"
193
+ },
194
+ "500": {
195
+ "$ref": "#/responses/500"
196
+ }
197
+ }
198
+ }
199
+ },
200
+ "/report/{id}": {
201
+ "get": {
202
+ "tags": [
203
+ "report"
204
+ ],
205
+ "description": "Get a QMRF report prototype",
206
+ "parameters": [
207
+ {
208
+ "name": "accept",
209
+ "in": "header",
210
+ "description": "requested Content-Type",
211
+ "required": true,
212
+ "type": "string",
213
+ "enum": [
214
+ "application/xml"
215
+ ]
216
+ },
217
+ {
218
+ "$ref": "#/parameters/id"
219
+ },
220
+ {
221
+ "$ref": "#/parameters/subjectid"
222
+ }
223
+ ],
224
+ "produces": [
225
+ "application/xml"
226
+ ],
227
+ "responses": {
228
+ "200": {
229
+ "$ref": "#/responses/200"
230
+ },
231
+ "400": {
232
+ "$ref": "#/responses/400"
233
+ },
234
+ "401": {
235
+ "$ref": "#/responses/401"
236
+ },
237
+ "403": {
238
+ "$ref": "#/responses/403"
239
+ },
240
+ "404": {
241
+ "$ref": "#/responses/404"
242
+ }
243
+ }
244
+ }
245
+ },
246
+ "/dataset": {
247
+ "get": {
248
+ "tags": [
249
+ "dataset"
250
+ ],
251
+ "description": "Get a list of all datasets",
252
+ "parameters": [
253
+ {
254
+ "name": "accept",
255
+ "in": "header",
256
+ "description": "requested Content-Type",
257
+ "required": true,
258
+ "type": "string",
259
+ "enum": [
260
+ "text/uri-list",
261
+ "application/json"
262
+ ]
263
+ },
264
+ {
265
+ "$ref": "#/parameters/subjectid"
266
+ }
267
+ ],
268
+ "produces": [
269
+ "text/uri-list",
270
+ "application/json"
271
+ ],
272
+ "responses": {
273
+ "200": {
274
+ "$ref": "#/responses/200"
275
+ },
276
+ "400": {
277
+ "$ref": "#/responses/400"
278
+ },
279
+ "401": {
280
+ "$ref": "#/responses/401"
281
+ },
282
+ "404": {
283
+ "$ref": "#/responses/404"
284
+ },
285
+ "500": {
286
+ "$ref": "#/responses/500"
287
+ }
288
+ }
289
+ }
290
+ },
291
+ "/dataset/{id}": {
292
+ "get": {
293
+ "tags": [
294
+ "dataset"
295
+ ],
296
+ "description": "Get dataset representation",
297
+ "parameters": [
298
+ {
299
+ "name": "accept",
300
+ "in": "header",
301
+ "description": "requested Content-Type",
302
+ "required": true,
303
+ "type": "string",
304
+ "enum": [
305
+ "application/json",
306
+ "text/csv"
307
+ ]
308
+ },
309
+ {
310
+ "$ref": "#/parameters/id"
311
+ },
312
+ {
313
+ "$ref": "#/parameters/subjectid"
314
+ }
315
+ ],
316
+ "produces": [
317
+ "application/json",
318
+ "text/csv"
319
+ ],
320
+ "responses": {
321
+ "200": {
322
+ "$ref": "#/responses/200"
323
+ },
324
+ "400": {
325
+ "$ref": "#/responses/400"
326
+ },
327
+ "401": {
328
+ "$ref": "#/responses/401"
329
+ },
330
+ "403": {
331
+ "$ref": "#/responses/403"
332
+ },
333
+ "404": {
334
+ "$ref": "#/responses/404"
335
+ }
336
+ }
337
+ }
338
+ },
339
+ "/dataset/{id}/{attribute}": {
340
+ "get": {
341
+ "tags": [
342
+ "dataset"
343
+ ],
344
+ "description": "Get dataset representation",
345
+ "parameters": [
346
+ {
347
+ "name": "accept",
348
+ "in": "header",
349
+ "description": "requested Content-Type",
350
+ "required": true,
351
+ "type": "string",
352
+ "enum": [
353
+ "application/json"
354
+ ]
355
+ },
356
+ {
357
+ "name": "attribute",
358
+ "in": "path",
359
+ "description": "requested attribute",
360
+ "required": true,
361
+ "type": "string",
362
+ "enum": [
363
+ "compounds",
364
+ "nanoparticles",
365
+ "substances",
366
+ "features"
367
+ ]
368
+ },
369
+ {
370
+ "$ref": "#/parameters/id"
371
+ },
372
+ {
373
+ "$ref": "#/parameters/subjectid"
374
+ }
375
+ ],
376
+ "produces": [
377
+ "application/json"
378
+ ],
379
+ "responses": {
380
+ "200": {
381
+ "$ref": "#/responses/200"
382
+ },
383
+ "400": {
384
+ "$ref": "#/responses/400"
385
+ },
386
+ "401": {
387
+ "$ref": "#/responses/401"
388
+ },
389
+ "403": {
390
+ "$ref": "#/responses/403"
391
+ },
392
+ "404": {
393
+ "$ref": "#/responses/404"
394
+ }
395
+ }
396
+ }
397
+ },
398
+ "/substance": {
399
+ "get": {
400
+ "tags": [
401
+ "substance"
402
+ ],
403
+ "description": "Get a list of all substances",
404
+ "parameters": [
405
+ {
406
+ "name": "accept",
407
+ "in": "header",
408
+ "description": "requested Content-Type",
409
+ "required": true,
410
+ "type": "string",
411
+ "enum": [
412
+ "text/uri-list",
413
+ "application/json"
414
+ ]
415
+ },
416
+ {
417
+ "$ref": "#/parameters/subjectid"
418
+ }
419
+ ],
420
+ "produces": [
421
+ "text/uri-list",
422
+ "application/json"
423
+ ],
424
+ "responses": {
425
+ "200": {
426
+ "$ref": "#/responses/200"
427
+ },
428
+ "400": {
429
+ "$ref": "#/responses/400"
430
+ },
431
+ "401": {
432
+ "$ref": "#/responses/401"
433
+ },
434
+ "404": {
435
+ "$ref": "#/responses/404"
436
+ },
437
+ "500": {
438
+ "$ref": "#/responses/500"
439
+ }
440
+ }
441
+ }
442
+ },
443
+ "/substance/{id}": {
444
+ "get": {
445
+ "tags": [
446
+ "substance"
447
+ ],
448
+ "description": "Get substance representation",
449
+ "parameters": [
450
+ {
451
+ "name": "accept",
452
+ "in": "header",
453
+ "description": "requested Content-Type",
454
+ "required": true,
455
+ "type": "string",
456
+ "enum": [
457
+ "application/json"
458
+ ]
459
+ },
460
+ {
461
+ "$ref": "#/parameters/id"
462
+ },
463
+ {
464
+ "$ref": "#/parameters/subjectid"
465
+ }
466
+ ],
467
+ "produces": [
468
+ "application/json"
469
+ ],
470
+ "responses": {
471
+ "200": {
472
+ "$ref": "#/responses/200"
473
+ },
474
+ "400": {
475
+ "$ref": "#/responses/400"
476
+ },
477
+ "401": {
478
+ "$ref": "#/responses/401"
479
+ },
480
+ "403": {
481
+ "$ref": "#/responses/403"
482
+ },
483
+ "404": {
484
+ "$ref": "#/responses/404"
485
+ }
486
+ }
487
+ }
488
+ },
489
+ "/nanoparticle": {
490
+ "get": {
491
+ "tags": [
492
+ "nanoparticle"
493
+ ],
494
+ "description": "Get a list of all nanoparticles",
495
+ "parameters": [
496
+ {
497
+ "name": "accept",
498
+ "in": "header",
499
+ "description": "requested Content-Type",
500
+ "required": true,
501
+ "type": "string",
502
+ "enum": [
503
+ "text/uri-list",
504
+ "application/json"
505
+ ]
506
+ },
507
+ {
508
+ "$ref": "#/parameters/subjectid"
509
+ }
510
+ ],
511
+ "produces": [
512
+ "text/uri-list",
513
+ "application/json"
514
+ ],
515
+ "responses": {
516
+ "200": {
517
+ "$ref": "#/responses/200"
518
+ },
519
+ "400": {
520
+ "$ref": "#/responses/400"
521
+ },
522
+ "401": {
523
+ "$ref": "#/responses/401"
524
+ },
525
+ "404": {
526
+ "$ref": "#/responses/404"
527
+ },
528
+ "500": {
529
+ "$ref": "#/responses/500"
530
+ }
531
+ }
532
+ }
533
+ },
534
+ "/nanoparticle/{id}": {
535
+ "get": {
536
+ "tags": [
537
+ "nanoparticle"
538
+ ],
539
+ "description": "Get nanoparticle representation",
540
+ "parameters": [
541
+ {
542
+ "name": "accept",
543
+ "in": "header",
544
+ "description": "requested Content-Type",
545
+ "required": true,
546
+ "type": "string",
547
+ "enum": [
548
+ "application/json"
549
+ ]
550
+ },
551
+ {
552
+ "$ref": "#/parameters/id"
553
+ },
554
+ {
555
+ "$ref": "#/parameters/subjectid"
556
+ }
557
+ ],
558
+ "produces": [
559
+ "application/json"
560
+ ],
561
+ "responses": {
562
+ "200": {
563
+ "$ref": "#/responses/200"
564
+ },
565
+ "400": {
566
+ "$ref": "#/responses/400"
567
+ },
568
+ "401": {
569
+ "$ref": "#/responses/401"
570
+ },
571
+ "403": {
572
+ "$ref": "#/responses/403"
573
+ },
574
+ "404": {
575
+ "$ref": "#/responses/404"
576
+ }
577
+ }
578
+ }
579
+ },
580
+ "/feature": {
581
+ "get": {
582
+ "tags": [
583
+ "feature"
584
+ ],
585
+ "description": "Get a list of all features",
586
+ "parameters": [
587
+ {
588
+ "name": "accept",
589
+ "in": "header",
590
+ "description": "requested Content-Type",
591
+ "required": true,
592
+ "type": "string",
593
+ "enum": [
594
+ "text/uri-list",
595
+ "application/json"
596
+ ]
597
+ }
598
+ ],
599
+ "produces": [
600
+ "text/uri-list",
601
+ "application/json"
602
+ ],
603
+ "responses": {
604
+ "200": {
605
+ "$ref": "#/responses/200"
606
+ },
607
+ "400": {
608
+ "$ref": "#/responses/400"
609
+ },
610
+ "401": {
611
+ "$ref": "#/responses/401"
612
+ },
613
+ "404": {
614
+ "$ref": "#/responses/404"
615
+ },
616
+ "500": {
617
+ "$ref": "#/responses/500"
618
+ }
619
+ }
620
+ }
621
+ },
622
+ "/feature/{id}": {
623
+ "get": {
624
+ "tags": [
625
+ "feature"
626
+ ],
627
+ "description": "Get feature representation",
628
+ "parameters": [
629
+ {
630
+ "name": "acept",
631
+ "in": "header",
632
+ "description": "requested Content-Type",
633
+ "required": true,
634
+ "type": "string",
635
+ "enum": [
636
+ "application/json"
637
+ ]
638
+ },
639
+ {
640
+ "$ref": "#/parameters/id"
641
+ }
642
+ ],
643
+ "produces": [
644
+ "application/json"
645
+ ],
646
+ "responses": {
647
+ "200": {
648
+ "$ref": "#/responses/200"
649
+ },
650
+ "400": {
651
+ "$ref": "#/responses/400"
652
+ },
653
+ "401": {
654
+ "$ref": "#/responses/401"
655
+ },
656
+ "403": {
657
+ "$ref": "#/responses/403"
658
+ },
659
+ "404": {
660
+ "$ref": "#/responses/404"
661
+ }
662
+ }
663
+ }
664
+ },
665
+ "/validation": {
666
+ "get": {
667
+ "tags": [
668
+ "validation"
669
+ ],
670
+ "description": "Get a list of all validation types",
671
+ "parameters": [
672
+ {
673
+ "name": "accept",
674
+ "in": "header",
675
+ "description": "requested Content-Type",
676
+ "required": true,
677
+ "type": "string",
678
+ "enum": [
679
+ "text/uri-list",
680
+ "application/json"
681
+ ]
682
+ }
683
+ ],
684
+ "produces": [
685
+ "text/uri-list",
686
+ "application/json"
687
+ ],
688
+ "responses": {
689
+ "200": {
690
+ "$ref": "#/responses/200"
691
+ },
692
+ "400": {
693
+ "$ref": "#/responses/400"
694
+ },
695
+ "401": {
696
+ "$ref": "#/responses/401"
697
+ },
698
+ "404": {
699
+ "$ref": "#/responses/404"
700
+ },
701
+ "500": {
702
+ "$ref": "#/responses/500"
703
+ }
704
+ }
705
+ }
706
+ },
707
+ "/validation/{validationtype}": {
708
+ "get": {
709
+ "tags": [
710
+ "validation"
711
+ ],
712
+ "description": "Get all validations of a validation type",
713
+ "parameters": [
714
+ {
715
+ "name": "accept",
716
+ "in": "header",
717
+ "description": "requested Content-Type",
718
+ "required": true,
719
+ "type": "string",
720
+ "enum": [
721
+ "text/uri-list",
722
+ "application/json"
723
+ ]
724
+ },
725
+ {
726
+ "$ref": "#/parameters/valtype"
727
+ },
728
+ {
729
+ "$ref": "#/parameters/subjectid"
730
+ }
731
+ ],
732
+ "produces": [
733
+ "text/uri-list",
734
+ "application/json"
735
+ ],
736
+ "responses": {
737
+ "200": {
738
+ "$ref": "#/responses/200"
739
+ },
740
+ "400": {
741
+ "$ref": "#/responses/400"
742
+ },
743
+ "401": {
744
+ "$ref": "#/responses/401"
745
+ },
746
+ "403": {
747
+ "$ref": "#/responses/403"
748
+ },
749
+ "404": {
750
+ "$ref": "#/responses/404"
751
+ }
752
+ }
753
+ }
754
+ },
755
+ "/validation/{validationtype}/{id}": {
756
+ "get": {
757
+ "tags": [
758
+ "validation"
759
+ ],
760
+ "description": "Get validation representation",
761
+ "parameters": [
762
+ {
763
+ "name": "accept",
764
+ "in": "header",
765
+ "description": "requested Content-Type",
766
+ "required": true,
767
+ "type": "string",
768
+ "enum": [
769
+ "application/json"
770
+ ]
771
+ },
772
+ {
773
+ "$ref": "#/parameters/valtype"
774
+ },
775
+ {
776
+ "$ref": "#/parameters/id"
777
+ },
778
+ {
779
+ "$ref": "#/parameters/subjectid"
780
+ }
781
+ ],
782
+ "produces": [
783
+ "application/json"
784
+ ],
785
+ "responses": {
786
+ "200": {
787
+ "$ref": "#/responses/200"
788
+ },
789
+ "400": {
790
+ "$ref": "#/responses/400"
791
+ },
792
+ "401": {
793
+ "$ref": "#/responses/401"
794
+ },
795
+ "403": {
796
+ "$ref": "#/responses/403"
797
+ },
798
+ "404": {
799
+ "$ref": "#/responses/404"
800
+ }
801
+ }
802
+ }
803
+ },
804
+ "/compound/descriptor": {
805
+ "get": {
806
+ "tags": [
807
+ "compound",
808
+ "descriptor"
809
+ ],
810
+ "description": "Get a list of all descriptors",
811
+ "parameters": [
812
+ {
813
+ "name": "accept",
814
+ "in": "header",
815
+ "description": "requested Content-Type",
816
+ "required": true,
817
+ "type": "string",
818
+ "enum": [
819
+ "text/plain",
820
+ "application/json"
821
+ ]
822
+ }
823
+ ],
824
+ "produces": [
825
+ "text/plain",
826
+ "application/json"
827
+ ],
828
+ "responses": {
829
+ "200": {
830
+ "$ref": "#/responses/200"
831
+ },
832
+ "400": {
833
+ "$ref": "#/responses/400"
834
+ },
835
+ "401": {
836
+ "$ref": "#/responses/401"
837
+ },
838
+ "404": {
839
+ "$ref": "#/responses/404"
840
+ },
841
+ "500": {
842
+ "$ref": "#/responses/500"
843
+ }
844
+ }
845
+ },
846
+ "post": {
847
+ "tags": [
848
+ "compound",
849
+ "descriptor"
850
+ ],
851
+ "summary": "Descriptor calculation",
852
+ "description": "Calculate descriptors for a single compound as SMILES string <br> <strong>curl example:</strong> <pre>curl -Lk -X POST -i -H \"accept:application/json\" -F \"identifier=O=C1NC(=O)NC=C1\" -F \"descriptor=Openbabel.MW,JoeLib.LogP\" https://enm.in-silico.ch/compound/descriptor </pre>.",
853
+ "parameters": [
854
+ {
855
+ "name": "accept",
856
+ "in": "header",
857
+ "description": "requested Content-Type",
858
+ "required": true,
859
+ "type": "string",
860
+ "enum": [
861
+ "text/csv",
862
+ "application/json"
863
+ ],
864
+ "default": "text/csv"
865
+ },
866
+ {
867
+ "name": "identifier",
868
+ "in": "formData",
869
+ "description": "SMILES identifier",
870
+ "required": true,
871
+ "type": "string"
872
+ },
873
+ {
874
+ "name": "descriptor",
875
+ "in": "formData",
876
+ "description": "array of descriptors",
877
+ "required": true,
878
+ "type": "array",
879
+ "items": {
880
+ "type": "string"
881
+ }
882
+ },
883
+ {
884
+ "$ref": "#/parameters/subjectid"
885
+ }
886
+ ],
887
+ "produces": [
888
+ "text/csv",
889
+ "application/json"
890
+ ],
891
+ "responses": {
892
+ "200": {
893
+ "$ref": "#/responses/200"
894
+ },
895
+ "400": {
896
+ "$ref": "#/responses/400"
897
+ },
898
+ "401": {
899
+ "$ref": "#/responses/401"
900
+ },
901
+ "404": {
902
+ "$ref": "#/responses/404"
903
+ },
904
+ "500": {
905
+ "$ref": "#/responses/500"
906
+ }
907
+ }
908
+ }
909
+ },
910
+ "/compound/descriptor/{descriptor}": {
911
+ "get": {
912
+ "tags": [
913
+ "compound",
914
+ "descriptor"
915
+ ],
916
+ "description": "Get a list of a descriptors",
917
+ "parameters": [
918
+ {
919
+ "name": "accept",
920
+ "in": "header",
921
+ "description": "requested Content-Type",
922
+ "required": true,
923
+ "type": "string",
924
+ "enum": [
925
+ "text/plain",
926
+ "application/json"
927
+ ]
928
+ },
929
+ {
930
+ "name": "descriptor",
931
+ "in": "path",
932
+ "description": "descriptor name or ID",
933
+ "required": true,
934
+ "type": "string"
935
+ }
936
+ ],
937
+ "produces": [
938
+ "text/plain",
939
+ "application/json"
940
+ ],
941
+ "responses": {
942
+ "200": {
943
+ "$ref": "#/responses/200"
944
+ },
945
+ "400": {
946
+ "$ref": "#/responses/400"
947
+ },
948
+ "401": {
949
+ "$ref": "#/responses/401"
950
+ },
951
+ "404": {
952
+ "$ref": "#/responses/404"
953
+ },
954
+ "500": {
955
+ "$ref": "#/responses/500"
956
+ }
957
+ }
958
+ }
959
+ },
960
+ "/compound/{InChI}": {
961
+ "get": {
962
+ "tags": [
963
+ "compound"
964
+ ],
965
+ "description": "Get compound representation",
966
+ "parameters": [
967
+ {
968
+ "$ref": "#/parameters/InChI"
969
+ },
970
+ {
971
+ "name": "accept",
972
+ "in": "header",
973
+ "description": "requested Content-type",
974
+ "required": true,
975
+ "type": "string",
976
+ "enum": [
977
+ "application/json",
978
+ "chemical/x-daylight-smiles",
979
+ "chemical/x-inchi",
980
+ "chemical/x-mdl-sdfile",
981
+ "chemical/x-mdl-molfile",
982
+ "image/png",
983
+ "image/svg+xml",
984
+ "text/plain"
985
+ ]
986
+ }
987
+ ],
988
+ "produces": [
989
+ "application/json",
990
+ "chemical/x-daylight-smiles",
991
+ "chemical/x-inchi",
992
+ "chemical/x-mdl-sdfile",
993
+ "chemical/x-mdl-molfile",
994
+ "image/png",
995
+ "image/svg+xml",
996
+ "text/plain"
997
+ ],
998
+ "responses": {
999
+ "200": {
1000
+ "$ref": "#/responses/200"
1001
+ },
1002
+ "400": {
1003
+ "$ref": "#/responses/400"
1004
+ }
1005
+ }
1006
+ }
1007
+ },
1008
+ "/api/api.json": {
1009
+ "get": {
1010
+ "tags": [
1011
+ "api"
1012
+ ],
1013
+ "description": "Get swagger api in JSON",
1014
+ "produces": [
1015
+ "application/json"
1016
+ ],
1017
+ "responses": {
1018
+ "200": {
1019
+ "$ref": "#/responses/200"
1020
+ },
1021
+ "400": {
1022
+ "$ref": "#/responses/400"
1023
+ },
1024
+ "500": {
1025
+ "$ref": "#/responses/500"
1026
+ }
1027
+ }
1028
+ }
1029
+ },
1030
+ "/aa/authenticate": {
1031
+ "post": {
1032
+ "tags": [
1033
+ "authentication"
1034
+ ],
1035
+ "description": "Authentication against OpenSSO. Returns token. Requires Username and Password.",
1036
+ "operationId": "login",
1037
+ "consumes": [
1038
+ "text/plain"
1039
+ ],
1040
+ "produces": [
1041
+ "text/plain"
1042
+ ],
1043
+ "parameters": [
1044
+ {
1045
+ "in": "formData",
1046
+ "name": "username",
1047
+ "description": "username",
1048
+ "required": true,
1049
+ "type": "string"
1050
+ },
1051
+ {
1052
+ "in": "formData",
1053
+ "name": "password",
1054
+ "description": "password",
1055
+ "required": true,
1056
+ "type": "string",
1057
+ "format": "password"
1058
+ }
1059
+ ],
1060
+ "responses": {
1061
+ "200": {
1062
+ "$ref": "#/responses/200"
1063
+ },
1064
+ "400": {
1065
+ "$ref": "#/responses/400"
1066
+ },
1067
+ "401": {
1068
+ "$ref": "#/responses/401"
1069
+ }
1070
+ }
1071
+ }
1072
+ },
1073
+ "/aa/logout": {
1074
+ "post": {
1075
+ "description": "Devalidates a token. Requires Subjectid.",
1076
+ "operationId": "logout",
1077
+ "tags": [
1078
+ "authentication"
1079
+ ],
1080
+ "consumes": [
1081
+ "text/plain"
1082
+ ],
1083
+ "produces": [
1084
+ "text/plain"
1085
+ ],
1086
+ "parameters": [
1087
+ {
1088
+ "in": "formData",
1089
+ "name": "subjectid",
1090
+ "description": "subjectid",
1091
+ "required": true,
1092
+ "type": "string"
1093
+ }
1094
+ ],
1095
+ "responses": {
1096
+ "200": {
1097
+ "$ref": "#/responses/200"
1098
+ },
1099
+ "400": {
1100
+ "$ref": "#/responses/400"
1101
+ },
1102
+ "401": {
1103
+ "$ref": "#/responses/401"
1104
+ }
1105
+ }
1106
+ }
1107
+ }
1108
+ },
1109
+ "parameters": {
1110
+ "id": {
1111
+ "name": "id",
1112
+ "in": "path",
1113
+ "description": "id",
1114
+ "required": true,
1115
+ "type": "string"
1116
+ },
1117
+ "InChI": {
1118
+ "name": "InChI",
1119
+ "in": "path",
1120
+ "description": "InChI String",
1121
+ "required": true,
1122
+ "type": "string"
1123
+ },
1124
+ "valtype": {
1125
+ "name": "validationtype",
1126
+ "in": "path",
1127
+ "description": "validation type",
1128
+ "required": true,
1129
+ "type": "string"
1130
+ },
1131
+ "subjectid": {
1132
+ "in": "header",
1133
+ "name": "subjectid",
1134
+ "description": "authorization token",
1135
+ "required": false,
1136
+ "type": "string"
1137
+ }
1138
+ },
1139
+ "responses": {
1140
+ "200": {
1141
+ "description": "OK"
1142
+ },
1143
+ "400": {
1144
+ "description": "Bad Request"
1145
+ },
1146
+ "401": {
1147
+ "description": "Unauthorized"
1148
+ },
1149
+ "403": {
1150
+ "description": "Forbidden"
1151
+ },
1152
+ "404": {
1153
+ "description": "Resource Not Found"
1154
+ },
1155
+ "500": {
1156
+ "description": "Server Error"
1157
+ }
1158
+ },
1159
+ "tags": [
1160
+ {
1161
+ "name": "algorithm",
1162
+ "description": "Algorithm"
1163
+ },
1164
+ {
1165
+ "name": "api",
1166
+ "description": "Swagger API representation in JSON"
1167
+ },
1168
+ {
1169
+ "name": "authentication",
1170
+ "description": "minimal Authentication service"
1171
+ },
1172
+ {
1173
+ "name": "descriptor",
1174
+ "description": "Descriptor"
1175
+ },
1176
+ {
1177
+ "name": "model",
1178
+ "description": "Lazar Model Service"
1179
+ },
1180
+ {
1181
+ "name": "compound",
1182
+ "description": "Compound"
1183
+ },
1184
+ {
1185
+ "name": "dataset",
1186
+ "description": "Dataset"
1187
+ },
1188
+ {
1189
+ "name": "validation",
1190
+ "description": "Validation"
1191
+ },
1192
+ {
1193
+ "name": "substance",
1194
+ "description": "Substance"
1195
+ },
1196
+ {
1197
+ "name": "nanoparticle",
1198
+ "description": "Nanoparticle"
1199
+ },
1200
+ {
1201
+ "name": "feature",
1202
+ "description": "Feature"
1203
+ },
1204
+ {
1205
+ "name": "report",
1206
+ "description": "QMRF Reporting"
1207
+ }
1208
+ ]
1209
+ }