Skip to content
Tinbox

Build · Support desk

Build the support desk your team actually wants.

Assemble it from the parts: a shared support@ inbox, parsers that sort what arrives, an agent that looks up the order and drafts the answer on the thread, and a human who approves every reply — with the questions the agent can't answer waiting in Review.

An incoming message and an editable reply wait with a review marker.

Ask your agent.

“When a customer asks where their order is, look it up in our store, attach the status to the thread, and draft a reply. Ask me if the order cannot be found.”

What you get

The customer’s question, order context, and a reply draft together on the thread.

Connect a shared support inbox and an order-lookup tool for your store. Your team reviews and sends the reply.

See how to wire it up

The problem

Support lives in email. The helpdesk lives somewhere else.

Customers write to support@. To get assignment, macros, and a bot, most teams bolt on a helpdesk — another per-seat bill, another copy of every conversation, and an AI that can't see your orders.

With Tinbox the inbox is the desk. The mail, the customer's history, and the tools to look things up all live in your own account, so an agent can do the reading and drafting while your team keeps the final say.

Honest scope. Tinbox doesn't ship a packaged helpdesk. It ships the parts below; a support desk is what you (or we) assemble from them.

Tinbox lanes used

The parts, and where to read about each.

  1. 01Shared inbox

    support@ as a shared queue: assign, internal notes, @mentions, saved views, and rules that assign and set a response-time target.

    Inbox
  2. 02Parsers

    Classify each message as it lands — refunds, bugs, billing — with flags and queryable fields.

    Extend: Parsers
  3. 03Agent tools

    Give the agent a lookup into your store or billing system, behind a secret and a host allowlist.

    Extend: Views & agent tools
  4. 04A per-inbox agent

    Bound to support@, it wakes on each inbound email and drafts a reply with the tools you allow.

    Automation & agents
  5. 05Handbook

    Plain-language policy every agent honors: what it may offer, when it must ask.

    Extend: Replies
  6. 06Human approval

    Drafts wait on the thread for edit / send; questions the agent can't answer wait in Review. Nothing reaches a customer without a human yes.

    Agents
  7. 07Contacts

    Every customer's threads and sends on one timeline, so the next answer has context.

    Contacts

The sketch

Short enough to read in one sitting.

The sketch: a parser that files refund requests, an order-lookup tool, and a support agent that drafts with human approval required — all in one config file. The runnable starter adds the provisioning step that creates the agent on your inbox.

tinbox.config.tsts
// tinbox.config.ts
import { defineConfig } from "tinbox/cf";
import { defineAgents } from "tinbox/cf/agents";
import { agenticSkill, defaultSkills, type AlgorithmicSkill } from "tinbox/cf/skills";
import { z } from "zod";

// 1. Parser: file refund requests and flag them (annotations only).
const refundParser: AlgorithmicSkill = {
  id: "refund-request",
  label: "Refund requests",
  kind: "algorithmic",
  appliesTo: "message",
  tagline: "Spot refund requests and pull out the order number.",
  match(ctx) {
    const text = `${ctx.message.subject}\n${ctx.message.body}`;
    if (!/refund|money back/i.test(text)) return null;
    const order = text.match(/order\s*#?\s*([A-Z0-9]{5,})/i);
    return { category: "refunds", flags: ["needs-reply"], extra: { orderNumber: order?.[1] } };
  },
};

// 2. A tool the agent can call to read the order from your store.
const orderLookup = agenticSkill({
  id: "order-lookup",
  label: "Order lookup",
  description: "Look up an order by number and return its status.",
  requiresEnv: ["SHOP_TOKEN"],
  requiresHosts: ["api.myshop.com"],
  inputSchema: z.object({ orderId: z.string() }),
  run: async ({ orderId }, ctx) =>
    ctx.fetch(`https://api.myshop.com/orders/${orderId}`, {
      headers: { authorization: `Bearer ${ctx.env.SHOP_TOKEN}` },
    }),
});

export default defineConfig({
  // …org, domains, auth
  skills: [...defaultSkills(), refundParser, orderLookup],

  // 3. Declare the agent bound to support@ (create its row with the starter's
  //    provision.ts — see the runnable example). It drafts; a person sends.
  agents: defineAgents({
    supportBot: {
      inboxId: "inbox_support",
      name: "Support Bot",
      systemPrompt: "Answer from the order status. Be brief and kind.",
      tools: ["search_emails", "get_thread", "order-lookup", "create_draft"],
    },
  }),
});
Your team can still read along in Gmail: add a forwarding rule in Settings → Forwarding and a copy of support@ mail goes to any address.

Or we build it for you

Want the support desk built for you?

We set up support@, write the parsers and the lookup into your store or billing system, configure the agent and its approval rules, and train your team on sending drafts and answering the Review queue.
Talk to us about it →

Build it on mail you own.

Free to install and use, even commercially — the CLI, SDK, and worker ship in one npm package. Deploy Tinbox on your own Cloudflare account and start from the sketch above — or have us build it with you.