【发布时间】:2021-04-01 05:27:17
【问题描述】:
我正在从 Zoho CRM API 获取数据
import requests
import json
import pandas
refresh_token="xxxx"
client_id="xxxx"
client_secret="xxx"
req1=requests.post("https://accounts.zoho.com/oauth/v2/token?refresh_token=" + refresh_token + "&client_id="+ client_id + "&client_secret=" + client_secret + "&grant_type=refresh_token")
print(req1.status_code)
data=req1.json()
acc_token=data['access_token']
headers= {'Authorization': 'Zoho-oauthtoken '+acc_token}
url="https://www.zohoapis.com/crm/v2/Leads"
r= requests.get(url,headers=headers)
print(r.status_code)
print(r.json())
我收到了回复,但我只能获得 200 条记录。 JSON 响应末尾有以下详细信息
'info': {'per_page': 200, 'count': 200, 'page': 1, 'more_records': True}}.
请帮我获取所有记录
【问题讨论】:
标签: python api python-requests jupyter-notebook zoho