---
title: "Email a 6-digit sign-in code (step 1 of agent onboarding without a browser)"
method: POST
path: "/v1/auth/request-code"
tags: ["discovery"]
---

# Email a 6-digit sign-in code (step 1 of agent onboarding without a browser)

`POST /v1/auth/request-code`

## Request

- Base URL: `https://postbag.dev`
- URL: `https://postbag.dev/v1/auth/request-code`
- Auth: none required

Public, unauthenticated. Sends a 6-digit code good for 10 minutes to the given address. Always 200 for a well-formed email, whether or not an account exists — this endpoint never confirms or denies an account's existence. Rate limited per email and per client IP. The human reads the code out of their inbox and gives it to the agent, which calls POST /v1/auth/verify-code next.

## Request body

- object
  - `email` string, email, required: Lowercased and trimmed before use. Always 200s for a well-formed address.

## Response `200`

ok

- object
  - `ok` true, required
  - `expires_in` integer, required
  - `next` string, required

## Other responses

- `429`: Rate limited
- `501`: Email sending is not configured on this server
- `502`: The code email could not be sent

---

[API](https://skmtc.dev/postbag/apis/postbag-api.md) · [All operations](https://skmtc.dev/postbag/apis/postbag-api/llms.txt) · [OpenAPI document](https://skmtc.dev/postbag/apis/postbag-api/revisions/3da976524695?raw)
