---
title: Mailbox tokens
description: Create, list and revoke the per-address tokens people use to connect gateway mailboxes.
---

Each address on a gateway has its own mailbox token. The token lets one person read and send mail for that address only. You create tokens with the gateway's admin token, then give each token to the person who owns the address.

## Create a token

From the gateway's folder in the source code (`apps/gateway-cloudflare` or `apps/gateway-resend`), run:

```bash
ADMIN_TOKEN=<admin token> bun run token https://<your gateway> create alice@example.com
```

The token is printed once. Copy it and send it to the person in a safe way. Creating a token again for the same address replaces the old one, so the old token stops working.

## List and revoke tokens

```bash
ADMIN_TOKEN=<admin token> bun run token https://<your gateway> list
ADMIN_TOKEN=<admin token> bun run token https://<your gateway> revoke alice@example.com
```

`list` shows which addresses have a token. `revoke` stops the token for an address at once.

:::warning
With the Resend gateway, an address with no token does not receive mail: mail sent to it is dropped. Revoking an address's token stops its mail. With the Cloudflare gateway in catch-all mode, mail for an address with no token is kept until you create one.
:::

## What the person does

The person connects a new mailbox, picks your gateway by its name, and enters:

- **Email address**: the address the token was created for.
- **Mailbox token**: the token you gave them.

Metis Suite refuses the gateway's admin token in this field, and a token shorter than 16 characters. It also checks that the token belongs to the address entered. For the user side, see [Mail](/guide/mail).
