$ref: '#/components/responses/UnexpectedError'
default:
$ref: '#/components/responses/UnexpectedError'
+ '/k8scluster/v1/clusters/register':
+ post:
+ tags:
+ - "K8s Cluster"
+ summary: Registering a Cluster
+ description: This API is used to register a cluster
+ operationId: registerk8sCluster
+ requestBody:
+ $ref: '#/components/requestBodies/RegisterClusterInfo'
+ responses:
+ '201':
+ description: Created
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ObjectId'
+ application/yaml:
+ schema:
+ $ref: '#/components/schemas/ObjectId'
+ '400':
+ $ref: '#/components/responses/BadRequest'
+ '401':
+ $ref: '#/components/responses/Unauthorized'
+ '403':
+ $ref: '#/components/responses/Forbidden'
+ '404':
+ $ref: '#/components/responses/NotFound'
+ '405':
+ $ref: '#/components/responses/MethodNotAllowed'
+ '406':
+ $ref: '#/components/responses/NotAcceptable'
+ '409':
+ $ref: '#/components/responses/Conflict'
+ '422':
+ $ref: '#/components/responses/UnprocessableEntity'
+ '500':
+ $ref: '#/components/responses/InternalServerError'
+ '503':
+ $ref: '#/components/responses/ServiceUnavailable'
+ '5XX':
+ $ref: '#/components/responses/UnexpectedError'
+ default:
+ $ref: '#/components/responses/UnexpectedError'
+ '/k8scluster/v1/clusters/{cluster_id}/deregister':
+ parameters:
+ - name: cluster_id
+ in: path
+ required: true
+ description: cluster_id
+ schema:
+ type: string
+ delete:
+ tags:
+ - "K8s Cluster"
+ summary: Deregister a Cluster
+ description: This API is used to deregister a specified cluster.
+ operationId: deregisterk8sCluster
+ responses:
+ '202':
+ description: Accepted
+ '400':
+ $ref: '#/components/responses/BadRequest'
+ '401':
+ $ref: '#/components/responses/Unauthorized'
+ '403':
+ $ref: '#/components/responses/Forbidden'
+ '404':
+ $ref: '#/components/responses/NotFound'
+ '405':
+ $ref: '#/components/responses/MethodNotAllowed'
+ '406':
+ $ref: '#/components/responses/NotAcceptable'
+ '409':
+ $ref: '#/components/responses/Conflict'
+ '422':
+ $ref: '#/components/responses/UnprocessableEntity'
+ '500':
+ $ref: '#/components/responses/InternalServerError'
+ '503':
+ $ref: '#/components/responses/ServiceUnavailable'
+ '5XX':
+ $ref: '#/components/responses/UnexpectedError'
+ default:
+ $ref: '#/components/responses/UnexpectedError'
'/k8scluster/v1/clusters/{cluster_id}/get_creds':
parameters:
- name: cluster_id
type: array
items:
type: integer
+ RegisterClusterInfo:
+ type: object
+ properties:
+ name:
+ type: string
+ credentials:
+ type: string
+ format: yaml|json
+ vim_account:
+ type: string
+ description:
+ type: string
+ bootstrap:
+ type: boolean
ClusterCreds:
type: string
format: yaml|json
application/yaml:
schema:
$ref: '#/components/schemas/CreateClusterInfo'
+ RegisterClusterInfo:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/RegisterClusterInfo'
+ application/yaml:
+ schema:
+ $ref: '#/components/schemas/RegisterClusterInfo'
ScaleNode:
content:
application/json: