diff --git a/openapi/openebench-rest-api.json b/openapi/openebench-rest-api.json new file mode 100644 index 0000000000000000000000000000000000000000..4455e1d03d2d8b95cfc38226844092610d2c207d --- /dev/null +++ b/openapi/openebench-rest-api.json @@ -0,0 +1,133 @@ +{ + "openapi" : "3.0.1", + "info" : { + "title" : "OpenEBench REST API services", + "description" : "OpenEBench REST API services", + "contact" : { + "email" : "https://openebench.bsc.es" + }, + "license" : { + "name" : "LGPL 2.1", + "url" : "https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html" + }, + "version" : "0.1.0" + }, + "servers" : [ { + "url" : "https://openebench.bsc.es/api/scientific/access" + } ], + "paths" : { + "/{collection}" : { + "get" : { + "summary" : "returns OpenEBench collection of data", + "operationId" : "getObjects", + "parameters" : [ { + "name" : "collection", + "in" : "path", + "description" : "OpenEBench collection", + "required" : true, + "schema" : { + "type" : "string", + "enum": ["BenchmarkingEvent", + "Challenge", + "Community", + "Contact", + "Dataset", + "IdSolv", + "Metrics", + "Reference", + "Schema", + "TestAction", + "Tool"] + }, + "example" : "Contact" + } ], + "responses" : { + "default" : { + "description" : "default response", + "content" : { + "application/json" : { } + } + } + } + } + }, + "/{collection}/{id}" : { + "get" : { + "summary" : "returns OpenEBench data object", + "operationId" : "getObject", + "parameters" : [ { + "name" : "collection", + "in" : "path", + "description" : "OpenEBench collection", + "required" : true, + "schema" : { + "type" : "string", + "enum": ["BenchmarkingEvent", + "Challenge", + "Community", + "Contact", + "Dataset", + "IdSolv", + "Metrics", + "Reference", + "Schema", + "TestAction", + "Tool"] + }, + "example" : "Contact" + }, { + "name" : "id", + "in" : "path", + "description" : "object id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "OEBD00200001FO" + } ], + "responses" : { + "default" : { + "description" : "default response", + "content" : { + "application/json" : { } + } + } + } + }, + "head" : { + "summary" : "Check whether the object exists", + "operationId" : "hasObject", + "parameters" : [ { + "name" : "collection", + "in" : "path", + "description" : "data collection", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "BenchmarkingEvent" + }, { + "name" : "id", + "in" : "path", + "description" : "object id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "OEBD00200001FO" + } ], + "responses" : { + "200" : { + "description" : "object exists" + }, + "400" : { + "description" : "invalid id" + }, + "404" : { + "description" : "object not found" + } + } + } + } + } +} \ No newline at end of file