Skip to main content
Modem captures your Plain threads as they happen: customer emails and chats, your team’s replies, and internal notes. It groups them into topics and links each message to the person and company behind it. Your team then asks the Modem Agent about them in Modem, Slack, or Discord. Modem connects as an internal connected agent. It reads your threads with an API key and adds its own webhook to hear about new activity. It can’t message your customers unless you give its key permission to.

Before you start

You need the Owner or admin role in your Modem organization to connect Plain from Modem’s settings.
Modem’s webhook subscribes to email, chat, and note events. It doesn’t subscribe to Slack, Microsoft Teams, or Discord message events.

Steps

1

Create the connected agent

In Plain, go to Agents → Connected agents → Add agent. Or your AI agent can do this step for you through Plain’s MCP server, following Connected agent set up. Name the agent Modem and pick the Internal Agent template.
2

Create its API key

Plain opens the API key step with the Internal template’s permissions already selected. They cover what Modem reads: threads and their messages, customers, labels, teammates, and machine users. Add these two, so Modem can add its webhook when you connect and remove it when you disconnect:
  • webhookTarget:create
  • webhookTarget:delete
Create the key and copy it. On the webhook step, click Skip for now. Modem adds its own webhook in the next step, so a webhook you add here would duplicate it.
3

Connect Plain in Modem

In Modem, go to Settings → Integrations → Plain, paste the API key, and click Connect Plain.Modem shows Connected to and your workspace’s name. Under API key permissions, it shows Every required permission is granted. If it lists a missing permission instead, add it to the key in Plain and click Check again.Modem adds its webhook under Settings → Webhooks in Plain. The webhook isn’t linked to the Modem agent, so it doesn’t show on the agent’s Webhooks tab.
4

Check new messages reach Modem

Send an email to your workspace’s support address from your own email address. Modem captures the new thread within a few minutes.If nothing arrives, click Disconnect on Modem’s Plain page, then connect again. Modem adds a fresh webhook when it reconnects.

Let Modem act on threads

When your team asks it to, the Modem Agent can act on Plain threads. With the Internal template’s permissions, it can already add internal notes and add or remove labels. To let it do more, edit Modem’s API key in Plain, add the permissions below, then click Check again in Modem: Modem asks you to approve each action before it runs, unless you set that action to always run.

Disconnect Modem

In Modem, go to Settings → Integrations → Plain, click Disconnect, and confirm. Modem deletes its webhook in Plain while its API key still works. Disconnect in Modem before you delete the Modem agent in Plain. Deleting the agent removes its API key, so Modem can’t delete its webhook. You then delete the webhook yourself under Settings → Webhooks.