AI agent payments

Plan a spending capability and export it for your agent.

SKILL.md — step-by-step skill for agent hosts (read-only self-check, consent rules, interruption recovery)

This page only plans and exports. It saves nothing and never asks for a key: your agent keeps its own state, you run the generated command on the agent machine, and every payment that needs approval is approved from the command line, never from this page.

1. Describe the capability

Empty lists mean none, never any. The budget must not widen: per payment, then per window, then lifetime.

Check before you grant

  • Set the issuer to your approval key address.
  • Name at least one chain.
  • Name at least one asset.
  • Name at least one recipient address or merchant id.
  • Fill in every budget field with a positive decimal number.
  • Set an expiry date.

2. Export it to the agent machine

Copy the command into the terminal where the agent runs, or hand the JSON to an MCP client that exposes aipay_capability_grant.

CLI command
aipay-agent capabilities grant --issuer <issuer-address> --per-payment <max-per-payment> --per-window <max-per-window> --window-seconds <window-seconds> --total <lifetime-total> --expiry <expiry> --risk medium --approval-mode auto
Capability JSON
{
  "issuer": "",
  "scope": {
    "chains": [],
    "assets": []
  },
  "budget": {
    "perPayment": "",
    "perWindow": "",
    "windowSeconds": "",
    "total": ""
  },
  "expiry": "",
  "riskLevel": "medium",
  "approval": {
    "mode": "auto"
  }
}
Sign this plan here (optional)

Normally you copy the command to the agent machine. You can also sign it here: paste the approval key file that `aipay-agent approval keygen` created, type its passphrase, and this page produces the same `aipay-grant-v1` envelope. The issuer must be that key, because it is also what approves escalated payments there.

The key file is decrypted in this tab only, used for this one signature, and never stored; the passphrase is cleared right after. The CLI `capabilities export` path still works and is equivalent.

Guide for the human running an agent — install, first run, capabilities and delegation, troubleshooting (English).

3. Inspect a policy snapshot

Paste the JSON printed by `aipay-agent policy` to read it here. This box is read-only: nothing is stored and nothing is sent.

Paste a snapshot to see the kill switch, capabilities and pending approvals.

4. Move a capability safely

Paste an `aipay-grant-v1` token to protect it with CryptoKey.im, or open a carrier someone sent you. This page never signs anything: the envelope already carries the issuer's signature, and it is checked again after decryption.

CryptoKey protects confidentiality, not authenticity: the signature is verified here after decryption, before any scope or budget is shown.

A token or JSON file is NOT encrypted: anyone who can read it can see the issuer, scope and budget. Keep it at mode 0600, or wrap it with CryptoKey.

5. Run the agent surface locally

The MCP server and CLI are not a hosted API: they run on the machine that owns the agent's key. The download below is the sanitized runtime (agent/ + the src/lib closure it imports), with a published sha256.

A distribution build is not attached to this deployment yet. The source checkout still works: `node agent/cli.mjs`.

What this page will never do

  • It never stores or transmits anything: the plan lives in this tab only.
  • It never asks for a seed phrase, a private key or a PIN.
  • It cannot grant, revoke or approve anything, and it never signs.
  • Approvals stay on the command line, so the agent can never approve itself.

Next steps

  1. 1.Create the approval key on the agent machine: aipay-agent approval keygen.
  2. 2.Grant the capability with the copied command (issuer is that key's address).
  3. 3.Run aipay-agent policy to export a snapshot and paste it above to check it.
  4. 4.When a payment escalates, approve it with aipay-agent approval approve --id <id>.