I want to get the response from an external url , which is working if I load the url in web browser and postman as well. But it is not working in erpnext. I have created a custom script to pull the response from the url as given below :
@Ryan1
I just tried your code and it works . so I am guessing the problem is the api authentication as your readystate indicates 4. are you sure about the url and the authentication in the header ? have you tried postman to test it ? try to remove the datatype . it was giving errors in my case .
Authorization is not needed actually, the site ‘http://localhost:5000’ (running in flask, not a part of erpnext) simply throws value 220 which I need to fetch in erpnext doc. @bahaou