On this page
Application credentials
Application credentials let scripts, CI pipelines and tools authenticate to the Patrii Cloud API without your personal password. Create a scoped credential per integration and revoke it independently.
An application credential is a long-lived identity made of an ID and a secret. It is scoped to the current project and carries a set of roles, so a script acts with exactly the permissions you grant, not your full personal access. Application credentials bypass interactive multi-factor prompts, which is what makes them suitable for automation.
The secret is shown only once, at creation. You store it in your CI or on the machine that runs the script, and use it to obtain API tokens. If a credential is no longer needed or may have leaked, you revoke just that credential, without changing your password or disturbing other integrations.
Key concepts
Application credential — An ID plus secret used by automation to authenticate to the API.
Secret — The confidential half, shown once at creation and never retrievable again.
Scope — The project the credential is bound to; it cannot act outside that project.
Roles — The permissions the credential carries, which can be narrower than your own.
Expiry — An optional date after which the credential stops working.
Before you start
- The project the automation should act in is the active project.
- A place to store the secret securely (a CI secret store or secrets vault).
- A name for the credential that identifies its integration.
Step by step
- Open application credentials
Open your account, or a project's actions menu, and go to Application credentials.
Screenshot — The Application Credentials page with the Create buttonThe Application Credentials page with the Create button - Create a credential
Give it a descriptive name (for example my-ci-pipeline), an optional description, and an optional expiry date.
Screenshot — The Create Application Credential dialogThe Create Application Credential dialog - Copy the secret once
The credential ID and secret are shown once. Copy them, or download the .env file, and store them in your CI secret store. The secret is not shown again.
Screenshot — The credential-created dialog with the one-time secret and Download .env buttonThe credential-created dialog with the one-time secret and Download .env button - Use it in automation
Set the ID and secret as environment variables where your script or pipeline runs, then call the API or CLI with them.
- Revoke when done
Delete the credential when the integration is retired or if the secret may be exposed. Any tokens issued from it stop working.
Examples
export PATRII_APP_CREDENTIAL_ID=<credential-id> export PATRII_APP_CREDENTIAL_SECRET=<credential-secret> patrii server list
# The Terraform provider reads differently named variables export PATRII_APPLICATION_CREDENTIAL_ID=<credential-id> export PATRII_APPLICATION_CREDENTIAL_SECRET=<credential-secret> terraform plan
curl -X POST https://api.patrii.cloud/auth/app-credential-login \
-H 'Content-Type: application/json' \
-d '{"credential_id": "<id>", "credential_secret": "<secret>"}'Limits & specifications
Application credential fields:
| Field | Meaning |
|---|---|
Name | Identifies the integration; letters, numbers, dashes and underscores. |
Credential ID | The non-secret identifier used to log in. |
Secret | The confidential half, shown once at creation. |
Roles | The permissions the credential carries in its project. |
Expires | Optional expiry; blank means it does not expire on its own. |
Best practices
- Create one credential per integration so you can revoke them independently.
- Set an expiry so forgotten credentials do not live forever.
- Store the secret in a CI secret store or the secrets vault, never in the repository.
- Grant only the roles the automation needs, not your full access.
- Revoke immediately on any suspicion of exposure; it does not affect your password.
FAQ
I lost the secret. Can I see it again?
How is this different from my password?
What happens to running jobs when I delete a credential?
Learn more
Everything you can do here in the console is also available through the Patrii Cloud API for automation and scripting.