0

The 0x Protocol API Endpoint for Polygon (Mumbai) doesn't seem to work.

curl --location --request GET 'https://mumbai.api.0x.org/swap/v1/quote?buyToken=0xcB1e72786A6eb3b44C2a2429e317c8a2462CFeb1&sellToken=0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889&sellAmount=10000' \
--header 'Content-Type: application/json' \
--data-raw '{"query":"query {\n  pairs {\n    id\n    tokenA\n    tokenB\n    exchange\n    router\n  }\n}","variables":{}}'

Response

{
   "reason": "Server Error"
}

2 Answers 2

0

I think it's because the contracts have been deployed on Mumbai but the API endpoint for that chain has not been released yet.

0

Since the first answer, the API endpoint has been deployed so you can use it now!

But for the pair you're querying its seems that there is not enough liquidity, you can use the the response from Joao Campos in this thread to help you for the rest

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.