Prerequisites
- A Harness account with the organizations, projects, and cost data you want agents to read.
- Permission to create a service account and assign role bindings. For a quick personal test, your own API key works instead.
- The identifiers (not display names) of any default organization or project you want to set.
- The Admin role in your CloudThinker workspace, which can add and edit connections. See Roles.
Setup
1
Create a service account
In Harness, open Account Settings → Access Control → Service Accounts and create one named
cloudthinker. Then add role bindings for read-only access:An account-level service account covers both project delivery data and account-level cost data.
2
Generate a token
Open the service account, select API Keys → API Key, and save a new key. Under that key, select Token, set an expiration date, and click Generate Token.Copy the token right away. It starts with
sat., and Harness shows it once. A personal key from your profile’s My API Keys gives a pat. token the same way.3
Add the connection in CloudThinker
In the sidebar, click More → Workspace settings → Connections, stay on the Builtin Connections tab, and select Harness. Fill in:
- API key: the token you generated
- Harness URL: keep
https://app.harness.iounless you use another cluster or a self-managed install. To find yours, sign in to Harness and copy the scheme and host from the browser address bar, for examplehttps://<your-host>. - Default organization and Default project: optional. Set both or leave both blank.
Connection details
Copy identifiers exactly as they appear in the resource’s settings in Harness. A display name like “Payments Team” won’t match.
Required permissions
The token inherits the permissions of its service account or user. Grant view access to everything agents should inspect:Agent capabilities
Every create, update, or delete goes through Approvals.
Every change an agent makes goes through your workspace’s Approvals first. On the default Auto · Rules + AI · Ask me mode, AI judgment can let a safe change run without asking — and an Allow Rule can too, once CloudThinker turns on Rule enforcement for your workspace. Choose Manual to approve every change yourself.
There’s no Allow writes switch on this connection, so to keep it read-only, grant the token view roles only. Agents can’t run, retry, or interrupt a pipeline execution, toggle a feature flag, sync a GitOps application, or approve a Harness approval step. Those controls aren’t part of this connection.
Verify the connection
Example prompts
Troubleshooting
A request says project scope is required
A request says project scope is required
The resource needs both an organization and a project identifier. Set Default organization and Default project, or ask the agent to list your organizations and projects first, then repeat the request with the identifiers.
An organization or project is not found
An organization or project is not found
You used a display name instead of an identifier. Copy the identifier from the resource’s settings in Harness.
The agent won't run or retry a pipeline
The agent won't run or retry a pipeline
That’s by design. Run, retry, or interrupt the pipeline in Harness. Agents can still inspect the execution and diagnose why it failed.
Security
- Least privilege — grant only the permissions the agents need for your use case; start read-only and widen later.
- Read-only by default — use read-only credentials unless you want agents to make changes through this connection.
- Rotate credentials — rotate keys and tokens on your normal schedule; CloudThinker picks up the new value when you update the connection.
- Revoke on offboarding — remove the credential at the provider when you delete a connection or a teammate leaves.
- Service account over personal key: the connection keeps working when a person’s access changes or they leave.
- Expiring token: set an expiration date on the token and replace it before it lapses.
Related
CircleCI Connection
Check pipeline status and analyze failed workflows.
Approvals
Control which Harness changes wait for a person.