Skip to main content
The Plain integration captures support threads from your Plain workspace in real time. Customer emails, chat messages, and your team’s internal notes flow into Modem, where they are grouped into topics, classified by type, and linked to the people and companies behind them.
Plain is currently in beta and access is rolled out per organization. If you don’t see it under SettingsIntegrations, email support@modem.dev to request access.
Plain is capture-only and read-only. Modem ingests thread messages, thread metadata, and customer profiles; it never writes anything back to Plain, and the Modem Agent has no tools for taking action inside Plain. You query captured Plain conversations from the Modem Agent on the web, where the agent can still act on what it finds in your other connected tools.

How it works

Modem connects to Plain with a machine-user API key you create in your Plain workspace. When you paste the key, Modem validates it, fetches your workspace’s Request signing secret, and registers a webhook target in Plain automatically. From then on Plain pushes thread activity to Modem as it happens; every delivery is verified against the signing secret before it’s processed. API keys in Plain don’t expire, so there’s no re-authorization cycle. Capture is webhook-based and real-time: a new customer message typically shows up in Modem within a few minutes.

Prerequisites

  • Owner or admin role in your Modem organization, to connect and manage the integration
  • Access to create machine users and API keys in your Plain workspace
  • Beta access enabled for your Modem organization (see the note above)

Setup

1

Create a machine-user API key in Plain

In Plain, go to SettingsMachine users / API keys and create a key. See Permissions below for what it needs.
2

Paste the key into Modem

Go to SettingsIntegrationsPlain in your Modem dashboard, paste the key, and click Connect Plain. Modem encrypts the key before storing it.
3

Modem registers its webhook

Modem validates the key, reads your workspace’s Request signing secret, and registers a webhook target in Plain. New thread activity starts flowing immediately.
4

Optionally run a backfill

Import recent existing threads so ongoing conversations show up too. See Historical Backfill below.

Permissions

The machine-user API key needs:
If your key can’t be granted workspaceHmac:read, use the enter it manually option on the connect form and paste the secret from Plain under SettingsRequest signing instead.

What Gets Captured

Thread messages

For each Plain thread, Modem captures the timeline as a single conversation:
  • Customer emails received and support replies sent
  • Chat messages from both sides
  • Internal notes written by your team, marked as internal
Email bodies are cleaned before they’re stored: quoted-reply chains and signature blocks are stripped, and inline attachment data is collapsed to a short placeholder. Attachment files themselves are not ingested.

Thread metadata

Each thread’s title, status, priority, labels, assignee, and a link back to the thread in Plain. Status, priority, and label changes are recorded on the conversation timeline for context, but these housekeeping entries don’t feed topic analysis; only real messages do.

Customers

Plain customer profiles (name and email) sync as they’re created and updated, and message authors are resolved to Modem people by email address. Your own teammates are matched to their real email addresses too, so support replies link to existing team members instead of creating duplicates. Plain’s automation and system actors are flagged as bots.

Historical Backfill

Connecting only captures activity from that point forward. To pull in recent history, run the optional backfill from SettingsIntegrationsPlain: it imports threads created in the last 30 days, up to 500 threads, along with their messages. The backfill runs in the background and doesn’t block real-time capture. Plain’s API is rate-limited, so a busy workspace can take a while; the card shows progress and you can re-run it if it fails.

Analyzing Plain Conversations

Once threads are flowing, ask the Modem Agent about them from the web dashboard like any other source.

Troubleshooting

The integration is in beta and enabled per organization. Email support@modem.dev to request access. Once enabled, the Plain card appears under SettingsIntegrations.
The most common gap is workspaceHmac:read: without it Modem can’t fetch the Request signing secret automatically. Grant the permission to the machine user, or use the manual fallback on the connect form and paste the secret from Plain under SettingsRequest signing. Also confirm the key has read access to threads and customers plus webhookTarget:create.
Confirm the integration shows as connected in SettingsIntegrationsPlain, then allow a few minutes for webhook delivery and processing. Modem only captures activity that happens after you connect; run the backfill for recent existing threads. If nothing arrives, disconnecting and reconnecting registers a fresh webhook target.
The backfill covers threads created in the last 30 days, up to 500 threads, so older or excess threads aren’t imported. If a run failed, the card shows the error and a Run again button; re-running is safe and won’t duplicate messages. If it still looks wrong, contact support@modem.dev.
Message authors are matched to Modem people by email address. If a Plain customer has no email on their profile, their activity won’t be linked automatically.

Disconnecting

To disconnect Plain:
  1. Go to SettingsIntegrationsPlain
  2. Click Disconnect and confirm
Modem stops accepting deliveries from the workspace and attempts to remove the webhook target it registered in Plain. Removal is best-effort: if the stored API key has already been revoked or Plain’s API is unavailable, the disconnect still completes and you may need to delete the target in Plain yourself. Historical data remains in Modem after disconnecting.

The Modem Agent

Query and act on your captured Plain conversations from the web.

Topics

See how support threads are grouped into themes and classified.

Companies & People

Understand how Plain customers are linked into unified profiles.

All Integrations

Browse every data source and agent tool.