Docs · v0
Enroll API
Product-triggered outbound. Your app already has the address. POST /api/enroll puts them on a sequence sent from the customer's domain. v0 does not require a Bearer API key — use a session cookie or the optional workspace header.
POST /api/enroll
JSON body. email and provenance.source are required. sequenceId is an optional UUID — omit it to use the workspace default sequence. Tags merge onto the contact.
curl -s -X POST $APP_URL/api/enroll \
-H 'content-type: application/json' \
-H 'x-enrollmill-workspace: you@company.com' \
-d '{
"email": "casey@example.com",
"sequenceId": "11111111-1111-1111-1111-111111111111",
"tags": ["trial"],
"provenance": {
"source": "usagemill.overage",
"eventId": "evt_01HQ",
"mill": "usagemill"
}
}'200 returns { ok, enrollmentId, contactId, sequenceId, status, idempotent }. Invalid JSON or payload is 400.
Workspace (no Bearer key in v0)
Auth is soft. There is no API key header yet. Resolution order:
- Signed-in session cookie, if present.
- Optional header
x-enrollmill-workspace(email). Creates the workspace on first use. - Otherwise the first user in the database, or
mill@enrollmill.com.
Idempotency
When provenance.eventId is set, retries with the same workspace + event return the existing enrollment and idempotent: true. Without an event id, the key is workspace + email + sequence + source.
Stop on reply or bounce
Webhook stubs accept a payload and record a timeline event. If a matching contact exists, the latest enrollment status becomes replied or bounced — that is the v0 stop. There is no guaranteed inbox and no warmup product.
curl -s -X POST $APP_URL/api/webhooks/bounce \
-H 'content-type: application/json' \
-d '{"email":"casey@example.com","reason":"mailbox full"}'
curl -s -X POST $APP_URL/api/webhooks/reply \
-H 'content-type: application/json' \
-d '{"email":"casey@example.com","text":"unsubscribe me"}'Both return { ok: true, recorded: true, contactId, enrollmentId }.
GET /api/health
curl -s $APP_URL/api/health
# {"ok":true}Domain checklist (manual in v0)
Mail should leave on a domain you control. Enrollmill does not auto-verify SPF, DKIM, or DMARC yet. Inspect DNS yourself, then tick the boxes on /domains (sign-in required).
- SPF — TXT,
v=spf1 include:<your ESP> -all - DKIM — selector CNAME or TXT from your ESP
- DMARC — TXT on
_dmarc, start withp=none
Anti-claims
We will not sell a scrape, a LinkedIn farm, an owned prospect database, inbox warmup as the hero feature, or a guaranteed inbox. Enrollmill enrolls people your product already knows, on the customer's reputation.
Media Yard LLC · PO Box 73, Pennsauken, NJ 08110 · Terms · Privacy · Support