{"openapi":"3.1.0","info":{"title":"MoonPay (BYOK) API","version":"0.1.0","description":"MoonPay (BYOK) lets an AI assistant read your own MoonPay data through the MoonPay API with a key you supply (MoonPay publishable API key (pk_test_... or pk_live_...)). Read-only: 9 tools (list_countries, list_currencies, search_currencies, get_currency_limits, get_network_fees, get_buy_quote, get_sell_quote, list_defi_tokens, get_defi_token). The BYOK key travels with each request, is used for...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-moonpay.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-moonpay/docs"},"termsOfService":"https://connectorbay.com/byok-moonpay/terms"},"servers":[{"url":"https://byok-moonpay.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-moonpay/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_countries":{"post":{"operationId":"list_countries","summary":"List the countries MoonPay supports, with whether buying and selling are allowed in each and which identity documents ar","description":"List the countries MoonPay supports, with whether buying and selling are allowed in each and which identity documents are accepted. Use for \"Is MoonPay available for buying and selling crypto in Brazil\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_countriesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_currencies":{"post":{"operationId":"list_currencies","summary":"List the fiat and crypto currencies MoonPay supports with min and max buy and sell amounts, precision, suspension status","description":"List the fiat and crypto currencies MoonPay supports with min and max buy and sell amounts, precision, suspension status and network metadata. The list is long, so only the first items are returned. Use for \"Which cryptocurrencies can I buy through MoonPay and what are the minimum amounts\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"show":{"anyOf":[{"enum":["enabled","all"],"type":"string"},{"type":"null"}],"default":null,"description":"'enabled' returns the currencies enabled for your account, 'all' every currency MoonPay supports. By default the list is the enabled ones filtered by the caller's location.","title":"Show"}},"title":"list_currenciesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/search_currencies":{"post":{"operationId":"search_currencies","summary":"Search MoonPay's catalog of centralised and DeFi currencies by name or symbol, with price, 24h change, market cap, volum","description":"Search MoonPay's catalog of centralised and DeFi currencies by name or symbol, with price, 24h change, market cap, volume and token security flags. Page with the cursor. Use for \"Which tokens on Polygon can I buy through MoonPay and what is their market cap\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"search":{"anyOf":[{"maxLength":100,"type":"string"},{"type":"null"}],"default":null,"description":"Case-insensitive search term matched against the currency name and symbol.","title":"Search"},"network_codes":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Comma-separated network codes to include, for example 'ethereum,polygon'.","title":"Network Codes"},"source":{"anyOf":[{"enum":["all","cefi","defi"],"type":"string"},{"type":"null"}],"default":null,"description":"Which catalogue to search: all (default), cefi or defi.","title":"Source"},"limit":{"anyOf":[{"maximum":200,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"How many currencies per page (1 to 200, default set by MoonPay).","title":"Limit"},"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Paging cursor: the nextCursor value from the previous answer.","title":"Cursor"},"sort_by":{"anyOf":[{"enum":["name","priceUsd","marketCap"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort field (default name).","title":"Sort By"},"sort_order":{"anyOf":[{"enum":["asc","desc"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort direction (default asc).","title":"Sort Order"},"is_buy_supported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to return only currencies that can be bought, false only those that cannot.","title":"Is Buy Supported"},"is_sell_supported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to return only currencies that can be sold, false only those that cannot.","title":"Is Sell Supported"},"is_native_token":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to return only native network tokens, false only non-native tokens.","title":"Is Native Token"}},"title":"search_currenciesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_currency_limits":{"post":{"operationId":"get_currency_limits","summary":"Get the minimum and maximum amounts MoonPay allows for buying one cryptocurrency with a fiat currency, optionally for on","description":"Get the minimum and maximum amounts MoonPay allows for buying one cryptocurrency with a fiat currency, optionally for one payment method. Use for \"What is the minimum and maximum I can spend buying ETH with USD on MoonPay\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"currency_code":{"description":"Lower-case code of the cryptocurrency from list_currencies (type crypto), for example 'btc', 'eth' or 'usdc'.","maxLength":200,"title":"Currency Code","type":"string"},"base_currency_code":{"description":"Lower-case code of the fiat currency from list_currencies (type fiat), for example 'usd' or 'eur'.","maxLength":20,"title":"Base Currency Code","type":"string"},"are_fees_included":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"description":"True if the amount you give already includes fees.","title":"Are Fees Included"},"payment_method":{"anyOf":[{"enum":["ach_bank_transfer","credit_debit_card","paypal","gbp_bank_transfer","gbp_open_banking_payment","pix_instant_payment","sepa_bank_transfer"],"type":"string"},{"type":"null"}],"default":null,"description":"Payment method to quote for.","title":"Payment Method"}},"required":["currency_code","base_currency_code"],"title":"get_currency_limitsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_network_fees":{"post":{"operationId":"get_network_fees","summary":"Get the current network (gas) fee MoonPay charges for each given cryptocurrency, expressed in each given fiat currency. ","description":"Get the current network (gas) fee MoonPay charges for each given cryptocurrency, expressed in each given fiat currency. Use for \"What are the network fees for sending ETH and BTC in USD and GBP\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"crypto_currencies":{"description":"Comma-separated crypto currency codes, for example 'eth,btc'.","maxLength":200,"title":"Crypto Currencies","type":"string"},"fiat_currencies":{"description":"Comma-separated fiat currency codes, for example 'usd,gbp'.","maxLength":200,"title":"Fiat Currencies","type":"string"}},"required":["crypto_currencies","fiat_currencies"],"title":"get_network_feesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_buy_quote":{"post":{"operationId":"get_buy_quote","summary":"Get a real-time quote for buying a cryptocurrency with fiat: amount received, price, MoonPay fee, network fee and total.","description":"Get a real-time quote for buying a cryptocurrency with fiat: amount received, price, MoonPay fee, network fee and total. Give either the fiat amount to spend or the crypto amount to buy. No transaction is created. Use for \"How much BTC would I get for 200 USD by card on MoonPay and what are the fees\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"currency_code":{"description":"Lower-case code of the cryptocurrency from list_currencies (type crypto), for example 'btc', 'eth' or 'usdc'.","maxLength":200,"title":"Currency Code","type":"string"},"base_currency_code":{"description":"Lower-case code of the fiat currency from list_currencies (type fiat), for example 'usd' or 'eur'.","maxLength":20,"title":"Base Currency Code","type":"string"},"base_currency_amount":{"anyOf":[{"maximum":100000000,"minimum":0,"type":"number"},{"type":"null"}],"default":null,"description":"Fiat amount the customer wants to spend. Required unless quote_currency_amount is given.","title":"Base Currency Amount"},"quote_currency_amount":{"anyOf":[{"maximum":1000000000,"minimum":0,"type":"number"},{"type":"null"}],"default":null,"description":"Crypto amount the customer wants to buy. Takes precedence over base_currency_amount when both are given.","title":"Quote Currency Amount"},"are_fees_included":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"description":"True if the amount you give already includes fees.","title":"Are Fees Included"},"payment_method":{"anyOf":[{"enum":["ach_bank_transfer","credit_debit_card","paypal","gbp_bank_transfer","gbp_open_banking_payment","pix_instant_payment","sepa_bank_transfer"],"type":"string"},{"type":"null"}],"default":null,"description":"Payment method to quote for.","title":"Payment Method"}},"required":["currency_code","base_currency_code"],"title":"get_buy_quoteArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_sell_quote":{"post":{"operationId":"get_sell_quote","summary":"Get a real-time quote for selling a cryptocurrency for fiat: amount paid out, price and fees. No transaction is created.","description":"Get a real-time quote for selling a cryptocurrency for fiat: amount paid out, price and fees. No transaction is created. Use for \"How much EUR would I get selling 0.5 BTC on MoonPay\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"currency_code":{"description":"Lower-case code of the cryptocurrency from list_currencies (type crypto), for example 'btc', 'eth' or 'usdc'.","maxLength":200,"title":"Currency Code","type":"string"},"quote_currency_code":{"description":"Lower-case fiat currency code to be paid out, for example 'eur'.","maxLength":20,"title":"Quote Currency Code","type":"string"},"base_currency_amount":{"description":"Amount of the cryptocurrency to sell (up to 5 decimals).","maximum":1000000000,"minimum":0,"title":"Base Currency Amount","type":"number"},"payout_method":{"anyOf":[{"enum":["ach_bank_transfer","credit_debit_card","paypal","gbp_bank_transfer","gbp_open_banking_payment","pix_instant_payment","sepa_bank_transfer"],"type":"string"},{"type":"null"}],"default":null,"description":"Payout method to quote for.","title":"Payout Method"}},"required":["currency_code","quote_currency_code","base_currency_amount"],"title":"get_sell_quoteArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_defi_tokens":{"post":{"operationId":"list_defi_tokens","summary":"Search MoonPay's DeFi token list with market cap, liquidity, volume and price change over several windows. Page with the","description":"Search MoonPay's DeFi token list with market cap, liquidity, volume and price change over several windows. Page with the cursor. Use for \"Which DeFi tokens on Base have the largest market cap on MoonPay\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"sort":{"anyOf":[{"enum":["marketCap","price"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort field.","title":"Sort"},"sort_order":{"anyOf":[{"enum":["asc","desc"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort direction.","title":"Sort Order"},"search":{"anyOf":[{"maxLength":100,"type":"string"},{"type":"null"}],"default":null,"description":"Search term matched against token name and symbol.","title":"Search"},"network_codes":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Comma-separated network codes to include, for example 'ethereum,base'.","title":"Network Codes"},"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Paging cursor from the previous answer's meta.nextCursor.","title":"Cursor"},"size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"How many tokens per page.","title":"Size"}},"title":"list_defi_tokensArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_defi_token":{"post":{"operationId":"get_defi_token","summary":"Get MoonPay's market data for one DeFi token by contract address and network: market cap, liquidity, volume, price chang","description":"Get MoonPay's market data for one DeFi token by contract address and network: market cap, liquidity, volume, price change and mint or freeze flags. Use for \"What is the liquidity and 24h volume of a token contract on Ethereum according to MoonPay\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"contract_address":{"description":"Token contract address.","maxLength":100,"title":"Contract Address","type":"string"},"network_code":{"description":"MoonPay network code, for example 'ethereum', 'polygon' or 'base'.","maxLength":40,"title":"Network Code","type":"string"}},"required":["contract_address","network_code"],"title":"get_defi_tokenArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}