Payments and finance

Adyen API keys: find, store, rotate, and use them safely with AI agents

Adyen API keys are generated in the Customer Area under Developers → API credentials, per credential and per environment. The key is shown once, and generating a new one keeps the old key valid for 24 hours.

Adyen key types

TypePrefixSecret?ScopeExpiry
API key
Test and live keys are separate; live keys are generated in the live Customer Area.
—YesDetermined by the roles enabled on the API credentialOld keys stay active 24 hours after a new one is generated, unless expired sooner

How to create a Adyen key

  1. In the Customer Area select your company account and go to Developers → API credentials.
  2. Open the credential on the Payments or Platforms tab.
  3. Under Server settings → Authentication select API key and click Generate API key.
  4. Copy the key before leaving the page, then Save changes.

Limiting what the key can do

Roles on the credential (under Permissions) define what it can do; at least one must be enabled. Under Server settings → Allowed IP range you can limit requests to listed IP ranges.

How to rotate a Adyen key

  1. Generate a new API key on the credential; it becomes active immediately.
  2. Deploy the new key.
  3. Under Expiring keys expire the old key immediately, or let the 24-hour window end.

The previous key stays active for 24 hours; you can reset that window to 24 hours or expire it immediately.

How to revoke a Adyen key

  1. Credentials cannot be deleted. Set the credential to Inactive to block its keys immediately.

If your Adyen key leaked

  1. Generate a new API key and expire the old one immediately under Expiring keys.
  2. Set the credential Inactive if you cannot rotate right away.
  3. Add an allowed IP range to the credential.

Things that catch people out

  • The key cannot be copied again after you leave the page.
  • Authenticate with the x-API-key header (header names are case-insensitive); Basic auth with a web service user is the alternative.
  • Credentials cannot be deleted, only set Inactive.

Using your Adyen key with AI agents

A coding agent that can read your .env file or your shell history can read the key, and anything in its context can end up in logs, transcripts or a prompt-injected request. The safer pattern is to keep the key in a credential broker that performs the authenticated step for the agent and hands back only the result.

BotPassword works this way. For a Adyen key, these intents fit:

IntentWhat BotPassword does
run_withRuns a command with the key injected as an environment variable or a 0600 temporary file, never on the command line, and redacts the key from the output.
http_requestMakes an authenticated API call after checking the destination against the hosts this key may be sent to. The response comes back with credential-shaped values redacted, and one that holds the key itself is refused.
rotatePartly built: creates a new key, stores it as pending, verifies it, promotes it, then revokes the old key after a grace period. Today it works for Cloudflare tokens and AWS IAM keys you have set up, and an agent can start it only under a grant with autopilot; other providers cannot be rotated through their API yet.
store_secretSaves a value the agent already holds as a new vault item.

Set it up in your agent: Aider · Amp · Claude Code · Claude Desktop · Cline · OpenAI Codex CLI · all agents

Frequently asked questions

Where do I find my Adyen API key?

In the Customer Area under Developers → API credentials; generate it under Server settings → Authentication. It cannot be viewed again later.

How do I send an Adyen API key?

In the x-API-key HTTP request header.

What happens to the old Adyen key when I generate a new one?

It stays active for 24 hours unless you expire it immediately under Expiring keys.

Can an AI agent use my Adyen key without seeing it?

Yes, if the key never enters the agent's context. Instead of pasting the key into a chat or leaving it in a .env file the agent can read, keep it in a credential broker that injects it into the command or request on the agent's behalf. BotPassword does this with run_with, http_request, store_secret, so the agent gets the result and never the value.

Stop pasting Adyen keys into agents

BotPassword is in early access. Request an invite and we'll email you when your spot opens.