trace_filter API error
const response = await axios.post(url, {
jsonrpc: '2.0',
method: 'trace_filter',
id: 1,
params: [{
fromBlock: '0x0',
toBlock: 'latest',
fromAddress: ['0x2a357cc5E340685cb7e5827659a561C346C23321'],
toAddress: ['0xF0031782d37819F8E209C4421C774eD1f6163052]
}]
});
i requested api like that way
but i got message below that way
Error fetching traces: AxiosError: Request failed with status code 503
at settle (webpack-internal:///(rsc)/./nodemodules/axios/lib/core/settle.js:21:16)
at IncomingMessage.handleStreamEnd (webpack-internal:///(rsc)/./node_modules/axios/lib/adapters/http.js:513:81)
at IncomingMessage.emit (node:events:527:35)
at endReadableNT (node:internal/streams/readable:1589:12)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
at Axios.request (webpack-internal:///(rsc)/./node_modules/axios/lib/core/Axios.js:50:49)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async traceFilter (webpack-internal:///(rsc)/./src/lib/server/trace/trace.ts:16:30)
at async GET (webpack-internal:///(rsc)/./src/app/api/tracking/connect/route.ts:26:5)
at async /Users/godfgod1/Desktop/unique/babam-renewal/node_modules/next/dist/compiled/next-server/app-route.runtime.dev.js:6:62499 {
code: 'ERR_BAD_RESPONSE',
config: {
transitional: {
silentJSONParsing: true,
forcedJSONParsing: true,
clarifyTimeoutError: false
},
adapter: [ 'xhr', 'http' ],
transformRequest: [ [Function: transformRequest] ],
transformResponse: [ [Function: transformResponse] ],
timeout: 0,
xsrfCookieName: 'XSRF-TOKEN',
xsrfHeaderName: 'X-XSRF-TOKEN',
maxContentLength: -1,
maxBodyLength: -1,
env: { FormData: [Function], Blob: [class Blob] },
validateStatus: [Function: validateStatus],
headers: Object [AxiosHeaders] {
Accept: 'application/json, text/plain, /_',
'Content-Type': 'application/json',
'User-Agent': 'axios/1.6.8',
'Content-Length': '218',
'Accept-Encoding': 'gzip, compress, deflate, br'
},
method: 'post',
url: 'https://eth-mainnet.g.alchemy.com/v2/BTxsbEwRHeWtkwZhLbYJWINk6TZB3LBe',
data: '{"jsonrpc":"2.0","method":"trace_filter","id":1,"params":[{"fromBlock":"0x0","toBlock":"latest","fromAddress":["0x2a357cc5E340685cb7e5827659a561C346C23321"],"toAddress":["0xF0031782d37819F8E209C4421C774eD1f6163052"]}]}'
},
response: {
status: 503,
statusText: 'Service Unavailable',
headers: Object [AxiosHeaders] {
date: 'Mon, 23 Sep 2024 03:33:00 GMT',
'content-type': 'application/json',
'content-length': '101',
connection: 'keep-alive',
'cf-ray': '8c7777cb3de6d1da-ICN',
'cf-cache-status': 'DYNAMIC',
'access-control-allow-origin': '*',
'access-control-allow-credentials': 'true',
'x-alchemy-trace-id': '9911c9775545ce6e3d4f2009dbd829d3',
vary: 'Accept-Encoding',
'set-cookie': [Array],
server: 'cloudflare'
},
sometimes that is working
but most of time that is not working
obviosuly i paid for that and am a growth memeber
could you help me to solve it?