oc-peer/swagger/swagger.json

174 lines
5.2 KiB
JSON
Raw Normal View History

2024-07-11 11:40:11 +02:00
{
"swagger": "2.0",
"info": {
2024-09-04 17:23:30 +02:00
"title": "oc-peers",
"description": "Manage OpenCloud peers\n",
2024-07-11 11:40:11 +02:00
"version": "1.0.0",
2024-09-04 17:23:30 +02:00
"termsOfService": "http://cloud.o-forge.io/",
2024-07-11 11:40:11 +02:00
"contact": {
2024-09-04 17:23:30 +02:00
"email": "admin@o-cloud.io"
2024-07-11 11:40:11 +02:00
},
"license": {
2024-09-05 09:35:21 +02:00
"name": "MIT",
"url": "https://opensource.org/license/mit"
2024-07-11 11:40:11 +02:00
}
},
2024-07-24 10:25:08 +02:00
"basePath": "/oc/",
2024-07-11 11:40:11 +02:00
"paths": {
2024-08-26 12:07:54 +02:00
"/peer/": {
2024-07-11 11:40:11 +02:00
"get": {
"tags": [
2024-08-26 12:07:54 +02:00
"peer"
2024-07-11 11:40:11 +02:00
],
2024-08-26 12:07:54 +02:00
"description": "find all peer\n\u003cbr\u003e",
"operationId": "PeerController.GetAll",
2024-07-11 11:40:11 +02:00
"responses": {
"200": {
2024-08-26 12:07:54 +02:00
"description": "{peer} models.peer"
2024-07-11 11:40:11 +02:00
}
}
}
},
2024-08-26 12:07:54 +02:00
"/peer/search/{search}": {
2024-07-24 10:25:08 +02:00
"get": {
"tags": [
2024-08-26 12:07:54 +02:00
"peer"
],
"description": "search workspace\n\u003cbr\u003e",
"operationId": "PeerController.Search",
"parameters": [
{
"in": "path",
"name": "search",
"description": "the word search you want to get",
"required": true,
"type": "string"
}
2024-07-24 10:25:08 +02:00
],
"responses": {
"200": {
2024-08-26 12:07:54 +02:00
"description": "{workspace} models.workspace"
2024-07-24 10:25:08 +02:00
}
}
}
},
2024-08-26 12:07:54 +02:00
"/peer/{id}": {
2024-08-06 11:09:38 +02:00
"get": {
"tags": [
2024-08-26 12:07:54 +02:00
"peer"
2024-08-06 11:09:38 +02:00
],
2024-08-26 12:07:54 +02:00
"description": "find peer by peerid\n\u003cbr\u003e",
"operationId": "PeerController.Get",
2024-08-06 11:09:38 +02:00
"parameters": [
{
"in": "path",
2024-08-26 12:07:54 +02:00
"name": "id",
"description": "the peer id you want to get",
2024-08-06 11:09:38 +02:00
"required": true,
"type": "string"
2024-08-26 12:07:54 +02:00
}
],
"responses": {
"200": {
"description": "{peer} models.peer"
}
}
},
"put": {
"tags": [
"peer"
],
"description": "create peers\n\u003cbr\u003e",
"operationId": "PeerController.Update",
"parameters": [
2024-08-06 11:09:38 +02:00
{
"in": "path",
2024-08-26 12:07:54 +02:00
"name": "id",
"description": "the peer id you want to get",
2024-08-06 11:09:38 +02:00
"required": true,
"type": "string"
2024-08-26 12:07:54 +02:00
},
{
"in": "body",
"name": "body",
"description": "The peer content",
"required": true,
"schema": {
"$ref": "#/definitions/models.peer"
}
2024-08-06 11:09:38 +02:00
}
],
"responses": {
"200": {
2024-08-26 12:07:54 +02:00
"description": "",
"schema": {
"$ref": "#/definitions/models.peer"
}
2024-08-06 11:09:38 +02:00
}
}
}
},
2024-08-26 12:07:54 +02:00
"/status/": {
"post": {
2024-08-06 11:09:38 +02:00
"tags": [
2024-08-26 12:07:54 +02:00
"status"
2024-08-06 11:09:38 +02:00
],
2024-08-26 12:07:54 +02:00
"description": "get peer status if it's alive\n\u003cbr\u003e",
"operationId": "StatusController.Status",
2024-08-06 11:09:38 +02:00
"parameters": [
{
2024-08-26 12:07:54 +02:00
"in": "body",
"name": "body",
"description": "of",
"schema": {
"$ref": "#/definitions/list"
}
2024-08-06 11:09:38 +02:00
}
],
"responses": {
"200": {
2024-08-26 12:07:54 +02:00
"description": "{status} models.status"
2024-08-06 11:09:38 +02:00
}
}
}
2024-08-26 12:07:54 +02:00
},
"/version/": {
"get": {
"tags": [
"version"
],
"description": "get version\n\u003cbr\u003e",
"operationId": "VersionController.GetAll",
"responses": {
"200": {
"description": ""
}
}
}
}
},
"definitions": {
"list": {
"title": "list",
"type": "object"
},
"models.peer": {
"title": "peer",
"type": "object"
2024-07-11 11:40:11 +02:00
}
},
"tags": [
2024-08-06 11:09:38 +02:00
{
2024-08-26 12:07:54 +02:00
"name": "status",
"description": "Operations about workflow\n"
},
{
"name": "peer",
2024-08-06 11:09:38 +02:00
"description": "Operations about workflow\n"
},
2024-07-11 11:40:11 +02:00
{
"name": "version",
"description": "VersionController operations for Version\n"
}
]
}