原因:
authorization=response['data']['authorization']
print(authorization)
........................
response = requests.post(url1, data=date1,headers=authorization).json()
直接把请求返回的authorization当做参数传给了post的header
但是post请求参数的headers要求的是 字典 类型,但是上面返回的authorization是字符串
解决方法:
head = {'authorization': authorization} # 将header封装到字典里去
response = requests.post(url1, data=date1,headers=head).json()