Hello, I need help to login to my client oc store api. I ve done everything according to the docs (found here http://docs.opencart.com/en-gb/system/users/api/), but when I try to login in order to fetch the token, I get this response
"<b>Notice</b>: Undefined index: api_token in
<b>/var/app/current/public/catalog/controller/startup/session.php</b> on line
<b>8</b>"
I whitelisted my IP, I tripple checked my key and username, and really cant tell what is wrong with this.
here is my python code
Code: Select all
base_url = "https://www.terracesmenswear.co.uk/index.php"
login_route = "?route=api/login"
orders = "?route=api/order/history"
r = requests.post(base_url+login_route, data={
'username':username,
'key':key
})
print (r.text)
<b>Notice</b>: Undefined index: api_token in <b>/var/app/current/public/catalog/controller/startup/session.php</b> on line<b>8</b>