Clusters
This contains APIs related to Gitops Clusters
Cluster Identifier for the entity
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
environmentIdentifier
agentIdentifier
Specify whether cluster is deleted or not
falseBad Request
This is Failure entity as defied in Harness
Internal Server Error
The saved Cluster
GET /gateway/ng/api/gitops/clusters/{identifier}?accountIdentifier=text&environmentIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Unlink a cluster from an environment by identifier
Cluster Identifier for the entity
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
environmentIdentifier
agentIdentifier
Scope for the gitops cluster
Bad Request
This is Failure entity as defied in Harness
Internal Server Error
Returns true if the Cluster is deleted
DELETE /gateway/ng/api/gitops/clusters/{identifier}?accountIdentifier=text&environmentIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Gets a list of GitOps clusters linked to an environment
Page Index of the results to fetch.Default Value: 0
0Results per page
100Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Environment Identifier of the clusters
The word to be searched and included in the list response
List of cluster identifiers
Specifies the sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order
Scope of linked clusters to be returned, ACCOUNT/ORGANIZATION/PROJECT. Returns all by default if this is not specified
Bad Request
This is Failure entity as defied in Harness
Internal Server Error
Returns the list of cluster for a Project
GET /gateway/ng/api/gitops/clusters?accountIdentifier=text&environmentIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Link a GitOps cluster to an environment by identifier
Account Identifier for the Entity.
This is the ClusterRequest entity defined in Harness
identifier of the cluster
organization identifier of the cluster
agent identifier of the cluster
project identifier of the cluster
environment identifier of the cluster
scope at which the cluster exists in harness gitops, project vs org vs account
Bad Request
This is Failure entity as defied in Harness
Internal Server Error
Returns the linked Cluster
POST /gateway/ng/api/gitops/clusters?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 130
{
"identifier": "text",
"orgIdentifier": "text",
"agentIdentifier": "text",
"projectIdentifier": "text",
"envRef": "text",
"scope": "ACCOUNT"
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Account Identifier of the environment.
Batch Request to link clusters to the environment in a batch
Organization identifier of the environment
Project identifier of the environment
Environment identifier for the cluster
Link all clusters to the environment. When true, links all clusters matching the searchTerm.
Search term to filter clusters when linkAllClusters is true. Only used with linkAllClusters=true.
Skip cluster existence validation in GitOps service. When true, allows linking clusters without verifying they exist in GitOps. Useful for pre-provisioning scenarios or when clusters are being created asynchronously.
Bad Request
This is Failure entity as defied in Harness
Internal Server Error
Returns the linked Clusters
POST /gateway/ng/api/gitops/clusters/batch?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 231
{
"orgIdentifier": "text",
"projectIdentifier": "text",
"envRef": "text",
"clusters": [
{
"identifier": "text",
"agentIdentifier": "text",
"name": "text",
"scope": "ACCOUNT"
}
],
"linkAllClusters": true,
"searchTerm": "text",
"skipClusterValidation": true
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Account Identifier for the Entity.
Batch Request to unlink clusters to the environment in a batch
Organization identifier of the environment
Project identifier of the environment
Environment identifier for the cluster
Unlink all clusters from the environment. Warning: Setting this to true will unlink ALL clusters linked to provided environment
Bad Request
This is Failure entity as defied in Harness
Internal Server Error
Returns true if all the Clusters are deleted
POST /gateway/ng/api/gitops/clusters/batchunlink?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 184
{
"orgIdentifier": "text",
"projectIdentifier": "text",
"envRef": "text",
"clusters": [
{
"identifier": "text",
"agentIdentifier": "text",
"name": "text",
"scope": "ACCOUNT"
}
],
"unlinkAllClusters": true
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Last updated
Was this helpful?