I am trying to get ORDER data from shopify. I have created a private store, I have the api credentials in my code but,
def get_all_orders():
last=0
orders=pd.DataFrame()
while True:
url = [email removed]
response = requests.request(“GET”, url)
df=pd.DataFrame(response.json()[‘Order’])
orders=pd.concat([orders,df])
last=df[‘id’].iloc[-1]
if len(df)<=250:
break
return(orders)
df=get_all_orders()
df.head()
KeyError: 'Order'
I want to extract data by manipulating ‘date’ but it seems like the code is unable to fetch ‘order’ attribute from the store. Need Help! Thanks.