{ "swagger": "2.0", "info": { "version": "5.0.0pre1", "title": "OpenTox Algorithm service", "description": "An OpenTox REST Webservice.
Provides access to OpenTox algorithms.", "contact": { "name": "Christoph Helma, Andreas Maunz, in silico toxicology", "url": "http://www.in-silico.ch", "email": "support@in-silico.ch" }, "license": { "name": "GNU GENERAL PUBLIC LICENSE", "url": "https://github.com/opentox/algorithm/blob/master/LICENSE" } }, "host": "enm.in-silico.ch", "schemes": [ "https" ], "paths": { "/algorithm": { "head": { "tags": [ "algorithm" ], "description": "for service check", "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } }, "get": { "tags": [ "algorithm" ], "description": "Get a list of all available algorithm", "produces": [ "text/uri-list" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/lazar": { "get": { "tags": [ "algorithm" ], "description": "representation of lazar algorithm", "parameters": [ { "$ref": "#/parameters/subjectid" }, { "$ref": "#/parameters/accept_representation" } ], "produces": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } }, "post": { "tags": [ "algorithm" ], "description": "Create a lazar prediction model", "parameters": [ { "$ref": "#/parameters/subjectid" }, { "$ref": "#/parameters/dataset_uri" }, { "$ref": "#/parameters/prediction_feature" }, { "$ref": "#/parameters/feature_generation_uri" } ], "produces": [ "text/uri-list" ], "responses": { "202": { "$ref": "#/responses/202" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/lazar/predict": { "post": { "tags": [ "algorithm" ], "description": "Make a lazar prediction - not to be called directly!", "parameters": [ { "name": "compound_uri", "description": "URI of compound to be predicted", "required": true, "in": "header", "type": "string" }, { "name": "training_dataset_uri", "description": "URI of training dataset", "required": true, "in": "header", "type": "string" }, { "name": "prediction_feature_uri", "description": "URI of prediction feature", "required": true, "in": "header", "type": "string" }, { "name": "feature_dataset_uri", "description": "URI of feature dataset", "required": true, "in": "header", "type": "string" }, { "name": "feature_calculation_algorithm", "description": "Name of feature calculation algorithm", "required": true, "in": "header", "type": "string" }, { "name": "min_sim", "description": "Numericvalue for minimum similarity", "required": true, "in": "header", "type": "string" }, { "name": "prediction_algorithm", "description": "Name of prediction algorithm", "required": true, "in": "header", "type": "string" }, { "name": "propositionalized", "description": "Whether propositionalization should be used", "required": true, "in": "header", "type": "string" }, { "name": "pc_type", "description": "Physico-chemical descriptor type", "required": false, "in": "header", "type": "string" }, { "name": "pc_lib", "description": "Physico-chemical descriptor library", "required": false, "in": "header", "type": "string" } ], "produces": [ "text/uri-list" ], "responses": { "202": { "$ref": "#/responses/202" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/fminer": { "get": { "tags": [ "algorithm" ], "description": "Get list of fminer algorithms", "produces": [ "text/uri-list" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/fminer/bbrc": { "get": { "tags": [ "algorithm" ], "description": "Get representation of BBRC algorithm", "parameters": [ { "$ref": "#/parameters/accept_representation" } ], "produces": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } }, "post": { "tags": [ "algorithm" ], "description": "run bbrc algorithm on dataset", "parameters": [ { "$ref": "#/parameters/dataset_uri" }, { "$ref": "#/parameters/prediction_feature" }, { "$ref": "#/parameters/min_frequency" }, { "$ref": "#/parameters/feature_type" }, { "name": "backbone", "description": "BBRC classes, pass 'false' to switch off mining for BBRC representatives.", "in": "header", "required": false, "type": "string", "enum": [ true, false ], "default": true }, { "name": "min_chisq_significance", "description": "Significance threshold (between 0 and 1)", "in": "header", "required": false, "type": "string" }, { "$ref": "#/parameters/nr_hits" }, { "$ref": "#/parameters/get_target" } ], "produces": [ "text/uri-list" ], "responses": { "202": { "$ref": "#/responses/202" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/fminer/bbrc/sample": { "get": { "tags": [ "algorithm" ], "description": "Get representation of BBRC algorithm sample", "parameters": [ { "$ref": "#/parameters/accept_representation" } ], "produces": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/fminer/last": { "get": { "tags": [ "algorithm" ], "description": "Get representation of fminer LAST-PM algorithm", "parameters": [ { "$ref": "#/parameters/accept_representation" } ], "produces": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } }, "post": { "tags": [ "algorithm" ], "description": "Run last algorithm on a dataset", "parameters": [ { "$ref": "#/parameters/dataset_uri" }, { "$ref": "#/parameters/prediction_feature" }, { "$ref": "#/parameters/min_frequency" }, { "$ref": "#/parameters/feature_type" }, { "$ref": "#/parameters/nr_hits" }, { "$ref": "#/parameters/get_target" } ], "produces": [ "text/uri-list" ], "responses": { "202": { "$ref": "#/responses/202" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } }, "/algorithm/fminer/{method}/match": { "get": { "tags": [ "algorithm" ], "description": "Get representation of matching algorithm", "parameters": [ { "name": "method", "in": "path", "required": true, "type": "string" }, { "$ref": "#/parameters/accept_representation" } ], "produces": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "responses": { "200": { "$ref": "#/responses/200" }, "400": { "$ref": "#/responses/400" }, "401": { "$ref": "#/responses/401" }, "404": { "$ref": "#/responses/404" } } } } }, "parameters": { "subjectid": { "name": "subjectid", "in": "header", "description": "authorization token, required if A&A active", "required": false, "type": "string" }, "dataset_uri": { "name": "dataset_uri", "description": "Training dataset URI", "in": "header", "required": true, "type": "string" }, "prediction_feature": { "name": "prediction_feature", "description": "URI of the feature to be predicted (i.e. dependent variable)", "in": "header", "required": true, "type": "string" }, "feature_generation_uri": { "name": "feature_generation_uri", "description": "URI of the feature generation algorithm", "in": "header", "required": false, "type": "string" }, "min_frequency": { "name": "min_frequency", "description": "Minimum frequency (default 5)", "in": "header", "required": false, "type": "string" }, "feature_type": { "name": "feature_type", "description": "Feature type, can be 'paths' or 'trees' (default 'trees')", "in": "header", "required": false, "type": "string", "enum": [ "path", "trees" ], "default": "trees" }, "nr_hits": { "name": "nr_hits", "description": "Set to 'true' to get hit count instead of presence", "in": "header", "required": false, "type": "string" }, "get_target": { "name": "get_target", "description": "Set to 'true' to obtain target variable as feature", "in": "header", "required": false, "type": "string" }, "accept_representation": { "name": "accept", "in": "header", "description": "requested Content-type", "required": false, "type": "string", "enum": [ "text/plain", "application/rdf+xml", "text/turtle", "text/html" ], "default": "text/plain" } }, "responses": { "200": { "description": "OK" }, "202": { "description": "Accepted", "examples": { "text/uri-list": "\"https://enm.in-silico.ch/task/\"" } }, "400": { "description": "Bad Request" }, "401": { "description": "Unauthorized" }, "404": { "description": "Resource Not Found" } }, "tags": [ { "name": "algorithm", "description": "Algorithm service" } ] }