用python的request模块获取access_token时提示报错

作者:jd3096 | 更新时间:2021-05-16 | 浏览量:732

这是我的代码

import requests
import json
url='https://www.bigiot.net/oauth/token'
values={"cliend_id":"1109","client_secret":"fc1c890e2e","username":"15790","password":"0894aef469","grant_type":"password"}
headers={"Content-Type": "application/x-www-form-urlencoded"}
jdjd=requests.post(url=url,data=values)
print(jdjd.text)

错误代码

{"error":"invalid_client","error_description":"Client credentials were not found in the headers or body"}

请问可能是什么原因呢?


评论:共1条

贝壳物联 评论于:2021-05-21 09:28:58
可能请求方式,或请求信息没有正确发送。
返回顶部