python爬取ajax


import requests

url = 'https://api.bilibili.com/x/v2/reply/main?csrf=056718067a9e03b351569ee0294e4a1e&mode=3&next=2&oid=813963991&plat=1&type=1'
header = {
    'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36'
}

response = requests.get(url,headers=header,verify=False)

result = response.json()

print(result['code'])

result :0

原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/tech/python/280773.html

(0)
上一篇 2022年8月15日 22:17
下一篇 2022年8月15日 22:23

相关推荐

发表回复

登录后才能评论

WordPress 数据库错误: [Duplicate entry '80-d16c1647a53da3ad6bbb3d1108156ba7' for key 'task_id_source_url_key']
insert into wp_autoblog_queue(task_id,source_url,source_url_key,create_date_time,not_check_stoped,post_interval) values(80,'https://pythonjishu.com/robotic-process-automation/','d16c1647a53da3ad6bbb3d1108156ba7',1735382269,0,0)