How AI automation agencies connect clients' Instagram, Facebook and TikTok to their AI agents
An AI automation agency connects a client's Instagram, Facebook and TikTok with a hosted connect link tagged with the client's id, then lets its agents act through automations or MCP. easyCoexistence's Partner API runs this on one key with no app review: clients sign in without sharing passwords, a call_webhook step hands comments and DMs to the agent, and each account costs US$ 9 to US$ 0.75 a month.
easyCoexistence is social media infrastructure for AI agents: its Partner API connects your customers' WhatsApp, Instagram, Facebook and TikTok accounts to your product, with no app review on your side.
The longest external_ref a connect session takes: the agency's own client id, echoed on events and lists.
How long a hosted connect link stays valid for the client who opens it.
What a Meta app needs to serve Instagram professional accounts it doesn't own or manage, after App Review and Business Verification.
Window for one private reply to an Instagram comment, counted from when the comment was created.
What TikTok requires before a developer may send or read DMs through its Business Messaging API.
easyCoexistence's price per client connection per month, falling as the agency's total grows across seven bands.
How does an agency connect a client's accounts?
With a hosted link per client and network, created from the agency's backend or workflow. POST /connect-sessions with channel set to instagram, facebook or tiktok, the client's id from your CRM as external_ref and your agency's name as partner_name returns a url. Send it by email or chat; it works for an hour. The client signs in with the network's own login, phones included, and lands on your redirect_url with a channel_id. They never share a password and need no easyCoexistence account, email or card. Instagram takes a Business or Creator account signed in with Instagram Login, no Facebook Page needed; Facebook takes Pages the client administers or has task access to, and a client with several Pages ticks the ones to connect; TikTok takes Personal and Business accounts.
curl -X POST https://easycoexistence.com/api/v1/connect-sessions \
-H "Authorization: Bearer $EC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"channel": "instagram",
"redirect_url": "https://agency.example.com/clients/connected",
"external_ref": "client_bloom_cafe",
"partner_name": "Northwind AI"
}'How do the agency's agents answer a client's comments and DMs?
Through automations on the client's channel, created with POST /channels/{id}/automations. On Instagram and Facebook a flow starts on dm_received, comment_received or tag_added, a contact getting a tag, and on TikTok on comment_received, for any message or a keyword. Two steps put an agent behind it. A call_webhook step POSTs the event to your agent's URL, an n8n or Make webhook or your own endpoint, signed with X-EC-Signature and the automation's secret; the body names the channel by channel_id, which you mapped to the client's external_ref, and carries the person, the comment or message and, for DMs, recent history. Answer {"reply": "..."} and easyCoexistence sends it: a DM on Instagram, a Messenger message on Facebook, a public reply on TikTok. An ai_reply step writes the answer instead with the Anthropic, OpenAI or OpenRouter key saved on the agency's account, using a prompt and model set per automation. reply_comment, reply_text and hide_comment cover fixed replies and moderation, POST /automations/{id}/test dry-runs a flow, and each run is logged.
POST https://agent.example.com/hooks/ec
X-EC-Event: automation.step
X-EC-Signature: t=1764680400,v1=5f0c...
{
"event": "automation.step",
"channel": { "type": "instagram", "channel_id": "9a41...", "username": "bloomcafe" },
"contact": { "id": "...", "name": "Maya" },
"message": { "text": "Do you deliver on Sundays?" },
"history": [ ...recent messages... ]
}
HTTP 200, within 20 seconds:
{ "reply": "We do, from 9 am to 2 pm. Want the menu?" }Can the agency's own assistant work across clients through MCP?
Yes, for the agency's team. easyCoexistence's MCP server at https://easycoexistence.com/api/mcp signs in with OAuth to the agency's account, so Claude, ChatGPT, Claude Code, Cursor, Codex or Gemini CLI reach each client channel connected there and can publish, reply to comments, send DMs, set up comment rules and read insights when someone asks. It authenticates with OAuth, not an API key, so it suits a person directing an assistant; an agent that runs unattended for a client works through automations and the REST API. In ChatGPT, publishing and replying need a Business or Enterprise/Edu workspace, on the web. easyCoexistence's MCP docs cover the setup. The two routes side by side:
| Automations | MCP server | |
|---|---|---|
| Acts when | A client's comment or DM arrives | Someone on your team asks the assistant |
| Signs in with | Your ec_live_ key, to create them | OAuth, to the agency's account |
| The model | Yours behind call_webhook, or ai_reply on your key | The assistant's own |
| Built for | Client-facing agents that run around the clock | The team's own work across clients |
How does the agency keep each client's events apart?
By account and by external_ref. PUT /channels/{id}/webhook gives each client account its own destination and signing secret, shown once, so that client's comments, mentions and DMs reach the URL you chose for them, signed with X-EC-Signature. Status events go to the agency's events URL, signed the same way, and carry the client's external_ref: channel.disconnected tells you which client needs a new connect link, and channel.connected tells you they are back. Each account is checked every 6 hours, with an email to the agency when one needs reconnecting. GET /channels?external_ref=client_bloom_cafe lists one client's accounts, and the same filter works on posts and automations. Comments and DMs pass to your endpoint without a copy by default; with automations on, they pass through easyCoexistence so the flow can run, and conversations are kept for the 30, 90 or 365 days you choose.
What does the agency pay for each client?
One connection per client account, billed to the agency, and nothing billed to the client. An Instagram account, a Facebook Page or a TikTok account connected with the agency's key is one connection on the agency's easyCoexistence account, priced by the band the agency's total reaches, across seven bands: US$ 9 a month each for up to five connections, down to US$ 0.75 each from 2,001. Every feature is included on every network, so a client's TikTok costs the same as their Instagram. AI replies run on the agency's own provider key, with no fee per reply from easyCoexistence, and DELETE /channels/{id} stops a departed client's billing at the end of the cycle. The agency sets its own retainer on top.
How to set it up
- Create the agency's keyIn the easyCoexistence dashboard, open Developers and create an ec_live_ key for your backend or your n8n or Make credentials.
- Send each client a connect linkPOST /connect-sessions per network with the client's id as external_ref and your agency's name as partner_name, then send the url.
- Map the channel to the clientWhen the client lands on your redirect_url, confirm the session from your backend and store its channel_id under the client.
- Put the agent behind an automationPOST /channels/{id}/automations with a trigger and a call_webhook step pointing at the agent, or an ai_reply step, then dry-run it with POST /automations/{id}/test.
- Route events per clientSet PUT /channels/{id}/webhook for each account and an events URL for channel.* status events, and verify X-EC-Signature on each delivery.
Common mistakes
- Letting the agent think past 20 seconds. The call_webhook step waits 20 seconds for the reply, then fails, so answer fast and keep slow lookups out of the reply path.
- Identifying the client by the payload's username. A handle can change while the channel_id stays, so map channel_id to your external_ref when the client connects.
- Expecting one ai_reply key per client. Keys are saved per account and provider, so each client's ai_reply uses the agency's key; put a client's own model behind call_webhook instead.
- Promising clients TikTok DMs. TikTok's Business Messaging API needs its own reviews, so on TikTok the agent answers in public comment replies, up to 150 characters from an automation.
easyCoexistence gives AI automation agencies the infrastructure under their agents: one hosted link per client for Instagram, Facebook and TikTok, automations that hand comments and DMs to the agency's agent, an MCP server for the team and signed events per client, with no Meta app review or TikTok audit on the agency's side. US$ 9 to US$ 0.75 per connection per month, falling as you add connections, with the first 3 days free.
easyCoexistence is a multichannel API and MCP server that connects AI agents such as Claude and ChatGPT to WhatsApp, Instagram, TikTok, Facebook, Google Business Profile and more. On WhatsApp it uses Coexistence: the business keeps using its number in the WhatsApp Business app while the AI works through Meta's official API.
Frequently asked questions
Do clients need an easyCoexistence account?
No. A client opens the link, signs in with the network's own login and is done; the account joins the agency's easyCoexistence account, where it is billed and monitored.
Can an agency build the agent in n8n or Make?
Yes. Point a call_webhook step at an n8n or Make webhook that answers with {"reply": "..."}, and verify X-EC-Signature with the automation's signing secret.
Does the agency need its own Meta app or TikTok app?
No. easyCoexistence is a Meta Tech Provider with its own reviewed Meta app and has its own app on TikTok's API for Business, so clients sign in through those.
Can a client see the agency's name when connecting?
Yes. The hosted page shows the name sent as partner_name, while the network's own consent screen names easyCoexistence as the app asking for access.
Keep reading
Connect your first channel in two minutes.
No platform reviews to wait for. Connect WhatsApp, Instagram, TikTok or another channel, then ask your AI to post, reply or report, and watch it work.
- 3 days free
- Cancel any time
- Official APIs only
- Monitored 24/7
Verified on