BigCommerce API - 无法获得产品列表

时间:2017-01-03 14:28:19

标签: python django flask bigcommerce

如下所示调用bigcommerce api

url = 'https://api.bigcommerce.com/stores/XXX/v2/products/'
    headers = {'X-Auth-Client': 'XXXX',
               'X-Auth-Token': 'XXXX',   'Content-Type': 'application/json',
               'Accept': 'application/json'}   
    data = {'scope': 'store_v2_products'}
    r = requests.get(url,data=json.dumps(data), headers=headers) 
    print json.dumps(r.json(), indent=4)

获得以下回复

<Response [401]>
{
 "error": "You are not authorized." 
}
我做错了什么?

0 个答案:

没有答案