Skip to main content

Integration Steps Reference

Last updated on

Harness 3.0 provides integration steps for HTTP requests, notifications, ticketing systems, CI tools, remote execution, and AI-based verification. These steps enable pipelines to interact with external systems and services.


HTTP Step

Template: httpStep@1.0.0 · Module: CD/Custom

Execute HTTP requests with support for all methods, custom headers, mTLS authentication, response validation using CEL expressions, and output variable extraction. Runs in harnessdev/harness-http:0.0.1.

InputTypeRequiredDescription
urlstringYesURL for the HTTP request
methodselectYes (default: GET)HTTP method (GET, POST, PUT, DELETE, PATCH, HEAD, OPTIONS, TRACE, CONNECT)
headersstring (textarea)NoHTTP headers as JSON (e.g., {"Content-Type":"application/json"})
bodystring (textarea)NoRequest body content
body_filestringNoPath to file containing body
work_dirstringNoWorking directory (default: workspace)
assertionstring (textarea)NoCEL expression for validation (e.g., response.code == 200)
output_varsstring (textarea)NoJSON mapping for output variables
env_varskey-value-pairsNoEnvironment variables
client_certstring (secret)NoClient certificate for mTLS
client_keystring (secret)NoPrivate key for mTLS
skip_verifybooleanNo (default: false)Skip SSL/TLS verification
proxystringNoHTTP/HTTPS proxy URL
disable_redirectbooleanNo (default: false)Disable redirect following
log_levelselectNo (default: debug)Log level
CEL Expression Support

The HTTP step uses CEL (Common Expression Language) for response assertions and output variable extraction. Use response.code for status code, response.body for parsed JSON body, and response.headers for response headers.

http-get.yaml
steps:
- name: Health Check
uses: httpStep@1.0.0
with:
url: https://api.example.com/health
method: GET
assertion: response.code == 200
http-post.yaml
steps:
- name: Create Resource
uses: httpStep@1.0.0
with:
url: https://api.example.com/resources
method: POST
headers: '{"Content-Type":"application/json","Authorization":"Bearer <+secrets.getValue(\"api_token\")>"}'
body: '{"name":"new-resource","type":"production"}'
assertion: response.code == 201
output_vars: '{"resource_id":"response.body.id"}'
http-mtls.yaml
steps:
- name: Secure API Call
uses: httpStep@1.0.0
with:
url: https://internal-api.example.com/data
method: GET
client_cert: <+secrets.getValue("client_cert")>
client_key: <+secrets.getValue("client_key")>

Email Step

Template: email@1.0.0 · Module: CD

Send email notifications to recipients and user groups. Runs in harnessdev/email:0.0.1.

InputTypeRequiredDescription
email_idsstringYesPrimary recipient email addresses
subjectstringYesEmail subject line
bodystring (textarea)YesEmail message content
cc_email_idsstringNoCC email addresses
to_user_groupsstringNoPrimary recipient user groups
cc_user_groupsstringNoCC user groups
smtp_configstringNoSMTP configuration
attachmentslistNoEmail attachments
log_levelselectNo (default: info)Log level
email-example.yaml
steps:
- name: Notify Team
uses: email@1.0.0
with:
email_ids: "team@example.com,lead@example.com"
subject: "Deployment Complete - <+pipeline.name>"
body: |
Pipeline <+pipeline.name> has completed successfully.
Environment: <+env.name>
Build: <+pipeline.sequenceId>

Jira Integration Steps

Three integration steps for creating, updating, and approving via Jira issues.

StepTemplate IDVersionDescription
Jira CreatejiraCreate1.0.0Create a new Jira issue
Jira UpdatejiraUpdate1.0.0Update an existing Jira issue
Jira ApprovaljiraApproval1.0.0Approve or reject via Jira issue

Key inputs (create step):

InputTypeRequiredDescription
connectorconnector (Jira)YesJira connector
projectstringYesJira project key (e.g., PROJ)
issue_typestringYesIssue type (Story, Bug, Task, etc.)
fieldskey-value-pairsNoAdditional fields to set
jira-create.yaml
steps:
- name: Create Bug Ticket
uses: jiraCreate@1.0.0
with:
connector: account.jira
project: PROJ
issue_type: Bug
fields:
summary: "Deployment failed - <+pipeline.name>"
description: "Pipeline execution <+pipeline.executionId> failed."
priority: High
jira-approval.yaml
steps:
- name: Jira Approval
uses: jiraApproval@1.0.0
with:
connector: account.jira
issue_key: <+pipeline.variables.jira_ticket>
approval_criteria:
status: Approved

ServiceNow Integration Steps

Four integration steps for creating, updating, approving, and importing records via ServiceNow.

StepTemplate IDVersionDescription
ServiceNow CreateserviceNowCreate1.0.0Create a ServiceNow ticket
ServiceNow UpdateserviceNowUpdate1.0.0Update an existing ticket
ServiceNow ApprovalserviceNowApproval1.0.0Approve or reject via ServiceNow
ServiceNow Import SetserviceNowImportSet1.0.0Import a set of records
servicenow-create.yaml
steps:
- name: Create Change Request
uses: serviceNowCreate@1.0.0
with:
connector: account.servicenow
table: change_request
fields:
short_description: "Deploy <+service.name> to production"
category: Software
priority: "2"

Jenkins Build

Template: jenkinsBuild@1.0.0 · Module: CI

Execute a Jenkins job and monitor its progress.

InputTypeRequiredDescription
connectorconnector (Jenkins)YesJenkins connector
jobstringYesJenkins job name/path
paramskey-value-pairsNoJob parameters
jenkins-build.yaml
steps:
- name: Trigger Jenkins Build
uses: jenkinsBuild@1.0.0
with:
connector: account.jenkins
job: my-project/main
params:
BRANCH: main
DEPLOY_ENV: staging

Bamboo Build

Template: bambooBuild@1.0.0 · Module: CI

Execute a Bamboo plan and monitor its progress.

InputTypeRequiredDescription
connectorconnector (Bamboo)YesBamboo connector
planstringYesBamboo plan key
paramskey-value-pairsNoBuild parameters
bamboo-build.yaml
steps:
- name: Trigger Bamboo Build
uses: bambooBuild@1.0.0
with:
connector: account.bamboo
plan: PROJ-PLAN

SSH Step

Template: ssh@1.0.0 · Module: CD

Execute a shell script on a remote host using SSH. Runs in harnessdev/ssh:0.0.1.

InputTypeRequiredDescription
hoststringYesTarget SSH host/IP
scriptstringYesShell script to execute
portintegerNo (default: 22)SSH port
work_dirstringNoRemote working directory
env_varskey-value-pairsNoEnvironment variables
out_varskey-value-pairsNoOutput variables to capture
secret_out_varskey-value-pairsNoSecret output variables
script_timeoutstringNo (default: 30m)Execution timeout
log_levelselectNo (default: info)Log level
ssh-deploy.yaml
steps:
- name: Deploy to Server
uses: ssh@1.0.0
with:
host: 10.0.1.100
port: 22
script: |
cd /opt/app
docker pull myorg/myapp:latest
docker-compose up -d
env_vars:
APP_VERSION: <+pipeline.sequenceId>
out_vars:
deploy_status: DEPLOY_STATUS
script_timeout: 10m

WinRM Step

Template: winrm@1.0.0 · Module: CD

Execute a PowerShell script on a remote Windows host using WinRM.

InputTypeRequiredDescription
hoststringYesTarget WinRM host
scriptstringYesPowerShell script to execute
portintegerNo (default: 5985)WinRM port
env_varskey-value-pairsNoEnvironment variables
out_varskey-value-pairsNoOutput variables
script_timeoutstringNo (default: 30m)Timeout
winrm-deploy.yaml
steps:
- name: Deploy to Windows
uses: winrm@1.0.0
with:
host: 10.0.1.200
script: |
Stop-Service -Name "MyApp"
Copy-Item "\\share\builds\latest\*" "C:\MyApp\" -Recurse
Start-Service -Name "MyApp"
script_timeout: 15m

AI Verify Step

Template: aiVerifyStep@2.0.0 · Module: CV

AI-based verification for continuous deployment with intelligent anomaly detection and log analysis. Supports multiple health source types including Datadog Metrics, Dynatrace Grail Logs, and generic log sources. Uses a matrix strategy to run verification across all configured health sources.

InputTypeRequiredDescription
health_sourcesarrayYesHealth source identifiers to verify
durationstringYes (default: 5)Verification duration in minutes
sensitivityselectYes (default: Medium)Anomaly detection sensitivity (Low, Medium, High)
fail_no_databooleanNo (default: true)Fail if no analysis data
fail_metricbooleanNo (default: true)Fail if any metric has no analysis
control_regexstringNoRegex for control nodes (e.g., .*primary.*)
test_regexstringNoRegex for test nodes (e.g., .*canary.*)
baseline_endstringYesEnd time of pre-deployment analysis window
verify_startstringYesStart time of post-deployment analysis window
contextstringNoNatural language context for monitoring
servicestringNoService identifier (default: from context)
envstringNoEnvironment identifier
infrastringNoInfrastructure identifier

Verification workflow: (1) Maps health sources to appropriate data collection plugins (Datadog, Dynatrace, etc.). (2) Runs data collection in parallel using matrix strategy across health sources. (3) Compares baseline (pre-deployment) metrics with verification (post-deployment) metrics. (4) Uses AI to detect anomalies and analyze logs. (5) Reports pass/fail based on sensitivity configuration.

ai-verify.yaml
steps:
- name: AI Verification
uses: aiVerifyStep@2.0.0
with:
health_sources:
- datadog_metrics_prod
- dynatrace_logs_prod
duration: "10"
sensitivity: Medium
context: "Verify new deployment has no performance regression"
Health Source Plugin Selection

AI Verify automatically selects the appropriate data collection plugin based on your health source type. Datadog Metrics uses the metrics plugin, Dynatrace Grail uses the log plugin, and other sources use the default log analysis plugin.