ServiceOverrides

This contains APIs related to Service Overrides V2

Update an ServiceOverride Entity

Securityx-api-key
Request
query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

Request Body schema: application/json
required

Details of the Service Override to be updated

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

environmentRef
required
string

Environment Reference for the Entity.

serviceRef
string

Service Reference for Entity

infraIdentifier
string

infraIdentifier

clusterIdentifier
string

clusterIdentifier

type
required
string

Type of the override which is based on source of overrides

Enum: "ENV_GLOBAL_OVERRIDE" "ENV_SERVICE_OVERRIDE" "INFRA_GLOBAL_OVERRIDE" "INFRA_SERVICE_OVERRIDE" "CLUSTER_GLOBAL_OVERRIDE" "CLUSTER_SERVICE_OVERRIDE"
object (ServiceOverrideSpec)

This is the Service Override Spec entity defined in Harness

yaml
string
identifier
string

Service Overrides Identifier for Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Returns the updated ServiceOverride

put/ng/api/serviceOverrides
Request samples
application/json

Sample Service Override Request

{
  • "orgIdentifier": "defaultOrgId",
  • "projectIdentifier": "defaultProjId",
  • "environmentRef": "defaultEnvRef",
  • "serviceRef": "defaultServiceRef",
  • "infraIdentifier": "defaultInfraId",
  • "type": "ENV_SERVICE_OVERRIDE",
  • "spec": {
    }
}
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}

Create an ServiceOverride Entity

Securityx-api-key
Request
query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

Request Body schema: application/json
required

Details of the Service Override to be updated

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

environmentRef
required
string

Environment Reference for the Entity.

serviceRef
string

Service Reference for Entity

infraIdentifier
string

infraIdentifier

clusterIdentifier
string

clusterIdentifier

type
required
string

Type of the override which is based on source of overrides

Enum: "ENV_GLOBAL_OVERRIDE" "ENV_SERVICE_OVERRIDE" "INFRA_GLOBAL_OVERRIDE" "INFRA_SERVICE_OVERRIDE" "CLUSTER_GLOBAL_OVERRIDE" "CLUSTER_SERVICE_OVERRIDE"
object (ServiceOverrideSpec)

This is the Service Override Spec entity defined in Harness

yaml
string
identifier
string

Service Overrides Identifier for Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Returns the created ServiceOverride

post/ng/api/serviceOverrides
Request samples
application/json

Sample Service Override Request

{
  • "orgIdentifier": "defaultOrgId",
  • "projectIdentifier": "defaultProjId",
  • "environmentRef": "defaultEnvRef",
  • "serviceRef": "defaultServiceRef",
  • "infraIdentifier": "defaultInfraId",
  • "type": "ENV_SERVICE_OVERRIDE",
  • "spec": {
    }
}
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}

Gets Service Overrides by Identifier

Securityx-api-key
Request
path Parameters
identifier
required
string

Service Overrides Identifier for Entity.

query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Returns the Service Override by the identifier and scope derived from accountId, org identifier and project identifier

get/ng/api/serviceOverrides/{identifier}
Request samples
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}

Delete a ServiceOverride entity

Securityx-api-key
Request
path Parameters
identifier
required
string

Service Overrides Identifier for Entity.

query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Returns true if the Service Override is deleted

delete/ng/api/serviceOverrides/{identifier}
Request samples
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}

Move ServiceOverride YAML from inline to remote or remote to inline

Securityx-api-key
Request
query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

connectorRef
string

Identifier of Connector needed for CRUD operations on the respective Entity

repoName
string

Name of the repository.

branch
string

Name of the branch.

filePath
string

File Path of the Entity.

commitMsg
string

File Path of the Entity.

isNewBranch
boolean
Default: false

Checks the new branch

baseBranch
string

Name of the default branch.

isHarnessCodeRepo
boolean
Default: false

Is Harness code repo enabled

moveConfigType
string

Tells weather the entity has to be moved from inline to remote or remote to inline

Enum: "INLINE_TO_REMOTE" "REMOTE_TO_INLINE"
environmentRef
string

Environment Reference for the Entity.

serviceRef
string

Service Reference for Entity

infraIdentifier
string

infraIdentifier

serviceOverridesType
string

Type of the override which is based on source of overrides

Enum: "ENV_GLOBAL_OVERRIDE" "ENV_SERVICE_OVERRIDE" "INFRA_GLOBAL_OVERRIDE" "INFRA_SERVICE_OVERRIDE" "CLUSTER_GLOBAL_OVERRIDE" "CLUSTER_SERVICE_OVERRIDE"
identifier
string

Service Overrides Identifier for Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Fetches ServiceOverride YAML from Harness DB and creates a remote entity or Fetches ServiceOverride YAML from remote repository and creates a inline entity

post/ng/api/serviceOverrides/move-config
Request samples
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}

Update git-metadata in remote ServiceOverride Entity

Update git-metadata in remote ServiceOverride and returns the identifier of updated ServiceOverride

Securityx-api-key
Request
query Parameters
accountIdentifier
required
string

Account Identifier for the Entity.

orgIdentifier
string

Organization Identifier for the Entity.

projectIdentifier
string

Project Identifier for the Entity.

identifier
string

Service Overrides Identifier for Entity.

environmentRef
string

Environment Reference for the Entity.

serviceRef
string

Service Reference for Entity

infraIdentifier
string

infraIdentifier

serviceOverridesType
string

Type of the override which is based on source of overrides

Enum: "ENV_GLOBAL_OVERRIDE" "ENV_SERVICE_OVERRIDE" "INFRA_GLOBAL_OVERRIDE" "INFRA_SERVICE_OVERRIDE" "CLUSTER_GLOBAL_OVERRIDE" "CLUSTER_SERVICE_OVERRIDE"
object (GitMetadataUpdateRequestInfo)

Identifier of Connector needed for CRUD operations on the respective Entity

object (GitMetadataUpdateRequestInfo)

Name of the repository.

object (GitMetadataUpdateRequestInfo)

File Path of the Entity.

Responses
400

Bad Request

500

Internal Server Error

default

Returns identifier and associated environmentRef, serviceRef and infraIdentifier of updated ServiceOverride

put/ng/api/serviceOverrides/update-git-metadata
Request samples
Response samples
{
  • "status": "SUCCESS",
  • "code": "DEFAULT_ERROR_CODE",
  • "message": "string",
  • "correlationId": "string",
  • "errors": [
    ]
}