The Harness Code integration with Corgea lets you scan repositories hosted in Harness Code, receive automated security reviews on every pull request, and create pull requests for code fixes directly from the Corgea platform.Documentation Index
Fetch the complete documentation index at: https://docs.corgea.app/llms.txt
Use this file to discover all available pages before exploring further.
Corgea integrates with Harness Code (the Git-based SCM inside the Harness platform). It does not require — and is independent of — Harness CI/CD pipelines.
Open your Harness profile
Sign in to Harness, then click your username at the bottom-left of the navigation bar and choose Profile Overview.

Create a new API key
Scroll down to the My API Keys section of your profile and click + API Key to create a new key.

Add a token to the API key
The API key itself does not authenticate requests — you need to generate a token under it. Expand the API key you just created and click + Token.

Generate the token
Give the token a name (for example 
corgea-token) and an expiration date, then click Generate Token.
Copy the token
Copy the generated token to your clipboard, then close the dialog. Harness tokens follow the format 
pat.<accountId>.<tokenId>.<secret> — Corgea automatically derives your account ID from the token, so you don’t need to provide it separately.
Open the Corgea integrations page
Sign in to Corgea at 
corgea.app (or {your-instance}.corgea.app for self-hosted deployments) and open the Integrations page from the sidebar. In the Code Repository Integrations section, click the + button next to Harness.
Add the integration
Paste the token you copied from Harness into the API Token field.By default Corgea discovers repositories across every Harness organization the token can see. If you want to limit which orgs Corgea looks at, enter a comma-separated list of org identifiers in the Org allowlist field (for example 
default,my-other-org). Leave it blank to allow all orgs.
Optional settings
Expand Optional settings if you need to adjust any of the defaults:
- Name — a friendly label for the integration. Useful when connecting multiple Harness accounts.
- Base URL — defaults to
https://app.harness.iofor Harness SaaS. Override this if you are connecting to a self-hosted Harness installation. - Gateway prefix — defaults to
/gateway(the SaaS prefix). Some self-hosted deployments drop this prefix; in that case clear the field.

H icon and a <org>/<project>/<repo> label.
How it works
- Repository discovery — Corgea calls the Harness Code API to list every repository under the orgs/projects your token can access (filtered by the allowlist if you set one). New repositories show up automatically; you can force a refresh from the Projects page.
- Pull request scans — when you bind a Corgea project to a Harness repo, Corgea registers a per-repo webhook on Harness Code. Subsequent PR opens, reopens, and pushes trigger an incremental scan and post the results as inline review comments on the diff. Corgea also writes a commit status check (
corgea-security-scan) so PR rules can require it before merging. - Apply fixes as PRs — from any Corgea-detected issue you can click Create Pull Request to have Corgea push the fix to a new Harness branch and open a PR back into the issue’s source branch.
- Corgea Agent — replies to Corgea’s PR comments are routed through the Corgea Agent (when enabled for your company), which can mark issues as false positives, assign them, or answer follow-up questions, threaded under the original review comment.
Permissions
The user (or service account) that owns the API key must have at least the Code Repository Viewer role on every project you want Corgea to read. To enable PR comments, status checks, and PR creation, grant Code Repository Admin (or an equivalent custom role with create/comment/status permissions). See the Harness RBAC documentation for details.Supported Harness deployments
| Deployment | Supported | Notes |
|---|---|---|
Harness SaaS (app.harness.io) | ✅ | Works out of the box with the defaults. |
| Harness Self-Managed Enterprise | ✅ | Override Base URL and, if needed, clear the Gateway prefix field. |

