Hello. I am playing with a Jupiter trading bot example described here:
(Create a Solana Trading Bot Using Jupiter API | QuickNode)
Using free endpoints (to try and evaluate before I pay for production stuff)
When I use the predefined pair USDC/Solana, it all works just perfectly.
But when I’m trying to replace USDC with an SPL token address, the Jupiter API always returns 400: Bad Request error when trying to obtain the quote, with any example of an existing SPL token. The “good request” and any “bad request” differ only with the token address.
Here is an example of response with error:
Response {
status: 400,
statusText: ‘Bad Request’,
headers: Headers {
date: ‘Thu, 16 May 2024 18:09:07 GMT’,
‘content-type’: ‘application/json’,
‘content-length’: ‘75’,
connection: ‘keep-alive’,
‘cf-ray’: ‘884d51255958b188-WAW’,
‘cf-cache-status’: ‘DYNAMIC’,
‘access-control-allow-origin’: ‘',
‘access-control-allow-headers’: '’,
‘access-control-max-age’: ‘86400’,
‘access-control-request-method’: ‘GET, POST, OPTIONS’,
m: ‘’,
vary: ‘Accept-Encoding’,
server: ‘cloudflare’,
‘alt-svc’: ‘h3=“:443”; ma=86400’
},
body: ReadableStream { locked: false, state: ‘readable’, supportsBYOB: true },
bodyUsed: false, ok: false, redirected: false, type: ‘basic’, url: ‘https://quote-api.jup.ag/v6/quote?inputMint=FaWWacd1g4tniELWoSV1c3WbAf4Q53XUjmkGP6hvCGwM&outputMint=So11111111111111111111111111111111111111112&amount=1’ } }
Am I doing something wrong? If I upgrade to paid plans for both QuickNode and Jupiter add-on, should it work well, or the problem is not the free stuff used?
Thanks everybody who can help.
2 posts - 2 participants