2022-07-22 16:52:36 +02:00
|
|
|
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
|
2022-07-26 21:16:02 +02:00
|
|
|
package rest_server_zrok
|
2022-07-22 16:52:36 +02:00
|
|
|
|
|
|
|
// This file was generated by the swagger tool.
|
|
|
|
// Editing this file might prove futile when you re-run the swagger generate command
|
|
|
|
|
|
|
|
import (
|
|
|
|
"encoding/json"
|
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
|
|
|
// SwaggerJSON embedded version of the swagger document used at generation time
|
|
|
|
SwaggerJSON json.RawMessage
|
|
|
|
// FlatSwaggerJSON embedded flattened version of the swagger document used at generation time
|
|
|
|
FlatSwaggerJSON json.RawMessage
|
|
|
|
)
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
SwaggerJSON = json.RawMessage([]byte(`{
|
|
|
|
"consumes": [
|
2022-07-22 17:45:37 +02:00
|
|
|
"application/zrok.v1+json"
|
2022-07-22 16:52:36 +02:00
|
|
|
],
|
|
|
|
"produces": [
|
2022-07-22 17:45:37 +02:00
|
|
|
"application/zrok.v1+json"
|
2022-07-22 16:52:36 +02:00
|
|
|
],
|
|
|
|
"schemes": [
|
|
|
|
"http"
|
|
|
|
],
|
|
|
|
"swagger": "2.0",
|
|
|
|
"info": {
|
2022-07-22 17:16:30 +02:00
|
|
|
"description": "zrok client access",
|
|
|
|
"title": "zrok",
|
2022-07-22 16:52:36 +02:00
|
|
|
"version": "1.0.0"
|
|
|
|
},
|
2022-08-02 15:26:06 +02:00
|
|
|
"basePath": "/api/v1",
|
2022-07-22 16:52:36 +02:00
|
|
|
"paths": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"/account": {
|
|
|
|
"post": {
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "createAccount",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/accountRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "account created",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/accountResponse"
|
|
|
|
}
|
2022-07-25 22:23:55 +02:00
|
|
|
},
|
|
|
|
"400": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "account not created (already exists)",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 22:23:55 +02:00
|
|
|
},
|
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 17:44:17 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-07-25 17:51:23 +02:00
|
|
|
},
|
2022-09-01 23:39:02 +02:00
|
|
|
"/disable": {
|
|
|
|
"post": {
|
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "disable",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/disableRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "environment disabled"
|
|
|
|
},
|
|
|
|
"401": {
|
|
|
|
"description": "invalid environment"
|
|
|
|
},
|
|
|
|
"500": {
|
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 23:05:44 +02:00
|
|
|
"/enable": {
|
|
|
|
"post": {
|
2022-07-27 20:45:16 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-25 23:05:44 +02:00
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "enable",
|
2022-08-03 20:25:27 +02:00
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/enableRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
2022-07-25 23:05:44 +02:00
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "environment enabled",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/enableResponse"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 20:50:46 +02:00
|
|
|
"401": {
|
|
|
|
"description": "invalid api key"
|
|
|
|
},
|
2022-07-26 18:26:58 +02:00
|
|
|
"404": {
|
|
|
|
"description": "account not found"
|
|
|
|
},
|
2022-07-25 23:05:44 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 23:05:44 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-02 19:23:31 +02:00
|
|
|
"/login": {
|
|
|
|
"post": {
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "login",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/loginRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "login successful",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/loginResponse"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"401": {
|
|
|
|
"description": "invalid login"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"/overview": {
|
|
|
|
"get": {
|
2022-08-03 20:58:11 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-08-03 20:36:40 +02:00
|
|
|
"tags": [
|
|
|
|
"metadata"
|
|
|
|
],
|
|
|
|
"operationId": "overview",
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "overview returned",
|
|
|
|
"schema": {
|
2022-08-03 21:05:28 +02:00
|
|
|
"$ref": "#/definitions/environmentServicesList"
|
2022-08-03 20:36:40 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"500": {
|
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"/tunnel": {
|
|
|
|
"post": {
|
2022-07-28 20:32:49 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-26 21:38:35 +02:00
|
|
|
"tags": [
|
|
|
|
"tunnel"
|
|
|
|
],
|
|
|
|
"operationId": "tunnel",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/tunnelRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "tunnel created",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/tunnelResponse"
|
|
|
|
}
|
2022-07-27 19:17:47 +02:00
|
|
|
},
|
2022-08-01 21:44:26 +02:00
|
|
|
"401": {
|
|
|
|
"description": "invalid environment identity",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 19:17:47 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-26 21:38:35 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"/untunnel": {
|
|
|
|
"delete": {
|
2022-07-28 20:32:49 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-27 17:35:28 +02:00
|
|
|
"tags": [
|
|
|
|
"tunnel"
|
|
|
|
],
|
|
|
|
"operationId": "untunnel",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/untunnelRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "tunnel removed"
|
|
|
|
},
|
2022-08-01 21:44:26 +02:00
|
|
|
"404": {
|
|
|
|
"description": "not found",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-27 17:35:28 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 17:51:23 +02:00
|
|
|
"/version": {
|
|
|
|
"get": {
|
|
|
|
"tags": [
|
|
|
|
"metadata"
|
|
|
|
],
|
|
|
|
"operationId": "version",
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "retrieve the current server version",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/version"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-07-22 16:52:36 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"definitions": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"accountRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"accountResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-07-25 22:42:06 +02:00
|
|
|
"token": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-16 17:46:54 +02:00
|
|
|
"authUser": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-09-01 23:39:02 +02:00
|
|
|
"disableRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"identity": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:25:27 +02:00
|
|
|
"enableRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"description": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"host": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 22:42:06 +02:00
|
|
|
"enableResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-07-26 18:26:58 +02:00
|
|
|
"cfg": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-25 22:42:06 +02:00
|
|
|
"identity": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 17:54:11 +02:00
|
|
|
"environment": {
|
2022-08-02 19:54:40 +02:00
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"active": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"address": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:54:40 +02:00
|
|
|
"createdAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"description": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"host": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:54:40 +02:00
|
|
|
"updatedAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"zitiIdentityId": {
|
2022-08-02 19:54:40 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"environmentServices": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"environment": {
|
|
|
|
"$ref": "#/definitions/environment"
|
|
|
|
},
|
|
|
|
"services": {
|
|
|
|
"$ref": "#/definitions/services"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 21:05:28 +02:00
|
|
|
"environmentServicesList": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/environmentServices"
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 17:54:11 +02:00
|
|
|
"environments": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/environment"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"errorMessage": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:23:31 +02:00
|
|
|
"loginRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"email": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"loginResponse": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-27 20:45:16 +02:00
|
|
|
"principal": {
|
2022-07-28 18:12:50 +02:00
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"id": {
|
|
|
|
"type": "integer"
|
|
|
|
},
|
|
|
|
"token": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
2022-07-27 20:45:16 +02:00
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"service": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"active": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
|
|
|
"createdAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"endpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"updatedAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"zitiServiceId": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"services": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/service"
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"tunnelRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-08-16 17:46:54 +02:00
|
|
|
"authScheme": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"authUsers": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/authUser"
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"endpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 20:25:27 +02:00
|
|
|
"zitiIdentityId": {
|
2022-07-26 21:38:35 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"tunnelResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-08-09 17:49:40 +02:00
|
|
|
"proxyEndpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"service": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"untunnelRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"service": {
|
|
|
|
"type": "string"
|
2022-08-03 20:58:11 +02:00
|
|
|
},
|
|
|
|
"zitiIdentityId": {
|
|
|
|
"type": "string"
|
2022-07-27 17:35:28 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-22 16:52:36 +02:00
|
|
|
"version": {
|
2022-07-27 20:45:16 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"securityDefinitions": {
|
|
|
|
"key": {
|
|
|
|
"type": "apiKey",
|
|
|
|
"name": "x-token",
|
|
|
|
"in": "header"
|
2022-07-22 16:52:36 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}`))
|
|
|
|
FlatSwaggerJSON = json.RawMessage([]byte(`{
|
|
|
|
"consumes": [
|
2022-07-22 17:45:37 +02:00
|
|
|
"application/zrok.v1+json"
|
2022-07-22 16:52:36 +02:00
|
|
|
],
|
|
|
|
"produces": [
|
2022-07-22 17:45:37 +02:00
|
|
|
"application/zrok.v1+json"
|
2022-07-22 16:52:36 +02:00
|
|
|
],
|
|
|
|
"schemes": [
|
|
|
|
"http"
|
|
|
|
],
|
|
|
|
"swagger": "2.0",
|
|
|
|
"info": {
|
2022-07-22 17:16:30 +02:00
|
|
|
"description": "zrok client access",
|
|
|
|
"title": "zrok",
|
2022-07-22 16:52:36 +02:00
|
|
|
"version": "1.0.0"
|
|
|
|
},
|
2022-08-02 15:26:06 +02:00
|
|
|
"basePath": "/api/v1",
|
2022-07-22 16:52:36 +02:00
|
|
|
"paths": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"/account": {
|
|
|
|
"post": {
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "createAccount",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/accountRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "account created",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/accountResponse"
|
|
|
|
}
|
2022-07-25 22:23:55 +02:00
|
|
|
},
|
|
|
|
"400": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "account not created (already exists)",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 22:23:55 +02:00
|
|
|
},
|
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 17:44:17 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-07-25 17:51:23 +02:00
|
|
|
},
|
2022-09-01 23:39:02 +02:00
|
|
|
"/disable": {
|
|
|
|
"post": {
|
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "disable",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/disableRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "environment disabled"
|
|
|
|
},
|
|
|
|
"401": {
|
|
|
|
"description": "invalid environment"
|
|
|
|
},
|
|
|
|
"500": {
|
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 23:05:44 +02:00
|
|
|
"/enable": {
|
|
|
|
"post": {
|
2022-07-27 20:45:16 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-25 23:05:44 +02:00
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "enable",
|
2022-08-03 20:25:27 +02:00
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/enableRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
2022-07-25 23:05:44 +02:00
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "environment enabled",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/enableResponse"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 20:50:46 +02:00
|
|
|
"401": {
|
|
|
|
"description": "invalid api key"
|
|
|
|
},
|
2022-07-26 18:26:58 +02:00
|
|
|
"404": {
|
|
|
|
"description": "account not found"
|
|
|
|
},
|
2022-07-25 23:05:44 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-25 23:05:44 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-02 19:23:31 +02:00
|
|
|
"/login": {
|
|
|
|
"post": {
|
|
|
|
"tags": [
|
|
|
|
"identity"
|
|
|
|
],
|
|
|
|
"operationId": "login",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/loginRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "login successful",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/loginResponse"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"401": {
|
|
|
|
"description": "invalid login"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"/overview": {
|
|
|
|
"get": {
|
2022-08-03 20:58:11 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-08-03 20:36:40 +02:00
|
|
|
"tags": [
|
|
|
|
"metadata"
|
|
|
|
],
|
|
|
|
"operationId": "overview",
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "overview returned",
|
|
|
|
"schema": {
|
2022-08-03 21:05:28 +02:00
|
|
|
"$ref": "#/definitions/environmentServicesList"
|
2022-08-03 20:36:40 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"500": {
|
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"/tunnel": {
|
|
|
|
"post": {
|
2022-07-28 20:32:49 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-26 21:38:35 +02:00
|
|
|
"tags": [
|
|
|
|
"tunnel"
|
|
|
|
],
|
|
|
|
"operationId": "tunnel",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/tunnelRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"201": {
|
|
|
|
"description": "tunnel created",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/tunnelResponse"
|
|
|
|
}
|
2022-07-27 19:17:47 +02:00
|
|
|
},
|
2022-08-01 21:44:26 +02:00
|
|
|
"401": {
|
|
|
|
"description": "invalid environment identity",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 19:17:47 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-26 21:38:35 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"/untunnel": {
|
|
|
|
"delete": {
|
2022-07-28 20:32:49 +02:00
|
|
|
"security": [
|
|
|
|
{
|
|
|
|
"key": []
|
|
|
|
}
|
|
|
|
],
|
2022-07-27 17:35:28 +02:00
|
|
|
"tags": [
|
|
|
|
"tunnel"
|
|
|
|
],
|
|
|
|
"operationId": "untunnel",
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "body",
|
|
|
|
"in": "body",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/untunnelRequest"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "tunnel removed"
|
|
|
|
},
|
2022-08-01 21:44:26 +02:00
|
|
|
"404": {
|
|
|
|
"description": "not found",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"500": {
|
2022-07-27 19:38:35 +02:00
|
|
|
"description": "internal server error",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/errorMessage"
|
|
|
|
}
|
2022-07-27 17:35:28 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 17:51:23 +02:00
|
|
|
"/version": {
|
|
|
|
"get": {
|
|
|
|
"tags": [
|
|
|
|
"metadata"
|
|
|
|
],
|
|
|
|
"operationId": "version",
|
|
|
|
"responses": {
|
|
|
|
"200": {
|
|
|
|
"description": "retrieve the current server version",
|
|
|
|
"schema": {
|
|
|
|
"$ref": "#/definitions/version"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-07-22 16:52:36 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"definitions": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"accountRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"accountResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-07-25 22:42:06 +02:00
|
|
|
"token": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-16 17:46:54 +02:00
|
|
|
"authUser": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-09-01 23:39:02 +02:00
|
|
|
"disableRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"identity": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:25:27 +02:00
|
|
|
"enableRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"description": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"host": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-25 22:42:06 +02:00
|
|
|
"enableResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-07-26 18:26:58 +02:00
|
|
|
"cfg": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-25 22:42:06 +02:00
|
|
|
"identity": {
|
2022-07-25 17:44:17 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 17:54:11 +02:00
|
|
|
"environment": {
|
2022-08-02 19:54:40 +02:00
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"active": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"address": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:54:40 +02:00
|
|
|
"createdAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"description": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"host": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:54:40 +02:00
|
|
|
"updatedAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 19:48:17 +02:00
|
|
|
"zitiIdentityId": {
|
2022-08-02 19:54:40 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"environmentServices": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"environment": {
|
|
|
|
"$ref": "#/definitions/environment"
|
|
|
|
},
|
|
|
|
"services": {
|
|
|
|
"$ref": "#/definitions/services"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 21:05:28 +02:00
|
|
|
"environmentServicesList": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/environmentServices"
|
|
|
|
}
|
|
|
|
},
|
2022-08-03 17:54:11 +02:00
|
|
|
"environments": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/environment"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"errorMessage": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-02 19:23:31 +02:00
|
|
|
"loginRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"email": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"password": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"loginResponse": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-27 20:45:16 +02:00
|
|
|
"principal": {
|
2022-07-28 18:12:50 +02:00
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"id": {
|
|
|
|
"type": "integer"
|
|
|
|
},
|
|
|
|
"token": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"username": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
2022-07-27 20:45:16 +02:00
|
|
|
},
|
2022-08-03 20:36:40 +02:00
|
|
|
"service": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"active": {
|
|
|
|
"type": "boolean"
|
|
|
|
},
|
|
|
|
"createdAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"endpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"updatedAt": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"zitiServiceId": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"services": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/service"
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"tunnelRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-08-16 17:46:54 +02:00
|
|
|
"authScheme": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
"authUsers": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"$ref": "#/definitions/authUser"
|
|
|
|
}
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"endpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-08-03 20:25:27 +02:00
|
|
|
"zitiIdentityId": {
|
2022-07-26 21:38:35 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"tunnelResponse": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2022-08-09 17:49:40 +02:00
|
|
|
"proxyEndpoint": {
|
|
|
|
"type": "string"
|
|
|
|
},
|
2022-07-26 21:38:35 +02:00
|
|
|
"service": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-27 17:35:28 +02:00
|
|
|
"untunnelRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"service": {
|
|
|
|
"type": "string"
|
2022-08-03 20:58:11 +02:00
|
|
|
},
|
|
|
|
"zitiIdentityId": {
|
|
|
|
"type": "string"
|
2022-07-27 17:35:28 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-07-22 16:52:36 +02:00
|
|
|
"version": {
|
2022-07-27 20:45:16 +02:00
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"securityDefinitions": {
|
|
|
|
"key": {
|
|
|
|
"type": "apiKey",
|
|
|
|
"name": "x-token",
|
|
|
|
"in": "header"
|
2022-07-22 16:52:36 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}`))
|
|
|
|
}
|