{ "openapi": "3.0.0", "info": { "title": "public/portworx/platform/targetcluster/apiv1/targetcluster.proto", "version": "version not set" }, "tags": [ { "name": "TargetClusterService" } ], "paths": { "/core/v1/clusters": { "get": { "summary": "List API lists all the target clusters for a Tenant (Organization)", "operationId": "TargetClusterService_ListTargetClusters", "responses": { "200": { "description": "A successful response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/v1ListTargetClustersResponse" } } } }, "default": { "description": "An unexpected error response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/googlerpcStatus" } } } } }, "parameters": [ { "name": "tenantId", "description": "List target clusters associated with a Tenant (Organization).", "in": "query", "required": true, "schema": { "type": "string" } }, { "name": "pagination.pageNumber", "description": "Page number is the page number to return based on the size.", "in": "query", "required": false, "schema": { "type": "string", "format": "int64" } }, { "name": "pagination.pageSize", "description": "Page size is the maximum number of records to include per page.", "in": "query", "required": false, "schema": { "type": "string", "format": "int64" } }, { "name": "sort.sortBy", "description": "Name of the attribute to sort results by.\n\n - FIELD_UNSPECIFIED: Unspecified, do not use.\n - NAME: Sorting based on the name of the resource.\n - CREATED_AT: Sorting on create time of the resource.\n - UPDATED_AT: Sorting on update time of the resource.\n - PHASE: Sorting on phase of the resource.", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "FIELD_UNSPECIFIED", "NAME", "CREATED_AT", "UPDATED_AT", "PHASE" ], "default": "FIELD_UNSPECIFIED" } }, { "name": "sort.sortOrder", "description": "Order of sorting to be applied on requested list.\nIf sort_by having some value and sort_order is not provided, by default ascending order will be used to sort the list.\n\n - VALUE_UNSPECIFIED: Unspecified, do not use.\n - ASC: Sort order ascending.\n - DESC: Sort order descending.", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "VALUE_UNSPECIFIED", "ASC", "DESC" ], "default": "VALUE_UNSPECIFIED" } }, { "name": "respData", "description": "Response data flags for listing target clusters.\n\n - RESP_DATA_UNSPECIFIED: RespData Unspecified. complete resource will be populated.\n - INDEX: only uid, name, labels should be populated.\n - LITE: only meta data should be populated.\n - FULL: complete resource should be populated.", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "RESP_DATA_UNSPECIFIED", "INDEX", "LITE", "FULL" ], "default": "RESP_DATA_UNSPECIFIED" } } ], "tags": [ "TargetClusterService" ] } }, "/core/v1/clusters/{id}": { "get": { "summary": "GetTargetCluster API returns the info about the TargetCluster for given name.", "operationId": "TargetClusterService_GetTargetCluster", "responses": { "200": { "description": "A successful response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/v1TargetCluster" } } } }, "default": { "description": "An unexpected error response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/googlerpcStatus" } } } } }, "parameters": [ { "name": "id", "description": "Unique identifier of the cluster whose details needs to be fetched.", "in": "path", "required": true, "schema": { "type": "string" } } ], "tags": [ "TargetClusterService" ] }, "delete": { "summary": "DeleteTargetCluster API deletes the specified TargetCluster.", "operationId": "TargetClusterService_DeleteTargetCluster", "responses": { "200": { "description": "A successful response.", "content": { "application/json": { "schema": { "type": "object", "properties": {} } } } }, "default": { "description": "An unexpected error response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/googlerpcStatus" } } } } }, "parameters": [ { "name": "id", "description": "Unique identifier of the cluster whose details needs to be fetched.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "force", "description": "Flag to indicate force delete.", "in": "query", "required": false, "schema": { "type": "boolean" } } ], "tags": [ "TargetClusterService" ] } }, "/core/v1/clusters/{targetCluster.meta.uid}": { "put": { "summary": "UpdateTargetCluster API updates the metadata(e.g name/labels/annotations and desc) of the specified TargetCluster.", "operationId": "TargetClusterService_UpdateTargetCluster", "responses": { "200": { "description": "A successful response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/v1TargetCluster" } } } }, "default": { "description": "An unexpected error response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/googlerpcStatus" } } } } }, "parameters": [ { "name": "targetCluster.meta.uid", "description": "UID of the resource of the format -.", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "meta": { "type": "object", "properties": { "name": { "type": "string", "description": "Name of the resource." }, "description": { "type": "string", "description": "Description of the resource." }, "resourceVersion": { "type": "string", "description": "A string that identifies the version of this object that can be used by clients to determine when objects have changed.\nThis value must be passed unmodified back to the server by the client." }, "createTime": { "type": "string", "format": "date-time", "description": "Creation time of the object.", "readOnly": true }, "updateTime": { "type": "string", "format": "date-time", "description": "Update time of the object.", "readOnly": true }, "labels": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Labels to apply to the object." }, "annotations": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Annotations for the object." }, "parentReference": { "$ref": "#/components/schemas/v1Reference" }, "resourceNames": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Resource names holds the mapping between the resource IDs and its display name which will be consumed by the frontend.", "readOnly": true } }, "description": "Metadata of the target cluster(Resource Meta).", "title": "Metadata of the target cluster(Resource Meta)." }, "config": { "$ref": "#/components/schemas/platformTargetClusterv1Config" }, "status": { "$ref": "#/components/schemas/platformTargetClusterv1Status" } }, "title": "Target cluster details." } } }, "description": "Target cluster details.", "required": true }, "tags": [ "TargetClusterService" ] } }, "/core/v1/clusters:search": { "post": { "summary": "List API lists all the target clusters for a Tenant (Organization)", "operationId": "TargetClusterService_ListTargetClusters2", "responses": { "200": { "description": "A successful response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/v1ListTargetClustersResponse" } } } }, "default": { "description": "An unexpected error response.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/googlerpcStatus" } } } } }, "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/v1ListTargetClustersRequest" } } }, "description": "ListTargetClusterRequest is a request message to the List TargetCluster API.", "required": true }, "tags": [ "TargetClusterService" ] } } }, "components": { "schemas": { "ApplicationHealthHealth": { "type": "string", "enum": [ "HEALTH_UNSPECIFIED", "UNKNOWN", "HEALTHY", "UNHEALTHY" ], "default": "HEALTH_UNSPECIFIED", "description": "Health determines health of an application.\n\n - HEALTH_UNSPECIFIED: Must be set in the proto file; ignore.\n - UNKNOWN: Application health is unknown.\n - HEALTHY: Application is healthy.\n - UNHEALTHY: Application is unhealthy." }, "ResourceSelectorResourceFilter": { "type": "object", "properties": { "resourceType": { "$ref": "#/components/schemas/v1InfraResourceType" }, "op": { "$ref": "#/components/schemas/SelectorOperator" }, "values": { "type": "array", "items": { "type": "string" }, "description": "Value of key,value pair against which filtering needs to be performs." } }, "description": "ResourceFilter is filter for a given resource type." }, "SelectorFilter": { "type": "object", "properties": { "key": { "type": "string", "description": "Key of key,value pair against which filtering needs to be performs." }, "op": { "$ref": "#/components/schemas/SelectorOperator" }, "values": { "type": "array", "items": { "type": "string" }, "description": "Value of key,value pair against which filtering needs to be performs if operator is EXIST, value should be an empty array." } }, "description": "Filter for a given key." }, "SelectorOperator": { "type": "string", "enum": [ "OPERATOR_UNSPECIFIED", "IN", "NOT_IN", "LIKE" ], "default": "OPERATOR_UNSPECIFIED", "description": "Operator specifies the relationship between the provided (key,value) pairs in the response.\n\n - OPERATOR_UNSPECIFIED: Unspecified, do not use.\n - IN: IN specifies that the key should be associated with atleast 1 of the element in value list.\n - NOT_IN: NOT_IN specifies that the key should not be associated with any of the element in value list.\n - LIKE: LIKE specified that the key should be of a specified pattern" }, "SortByField": { "type": "string", "enum": [ "FIELD_UNSPECIFIED", "NAME", "CREATED_AT", "UPDATED_AT", "PHASE" ], "default": "FIELD_UNSPECIFIED", "description": "Field names for sorting the list of resources.\n\n - FIELD_UNSPECIFIED: Unspecified, do not use.\n - NAME: Sorting based on the name of the resource.\n - CREATED_AT: Sorting on create time of the resource.\n - UPDATED_AT: Sorting on update time of the resource.\n - PHASE: Sorting on phase of the resource." }, "googlerpcStatus": { "type": "object", "properties": { "code": { "type": "integer", "format": "int32" }, "message": { "type": "string" }, "details": { "type": "array", "items": { "$ref": "#/components/schemas/protobufAny" } } } }, "platformTargetClusterv1Config": { "type": "object", "description": "Desired configuration of the Target Cluster." }, "platformTargetClusterv1Status": { "type": "object", "properties": { "metadata": { "$ref": "#/components/schemas/v1Metadata" }, "phase": { "$ref": "#/components/schemas/v1TargetClusterPhasePhase" }, "lastStatusUpdateTime": { "type": "string", "format": "date-time", "description": "Timestamp of cluster's last status update to control plane." }, "platformAgent": { "$ref": "#/components/schemas/v1TargetClusterApplicationStatus" }, "applications": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/v1TargetClusterApplicationStatus" }, "description": "Status of applications running in the target cluster eg: BAAS, PDS, MPXE." } }, "description": "Status of the Target Cluster." }, "protobufAny": { "type": "object", "properties": { "@type": { "type": "string" } }, "additionalProperties": {} }, "v1ApplicationPhasePhase": { "type": "string", "enum": [ "PHASE_UNSPECIFIED", "PENDING", "DEPLOYING", "SUCCEEDED", "FAILED", "DELETING" ], "default": "PHASE_UNSPECIFIED", "description": "AppStatus determines status of an application.\n\n - PHASE_UNSPECIFIED: Must be set in the proto file; ignore.\n - PENDING: Application yet to be installed.\n - DEPLOYING: Application deployment on the target cluster in progress.\n - SUCCEEDED: Installed successfully.\n - FAILED: Application failed to install.\n - DELETING: Application is being deleted." }, "v1InfraResourceType": { "type": "string", "enum": [ "TYPE_UNSPECIFIED", "ACCOUNT", "TENANT", "PROJECT", "TARGET_CLUSTER", "NAMESPACE", "CREDENTIAL", "BACKUP_LOCATION", "BACKUP_POLICY", "TEMPLATE", "INVITATION" ], "default": "TYPE_UNSPECIFIED", "description": "Type of the resource.\n\n - TYPE_UNSPECIFIED: Unspecified, do not use.\n - ACCOUNT: Currently supported infra resources.\nInfra resource of type account.\n - TENANT: Infra resource of type Tenant (Organization).\n - PROJECT: Infra resource of type projects.\n - TARGET_CLUSTER: Infra resource target cluster.\n - NAMESPACE: Infra resource of type namespace.\n - CREDENTIAL: Infra resource of type credential.\n - BACKUP_LOCATION: Infra resource of type backup location.\n - BACKUP_POLICY: Infra resource of type backup policy.\n - TEMPLATE: Infra resource of type template.\n - INVITATION: Infra resource of type invitation." }, "v1KubePlatformType": { "type": "string", "enum": [ "TYPE_UNSPECIFIED", "AWS", "AZURE", "OCP", "GCP", "VSPHERE", "UNKNOWN" ], "default": "TYPE_UNSPECIFIED", "description": "kubeplatform values.\n\n - TYPE_UNSPECIFIED: Unsepecified.\n - AWS: Aws platform.\n - AZURE: Azure platform.\n - OCP: Openshift cloud platform.\n - GCP: Google cloud platform.\n - VSPHERE: VMware vSphere.\n - UNKNOWN: Unknown platform." }, "v1ListTargetClustersRequest": { "type": "object", "properties": { "tenantId": { "type": "string", "description": "List target clusters associated with a Tenant (Organization)." }, "pagination": { "$ref": "#/components/schemas/v1PageBasedPaginationRequest" }, "labelSelector": { "$ref": "#/components/schemas/v1Selector" }, "fieldSelector": { "$ref": "#/components/schemas/v1Selector" }, "infraResourceSelector": { "$ref": "#/components/schemas/v1ResourceSelector" }, "sort": { "$ref": "#/components/schemas/v1Sort" }, "respData": { "$ref": "#/components/schemas/v1RespData" } }, "description": "ListTargetClusterRequest is a request message to the List TargetCluster API.", "required": [ "tenantId" ] }, "v1ListTargetClustersResponse": { "type": "object", "properties": { "clusters": { "type": "array", "items": { "$ref": "#/components/schemas/v1TargetCluster" }, "description": "\nThe list of TargetClusters visible to the caller." }, "pagination": { "$ref": "#/components/schemas/v1PageBasedPaginationResponse" } }, "description": "ListTargetClusterResponse is the response message to the List TargetCluster API." }, "v1Meta": { "type": "object", "properties": { "uid": { "type": "string", "description": "UID of the resource of the format -." }, "name": { "type": "string", "description": "Name of the resource." }, "description": { "type": "string", "description": "Description of the resource." }, "resourceVersion": { "type": "string", "description": "A string that identifies the version of this object that can be used by clients to determine when objects have changed.\nThis value must be passed unmodified back to the server by the client." }, "createTime": { "type": "string", "format": "date-time", "description": "Creation time of the object.", "readOnly": true }, "updateTime": { "type": "string", "format": "date-time", "description": "Update time of the object.", "readOnly": true }, "labels": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Labels to apply to the object." }, "annotations": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Annotations for the object." }, "parentReference": { "$ref": "#/components/schemas/v1Reference" }, "resourceNames": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Resource names holds the mapping between the resource IDs and its display name which will be consumed by the frontend.", "readOnly": true } }, "description": "Meta holds general resource metadata." }, "v1Metadata": { "type": "object", "properties": { "kubeServerVersion": { "type": "string", "description": "Version of kubernetes api server." }, "kubePlatform": { "$ref": "#/components/schemas/v1KubePlatformType" }, "pxeMetadata": { "$ref": "#/components/schemas/v1PXEMetadata" } }, "description": "TargetClusterMetadata represents the metadata of a cluster." }, "v1PXEMetadata": { "type": "object", "properties": { "csiEnabled": { "type": "boolean", "description": "CSIEnabled flag depicts if csi is supported on the target cluster." }, "serviceName": { "type": "string", "description": "Name of portworx api service on the target cluster." }, "serviceNamespace": { "type": "string", "description": "Namespace of portworx api service on the target cluster." }, "version": { "type": "string", "description": "Version of PXE installed on the target cluster." }, "securityEnabled": { "type": "boolean", "description": "SecurityEnabled flag depicts if px security is enabled on the target cluster." } }, "description": "PX Enterprise metadata on the target cluster." }, "v1PageBasedPaginationRequest": { "type": "object", "properties": { "pageNumber": { "type": "string", "format": "int64", "description": "Page number is the page number to return based on the size." }, "pageSize": { "type": "string", "format": "int64", "description": "Page size is the maximum number of records to include per page." } }, "description": "Request parameters for page-based pagination." }, "v1PageBasedPaginationResponse": { "type": "object", "properties": { "totalRecords": { "type": "string", "format": "int64", "description": "Total records without pagination available in the dataset." }, "currentPage": { "type": "string", "format": "int64", "description": "Current page number for this paginated response." }, "pageSize": { "type": "string", "format": "int64", "description": "Page size used for pagination." }, "totalPages": { "type": "string", "format": "int64", "description": "Total pages based on the page_size provided in the request." }, "nextPage": { "type": "string", "format": "int64", "description": "Next page if available in the dataset, -1 if unavailable." }, "prevPage": { "type": "string", "format": "int64", "description": "Previous page if available in the dataset, -1 if unavailable." } }, "description": "Metadata related to page based pagination for paginated API responses." }, "v1Reference": { "type": "object", "properties": { "type": { "type": "string", "description": "API group of the resource." }, "version": { "type": "string", "description": "Version of the API." }, "uid": { "type": "string", "description": "UID of the resource." } }, "description": "Reference identifies the resource type, version of the uid and the resource." }, "v1ResourceSelector": { "type": "object", "properties": { "infraResourceFilters": { "type": "array", "items": { "$ref": "#/components/schemas/ResourceSelectorResourceFilter" }, "description": "Infra_resource_filters is the list of all filters that should be applied to fetch data related to infra resource.\nEach filter will have AND relationship." } }, "description": "ResourceSelector is used to query resources using the associated infra resources." }, "v1RespData": { "type": "string", "enum": [ "RESP_DATA_UNSPECIFIED", "INDEX", "LITE", "FULL" ], "default": "RESP_DATA_UNSPECIFIED", "description": "RespData provides flags which provides info about the fields that should be populated in the response.\n\n - RESP_DATA_UNSPECIFIED: RespData Unspecified. complete resource will be populated.\n - INDEX: only uid, name, labels should be populated.\n - LITE: only meta data should be populated.\n - FULL: complete resource should be populated." }, "v1Selector": { "type": "object", "properties": { "filters": { "type": "array", "items": { "$ref": "#/components/schemas/SelectorFilter" }, "description": "FilterList is the list of all filters that should be applied." } }, "description": "Selector is used to query resources using the associated labels or field names." }, "v1Sort": { "type": "object", "properties": { "sortBy": { "$ref": "#/components/schemas/SortByField" }, "sortOrder": { "$ref": "#/components/schemas/v1SortOrderValue" } }, "description": "The details of the attribute for which the requested list of resource to be sorted." }, "v1SortOrderValue": { "type": "string", "enum": [ "VALUE_UNSPECIFIED", "ASC", "DESC" ], "default": "VALUE_UNSPECIFIED", "description": "Value of sort order for the list of resources.\n\n - VALUE_UNSPECIFIED: Unspecified, do not use.\n - ASC: Sort order ascending.\n - DESC: Sort order descending." }, "v1TargetCluster": { "type": "object", "properties": { "meta": { "$ref": "#/components/schemas/v1Meta" }, "config": { "$ref": "#/components/schemas/platformTargetClusterv1Config" }, "status": { "$ref": "#/components/schemas/platformTargetClusterv1Status" } }, "description": "TargetCluster is a high level entity that represents one large company(e.g. a Pure)." }, "v1TargetClusterApplicationStatus": { "type": "object", "properties": { "version": { "type": "string", "description": "current installed version." }, "phase": { "$ref": "#/components/schemas/v1ApplicationPhasePhase" }, "health": { "$ref": "#/components/schemas/ApplicationHealthHealth" } }, "description": "Status of the Application." }, "v1TargetClusterPhasePhase": { "type": "string", "enum": [ "PHASE_UNSPECIFIED", "CONNECTED", "DISCONNECTED", "FAILED", "DELETING" ], "default": "PHASE_UNSPECIFIED", "description": "Supported values of phase of target cluster.\n\n - PHASE_UNSPECIFIED: Must be set in the proto file; ignore.\n - CONNECTED: Represents target cluster is connected to control plane.\n - DISCONNECTED: Represents target cluster is disconnected from control plane if\nheartbeat is not received for three consecutive cycles.\n - FAILED: Represents target cluster failed to setup agent.\n - DELETING: Represents target cluster deletion in progress." } } } }