canonical: https://jentic.com/apis/mailinapp.com/mailinapp

# MailInApp API

The MailInApp API sends transactional and marketing email, keeps contacts in lists, and enrolls people in automated journeys, with deals, webinars, and course memberships on the same account. A send can be freeform with subject and html, or use an existing studio project with mergeData, and suppressed or invalid addresses are skipped. Contacts are upserted one at a time or up to 500 per batch into a list, deals are created and moved between pipeline stages, and journeys with an API trigger accept enrollments by email. Account-level REST Hooks webhook subscriptions push signed events to Zapier, n8n, or your own backend.

## For AI agents

Send email, upsert contacts, enroll people in journeys, track deals, and register webinar attendees with MailInApp, plus signed webhook subscriptions for its events.

## Scope

Does not process payments, send SMS, or host webinar video streams. Use for email sends, contacts, journeys, deals, and webinar and course access only.

## Capabilities

- Send a transactional or marketing email freeform or from a studio project with mergeData
- Upsert one contact or up to 500 contacts per batch into a list, and find a contact by email
- Enroll a contact in a journey that accepts API-triggered enrollment
- Create a deal with value, currency, pipelineId, and stageId, then move it to another stage
- Schedule a webinar and register attendees by email and name
- Grant or revoke course membership access and mint a member-portal embed URL
- Subscribe a URL to account events with REST Hooks and preview sample event payloads

## Use cases

### AI agent nurturing a new lead through Jentic

A sales-assist agent receives a demo request and needs to file it and start follow-up. Through Jentic it searches for 'add a contact to a list', loads the MailInApp upsert operation, adds the lead to a list with fields, creates a deal in the right pipeline stage, and enrolls the contact in an API-triggered journey. The API key is injected at call time.

Example prompt: Call POST `/api/v1/contacts` with listId and email 'lead@example.com', POST `/api/v1/deals` with title 'Demo request' and pipelineId, then POST `/api/v1/journeys/{id}/trigger` with email and listId

### Transactional email from an app

An app sends receipts and password resets and wants them designed in a studio template. MailInApp sends with a projectId and mergeData for the template, or freeform with subject, html, and text, and marks suppressed or invalid addresses as not sent. An Idempotency-Key header lets a retried send avoid a duplicate.

Example prompt: Call POST `/api/v1/send` with to 'customer@example.com', type 'transactional', projectId, and mergeData holding the order number

### Webinar and course access

Creators running webinars and paid courses want registrations and access in one place. MailInApp schedules a webinar with a title, scheduledAt, and capacity, registers attendees by email and name, grants or revokes course membership with the active flag, and mints a member-portal embed URL so a buyer lands straight in the course.

Example prompt: Call POST `/api/v1/courses/{id}/enroll` with email and active true after a purchase, then POST `/api/v1/courses/{id}/embed-token` for the same email

### Event hooks for Zapier or n8n

Automation builders want MailInApp events to start flows elsewhere. REST Hooks subscriptions register a URL for chosen events, sample payloads can be fetched by type before wiring a flow, and each delivery is signed with an HMAC in X-MailInApp-Signature and carries X-MailInApp-Idempotency-Key so a receiver can drop redeliveries.

Example prompt: Call GET `/api/v1/events/sample` for an event type, then POST `/api/v1/webhooks` with url and events to subscribe

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | `/api/v1/send` | Send an email |
| POST | `/api/v1/contacts` | Create or update contacts |
| POST | `/api/v1/journeys/{id}/trigger` | Enroll a contact in a journey |
| POST | `/api/v1/deals` | Create a deal |
| PATCH | `/api/v1/deals/{id}` | Update or move a deal |
| POST | `/api/v1/webinars/{id}/register` | Register for a webinar |
| POST | `/api/v1/courses/{id}/enroll` | Grant or revoke course access |
| POST | `/api/v1/webhooks` | Subscribe to events |

## Key resources

- **Contacts and lists** — Contacts upserted into lists, found by email
- **Journeys** — Automations that accept api-triggered enrollments
- **Deals and pipelines** — Deals with value, currency, and stage across pipelines
- **Webinars and courses** — Scheduled webinars with registrations, and course memberships with embed URLs
- **Webhook subscriptions** — REST Hooks subscriptions delivering signed events

## AI readiness

This API is usable in Jentic One now. Its AI-readiness score against Jentic's framework shows where it stands today and where improvements would make it even easier for agents to use.

- **Score:** 64 / 100
- **Maturity:** AI-Aware
- **Dimensions:**
  - Foundational Compliance: 93 / 100
  - Developer Experience & Jentic Compatibility: 63 / 100
  - AI-Readiness & Agent Experience: 46 / 100
  - Agent Usability: 94 / 100
  - Security: 60 / 100
  - AI Discoverability: 61 / 100
- **View full report:** https://jentic.com/apis/mailinapp.com/mailinapp/scorecard
- **How the score is calculated:** https://docs.jentic.com/reference/api-readiness-framework/overview/
- **More about the dimensions:** https://docs.jentic.com/reference/api-readiness-framework/specification/#dimensional-model-overview

### Score it yourself

Every API in the directory is allowlisted, so you can re-score it with no key required.

- **Score your own API:** https://jentic.com/scorecard.md
- **Scoring CLI agent skill:** https://github.com/jentic/jentic-api-scorecard/blob/main/skills/jentic-api-scorecard/SKILL.md

```sh
npx @jentic/api-scorecard-cli score <openapi-url>
```

## Why Jentic

- **Setup:** Wiring MailInApp by hand means a bearer key, Idempotency-Key headers on sends and deals, per-route-family rate limits, and verifying HMAC-signed webhooks. Through Jentic you install once, import MailInApp from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** MailInApp puts journey, deal, webinar, and course ids in the URL path, such as `/api/v1/journeys/{id}/trigger`, so a rule can pin your agent to one journey or one course and the operations you pick. You choose the operations it may call, so ones like sending email, revoking course access, or unsubscribing a webhook are not included unless you add them.
- **Credential handling:** Your MailInApp API key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'enroll a contact in a journey' or 'send an email', and Jentic returns the matching MailInApp operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Mailchimp** — Email marketing with audiences, campaigns, and automations
- **Brevo** — Email, SMS, and marketing automation with a CRM
- **Kit (ConvertKit)** — Creator email marketing with sequences and tags
- **Pipedrive** — Sales CRM with full deal pipeline management

## FAQ

### What authentication does the MailInApp API use?

The MailInApp API authenticates with an API key from Dashboard, Developers, sent as a bearer token in the Authorization header in the mia_live_ format, per its OpenAPI spec. One operation, GET `/api/v1/liveview/{token}`, takes no key because the signed token in its path is the authorization. Through Jentic the key is stored by your own instance and attached at call time.

### What are the rate limits for the MailInApp API?

The MailInApp OpenAPI spec states that each key is rate limited per route family at 60 requests per minute unless an operation notes otherwise, and requests over the limit get a 429 response.

### Can I enroll a contact in a journey with the MailInApp API?

Yes. GET `/api/v1/journeys` with the trigger filter set to `api` lists the journeys that accept enrollment, and POST `/api/v1/journeys/{id}/trigger` enrolls a contact by email and listId.

### Is there a MailInApp MCP server?

You don't need an MCP server to give your agent MailInApp. Jentic connects it directly from the API Directory: import it, store your API key once, and your agent calls the send, contact, journey, and deal operations on demand without loading another server's tool definitions into its context.

### How do I send an email through Jentic?

Search Jentic for 'send an email with MailInApp', load the POST `/api/v1/send` operation, and run it with to plus either subject and html or a projectId with mergeData. To run it on your own infrastructure, install Jentic One from its GitHub repo.

### Can I limit what my agent is allowed to do with the MailInApp API?

Yes. For example, a rule that allows POST `/api/v1/contacts` and POST `/api/v1/journeys/{id}/trigger` for one journey id lets the agent add leads and start that one sequence while it cannot send ad hoc email, change deals, or delete webhook subscriptions. Jentic logs each call the agent makes.
