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:createwebhookTarget:delete
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.

