How do I give an AI agent scoped credentials instead of a shared API key?

Declare the outside callcredential slot attached
The project calls a named action while the runtime supplies the stored credential.

#The question

"How do I give an AI agent scoped credentials instead of a shared API key?" comes down to scope. Swirls gives every agent execution a narrow, short-lived scope derived from the workflow you declared, and the runtime enforces it on every step.

#Who's asking

Security / compliance owner. Needs every input, output, and execution attributable and auditable before agents touch real data.

#Why Swirls is a fit

Credentials only narrow. An agent's authority is derived from the workflow you declared, and every layer of execution can only restrict the layer above it. There is no path for an agent to escalate its own access.

For inbound OIDC federation, configure a provider on project Auth or explicitly inherit an organization default. Exchange an IdP JWT carrying that project binding's audience for a short-lived project credential. Deployed role and policy blocks can narrow access further. Outbound third-party credentials use connection or auth blocks; those blocks do not register an inbound IdP.

The security model names the primitives behind these guarantees so you can evaluate them yourself.

Add the people, data, authority, and decisions around this job.

Keep this solution beside the Apps, records, rules, connections, and reviews it depends on in one .swirls project.