canonical: https://jentic.com/apis/customer.io/customerio-api

# Customer.io API

Jentic publishes the only available OpenAPI specification for Customer.io API, keeping it validated and agent-ready. Customer.io is a marketing automation platform that combines behavioural messaging, segmentation, and transactional email into a single workflow tool. This API surface covers customer identification and lifecycle, event tracking, device management, segment and campaign listing, newsletter metrics, customer and delivery exports, and transactional email sending. Authentication uses HTTP Basic with a site ID and API key pair.

## For AI agents

Identify and track customers, send transactional email, manage devices, list campaigns and segments, and export delivery and customer data through Customer.io.

## Scope

Does not handle SMS sending, push notification delivery payloads, or in-app messages - use for customer identification, event tracking, transactional email, and campaign metrics only.

## Capabilities

- Identify and update customer profiles by customer_id with traits and timestamps
- Track named events for an identified customer or anonymously to drive campaign triggers
- Send transactional email through the /send/email endpoint with template and recipient data
- List campaigns and retrieve campaign metrics, actions, and newsletter performance
- Suppress, unsuppress, or delete customer profiles for compliance and lifecycle hygiene
- Export customer and delivery datasets for downstream analytics and audit

## Use cases

### Behavioural Email Automation

Drive lifecycle email campaigns from product behaviour by identifying customers and tracking events that match Customer.io campaign triggers. Use PUT /customers/{customer_id} to maintain the profile and POST /customers/{customer_id}/events to record actions like 'cart_abandoned' or 'trial_expired'. Integration takes a day or two compared with hand-rolling a behavioural messaging stack.

Example prompt: Call PUT /customers/{customer_id} with the user's email and signup_date, then POST /customers/{customer_id}/events with name='trial_started' to enrol them in the trial nurture campaign

### Transactional Email Sending

Send transactional emails such as receipts, password resets, and confirmations through Customer.io's transactional API. POST /send/email accepts a transactional message ID, recipient, and template variables, so product teams can use the same provider for both lifecycle and transactional traffic.

Example prompt: Call POST /send/email with transactional_message_id for the password reset template, the user email, and a reset link variable

### Campaign Performance Reporting

Pull campaign and newsletter metrics into a reporting dashboard or warehouse. GET /campaigns lists active campaigns, GET /campaigns/{campaign_id}/metrics returns send, open, click, and conversion counts, and GET /newsletters/{newsletter_id}/metrics covers one-off sends. Suitable for marketing analysts who want Customer.io performance alongside other channel metrics.

Example prompt: Call GET /campaigns to list campaign IDs, then GET /campaigns/{campaign_id}/metrics for each to populate a weekly performance dashboard

### Customer Data Export

Export customer and delivery datasets for warehouse load, audit, or migration. POST /exports/customers and POST /exports/deliveries kick off async export jobs that return downloadable archives. Used by data teams running daily syncs or by ops teams preparing GDPR data subject access responses.

Example prompt: Call POST /exports/customers with the desired filter to start an export job, then poll GET /activities to confirm completion before downloading

### AI Agent Messaging via Jentic

An AI agent automating customer communications uses Jentic to call Customer.io directly without bespoke integration code. The agent searches for 'send transactional email' or 'track customer event', loads the schema, supplies the parameters, and triggers the action.

Example prompt: Use Jentic to search 'send transactional email' and execute /send/email with the password reset template after a user requests a reset

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| PUT | /customers/{customer_id} | Identify or update a customer |
| POST | /customers/{customer_id}/events | Track a customer event |
| POST | /send/email | Send a transactional email |
| GET | /campaigns | List campaigns |
| GET | /campaigns/{campaign_id}/metrics | Get campaign metrics |
| POST | /exports/customers | Start a customer export job |
| POST | /customers/{customer_id}/suppress | Suppress a customer |
| GET | /segments | List segments |

## Key resources

- **Customers** — Identify, update, suppress, and delete customer profiles
- **Events** — Track customer-attributed and anonymous events that drive campaign triggers
- **Campaigns** — List campaigns and retrieve metrics and action details
- **Newsletters** — List one-off newsletters and retrieve send metrics
- **Segments** — List segments and retrieve segment metadata
- **Transactional** — Send transactional email via templated messages
- **Exports** — Async customer and delivery export jobs
- **Activities** — Audit feed of activity across the workspace

## Why Jentic

- **Setup:** Wiring the Customer.io API by hand means encoding a site ID and key into a Basic auth header, choosing the right track host, and mapping its customer, event, and campaign routes yourself. Through Jentic you install once, import the Customer.io API from the API Directory, store the credential pair once, and your agent calls it.
- **Permission scoping:** Customer.io puts the customer id in the URL path (/customers/{customer_id}/...), so a rule can pin your agent to one customer: it can update that customer and record events for it. You choose the operations it may call, so a suppress or export call is not included unless you add it.
- **Credential handling:** Your Customer.io site ID and API key are stored once, encrypted, by your own Jentic One instance and injected at execution time. They never enter the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'send a transactional email' or 'track a customer event', and Jentic returns the matching Customer.io operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Customer.io Track API** — Customer.io's narrower track-only API surface for identification and events
- **Klaviyo API** — Marketing automation platform with behavioural email and SMS
- **Braze API** — Enterprise customer engagement platform with cross-channel orchestration
- **SendGrid Mail** — Pure transactional email delivery if you want to split lifecycle and transactional

## FAQ

### Why is there no official OpenAPI spec for Customer.io API?

Customer.io does not publish a single canonical OpenAPI specification covering this surface. Jentic generates and maintains this spec so that AI agents and developers can call Customer.io API via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does the Customer.io API use?

The API uses HTTP Basic authentication with a workspace site ID as the username and an API key as the password. Through Jentic both values are held in the encrypted vault and injected into the Authorization header at call time.

### Can I send transactional email with the Customer.io API?

Yes. Call POST /send/email with a transactional_message_id, the recipient email, and any template variables. The endpoint is suitable for receipts, password resets, and one-off notifications.

### What are the rate limits for the Customer.io API?

Rate limits depend on the Customer.io plan and the specific endpoint family; tracking endpoints generally accept higher throughput than App API endpoints. The spec does not encode exact numbers; check your workspace settings for current limits.

### How do I track a customer event through Jentic?

Run pip install jentic, search for 'track customer event', load POST /customers/{customer_id}/events, and execute it with the event name and any properties. Jentic posts the event so it can drive campaign triggers.

### How do I export delivery data from Customer.io?

Call POST /exports/deliveries to start an async export job. The response includes a job ID; poll GET /activities or use the deliveries export status to confirm completion before downloading the resulting archive.

### Can I limit what my agent is allowed to do with the Customer.io API?

Yes. Because you run Jentic One yourself, your own rules decide which Customer.io operations and credentials the agent may use. Since the customer id sits in the URL path, such as /customers/{customer_id}/events, a rule can pin the agent to a single customer so it can update that profile and track its events but nothing else. You choose the operations it may call, so a suppress or a POST /exports/customers request is not available unless you explicitly add it.
