# AI agents and the Accounts API

Give an AI agent its own key to prepare payments and recipients for a person to approve, covering what an agent key can and can't do, the permissions it may hold, its lower limits, its 24-hour requests, the badge your approvers see, and how to run one safely.

Source: https://dev.vezmo.com/docs/developers/accounts-api-agents


## Overview

An AI agent, such as an assistant that reads your supplier invoices, can prepare payments for you through the Accounts
API. It does that with an **agent key**: a key made for software that writes its own requests, with less room than a
key for your own systems. The agent drafts; a person in your business approves every payment and every recipient in
the dashboard, as for any key. See [Approve API requests](/docs/developers/accounts-api-approvals).

Agent keys need sending with approval on for your business. See
[Get access to the Accounts API](/docs/developers/accounts-api-access).

(Diagram: Example request card. From Vezmo's records: the recipient Atlas Studio LLC, Chase account ending 0193, local bank transfer, and USD 640.00 you send, at a fresh price that holds 10 minutes. Written by the agent, shown as quoted text: Sprint 3 of 4, as agreed on the 2 Nov call, and the reference INV-1042. A badge reads: Requested by an AI agent, key Ops assistant.)

## What an agent key can and can't do

| An agent key can | An agent key can never |
| --- | --- |
| Read your accounts, balances, transactions, statements and events | Approve anything, its own requests included |
| Read your recipients, with account numbers masked | Send money without a person's approval |
| Add a recipient, which waits for a person's approval | Change a recipient's bank or wallet details |
| Stop a recipient still waiting for approval | Make, see or change API keys, or raise any limit |
| Change a recipient's nickname and metadata | Archive a recipient a person already approved (a read and write key or the dashboard can) |
| Get rates and price a payment | Add or change webhook endpoints |
| Ask for a payment, and cancel its own request before anyone decides | Lift a hold or switch the Accounts API on or off, or cancel another key's requests |

## The permissions it may hold

An agent key may hold only these: `accounts.read`, `transactions.read`, `statements.read`, `events.read`,
`recipients.read`, `recipients.write`, `fx.read`, `quotes.write`, `transfers.read` and `transfers.request`. Any other
permission, a VezmoPay one included, is refused with `scope_not_allowed_for_key_type`. Choose only what the agent needs:
one that only drafts payments to recipients you already have doesn't need `recipients.write`.

Its key ID starts with `vzm_live_ag_` or `vzm_test_ag_`, so anyone reading your logs can tell it is an agent.

## How it differs from a key for your systems

- **Shorter waits.** Its payment requests and its recipients expire after 24 hours if nobody decides, instead of 7 days.
- **Lower limits.** USD 1,000 per request, USD 1,000 to one recipient in a day and 20 requests waiting at once. See
  [Limits for sending with approval](/docs/developers/accounts-api-limits).
- **A badge for your approvers.** Each of its requests shows **Requested by an AI agent**, with the key's name, so the
  person approving looks at it as something software wrote.
- **Its memo is quoted text.** Whatever the agent writes in a memo shows as plain quoted text, never as a link or as
  formatting, so it can't steer the person approving. The page shows the recipient and the price from Vezmo's own
  records, not from the request.

## Make an agent key

1. **Generate a key**
In **Settings › Developers**, in **Live keys** or **Test keys**, select **Generate key**.

2. **Choose An AI agent**
Under **Who uses this key**, choose **An AI agent**. Name the key after the agent, and pick its permissions from the
list above. You can give it limits lower than the standard ones.

3. **Confirm it's you**
We email you a code and ask for your passkey or authenticator app. The check names the key type and its limits.

A live agent key must expire, like every live key with Accounts API permissions. See
[Keys and permissions for the Accounts API](/docs/developers/accounts-api-keys).

## Run an agent safely

- **One key per agent.** Never share a key between an agent and your own systems, so you can revoke one without the
  other.
- **Keep the secret away from the model.** Give the agent a tool that calls the API, and keep the key's secret in that
  tool's server, never in a prompt, a chat or a file the model can read.
- **Limit where it runs.** Add the agent's server addresses to the key's allowed IP addresses.
- **Read before you approve.** Check each recipient with the payee on contact details you already had, and each amount
  against the invoice.

## Related

- [Approve API requests](/docs/developers/accounts-api-approvals)
- [Limits for sending with approval](/docs/developers/accounts-api-limits)
- [Keys and permissions for the Accounts API](/docs/developers/accounts-api-keys)
- [Accounts API reference](https://user.vezmo.com/docs/v1/accounts-api)

Vezmo is a financial technology company, not a bank. Banking, stablecoin and card services are provided by regulated
partners.
