GUIDES

Developer guide

Tab's developer surface — the REST API, the Agent SDK, the smart contracts, the bots, and the cron primitives. If you're integrating Tab into a product, this is the map.

The shortest path to a payment

  1. Sign up at /sign-up, claim a handle.
  2. Mint an API key at /dashboard/keys.
  3. POST /v1/orders with amount + recipient. You get back a checkout URL.
  4. Forward the buyer; listen for order.completed via a webhook subscription.

Full walkthrough: quick start.

REST API

Bearer-token auth, per-key rate limiting, JSON in and out, idempotency keys on every write. Endpoints:

Webhooks

Subscribe at /dashboard/webhooks. Every event is HMAC-SHA256 signed with a per-subscription secret + Stripe-style timestamp. Outbound URLs go through an SSRF guard so a registered webhook URL that resolves to a private IP gets rejected before the first byte ships.

Event types: order.created · order.completed · order.cancelled · order.expired · escrow.created · escrow.claimed · escrow.refunded · subscription.plan_created · subscription.started · subscription.charged · subscription.cancelled · subscription.halted · campaign.grant_paid.

Smart contracts

Four routers, all minimal Solidity, all non-upgradeable, fee capped at 5%. See the contracts overview for the surface, the deployment table, and audit scope.

Agent SDK

Build AI agents that take payments. The @tab/agent-sdkpackage exposes typed tool definitions for OpenAI's tool-call API, Anthropic's tool-use API, and an MCP server you can plug into Claude Desktop.

SDK overview walks through wiring a tool-using agent with allowance caps and per-call receipt verification.

Bots

tab-bots ships entrypoints for Telegram (grammy), Discord (discord.js), and Farcaster (Neynar). Each platform parsessend, tip, split, and connect commands and submits via TabBotRouter with on-chain dedup per message id. Unresolvable recipient handles deep-link to an OpenTab create form so the sender can lock funds for someone not on Tab yet.

Bot feature docs: /docs/features/tabbot.

Cron + admin

Five cron endpoints, all guarded by ADMIN_SECRET:

  • POST /api/cron/indexer — tails EVM settlement events, matches them to open orders. Per-chain via JSON body.
  • POST /api/cron/indexer-solana— watches the platform treasury's USDC ATA on Solana and matches incoming transfers to open Solana orders.
  • POST /api/cron/process-webhooks — retries pending deliveries on the 1m → 5m → 15m → 1h → 6h → 24h ladder.
  • POST /api/cron/charge — settles due subscription charges. Safe to re-run; the contract enforces the schedule.
  • POST /api/cron/dispatch-grants — dispatches campaign payouts. Same contract-side dedup.

Multi-chain

Six chains: Base (USDC), BSC (USDT), Solana (USDC), Ink (USDT0), Celo (cUSD), Tempo (αUSD). All four routers ship per chain. See multi-chain and cross-chain routing for the buyer-side "Fund From Anywhere" bridge story.

Source

Contracts and SDK are open-source under MIT. For integration help or partnership work, write to hello@thetab.bar.