Skip to main content

Cluster Service

Cluster Service API performs CRUD actions against cluster resources.

Service Definition

Package: cluster Service: ClusterService The ClusterService manages Kubernetes cluster configurations that Argo CD uses to deploy applications.

RPC Methods

List

Returns list of clusters. Request: ClusterQuery
string
The cluster server URL
string
The cluster name
ClusterID
The cluster identifier (type and value)
Response: ClusterList REST Endpoint: GET /api/v1/clusters

Get

Returns a cluster by server address or name. Request: ClusterQuery
string
The cluster server URL
string
The cluster name
ClusterID
The cluster identifier
ClusterID Fields:
string
The type of the specified cluster identifier (“server” - default, “name”)
string
The cluster server URL or cluster name
Response: Cluster REST Endpoint: GET /api/v1/clusters/{id.value}

Create

Creates a cluster. Request: ClusterCreateRequest
Cluster
required
The cluster configuration to create
bool
Whether to create or update the cluster if it already exists
Response: Cluster REST Endpoint: POST /api/v1/clusters

Update

Updates a cluster. Request: ClusterUpdateRequest
Cluster
required
The cluster configuration to update
string[]
List of fields to update (allows partial updates)
ClusterID
The cluster identifier
Response: Cluster REST Endpoint: PUT /api/v1/clusters/{id.value}

Delete

Deletes a cluster. Request: ClusterQuery
string
The cluster server URL
string
The cluster name
ClusterID
required
The cluster identifier
Response: ClusterResponse REST Endpoint: DELETE /api/v1/clusters/{id.value}

RotateAuth

Rotates the bearer token used for a cluster. Request: ClusterQuery
ClusterID
required
The cluster identifier
Response: ClusterResponse REST Endpoint: POST /api/v1/clusters/{id.value}/rotate-auth

InvalidateCache

Invalidates cluster cache. Request: ClusterQuery
ClusterID
required
The cluster identifier
Response: Cluster REST Endpoint: POST /api/v1/clusters/{id.value}/invalidate-cache

gRPC Example