Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Connectors

This contains APIs related to Connectors as defined in Harness

Fetches the list of CCM K8S Connectors corresponding to the request's filter criteria.

post
Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

searchTermstringOptional

This would be used to filter Connectors. Any Connector having the specified string in its Name, ID and Tag would be filtered.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

filterIdentifierstringOptional
includeAllConnectorsAvailableAtScopebooleanOptional

Specify whether or not to include all the Connectors accessible at the scope. For eg if set as true, at the Project scope we will get org and account Connector also in the response

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

getDistinctFromBranchesbooleanOptional

This when set to true along with GitSync enabled for the Connector, you can get one connector entity from each identifier. The connector entity can belong to any branch

pageIndexinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32 · max: 100Optional

Results per page(max 100)Default Value: 50

Default: 50
pageTokenstringOptional

Page Token of the next results to fetch.Default Value: ''

Body

Properties of the Connector Filter defined in Harness

connectorNamesstring[]Optional

This is the list of the Connector names on which the filter will be applied.

connectorIdentifiersstring[]Optional

This is the list of the Connector identifiers on which the filter will be applied.

descriptionstringOptional

Description of filter created.

inheritingCredentialsFromDelegatebooleanOptional

Boolean value to indicate if the Connector is using credentials from the Delegate to connect.

excludeHarnessManagedLlmConnectorsbooleanOptional

Exclude Harness-managed LLM connectors.

filterTypestring · enumOptionalPossible values:
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/ccmK8sList
POST /gateway/ng/api/connectors/ccmK8sList?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 362

{
  "connectorNames": [
    "text"
  ],
  "connectorIdentifiers": [
    "text"
  ],
  "description": "text",
  "types": [
    "K8sCluster"
  ],
  "categories": [
    "CLOUD_PROVIDER"
  ],
  "connectivityStatuses": [
    "SUCCESS"
  ],
  "inheritingCredentialsFromDelegate": true,
  "excludeHarnessManagedLlmConnectors": true,
  "connectorConnectivityModes": [
    "DELEGATE"
  ],
  "tags": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "filterType": "Connector"
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}
Deprecated

List all Connectors using filters

get

Lists all the Connectors matching the specified filters.

Query parameters
pageIndexinteger · int32Optional

Page number of navigation. By default, it is set to 0.

Default: 0
pageSizeinteger · int32 · max: 1000Optional

Number of entries per page.The default number of entries per page is 100, while the maximum number allowed is 1000.

Default: 100
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

searchTermstringOptional

This would be used to filter Connectors. Any Connector having the specified string in its Name, ID and Tag would be filtered.

typestring · enumOptional

Filter Connectors by type

Possible values:
categorystring · enumOptional

Filter Connectors by category

Possible values:
source_categorystring · enumOptional

Filter Connectors by Source Category. Available Source Categories are CLOUD_PROVIDER, SECRET_MANAGER, CLOUD_COST, ARTIFACTORY, CODE_REPO, MONITORING and TICKETING

Possible values:
versionstringOptional
branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors
GET /gateway/ng/api/connectors?accountIdentifier=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"
    }
  ]
}

Create a Connector

post

Creates a new Harness Connector.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

rootFolderstringOptional

Path to the root folder of the Entity. [Applicable for Old Git Sync only]

filePathstringOptional

File Path of the Entity.

commitMsgstringOptional

File Path of the Entity.

isNewBranchbooleanOptional

Checks the new branch

Default: false
baseBranchstringOptional

Name of the default branch.

connectorRefstringOptional

Identifier of Connector needed for CRUD operations on the respective Entity

storeTypestring · enumOptional

Tells whether the Entity is to be saved on Git or not

Possible values:
repoNamestringOptional

Name of the repository.

isHarnessCodeRepobooleanOptional

Is Harness code repo enabled

Body

This is the view of Connector entity as defined in Harness.

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors
POST /gateway/ng/api/connectors?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 241

{
  "connector": {
    "name": "text",
    "identifier": "text",
    "description": "text",
    "accountIdentifier": "text",
    "orgIdentifier": "text",
    "projectIdentifier": "text",
    "tags": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "type": "K8sCluster",
    "spec": {
      "connectorType": "text"
    }
  }
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Update a Connector

put

Updates a Connector for the given ID.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

rootFolderstringOptional

Path to the root folder of the Entity. [Applicable for Old Git Sync only]

filePathstringOptional

File Path of the Entity.

commitMsgstringOptional

Commit Message to use for the merge commit.

lastObjectIdstringOptional

Its required field during update call request. It can be fetched from the response of GET API call for the entity

resolvedConflictCommitIdstringOptional

If the entity is git-synced, this parameter represents the commit id against which file conflicts are resolved

baseBranchstringOptional

Name of the default branch.

connectorRefstringOptional

Identifier of Connector needed for CRUD operations on the respective Entity

lastCommitIdstringOptional

last commit id of the file

isNewBranchbooleanOptional

Checks the new branch

Default: false
isHarnessCodeRepobooleanOptional

Is Harness code repo enabled

Body

This is the view of Connector entity as defined in Harness.

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
put/connectors
PUT /gateway/ng/api/connectors?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 241

{
  "connector": {
    "name": "text",
    "identifier": "text",
    "description": "text",
    "accountIdentifier": "text",
    "orgIdentifier": "text",
    "projectIdentifier": "text",
    "tags": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "type": "K8sCluster",
    "spec": {
      "connectorType": "text"
    }
  }
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Return Connector details

get

Returns the Connector's details for the given Account and Connector ID.

Path parameters
identifierstringRequired

Connector Identifier

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/{identifier}
GET /gateway/ng/api/connectors/{identifier}?accountIdentifier=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"
    }
  ]
}

Delete a Connector

delete

Deletes a Connector for the given ID.

Path parameters
identifierstringRequired

Connector ID

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

rootFolderstringOptional

Path to the root folder of the Entity. [Applicable for Old Git Sync only]

filePathstringOptional

File Path of the Entity.

commitMsgstringOptional

Commit Message to use for the merge commit.

lastObjectIdstringOptional

Last Object Id

forceDeletebooleanOptional

If true, the Entity will be forced delete, without checking any references/usages

Default: false
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
delete/connectors/{identifier}
DELETE /gateway/ng/api/connectors/{identifier}?accountIdentifier=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"
    }
  ]
}

List all the configured field values for the given Connector type.

get

Returns all the configured field values for the given Connector type, which can be used during connector creation.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

connectorTypestring · enumRequired

Connector type

Possible values:
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/fieldValues
GET /gateway/ng/api/connectors/fieldValues?accountIdentifier=text&connectorType=K8sCluster HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}
Deprecated

Get the Template URL of connector

post
Query parameters
eventsEnabledbooleanOptional

Specify whether or not to enable events

curEnabledbooleanOptional

Specify whether or not to enable CUR

optimizationEnabledbooleanOptional

Specify whether or not to enable optimization

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/getceawstemplateurl
POST /gateway/ng/api/connectors/getceawstemplateurl HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Lists all Connectors for an account

get

Lists all the Connectors for the given Account ID.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/catalogue
GET /gateway/ng/api/connectors/catalogue?accountIdentifier=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 the connector's statistics by Account Identifier, Project Identifier and Organization Identifier

get
Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/stats
GET /gateway/ng/api/connectors/stats?accountIdentifier=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"
    }
  ]
}

Get list of GCP Projects

get

Returns the list of GCP project IDs that the connector has access to.

Path parameters
connectorRefstringRequired

Connector reference

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/{connectorRef}/gcp-projects
GET /gateway/ng/api/connectors/{connectorRef}/gcp-projects?accountIdentifier=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"
    }
  ]
}

Fetches the list of Connectors corresponding to the request's filter criteria.

post
Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

searchTermstringOptional

This would be used to filter Connectors. Any Connector having the specified string in its Name, ID and Tag would be filtered.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

filterIdentifierstringOptional
includeAllConnectorsAvailableAtScopebooleanOptional

Specify whether or not to include all the Connectors accessible at the scope. For eg if set as true, at the Project scope we will get org and account Connector also in the response

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

getDistinctFromBranchesbooleanOptional

This when set to true along with GitSync enabled for the Connector, you can get one connector entity from each identifier. The connector entity can belong to any branch

versionstringOptional
onlyFavoritesbooleanOptionalDefault: false
pageIndexinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32 · max: 100Optional

Results per page(max 100)Default Value: 50

Default: 50
pageTokenstringOptional

Page Token of the next results to fetch.Default Value: ''

Body

Properties of the Connector Filter defined in Harness

connectorNamesstring[]Optional

This is the list of the Connector names on which the filter will be applied.

connectorIdentifiersstring[]Optional

This is the list of the Connector identifiers on which the filter will be applied.

descriptionstringOptional

Description of filter created.

inheritingCredentialsFromDelegatebooleanOptional

Boolean value to indicate if the Connector is using credentials from the Delegate to connect.

excludeHarnessManagedLlmConnectorsbooleanOptional

Exclude Harness-managed LLM connectors.

filterTypestring · enumOptionalPossible values:
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/listV2
POST /gateway/ng/api/connectors/listV2?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 362

{
  "connectorNames": [
    "text"
  ],
  "connectorIdentifiers": [
    "text"
  ],
  "description": "text",
  "types": [
    "K8sCluster"
  ],
  "categories": [
    "CLOUD_PROVIDER"
  ],
  "connectivityStatuses": [
    "SUCCESS"
  ],
  "inheritingCredentialsFromDelegate": true,
  "excludeHarnessManagedLlmConnectors": true,
  "connectorConnectivityModes": [
    "DELEGATE"
  ],
  "tags": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "filterType": "Connector"
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Get list of Connectors by FQN

post

Lists all Connectors for an Account by Fully Qualified Name (FQN) with a limit of max 1000 FQNs per request.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

Bodystring[]
string[]Optional
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/listbyfqn
POST /gateway/ng/api/connectors/listbyfqn?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 8

[
  "text"
]
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Test Harness Connector connection with third-party tool

post

Tests if a Harness Connector can successfully connect Harness to a third-party tool.

Path parameters
identifierstringRequired

Connector ID

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

branchstringOptional

Name of the branch.

repoIdentifierstringOptional

Git Sync Config Id. [Applicable for Old Git Sync only]

getDefaultFromOtherRepobooleanOptional

if true, return all the default entities

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/testConnection/{identifier}
POST /gateway/ng/api/connectors/testConnection/{identifier}?accountIdentifier=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"
    }
  ]
}

Test Git Connector sync with repo

post

Tests if a Git Repo Connector can successfully connect Harness to a Git provider.

Path parameters
identifierstringRequired

Connector ID

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

repoURLstringOptional

URL of the repository, specify only in the case of Account Type Git Connector

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/connectors/testGitRepoConnection/{identifier}
POST /gateway/ng/api/connectors/testGitRepoConnection/{identifier}?accountIdentifier=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"
    }
  ]
}

Test a Harness Connector

get

Tests if a Connector can successfully connect Harness to a third-party tool using the an Account and Connector ID.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

identifierstringOptional

Connector ID

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/connectors/validateUniqueIdentifier
GET /gateway/ng/api/connectors/validateUniqueIdentifier?accountIdentifier=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"
    }
  ]
}

Last updated

Was this helpful?