Is there an equivalent of curl -k
option in axios? when i am calling api with curl -k
it is working perfectly fine but if i am using it via axios code in node js it gives ssl chain certificate issue.
Asked
Active
Viewed 77 times
1 Answers
0
I believe you can use a HTTPS agent to ignore SSL errors like so:
const instance = axios.create({
httpsAgent: new https.Agent({
rejectUnauthorized: false
})
});

Conor Reid
- 578
- 3
- 16