Quickstart Tools Connect docs
ESPRESSO CASH MCP

One URL for your agent.
It books and buys, paid in USDC.

Your AI agent books flights and hotels and buys from Shopify stores for its user, paid in USDC on Solana. The money waits in an on-chain escrow and is released only when the supplier confirms; anything else is refunded automatically.

MCP serverhttps://buy.espressocash.com
โœˆ๏ธ FlightsLive airline inventory worldwide. The PNR comes back as soon as the ticket is issued.
๐Ÿจ HotelsSearch, compare rooms and rates, book, cancel within the hotel's terms.
๐Ÿ›๏ธ ShopAny Shopify store, delivered to the buyer's address. Up to 10 items per store checkout.
๐Ÿ†“ Free up to the purchaseSearching, quoting and reading cost nothing. Only the purchase is paid, into its own escrow.
๐Ÿ” No account, no keyThe buyer's Solana wallet is the identity: it funds the escrow and receives any refund.
Building a site or a game that charges its users? That's Espresso Connect: docs.espressocash.com. This MCP is for agents buying on a user's behalf.

Connect

Streamable HTTP with plain JSON answers (no SSE stream, no session). Any MCP client that takes a URL works.

ClientHow
Claude (claude.ai, desktop)Settings โ†’ Connectors โ†’ Add custom connector โ†’ paste the URL.
Claude Codeclaude mcp add --transport http espresso https://buy.espressocash.com
Codex CLIIn ~/.codex/config.toml: [mcp_servers.espresso] with url = "https://buy.espressocash.com"
Cursor, Windsurf, others{"mcpServers": {"espresso": {"url": "https://buy.espressocash.com"}}} in their mcp.json
ChatGPTTurn on developer mode in the connector settings, then add a connector with the URL.

Check it answers:

curl -s https://buy.espressocash.com \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

What your agent needs

Quickstart: book a flight

Every purchase follows the same five steps. Pass every id (offer_id, intent_id) back exactly as you received it.

  1. search
  2. quote
  3. intent
  4. pay
  5. order
// 1. search (free). If status is "enriching", poll brij_get_flight_search_updates
brij_search_flights {"origin_iata": "LIS", "destination_iata": "JFK",
                     "depart_date": "2027-01-15", "adults": 1}
// โ†’ offers[]: offer_id, total_amount (all-in, USD), slices, airline

// 2. lock one offer: creates its escrow
brij_create_flight_intent {"offer_id": "<offer_id>", "funding_wallet": "<buyer wallet>"}
// โ†’ intent_id, expected_escrow_amount, customer_support_code (keep it!)

// 3. pay: the first call answers with the x402 payment requirements
brij_book_flight {"intent_id": "<intent_id>", "passengers": [{
  "given_name": "Ana", "family_name": "Silva", "born_on": "1990-04-02",
  "title": "ms", "gender": "f", "email": "[email protected]",
  "phone_number": "+351912345678"}]}
// โ†’ error with structuredContent = payment requirements. Sign them with the
//   funding wallet, then call again with _meta["x402/payment"] (or x402_payment).

// 4. follow it (free)
brij_get_intent {"intent_id": "<intent_id>"}
// โ†’ status โ€ฆ booked; booking_reference = the PNR. Relay it to the traveller.

Flows

Flights

brij_search_flights โ†’ (brij_get_flight_search_updates while status is enriching) โ†’ (brij_get_flight_offer_details) โ†’ brij_create_flight_intent โ†’ brij_book_flight โ†’ brij_get_intent

Hotels

(brij_find_hotel_places) โ†’ brij_search_hotels โ†’ brij_get_hotel_rates โ†’ brij_quote_hotel โ†’ brij_create_hotel_intent โ†’ brij_book_hotel โ†’ brij_get_hotel_order

brij_search_hotels {"location": "Lisbon", "check_in_date": "2027-01-15",
                    "check_out_date": "2027-01-18", "adults": 2}
brij_get_hotel_rates {"hotel_id": "<hotel_id>"}
brij_quote_hotel {"rate_id": "<rate_id>"}          // โ†’ offer_id "hotel:โ€ฆ"
brij_create_hotel_intent {"offer_id": "hotel:โ€ฆ", "funding_wallet": "<buyer wallet>"}
brij_book_hotel {"intent_id": "โ€ฆ", "guests": [{"given_name": "Ana", "family_name": "Silva"}],
                 "email": "[email protected]", "phone_number": "+351912345678"}

Shop (Shopify stores)

brij_shop_search โ†’ (brij_shop_product, brij_shop_store, brij_shop_stores) โ†’ brij_shop_quote โ†’ brij_create_shop_intent โ†’ brij_shop_buy โ†’ brij_get_shop_order

brij_shop_search {"query": "trail running shoes", "ships_to": "PT"}
brij_shop_quote {"variant_id": "<variant id>", "quantity": 1, "ship_to": {
  "first_name": "Ana", "last_name": "Silva", "street_address": "Rua Augusta 10",
  "city": "Lisboa", "postal_code": "1100-053", "country": "PT",
  "phone": "+351912345678"}}                   // โ†’ offer_id "shopcom:โ€ฆ", total
brij_create_shop_intent {"offer_id": "shopcom:โ€ฆ", "funding_wallet": "<buyer wallet>"}
brij_shop_buy {"intent_id": "โ€ฆ", "email": "[email protected]"}

Payment and refunds

  1. Intent. brij_create_*_intent takes the buyer's funding_wallet (and optionally a refund_wallet) and returns the escrow address, the amount and a customer_support_code. Keep the code: it is never shown again, and orders and refunds need it.
  2. Pay. The book/buy tool answers with x402 payment requirements for that escrow (as the tool error's structuredContent). Sign them with the funding wallet and call the same tool again with the payment in _meta["x402/payment"], or in the x402_payment argument (the base64 PAYMENT-SIGNATURE value) if your client cannot set _meta. The settlement comes back in _meta["x402/payment-response"].
  3. Outcome. Confirmed โ†’ captured. Anything else โ†’ refunded in full to the refund wallet, which was fixed when the intent was created and cannot be changed.

Quote the buyer the escrow amount: it is all-in (fare or stay or items + the service fee). Flights: 10 USDC + 2 %, at most 15 % of the fare. Hotels: 5 USDC + 2 %, at most 30. Shop: 2 USDC + 3 %.

A promo code the user gives you goes in promo_code on the intent. It is checked before anything is paid and waives the service fee when it applies.

Manual refund requests (brij_request_flight_refund) need the support code and the lead passenger's family name. They are reviewed by a person; the money can only go back to the refund wallet.

Limits and errors

Instead of a fee per call, calls are rate-limited per client and globally, by cost:

Kind of callPer client
Reads, polls, order status120 at once, 1 back a second
Flight search and offer details10, 1 back every 3 min
Hotel search, rates, quote40, 1 back every 10 s
Shop search, product, quote20, 1 back every 30 s
Creating an intent2, 1 back every 30 min
Refund requests3 an hour

The same call repeated within 15 minutes is free, so a pending search or quote can be polled. Paying (book/buy) is never rate-limited.

A refused call is a tool error with isError and a code: mcp_rate_limited or mcp_capacity_exhausted (429, with retry_after_seconds), intent_already_exists (409, with the existing intent_id), offer_not_found, promo_invalidโ€ฆ Nothing is ever charged for a refused call.

All tools

Generated from the server's own tools/list, so this list is always the live one. Each tool's full input schema is in tools/list.

Flights

brij_search_flightsSearch flights
brij_get_flight_search_updatesPoll a flight search
brij_get_flight_offer_detailsFlight offer details
brij_create_flight_intentLock a flight offer
brij_book_flightPay and book a flight (pays)
brij_get_intentRead an intent
brij_get_flight_orderFlight order status
brij_request_flight_refundRequest a flight refund
brij_list_airlinesSupported airlines

Hotels

brij_find_hotel_placesFind a city for a hotel search
brij_search_hotelsSearch hotels
brij_get_hotel_ratesHotel rooms and rates
brij_quote_hotelQuote a hotel rate
brij_create_hotel_intentLock a hotel quote
brij_book_hotelPay and book a hotel (pays)
brij_get_hotel_orderHotel booking status
brij_cancel_hotelCancel a hotel booking

Shop (Shopify stores)

brij_shop_searchSearch Shop's catalog
brij_shop_productRead one Shop product
brij_shop_storeA Shopify store's page
brij_shop_storesStores that deliver to a country
brij_shop_quoteQuote a Shop purchase
brij_create_shop_intentLock a Shop quote
brij_shop_buyPay for a Shop order (pays)
brij_get_shop_orderShop order status

FAQ

When is the buyer charged?

The USDC leaves the wallet into the purchase's own escrow when the agent pays. It leaves the escrow only when the supplier confirms (ticket issued, hotel booked, store order placed). Every other outcome refunds it in full, to the refund wallet.

What if the price changes after the quote?

The purchase is never made above what was paid into the escrow: it fails cleanly and refunds. Search or quote again.

Can it book for several people?

Flights: search with adults and send that many passengers, lead first. Hotels: rooms, adults and child ages on the search, at least one guest per room on the booking.

The agent lost the customer_support_code.

It cannot be read again. Keep it when the intent is created: order status and refund requests need it.

Is it the same as the HTTP API?

Yes: every tool is one route of the API, with the same checks. Over HTTP each call costs a small x402 fee; over MCP only the purchase is paid.

Partners and affiliates

Partner key. An app relaying many users' agents from one server can get a key, sent as Authorization: Bearer brij_mcp_โ€ฆ. It gives each of its agents 5ร— the rate limits (keyed by an X-BRIJ-Agent header) and its own global pool. Ask us for one.

Affiliates. Pass referrer (your code) on a flight intent and earn 20 % of the service fee on bookings that are flown without refund. Get a code with POST https://buy.espressocash.com/affiliates {"wallet": โ€ฆ} (free).