Pipeline
This contains pipeline APIs for files as provided as runtime input during pipeline execution
Download file from GCS using filePath
Account Identifier for the Entity.
filePath
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Download file from GCS using filePath
GET /gateway/pipeline/api/input-file/download-file?accountIdentifier=text&filePath=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Returns a file uploaded or filtered based on the fileIdentifier provided for a given nodeExecutionId
Returns a file uploaded or filtered based on the fileIdentifier provided for a given nodeExecutionId
The Pipeline Execution Id
Account Identifier for the Entity.
Step execution Id of upload step
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns a file uploaded or filtered based on the fileIdentifier provided for a given planExecutionId
GET /gateway/pipeline/api/input-file/file/{planExecutionId}?accountIdentifier=text&nodeExecutionId=text&fileName=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Converts an existing sequential pipeline to DAG format by adding depends_on fields to stages
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns the converted pipeline response
POST /gateway/pipeline/api/pipelines/{pipelineIdentifier}/convert-to-dag?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Creates a Pipeline
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Enable DAG execution for pipeline
falseName of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
Path to the root folder of the Entity. [Applicable for Old Git Sync only]
File Path of the Entity.
File Path of the Entity.
Checks the new branch
falseName of the default branch.
Identifier of Connector needed for CRUD operations on the respective Entity
Tells whether the Entity is to be saved on Git or not
Name of the repository.
Is Harness code repo enabled
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns created pipeline
POST /gateway/pipeline/api/pipelines?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/json
Accept: */*
Content-Length: 6
"text"{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Creates a Pipeline
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
Path to the root folder of the Entity. [Applicable for Old Git Sync only]
File Path of the Entity.
File Path of the Entity.
Checks the new branch
falseName of the default branch.
Identifier of Connector needed for CRUD operations on the respective Entity
Tells whether the Entity is to be saved on Git or not
Name of the repository.
Is Harness code repo enabled
Allow Dynamic Executions for the Pipeline
Enable DAG execution for pipeline
falsefalseBad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns created pipeline with metadata
POST /gateway/pipeline/api/pipelines/v2?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/yaml
Accept: */*
Content-Length: 3992
"|
pipeline:
name: Sample Pipeline
identifier: Sample_Pipeline
allowStageExecutions: false
projectIdentifier: Temp
orgIdentifier: default
tags: {}
stages:
- stage:
name: Sample Stage
identifier: Sample_Stage
description: \"\"
type: Approval
spec:
execution:
steps:
- step:
name: Approval Step
identifier: Approval_Step
type: HarnessApproval
timeout: 1d
spec:
approvalMessage: |-
Please review the following information
and approve the pipeline progression
includePipelineExecutionHistory: true
approvers:
minimumCount: 1
disallowPipelineExecutor: false
userGroups: <+input>
approverInputs: []
- step:
type: ShellScript
name: ShellScript Step
identifier: ShellScript_Step
spec:
shell: Bash
onDelegate: true
source:
type: Inline
spec:
script: <+input>
environmentVariables: []
outputVariables: []
executionTarget: {}
timeout: 10m
tags: {}
- stage:
name: Sample Deploy Stage
identifier: Sample_Deploy_Stage
description: \"\"
type: Deployment
spec:
serviceConfig:
serviceRef: <+input>
serviceDefinition:
spec:
variables: []
type: Kubernetes
infrastructure:
environmentRef: <+input>
infrastructureDefinition:
type: KubernetesDirect
spec:
connectorRef: <+input>
namespace: <+input>
releaseName: release-<+INFRA_KEY>
allowSimultaneousDeployments: false
execution:
steps:
- step:
name: Rollout Deployment
identifier: rolloutDeployment
type: K8sRollingDeploy
timeout: 10m
spec:
skipDryRun: false
rollbackSteps:
- step:
name: Rollback Rollout Deployment
identifier: rollbackRolloutDeployment
type: K8sRollingRollback
timeout: 10m
spec: {}
tags: {}
failureStrategies:
- onFailure:
errors:
- AllErrors
action:
type: StageRollback
"{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Returns a Pipeline by Identifier
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
if true, return all the default entities
This is a boolean value. If true, returns Templates resolved Pipeline YAML in the response else returns null.
falsefalsefalsefalseBad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns pipeline YAML
GET /gateway/pipeline/api/pipelines/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Updates a Pipeline by Identifier
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
Path to the root folder of the Entity. [Applicable for Old Git Sync only]
File Path of the Entity.
Commit Message to use for the merge commit.
Its required field during update call request. It can be fetched from the response of GET API call for the entity
If the entity is git-synced, this parameter represents the commit id against which file conflicts are resolved
Name of the default branch.
Identifier of Connector needed for CRUD operations on the respective Entity
last commit id of the file
Checks the new branch
falseIs Harness code repo enabled
Version of Entity to match
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns updated pipeline
PUT /gateway/pipeline/api/pipelines/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/json
Accept: */*
Content-Length: 6
"text"{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Deletes a Pipeline by Identifier
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
Path to the root folder of the Entity. [Applicable for Old Git Sync only]
File Path of the Entity.
Commit Message to use for the merge commit.
Last Object Id
Version of Entity to match
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Boolean status whether request was successful or not
DELETE /gateway/pipeline/api/pipelines/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Returns List of Pipelines in the Given Project
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Page Index of the results to fetch.Default Value: 0
0Results per page (max 200)
25Sort criteria for the elements.
Search term to filter out pipelines based on pipeline name, identifier, tags.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
if true, return all the default entities
Boolean flag to get distinct pipelines from all branches.
Properties of the Pipelines Filter defined in Harness
This specifies the corresponding Entity of the filter.
This is the list of the Pipeline Identifiers on which the filter will be applied.
This is the Pipeline Name on which the filter will be applied.
This is the Pipeline Description on which the filter will be applied.
This is the Pipeline repo filter on which the filter will be applied.
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Paginated list of pipelines.
POST /gateway/pipeline/api/pipelines/list?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"filterType": "PipelineSetup"
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Returns Pipeline Summary by Identifier
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
if true, return all the default entities
falsefalseBad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns Pipeline Summary having pipelineIdentifier as specified in request
GET /gateway/pipeline/api/pipelines/summary/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Identifier of Connector needed for CRUD operations on the respective Entity
Name of the repository.
Name of the branch.
File Path of the Entity.
isForceImport
falseIs Harness code repo enabled
Contains basic information required to be linked with imported Pipeline YAML
Expected Name of the Pipeline to be imported
Expected Description of the Pipeline to be imported
YAML Version of the Pipeline
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Import and Create Pipeline from Git Repository and saves a record for it in Harness
POST /gateway/pipeline/api/pipelines/import?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text&repoName=text&branch=text&filePath=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/json
Accept: */*
Content-Length: 69
{
"pipelineName": "text",
"pipelineDescription": "text",
"version": "text"
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Identifier of Connector needed for CRUD operations on the respective Entity
Name of the repository.
Name of the branch.
File Path of the Entity.
isForceImport
falseIs Harness code repo enabled
Contains basic information required to be linked with imported Pipeline YAML
Expected Name of the Pipeline to be imported
Expected Description of the Pipeline to be imported
YAML Version of the Pipeline
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Import and Create Pipeline from Git Repository and saves a record for it in Harness
POST /gateway/pipeline/api/pipelines/import/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text&repoName=text&branch=text&filePath=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/json
Accept: */*
Content-Length: 69
{
"pipelineName": "text",
"pipelineDescription": "text",
"version": "text"
}{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Force-refreshes the git file cache for a remote pipeline and returns the freshly fetched Pipeline. Requires the git branch query parameter — repo default branch is not inferred when branch is omitted. Intended for customer-facing recovery when the git-to-Harness sync is stale (webhook lost, race condition, etc.). Behind the PIPE_GITX_FORCE_REFRESH feature flag.
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns pipeline YAML fetched fresh from git
GET /gateway/pipeline/api/pipelines/refresh-and-get/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text&branch=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Update git-metadata in remote pipeline and returns the identifier of updated pipeline
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Identifier of Connector needed for CRUD operations on the respective Entity
Name of the repository.
File Path of the Entity.
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns identifier of updated pipeline
PUT /gateway/pipeline/api/pipelines/{pipelineIdentifier}/update-git-metadata?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Accept: */*
{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Updates a Pipeline by Identifier
Pipeline Identifier
Account Identifier for the Entity.
Organization Identifier for the Entity.
Project Identifier for the Entity.
Name of the branch.
Git Sync Config Id. [Applicable for Old Git Sync only]
Path to the root folder of the Entity. [Applicable for Old Git Sync only]
File Path of the Entity.
Commit Message to use for the merge commit.
Its required field during update call request. It can be fetched from the response of GET API call for the entity
If the entity is git-synced, this parameter represents the commit id against which file conflicts are resolved
Name of the default branch.
Identifier of Connector needed for CRUD operations on the respective Entity
last commit id of the file
Checks the new branch
falseIs Harness code repo enabled
Allow Dynamic Executions for the Pipeline
falseVersion of Entity to match
Bad Request
This is Failure entity as defied in Harness
Not Found
Internal server error
Returns updated pipeline with metadata
PUT /gateway/pipeline/api/pipelines/v2/{pipelineIdentifier}?accountIdentifier=text&orgIdentifier=text&projectIdentifier=text HTTP/1.1
Host: pipeline-service-6c65d4b68c-lrg8j
Content-Type: application/yaml
Accept: */*
Content-Length: 3992
"|
pipeline:
name: Sample Pipeline
identifier: Sample_Pipeline
allowStageExecutions: false
projectIdentifier: Temp
orgIdentifier: default
tags: {}
stages:
- stage:
name: Sample Stage
identifier: Sample_Stage
description: \"\"
type: Approval
spec:
execution:
steps:
- step:
name: Approval Step
identifier: Approval_Step
type: HarnessApproval
timeout: 1d
spec:
approvalMessage: |-
Please review the following information
and approve the pipeline progression
includePipelineExecutionHistory: true
approvers:
minimumCount: 1
disallowPipelineExecutor: false
userGroups: <+input>
approverInputs: []
- step:
type: ShellScript
name: ShellScript Step
identifier: ShellScript_Step
spec:
shell: Bash
onDelegate: true
source:
type: Inline
spec:
script: <+input>
environmentVariables: []
outputVariables: []
executionTarget: {}
timeout: 10m
tags: {}
- stage:
name: Sample Deploy Stage
identifier: Sample_Deploy_Stage
description: \"\"
type: Deployment
spec:
serviceConfig:
serviceRef: <+input>
serviceDefinition:
spec:
variables: []
type: Kubernetes
infrastructure:
environmentRef: <+input>
infrastructureDefinition:
type: KubernetesDirect
spec:
connectorRef: <+input>
namespace: <+input>
releaseName: release-<+INFRA_KEY>
allowSimultaneousDeployments: false
execution:
steps:
- step:
name: Rollout Deployment
identifier: rolloutDeployment
type: K8sRollingDeploy
timeout: 10m
spec:
skipDryRun: false
rollbackSteps:
- step:
name: Rollback Rollout Deployment
identifier: rollbackRolloutDeployment
type: K8sRollingRollback
timeout: 10m
spec: {}
tags: {}
failureStrategies:
- onFailure:
errors:
- AllErrors
action:
type: StageRollback
"{
"status": "SUCCESS",
"code": "DEFAULT_ERROR_CODE",
"message": "text",
"correlationId": "text",
"errors": [
{
"fieldId": "text",
"error": "text"
}
]
}Last updated
Was this helpful?