Use case

Your agent's code, connected to your customers

Run the agent on your own server, in any language. Flutch sends each customer message to your webhook and delivers your reply to Instagram, Telegram, web chat or the API.

Who builds it

Your agent already exists: a LangGraph graph, a service in another language or an n8n scenario. It works in a test chat, and now it has to answer real customers in Instagram, Telegram and a website chat, with someone from the team able to step in.

The agent stays on your server. Flutch sends it each customer message as one signed POST and delivers the reply to the customer's channel. The conversations, the contact cards and the handoff live on Flutch.

Instagram DM answered by your codeExample
  1. Can I change the delivery address on my order?
  2. POST to your webhook: threadId, the message and the platform
  3. Yes, until it ships. Send me the new address and I'll update order 1182.
  4. Actually, I'd rather talk to someone.
  5. Your reply carried "escalate": true · handed off to the team
Your server gets each message and answers with JSON. A reply with "escalate": true moves the conversation to your team's inbox with the reason.

How you build it on Flutch

  1. Point Flutch at your endpoint

    Choose Your own code in the console and enter your endpoint's HTTPS URL.

  2. Check the signature

    Copy the signing secret and check the signature of each request on your server.

  3. Test from the console

    Send a test message from the console, then write to the agent in the Playground.

  4. Connect channels

    Connect channels. Flutch keeps the conversations and contact cards and hands the conversation to your team when your reply asks for a person.

The contract

One POST per customer message, your JSON reply back. Flutch sends only the current message, so keep the history by threadId.

Flutch sends
POST https://your-app.example.com/flutch
X-Flutch-Timestamp: 1764500000
X-Flutch-Signature: v1=5f2c…

{
  "type": "message",
  "requestId": "78f71562-d69e-4dce-9c2f-bf556b389734",
  "agentId": "6b0aff3b965d9efd2a6cca28",
  "threadId": "6b0b0093965d9efd2a6ccc25",
  "platform": "instagram-dm",
  "user": { "id": "6b0aff3c965d9efd2a6cca3c", "name": "Anna" },
  "message": { "id": "6b0b0093965d9efd2a6ccc31", "text": "Do you deliver on Saturdays?", "trigger": null }
}
You answer
{
  "text": "I'll pass this to a colleague, they will reply here shortly.",
  "escalate": true,
  "reason": "Asks for a refund on order 1042"
}
  • Signature: X-Flutch-Signature is v1= and the HMAC-SHA256 of the timestamp, a dot and the raw body, with the agent's signing secret; refuse requests more than 5 minutes old.
  • Limits: 60 seconds for the whole reply, a 1 MB body, up to 10 attachments; no retries and no redirects.
  • Handoff: "escalate": true, or a failed reply, moves the conversation to your team's inbox with the reason.
  • Price: $0.002 per message, the 1-second processing minimum; the time Flutch waits for your server is not counted. Processing is free during launch.

What it costs to run

Your code calls its own models, so Flutch counts processing only: $0.002 per message at the 1-second minimum, and the time Flutch waits for your server is not counted. 5,000 messages a month come to $10.00 of processing, free during launch.

  • Storage is free during launch too. We will post the date charging starts on the pricing page four weeks ahead.
  • Channels, the inbox, contact cards, traces and Quality Control are included, and a new workspace starts with $5 of credit.

Where to start

The console will suggest starting with an agent on your own code.