Everything the apps do, you can do too. 60 REST endpoints, described by a single OpenAPI 3.1 contract, with a generated TypeScript client we use ourselves on web and mobile. No scraping, no reverse-engineering — it's the real thing.
Sign in with POST /v1/auth/login to start a session. Browser clients use a secure session cookie; mobile and server-to-server clients use a bearer token and rotate it with POST /v1/auth/refresh. There is no open relay — every send is authenticated and attributed to your account.
# Authenticate, then list the threads in a mailbox
curl -s https://api.anfon.co/v1/auth/login \
-H 'content-type: application/json' \
-d '{"email":"you@your-domain.au","password":"••••••••"}'
curl -s https://api.anfon.co/v1/mailboxes/$MAILBOX/threads \
-H "authorization: Bearer $TOKEN"
Typed client
We publish a TypeScript client generated straight from the OpenAPI spec — the same one powering our web and mobile apps. Point it at the spec and you get fully-typed calls and responses for every endpoint below.
import { listThreads, addNote } from '@anfon/api-client';
const { data } = await listThreads({
client, path: { mailbox_id }, query: { folder: 'inbox' },
});
// Collaborate: drop an internal note and @mention a teammate
await addNote({
client, path: { thread_id },
body: { body: 'Looping you in @sam', mentioned_user_ids: [samId] },
});
Endpoints
The full surface, grouped. Open any group for the routes; hit the interactive reference for request/response schemas and a live try-it console. A lock means the endpoint requires authentication.
Auth & sessions4
POST/v1/auth/loginAuthenticate and start a session
POST/v1/auth/logoutRevoke the current session
POST/v1/auth/refreshRotate a refresh token (mobile/api)
POST/v1/auth/signupCreate an account + owner and start a session
Account2
GET/v1/accountAccount details
GET/v1/meCurrent user + accessible mailboxes
Users & directory3
GET/v1/directoryList account people for @mention pickers
GET/v1/usersList account users (owner)
POST/v1/usersCreate a user (owner)
Domains7
GET/v1/domainsList domains
POST/v1/domainsOrder a domain + auto-provision DNS/DKIM (owner)
Building something with it? We'd love to hear about it — and we're adding IMAP/JMAP and webhooks to the roadmap. Tell us what you need at our contact page.