diff --git a/api/swagger.yaml b/api/swagger.yaml index fea616110..0fb676c7a 100644 --- a/api/swagger.yaml +++ b/api/swagger.yaml @@ -228,12 +228,45 @@ paths: produces: - "application/json" parameters: - - in: "body" - name: "body" - description: "Endpoint details" + - name: "Name" + in: "formData" + type: "string" + description: "Name that will be used to identify this endpoint (example: my-endpoint)" required: true - schema: - $ref: "#/definitions/EndpointCreateRequest" + - name: "URL" + in: "formData" + type: "string" + description: "URL or IP address of a Docker host (example: docker.mydomain.tld:2375)" + required: true + - name: "PublicURL" + in: "formData" + type: "string" + description: "URL or IP address where exposed containers will be reachable.\ + \ Defaults to URL if not specified (example: docker.mydomain.tld:2375)" + - name: "GroupID" + in: "formData" + type: "string" + description: "Endpoint group identifier. If not specified will default to 1 (unassigned)." + - name: "TLS" + in: "formData" + type: "string" + description: "Require TLS to connect against this endpoint (example: true)" + - name: "TLSSkipVerify" + in: "formData" + type: "string" + description: "Skip server verification when using TLS" (example: false) + - name: "TLSCACertFile" + in: "formData" + type: "file" + description: "TLS CA certificate file" + - name: "TLSCertFile" + in: "formData" + type: "file" + description: "TLS client certificate file" + - name: "TLSKeyFile" + in: "formData" + type: "file" + description: "TLS client key file" responses: 200: description: "Success" @@ -2344,10 +2377,22 @@ definitions: type: "string" example: "my-endpoint" description: "Endpoint name" + Type: + type: "integer" + example: 1 + description: "Endpoint environment type. 1 for a Docker environment, 2 for an agent on Docker environment." URL: type: "string" example: "docker.mydomain.tld:2375" description: "URL or IP address of the Docker host associated to this endpoint" + PublicURL: + type: "string" + example: "docker.mydomain.tld:2375" + description: "URL or IP address where exposed containers will be reachable" + GroupID: + type: "integer" + example: 1 + description: "Endpoint group identifier" AuthorizedUsers: type: "array" description: "List of user identifiers authorized to connect to this endpoint" @@ -2424,53 +2469,6 @@ definitions: type: "string" example: "hub_password" description: "Password used to authenticate against the DockerHub" - EndpointCreateRequest: - type: "object" - required: - - "Name" - - "URL" - properties: - Name: - type: "string" - example: "my-endpoint" - description: "Name that will be used to identify this endpoint" - URL: - type: "string" - example: "docker.mydomain.tld:2375" - description: "URL or IP address of a Docker host" - PublicURL: - type: "string" - example: "docker.mydomain.tld:2375" - description: "URL or IP address where exposed containers will be reachable.\ - \ Defaults to URL if not specified" - TLS: - type: "boolean" - example: true - description: "Require TLS to connect against this endpoint" - TLSSkipVerify: - type: "boolean" - example: false - description: "Skip server verification when using TLS" - TLSSkipClientVerify: - type: "boolean" - example: false - description: "Skip client verification when using TLS" - TLSCACertFile: - type: "file" - description: "TLS CA certificate file" - TLSCertFile: - type: "file" - description: "TLS client certificate file" - TLSKeyFile: - type: "file" - description: "TLS client key file" - EndpointCreateResponse: - type: "object" - properties: - Id: - type: "integer" - example: 1 - description: "Id of the endpoint" EndpointListResponse: type: "array" items: