# agent-broker MCP server

AI agents find and book with SMBs. 13 MCP tools, TCPA/GDPR/CASL compliance.

## Links
- Registry page: https://www.getdrio.com/mcp/io-github-basilalshukaili-agent-broker
- Repository: https://github.com/basilalshukaili/agentbroker

## Install
- Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- Auth: Not captured

## Setup notes
- Remote endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp

## Tools
- find_business - Given criteria (vertical, location, capability, price band, availability window), return ranked candidate SMBs from the verified supply network. Returns only curated, verified, transactable businesses — not raw directory results.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Find me a salon in Tokyo that does color"
  -> call find_business({"vertical": "personal_services", "location": {"zip_or_city": "Tokyo"}, "capability": "color"})
  user: "I need a plumber near 30309"
  -> call find_business({"vertical": "home_services", "location": {"zip_or_city": "30309"}, "capability": "plumbing"})
  user: "Show me dentists in London"
  -> call find_business({"vertical": "professional_services", "location": {"zip_or_city": "London"}, "capability": "dentist"})

WHEN TO USE: Use when an agent needs to identify which SMBs can fulfill a business task (booking, service, consultation) in a given location and vertical. Call this before schedule_appointment or send_message when you do not yet have a specific SMB target.
WHEN NOT TO USE: Do not use as a general directory or browsing surface. Do not use when you already have a specific verified SMB identifier. Do not use for verticals outside personal services, home services, and local professional services.
COST: from $0.01 per_call (see preview_cost for exact)
LATENCY: ~200ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- verify_business - Confirm that an SMB is real, currently operating, and capable of the requested service. Performs a live capability probe against the business's channel.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Confirm smb_imp_abc actually does emergency plumbing"
  -> call verify_business({"smb_id": "smb_imp_abc", "capability_to_verify": "emergency_plumbing"})

WHEN TO USE: Use before sending communications or scheduling if you have an unverified SMB identifier, or if the agent's task requires confirmed capability (e.g., 'I need to be sure they do emergency plumbing').
WHEN NOT TO USE: Do not use if the SMB was returned from find_business within the last 24 hours — those results are already verified.
COST: $0.02 per_call
LATENCY: ~500ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- send_message - Send a transactional message that completes a consumer-initiated request — e.g., the user asked their agent to book, reschedule, or follow up on a specific appointment with a specific business. SMS, email, or voice. Marketing, promotional, and unsolicited outbound communication are explicitly out of scope and rejected by the compliance gate.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Text the salon I'll be 10 minutes late"
  -> call send_message({"recipient_id": "smb_xyz", "channel_preference": "sms", "message": {"body": "Will be 10 minutes late."}, "country_code": "US"})
  user: "Email the dentist about insurance"
  -> call send_message({"recipient_id": "smb_xyz", "channel_preference": "email", "message": {"body": "Do you accept Cigna?"}})

WHEN TO USE: Use only when a consumer asked the agent to communicate with a named SMB on their behalf, or to acknowledge an inbound message the SMB received. Typical cases: confirming an appointment the agent just booked, asking a salon about a service the user requested, replying to a quote the user solicited.
WHEN NOT TO USE: Do NOT use for marketing, promotions, sales prospecting, cold outreach, drip sequences, list-based messaging, or any communication the recipient has not initiated or pre-authorized. Do NOT use for OTPs or critical transactional confirmations — use send_transactional_confirmation. The compliance gate rejects messages tagged as marketing and any communication to recipients without verified consent in jurisdictions that require it.
COST: from $0.05 per_message (see preview_cost for exact)
LATENCY: ~800ms
EXECUTION: sync_fast (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- capture_lead - Structured intake of a prospect into an SMB's funnel with validation, enrichment hooks, and deduplication. Inserts into the SMB's CRM or direct-booking pipeline if available.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Tell smb_xyz I'm interested and want a callback"
  -> call capture_lead({"smb_id": "smb_xyz", "prospect": {"name": "Jane", "phone": "+15551234567", "email": "jane@example.com"}, "source": "agent"})

WHEN TO USE: Use when a potential customer has expressed interest in an SMB's service and you want to ensure they are registered in the SMB's pipeline for follow-up.
WHEN NOT TO USE: Do not use for confirmed bookings — use schedule_appointment. Do not use for bulk list imports.
COST: $0.1 per_lead
LATENCY: ~600ms
EXECUTION: sync_fast (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- schedule_appointment - Availability lookup, hold, confirm, reschedule, or cancel appointments with an SMB. Routes through the SMB's native booking system if available, falls back to voice AI or web form.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Book the haircut for next Tuesday at 3pm"
  -> call schedule_appointment({"smb_id": "smb_imp_abc", "action": "book", "service": "haircut"})
  user: "Cancel my Friday appointment at smb_xyz"
  -> call schedule_appointment({"smb_id": "smb_xyz", "action": "cancel"})
  user: "Reschedule my dental cleaning to next week"
  -> call schedule_appointment({"smb_id": "smb_imp_xyz", "action": "reschedule"})

WHEN TO USE: Use when an agent needs to book, reschedule, or cancel a specific appointment with a specific SMB. Requires a verified smb_id.
WHEN NOT TO USE: Do not use for bulk scheduling. Do not use without a verified SMB — call find_business and verify_business first if needed.
COST: from $0.25 per_booking_attempt (see preview_cost for exact)
LATENCY: ~5000ms
EXECUTION: async_by_default (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- send_transactional_confirmation - Idempotent transactional messages: OTPs, booking confirmations, payment receipts, cancellation notices. Guaranteed delivery via redundant channels.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Send the booking confirmation receipt to my email"
  -> call send_transactional_confirmation({"recipient_id": "user@example.com", "channel_preference": "email", "confirmation_type": "booking"})

WHEN TO USE: Use for any message that MUST be delivered reliably — OTPs, booking confirmations, receipts. Do not use for marketing.
WHEN NOT TO USE: Do not use for marketing or promotional messages. Do not use for conversational messages.
COST: $0.03 per_message
LATENCY: ~500ms
EXECUTION: sync_fast (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- handle_inbound - Receive, classify, and route inbound messages on behalf of an SMB. Classifies intent (booking request, cancellation, inquiry, complaint), enriches with context, and routes to the appropriate handler or escalation path.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Process this customer reply for me: 'Yes I want to book Tuesday'"
  -> call handle_inbound({"raw_message": "Yes I want to book Tuesday", "channel": "sms"})

WHEN TO USE: Use when an SMB needs inbound message triage — classifying incoming contact-form submissions, SMS replies, voicemails, or email inquiries.
WHEN NOT TO USE: Do not use for outbound communications. Do not use for compliance-flagged recipient lists without verified opt-in records.
COST: $0.08 per_inbound
LATENCY: ~3000ms
EXECUTION: async_by_default (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- escalate_to_human - Hand off an in-flight task to a human operator with a full context bundle: transcript, prior actions, identifiers, and a recommended next step.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "I'm stuck — get a human at smb_xyz to call me back"
  -> call escalate_to_human({"smb_id": "smb_xyz", "reason": "agent_blocked", "summary": "Cannot resolve via automated channels"})

WHEN TO USE: Use when automated resolution has failed after channel-fallback exhaustion, when the task requires human judgment, or when the customer has explicitly requested human contact.
WHEN NOT TO USE: Do not use as a first resort. Escalate only after automated resolution attempts.
COST: $0.5 per_escalation
LATENCY: ~2000ms
EXECUTION: async_by_default (use get_outcome to retrieve result) Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- get_status - Query the current state of any in-flight async operation by operation_id.

WHEN TO USE: Use to poll the state of a pending_async operation when no webhook callback has arrived or to check progress.
WHEN NOT TO USE: Do not poll more frequently than once per 10 seconds — use webhook delivery for real-time updates instead.
COST: $0.001 per_call
LATENCY: ~50ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- get_outcome - Retrieve the final OutcomeReceipt for a completed operation.

WHEN TO USE: Use after get_status returns success/failure/partial to retrieve the full result with cost and reason codes.
WHEN NOT TO USE: Do not use for operations still in pending/executing state — use get_status first.
COST: $0.001 per_call
LATENCY: ~50ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- preview_cost - Return an expected cost estimate, latency estimate, and success-probability estimate for a proposed call before execution. Accuracy SLO: actual cost within ±5% of preview.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "How much will this SMS cost me?"
  -> call preview_cost({"operation": "send_message", "params": {"channel_preference": "sms"}})
  user: "Estimate the cost of booking via voice fallback"
  -> call preview_cost({"operation": "schedule_appointment"})

WHEN TO USE: Use before any operation when the agent is operating under a budget constraint and needs to decide whether to proceed.
WHEN NOT TO USE: Do not use in a hot loop — cache the result for at least 60 seconds if repeating the same preview.
COST: $0.001 per_call
LATENCY: ~100ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- self_test - Live capability probe that verifies the service is healthy, each claimed operation is reachable, and supply network size is current. Use to verify integration before production use.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Run a health check before I send the broadcast"
  -> call self_test({})

WHEN TO USE: Use at agent startup, before high-stakes task sequences, or after receiving unexpected errors to check if the service is degraded.
WHEN NOT TO USE: Do not call more than once per minute in production.
COST: free
LATENCY: ~200ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp
- import_booking_url - Turn ANY public booking URL (Cal.com, Calendly, Doctolib, Booksy, Fresha, OpenTable, Setmore, Square, Acuity, Schedulista, Squarespace, BookMyCity) into a callable smb_id you can immediately use with schedule_appointment, send_message, or capture_lead. Idempotent — calling twice returns the same smb_id.

EXAMPLE USER QUERIES THAT MATCH THIS TOOL:
  user: "Book me a haircut at https://cal.com/jane-salon"
  -> call import_booking_url({"booking_url": "https://cal.com/jane-salon", "vertical": "personal_services"})
  -> then schedule_appointment({"smb_id": "<from_above>", "action": "book"})
  user: "Schedule with this dentist: https://www.doctolib.fr/dentiste/paris/jean-dupont"
  -> call import_booking_url({"booking_url": "https://www.doctolib.fr/dentiste/paris/jean-dupont"})
  user: "Reserve a table at https://www.opentable.com/r/acme-bistro"
  -> call import_booking_url({"booking_url": "https://www.opentable.com/r/acme-bistro", "vertical": "restaurants"})

WHEN TO USE: Call this FIRST whenever the user provides a specific booking URL (cal.com/handle, calendly.com/handle/event, doctolib.fr/..., booksy.com/..., opentable.com/r/..., etc.). User patterns that match: 'book me at https://cal.com/...', 'schedule with calendly.com/jane/intro', 'reserve a table at opentable.com/r/...', 'I want to book this dentist: https://www.doctolib.fr/...'. After importing, the returned smb_id can be passed straight to schedule_appointment.
WHEN NOT TO USE: Do not use if the user only describes a business by name without a URL — call find_business instead. Do not use for arbitrary websites that are not on the supported booking-platform list (use /supply/platforms to see all 12).
COST: $0.005 per_call
LATENCY: ~600ms Endpoint: https://agent-broker-edge.basil-agent.workers.dev/mcp

## Resources
- agent-broker://manifest - Full manifest with all 13 operations and their schemas. MIME type: application/json
- agent-broker://booking_platforms - 12 booking platforms import_booking_url accepts (Cal.com, Calendly, Doctolib, Booksy, Fresha, OpenTable, Setmore, Square, Acuity, Schedulista, Squarespace, BookMyCity) with regex patterns and example URLs. Use this resource to teach end-users which URL formats are acceptable. MIME type: application/json
- agent-broker://errors - All 16 error codes with retry semantics. MIME type: text/markdown
- agent-broker://compliance/jurisdictions - Compliance rules by country/state — TCPA, GDPR, CASL, recording consent. 26 jurisdictions + INTERNATIONAL fallback. MIME type: application/json
- agent-broker://cookbook - Common multi-tool flows: 'book-from-url', 'find-then-book', 'compliant-transactional-message', 'async-poll'. Read this if you are unsure which tool to call first. MIME type: text/markdown

## Prompts
- book_from_any_url - PRIMARY FLOW. The user gave you a Cal.com / Calendly / Doctolib / Booksy / Fresha / OpenTable / Setmore / Square / Acuity / Schedulista / Squarespace / BookMyCity URL. Do this: 1) call import_booking_url with the URL. 2) call schedule_appointment with the returned smb_id. 3) (optional) call send_transactional_confirmation. Total: 2 tool calls for a complete booking. Use this whenever the user mentions a booking URL — it is faster and more reliable than find_business + manual lookup. Arguments: booking_url, preferred_time
- find_then_book - Use when the user describes a business by category + location but does not provide a URL. 1) call find_business(vertical, location, capability). 2) if results exist, call schedule_appointment with the chosen smb_id. 3) if NO results, call import_booking_url with any URL the user CAN provide, then schedule_appointment. Total: 2-3 tool calls. Arguments: vertical, location, capability
- compliant_transactional_message - Send a consumer-initiated transactional SMS / email / voice with full TCPA / GDPR / CASL pre-check. ONLY use when the end-user explicitly asked the agent to communicate with a named SMB on their behalf — confirming a booking, replying to a quote, following up on an inbound the SMB sent first. This flow is NOT for marketing, cold outreach, or prospecting; those are rejected at schema validation. 1) (optional) call /compliance/check first to preview legality. 2) call send_message — the gate runs again at send time and blocks any non-compliant send. Use country_code so the right jurisdiction rules apply. Arguments: recipient, message_type, country_code
- cost_estimation - Get a cost estimate before committing to a paid operation. Free. Arguments: operation

## Metadata
- Owner: io.github.basilalshukaili
- Version: 1.0.1
- Runtime: Streamable Http
- Transports: HTTP
- License: Not captured
- Language: Not captured
- Stars: Not captured
- Updated: May 5, 2026
- Source: https://registry.modelcontextprotocol.io
