You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Same request working with fetch
What I observed axios request converted the body into string like this
`0: "56438"`
but in fetch request raw data is in number type
Describe the bug
Hey folks , I am not getting desired response from a POST api request with axios . Please check the code snippet below
const rawData = [56438] const accessToken = storage.getToken(); method:'POST', headers, }); return axiosInstance.post<ResponseAgingAnalysis>(endpoints.agingAnalysis,rawData)
0: 56438
headers.append('Authorization',
Bearer ${accessToken}); headers.append('Content-Type', 'application/json; charset=utf-8'); return fetch('url',{body: JSON.stringify(rawData), method:'POST', headers, });
To Reproduce
No response
Code snippet
Expected behavior
I want request body should be same without type conversion .
Axios Version
1.6.7
Adapter Version
No response
Browser
No response
Browser Version
No response
Node.js Version
20
OS
No response
Additional Library Versions
Additional context/Screenshots
No response
The text was updated successfully, but these errors were encountered: