route/vendor/github.com/Xe/x/tools/svc/proto/svc.swagger.json

331 lines
6.5 KiB
JSON
Raw Normal View History

2017-10-06 15:29:20 +00:00
{
"swagger": "2.0",
"info": {
"title": "svc.proto",
"version": "version not set"
},
"schemes": [
"http",
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"paths": {
"/api/v1/apps/create": {
"post": {
"operationId": "Create",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/App"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/Manifest"
}
}
],
"tags": [
"Apps"
]
}
},
"/api/v1/apps/list": {
"get": {
"operationId": "List",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/AppsList"
}
}
},
"parameters": [
{
"name": "labelKey",
"in": "query",
"required": false,
"type": "string"
},
{
"name": "labelVal",
"in": "query",
"required": false,
"type": "string"
},
{
"name": "name",
"description": "will be matched to app names.",
"in": "query",
"required": false,
"type": "string"
}
],
"tags": [
"Apps"
]
}
},
"/api/v1/apps/{name}/delete": {
"delete": {
"operationId": "Delete",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/Ok"
}
}
},
"parameters": [
{
"name": "name",
"in": "path",
"required": true,
"type": "string"
}
],
"tags": [
"Apps"
]
}
},
"/api/v1/apps/{name}/inspect": {
"get": {
"operationId": "Inspect",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/App"
}
}
},
"parameters": [
{
"name": "name",
"in": "path",
"required": true,
"type": "string"
}
],
"tags": [
"Apps"
]
}
},
"/api/v1/apps/{name}/update": {
"post": {
"operationId": "Update",
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/App"
}
}
},
"parameters": [
{
"name": "name",
"in": "path",
"required": true,
"type": "string"
},
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/AppUpdate"
}
}
],
"tags": [
"Apps"
]
}
}
},
"definitions": {
"App": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"dockerImage": {
"type": "string"
},
"environment": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"labels": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"authorizedUsers": {
"type": "array",
"items": {
"type": "string"
}
},
"instances": {
"type": "integer",
"format": "int32"
},
"status": {
"type": "string"
}
}
},
"AppDelete": {
"type": "object",
"properties": {
"name": {
"type": "string"
}
}
},
"AppInspect": {
"type": "object",
"properties": {
"name": {
"type": "string"
}
}
},
"AppUpdate": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"newImage": {
"type": "string"
},
"envAdd": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"envRm": {
"type": "array",
"items": {
"type": "string"
}
},
"labelAdd": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"labelRm": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"grantUsers": {
"type": "array",
"items": {
"type": "string"
}
},
"revokeUsers": {
"type": "array",
"items": {
"type": "string"
}
},
"newInstanceCount": {
"type": "integer",
"format": "int32"
}
}
},
"AppsList": {
"type": "object",
"properties": {
"message": {
"type": "string"
},
"apps": {
"type": "array",
"items": {
"$ref": "#/definitions/App"
}
}
}
},
"AppsListParams": {
"type": "object",
"properties": {
"labelKey": {
"type": "string"
},
"labelVal": {
"type": "string"
},
"name": {
"type": "string",
"title": "will be matched to app names"
}
}
},
"Manifest": {
"type": "object",
"properties": {
"environment": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"labels": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"dockerImage": {
"type": "string"
},
"name": {
"type": "string"
}
}
},
"Ok": {
"type": "object",
"properties": {
"message": {
"type": "string"
}
}
}
}
}