Cortex connects to many third-party vendors whose system interfaces frequently change. As a result, integration behavior or configuration steps may shift without notice. If you encounter unexpected issues, check with your system administrator or refer to the vendor’s documentation for the most current information. Additionally, integration sync times vary and are subject to scheduling overrides and timing variance.
Prerequisites
- A configured Harness integration.
- The Harness API key used in that configuration must have permission to execute the pipelines you want to run.
- Permission to create or edit Workflows in Cortex. See Creating a Workflow.
Triggering a Harness pipeline from a Workflow
The Execute pipeline block runs a Harness pipeline as a step in a Workflow. You can chain it with other blocks, for example to require a manual approval before a deploy, or to post the run link to Slack after the pipeline starts. To add the Execute pipeline block to a Workflow:- From the main sidebar, select Workflows.
- Do one of the following:
- Select the All tab to search and filter across all of your organization’s Workflows.
- Select the Mine tab to search and filter only the Workflows you own.
- Note that Cortex saves your selection and restores it the next time you open this page.
- Locate the Workflow you want to edit, click the overflow menu next to it, then select Edit workflow.
- Click the + icon. The Search for blocks window opens.
- Search for Harness, then select Execute pipeline.
- In the side panel, configure the block metadata:
- Block name - Optionally, change the name of the block. The name auto-populates based on the block name.
- Slug - Optionally, change the slug. The slug auto-populates based on the block name and is made up of letters, digits, and hyphens.
- Alias - From the dropdown, select the Harness configuration the block should use (required). See Selecting the right configuration for more information.
- Enter the required pipeline details:
- Under Organization identifier, enter the identifier of the Harness organization that owns the pipeline (required).
- Under Project identifier, enter the identifier of the Harness project that owns the pipeline (required).
- Under Pipeline identifier, enter the identifier of the pipeline you want to run (required).
- Optionally, add runtime inputs:
- Under Runtime inputs, enter the pipeline’s runtime input values as YAML. Use this to pass values the pipeline expects at execution time, such as an environment or an image tag.
- Under Notes, enter a short description of the run. Cortex passes this to Harness so the execution is easier to identify in the Harness UI.
- Click Save.
Block outputs
When the pipeline is triggered successfully, the block returns:execution_id- The identifier of the Harness pipeline execution that was started.status- The execution status Harness reported at trigger time.response- The full response object from Harness, for any field not surfaced above.
The Execute pipeline block is synchronous. It returns as soon as Harness acknowledges the run, so
status reflects the state of the execution at trigger, not the final result of the pipeline. To act on the pipeline’s outcome, poll Harness in a later block or have the pipeline notify Cortex when it finishes.How the block authenticates
The block authenticates with the API key stored in the Harness configuration you select, so the pipeline runs as the owner of that key. It doesn’t run as the person who started the Workflow. Keep this in mind when you set up Harness permissions and when you review pipeline audit logs, since every run started from Cortex is attributed to the key’s owner.Selecting the right configuration
If you have more than one Harness configuration, always select an explicit Configuration alias on the block. A block left on the default configuration uses the default account’s credentials, which is a common cause of unexpected401 errors when you meant to use a different account.
This matters most for internally hosted instances. See Using the block with Cortex Axon Relay.
Using the block with Cortex Axon Relay
The Execute pipeline block works with internally hosted Harness instances connected through Cortex Axon Relay. The relay agent runs in your network and injects your Harness API key locally, so your credentials never leave your environment. For setup instructions, see Internally hosted integrations. Two things to know when you use the block over the relay:- Select the relay-backed configuration alias on the block. Cortex only routes a request through the relay when the block names a configuration alias. If the block is left on the default configuration, the request goes directly to Harness instead of through the relay and fails to authenticate.
- Your Harness API key stays on-premises. Cortex sends the request with a placeholder credential, and the relay agent replaces it with your real key before the request reaches Harness. Both personal access tokens and service account tokens are supported.
Viewing Harness integration logs
This feature is available in Cortex cloud.

Troubleshooting and FAQ
See frequently asked questions below.The block returns a 401 or authentication error
The block returns a 401 or authentication error
Check the following:
- The block has an explicit Configuration alias selected. If it’s set to the default configuration and your Harness instance is behind Cortex Axon Relay, the request bypasses the relay and fails.
- The API key in the selected configuration is still valid, and its owner has permission to execute the pipeline.
- The organization and project identifiers on the block match the account the selected configuration points at.
A relay-backed Harness configuration shows as failing validation
A relay-backed Harness configuration shows as failing validation
A newly created relay-backed configuration can show a failed connection test on the integration settings page, even when the setup is correct. Click Test connection on the configuration to re-run the check. If it still fails, confirm the Axon Relay agent is running and can reach your Harness host.
The pipeline started, but the Workflow moved on before it finished
The pipeline started, but the Workflow moved on before it finished
This is expected. The Execute pipeline block returns as soon as Harness acknowledges the run. Use the returned
execution_id in a later block to check the execution’s final state in Harness.