Hi,
I am trying to get json data from API from another website but I am unable to get a correct response from the website, I am suspecting that my response code being sent to the website is not correct. I would request anyone to help me find a way to make the correct request.
Code:
def getOrderShipmentDetails(self):
url = "https://shipway.in/api/getOrderShipmentDetails"
controller = frappe.get_doc("Shipway Settings")
request = {
"username": controller.username,
"password": controller.license_key,
"order_id": self.document_name
}
#self.test_data = str(controller.username)
frappe.msgprint(json.dumps(request))
response = make_get_request(url, auth=None, headers = None, data = request)
frappe.msgprint(json.dumps(response))
The response I am getting the from the website is as below:
{"status": "failed", "msg": "Invalid inputs ,Please send username , password and (order id or awbno)"}
The API documentation of the website is also enclosed but since this is my first time developing a connector I am presuming I am doing something silly
Any help on this would be greatly appreciated.