python requests cookie的获取和使用

python requests cookie的获取和使用_第1张图片

文章目录

  • 前言
  • 一、cookie是什么?
  • 二、使用步骤
    • 开始代码实现
    • 会话是什么
    • 然后写入我们的账号信息
  • 使用session访问登陆账号的url
    • 获取账号的书架上的数据
  • 完整的代码
  • 补充
    • 比较暴力的获取方式


前言

我们在使用爬虫中会用到很多账号登录才可以显示的内容所以我们要获取cookie进行模拟登录获取我们想要的内容


提示:以下是本篇文章正文内容,下面案例可供参考

一、cookie是什么?

以下内容是通过百度获取的内容

Cookie是一段不超过4KB的小型 文本 数据,由一个名称(Name)、一个值(Value)和其它几个用于控制Cookie有效期、安全性、使用范围的可选属性组成。 其中 : (1)Name/Value:设置Cookie的名称及相对应的值,对于认证Cookie,Value值包括Web服务器所提供的访问令牌 。

二、使用步骤

本次引用的库:(本次引用的库很少只有requests一个)

import requests

开始代码实现

首先是创建会话

session = requests.session()

会话是什么

以下是比较的官方的的说法
Session:在计算机中,尤其是在网络应用中,称为“会话控制”。Session对象存储特定用户会话所需的属性及配置信息。这样,当用户在应用程序的Web页之间跳转时,存储在Session对象中的变量将不会丢失,而是在整个用户会话中一直存在下去。当用户请求来自应用程序的 Web页时,如果该用户还没有会话,则Web服务器将自动创建一个 Session对象

我自己的理解其实就是两个客户端和服务器端的对话,对话中不会忘记之前说过的内容


然后写入我们的账号信息

data = {
    "loginName": "账号",
    "password": "密码"
}

然后编辑我们的登录账号的url

url = "https://passport.17k.com/ck/user/login"

这个网址我在抓包工具中没有找到不知道为什么但是在某个up博主可以找到我直接用的他连接很神奇可以直接用所以我就没有继续深究下去,直接下一步了

使用session访问登陆账号的url

esp =  session.post(url, data=data)
print(resp.text)
print(resp.cookies)  # 看cookie

输出的结果:
{"status":{"code":0,"msg":"succ"},"data":{"app":0,"appVersion":"","auditAvatarUrl":null,"auditNickname":null,"avatarUrl":"https:\/\/cdn.static.17k.com\/user\/avatar\/10\/30\/76\/98487630.jpg-88x88?v=1664633450000","bindWechatNickname":0,"channel":"0","clientPort":"","cpsOpid":"web","cpsSource":"0","createTimeValue":1664633450000,"deviceFlag":"2F9771F5-FEFA-3280-C27C-786A45A02CEE","deviceName":"17k","email":"","gender":1,"id":98487630,"info":"","ip":"183.197.187.172","isDeviceUser":0,"loginAuthEmail":0,"loginAuthMobile":1,"loginName":"19503230512","merchant":"web","mobile":"19503230512","msg":null,"newFlag":0,"newUserEndTimeValue":0,"newUserFlag":0,"nickname":"金龙于123","nicknameAuditStatus":null,"osVersion":"","platform":0,"registerAuto":0,"source":"","subApp":0,"sysNicknameFlag":null,"ua":"python-requests\/2.28.1","userName":"","oldUid":98487630,"_act":2},"time":1664721041000}

这样输出的结果我们会发现有我们的结果账号、用户名称、以及其他的一些信息
然后可以查看我们的cookie

获取账号的书架上的数据

因为session中是有cookie的信息所以我们要使用session对书架的网页进行访问

url = "https://user.17k.com/ck/author/shelf"
resqen = session.get(url)
print(resqen.text)
resqen.close()


运行的结果:
{"status":{"code":0,"msg":"succ"},"data":[{"bookId":3377676,"bookName":"我的透视超给力","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/76\/76\/3377676.jpg-189x272?v=1661851591000","authorId":85215151,"authorPenName":"番茄炖肉","introduction":"我是老中医,专治各种吹牛逼!\n我武道超神,吊打一切不服气!\n秦飞偶得神秘传承,拥有神眼,从此医术通天,武道超神,且看他逆天崛起,笑傲人生。","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":3,"name":"都市小说"},"bookCategory":{"id":87,"name":"都市异能"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47113049,"name":"第五百九十七章  营救任务","createTime":1664465467000,"updateTime":1664677416000,"isVIP":{"id":1,"name":"是"},"publishTime":1664665201000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633456000,"topTimeValue":0,"bookupdateTimeValue":1664677416000,"recCode":"null1664721641690273","type":5},{"bookId":3403515,"bookName":"天道关系户","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/15\/35\/3403515.jpg-189x272?v=1644304663000","authorId":46313415,"authorPenName":"单纯宅男","introduction":"黑暗深渊异魔暴动,异魔王横空降世,天澜城危。\n“叮。经系统检测,天澜城城主发布雇佣任务,剿灭异魔,是否接受?”\n“接受。”苏格望着那遮天蔽日的异魔,眼神炽热。\n“叮。本着客户至上、任务第一的原则,宿主修为将临时提升到帝境,以便完成任务。”\n“任务完成,将有十分之一临时修为转化为永久修为,可与宿主原修为叠加。”\n于是,人们震惊地看到——\n天澜城外,一剑光寒平地起,亿万异魔成飞灰。\n","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":21,"name":"玄幻奇幻"},"bookCategory":{"id":8,"name":"东方玄幻"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47126409,"name":"第486章 妥协","createTime":1664716614000,"updateTime":1664720407000,"isVIP":{"id":1,"name":"是"},"publishTime":1664716614000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633455000,"topTimeValue":0,"bookupdateTimeValue":1664720407000,"recCode":"null1664721641690273","type":5},{"bookId":3430856,"bookName":"分手后我成了前任的娇软白月光","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/56\/08\/3430856.jpg-189x272?v=1650790915000","authorId":96144514,"authorPenName":"欧阳元泉","introduction":"13年痴情错付,云雪尧一朝醒悟,痛快分手退婚,“渣男如狗,且抛且走!”\n重拾事业,她在职场中飒爽杀伐,惊艳众人。\n曾经弃她如敝履的男人,却疯了似的缠她上瘾,“尧尧,嫁给我好不好?”\n云雪尧潋滟轻笑:“霄爷如今,怎么活成了自己最讨厌的样子?”\n——\n用了整整七年去恨她,等到她决然转身,江凌霄才发现:所有的恨意都抵不过失去她的恐惧。\n“尧尧,我只求复合,不会逼你结婚。”\n“尧尧,我只求结婚,不会逼你生宝宝。”\n“尧尧,我们只生一个,不会让你多生……”\n云雪尧揣着第三胎,忍无可忍,“江凌霄,你这个卑鄙小人!”\n江凌霄:“尧尧,小人在你肚子里,我是你亲爱的。”","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":17,"name":"现代言情"},"bookCategory":{"id":134,"name":"总裁豪门"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47123197,"name":"第246章 想告诉他真相","createTime":1664637621000,"updateTime":1664640517000,"isVIP":{"id":1,"name":"是"},"publishTime":1664637621000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633454000,"topTimeValue":0,"bookupdateTimeValue":1664640517000,"recCode":"null1664721641690273","type":5},{"bookId":3411557,"bookName":"农门长姐:我娇养了五个大佬弟弟","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/57\/15\/3411557.jpg-189x272?v=1646704817000","authorId":60959010,"authorPenName":"香奈儿不香","introduction":"亲自带着百亿物资前往灾区赈灾的女霸总唐琪穿越开局就死娘,老爹征丁失踪,爷奶叔婶齐上阵要卖掉襁褓里的弟弟换粮食。\n  唐琪扬起扫帚,怒打极品血亲,化解危难后,看着三个小萝卜头弟弟,还有一个襁褓中的奶娃娃,她撸起袖子表示不要慌,有姐在就饿不死!\n  天无绝人之路,她的百亿物资竟然化作空间跟随她而来,唐琪凭着机智的头脑和天赋灵活使用百亿物资闷声发大财,斗渣渣、虐极品、送弟弟习文练武学医术,将他们养育成才。\n  后来--\n  少年将军:谁敢欺负我长姐,提头来见。\n  权臣首辅:谁敢辱骂我长姐,牢狱相会。\n  北周首富:谁敢骗财我长姐,赔个底掉。\n  鬼医传人:谁敢伤害我长姐,生不如死。\n  江湖少谷主:额我也来……谁敢欺负我义姐,虽远必毒。\n  京城众人皆惊:这唐家长女竟这般厉害,可婚配否?\n  镇国公爷:不瞒各位,娇妻已孕满三月,来年登门喝满月酒啊!","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":5,"name":"古代言情"},"bookCategory":{"id":140,"name":"女尊女强"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47125613,"name":"第665章 不如博一个好名声","createTime":1664705145000,"updateTime":1664706439000,"isVIP":{"id":1,"name":"是"},"publishTime":1664705145000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633453000,"topTimeValue":0,"bookupdateTimeValue":1664706439000,"recCode":"null1664721641690273","type":5},{"bookId":3421307,"bookName":"不灭造化决","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/07\/13\/3421307.jpg-189x272?v=1655708908000","authorId":41547791,"authorPenName":"言轻语","introduction":"异世大陆,强者为尊。\n少年陆泽惨遭背叛,却意外获得无上神功,从此龙游苍穹,鹰翱九霄。\n杀圣子,灭天骄,夺造化,逆天改命,强势崛起!\n一步一登天!\n一路披荆斩棘,一剑破万法!\n高歌猛进,无所不克,一直走到巅峰。","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":21,"name":"玄幻奇幻"},"bookCategory":{"id":8,"name":"东方玄幻"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47126575,"name":"第336章龙腾山,被魔兽追杀的小女孩","createTime":1664718112000,"updateTime":1664720366000,"isVIP":{"id":1,"name":"是"},"publishTime":1664718112000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633452000,"topTimeValue":0,"bookupdateTimeValue":1664720366000,"recCode":"null1664721641690273","type":5},{"bookId":3417179,"bookName":"穿书七零:作精女配靠玄学躺赢","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/79\/71\/3417179.jpg-189x272?v=1647830639000","authorId":80155009,"authorPenName":"一束清风","introduction":"玄学大佬宋柠,穿成年代文的同名作精假千金,刚穿越就惨遭公婆设计离婚。\n真千金和其养父母也趁机来找事,宋柠只好撸起袖子爬起来干架…\n本来以为老公是个糙汉军官,谁知乔博却英俊又贴心…\n宋柠:啧…老公真香!\n干回老本行的宋柠,运气出奇的好,干什么都顺利的不得了,随手做的事业也越做越大…\n宋柠:就离谱了…\n乔博:啧…软饭真香!","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":17,"name":"现代言情"},"bookCategory":{"id":136,"name":"年代种田"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47125267,"name":"第445章合作","createTime":1664699809000,"updateTime":1664714211000,"isVIP":{"id":1,"name":"是"},"publishTime":1664699809000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633451000,"topTimeValue":0,"bookupdateTimeValue":1664699871000,"recCode":"null1664721641690273","type":5}],"num":20,"curPage":1,"totalNum":6,"totalPage":1,"hasMore":0,"time":1664721641000}

完整的代码

import requests

# # 会话
session = requests.session()
data = {
    "loginName": "xxxxxxxx",
    "password": "xxxxxxx"
}

# 1. 登录
url = "https://passport.17k.com/ck/user/login"
resp =  session.post(url, data=data)
# print(resp.text)
#print(resp.cookies)  # 看cookie
#session中是有cookie的
# # 2. 拿书架上的数据
# # 刚才的那个
url = "https://user.17k.com/ck/author/shelf"
resqen = session.get(url)
resqen_json = resqen.json()
print(resqen_json)

补充

比较暴力的获取方式

但我们获取不到cookie的时候,我们就比较烦恼我们可以直接用一种比较暴力的方式进行获取,当然这个暴力不是让你去砸电脑哦只是双引号的暴力,不是实际意义上的暴力。
![在这里插入图片描述](https://img-blog.csdnimg.cn/f475a7f6c0b64bda9d60db7e7b29c3c2.png
让我们抓住这个包并且记住这个请求url给他复制下来并且对他发送请求(但是我们要给他封装一个cookie的数据也就是我画圈里面的):python requests cookie的获取和使用_第2张图片

url = "https://user.17k.com/ck/author/shelf?page=1&appKey=2406394919"
heads = {
"Cookie": "GUID=f383b9fb-f685-486a-bc3b-105370c6a101; c_channel=0; c_csc=web; accessToken=avatarUrl%3Dhttps%253A%252F%252Fcdn.static.17k.com%252Fuser%252Favatar%252F10%252F30%252F76%252F98487630.jpg-88x88%253Fv%253D1664633450000%26id%3D98487630%26nickname%3D%25E9%2587%2591%25E9%25BE%2599%25E4%25BA%258E123%26e%3D1680272481%26s%3Dc78db46934e06eb3; sensorsdata2015jssdkcross=%7B%22distinct_id%22%3A%2298487630%22%2C%22%24device_id%22%3A%2218393a7f4ca81e-0b4eeaecca8db8-78565473-2073600-18393a7f4cb85e%22%2C%22props%22%3A%7B%22%24latest_traffic_source_type%22%3A%22%E8%87%AA%E7%84%B6%E6%90%9C%E7%B4%A2%E6%B5%81%E9%87%8F%22%2C%22%24latest_referrer%22%3A%22https%3A%2F%2Fcn.bing.com%2F%22%2C%22%24latest_referrer_host%22%3A%22cn.bing.com%22%2C%22%24latest_search_keyword%22%3A%22%E6%9C%AA%E5%8F%96%E5%88%B0%E5%80%BC%22%7D%2C%22first_id%22%3A%22f383b9fb-f685-486a-bc3b-105370c6a101%22%7D"
}
resp = requests.get(url=url,headers=heads)
print(resp.text)
resp.close()
 运行结果:
 {"status":{"code":0,"msg":"succ"},"data":[{"bookId":3377676,"bookName":"我的透视超给力","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/76\/76\/3377676.jpg-189x272?v=1661851591000","authorId":85215151,"authorPenName":"番茄炖肉","introduction":"我是老中医,专治各种吹牛逼!\n我武道超神,吊打一切不服气!\n秦飞偶得神秘传承,拥有神眼,从此医术通天,武道超神,且看他逆天崛起,笑傲人生。","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":3,"name":"都市小说"},"bookCategory":{"id":87,"name":"都市异能"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47113049,"name":"第五百九十七章  营救任务","createTime":1664465467000,"updateTime":1664677416000,"isVIP":{"id":1,"name":"是"},"publishTime":1664665201000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633456000,"topTimeValue":0,"bookupdateTimeValue":1664677416000,"recCode":"null1664726825666120","type":5},{"bookId":3403515,"bookName":"天道关系户","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/15\/35\/3403515.jpg-189x272?v=1644304663000","authorId":46313415,"authorPenName":"单纯宅男","introduction":"黑暗深渊异魔暴动,异魔王横空降世,天澜城危。\n“叮。经系统检测,天澜城城主发布雇佣任务,剿灭异魔,是否接受?”\n“接受。”苏格望着那遮天蔽日的异魔,眼神炽热。\n“叮。本着客户至上、任务第一的原则,宿主修为将临时提升到帝境,以便完成任务。”\n“任务完成,将有十分之一临时修为转化为永久修为,可与宿主原修为叠加。”\n于是,人们震惊地看到——\n天澜城外,一剑光寒平地起,亿万异魔成飞灰。\n","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":21,"name":"玄幻奇幻"},"bookCategory":{"id":8,"name":"东方玄幻"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47126409,"name":"第486章 妥协","createTime":1664716614000,"updateTime":1664720407000,"isVIP":{"id":1,"name":"是"},"publishTime":1664716614000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633455000,"topTimeValue":0,"bookupdateTimeValue":1664720407000,"recCode":"null1664726825666120","type":5},{"bookId":3430856,"bookName":"分手后我成了前任的娇软白月光","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/56\/08\/3430856.jpg-189x272?v=1650790915000","authorId":96144514,"authorPenName":"欧阳元泉","introduction":"13年痴情错付,云雪尧一朝醒悟,痛快分手退婚,“渣男如狗,且抛且走!”\n重拾事业,她在职场中飒爽杀伐,惊艳众人。\n曾经弃她如敝履的男人,却疯了似的缠她上瘾,“尧尧,嫁给我好不好?”\n云雪尧潋滟轻笑:“霄爷如今,怎么活成了自己最讨厌的样子?”\n——\n用了整整七年去恨她,等到她决然转身,江凌霄才发现:所有的恨意都抵不过失去她的恐惧。\n“尧尧,我只求复合,不会逼你结婚。”\n“尧尧,我只求结婚,不会逼你生宝宝。”\n“尧尧,我们只生一个,不会让你多生……”\n云雪尧揣着第三胎,忍无可忍,“江凌霄,你这个卑鄙小人!”\n江凌霄:“尧尧,小人在你肚子里,我是你亲爱的。”","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":17,"name":"现代言情"},"bookCategory":{"id":134,"name":"总裁豪门"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47127069,"name":"第247章 他的“惩罚”让人心冷","createTime":1664722428000,"updateTime":1664722617000,"isVIP":{"id":1,"name":"是"},"publishTime":1664722428000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633454000,"topTimeValue":0,"bookupdateTimeValue":1664722617000,"recCode":"null1664726825666120","type":5},{"bookId":3411557,"bookName":"农门长姐:我娇养了五个大佬弟弟","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/57\/15\/3411557.jpg-189x272?v=1646704817000","authorId":60959010,"authorPenName":"香奈儿不香","introduction":"亲自带着百亿物资前往灾区赈灾的女霸总唐琪穿越开局就死娘,老爹征丁失踪,爷奶叔婶齐上阵要卖掉襁褓里的弟弟换粮食。\n  唐琪扬起扫帚,怒打极品血亲,化解危难后,看着三个小萝卜头弟弟,还有一个襁褓中的奶娃娃,她撸起袖子表示不要慌,有姐在就饿不死!\n  天无绝人之路,她的百亿物资竟然化作空间跟随她而来,唐琪凭着机智的头脑和天赋灵活使用百亿物资闷声发大财,斗渣渣、虐极品、送弟弟习文练武学医术,将他们养育成才。\n  后来--\n  少年将军:谁敢欺负我长姐,提头来见。\n  权臣首辅:谁敢辱骂我长姐,牢狱相会。\n  北周首富:谁敢骗财我长姐,赔个底掉。\n  鬼医传人:谁敢伤害我长姐,生不如死。\n  江湖少谷主:额我也来……谁敢欺负我义姐,虽远必毒。\n  京城众人皆惊:这唐家长女竟这般厉害,可婚配否?\n  镇国公爷:不瞒各位,娇妻已孕满三月,来年登门喝满月酒啊!","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":5,"name":"古代言情"},"bookCategory":{"id":140,"name":"女尊女强"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47125613,"name":"第665章 不如博一个好名声","createTime":1664705145000,"updateTime":1664706439000,"isVIP":{"id":1,"name":"是"},"publishTime":1664705145000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633453000,"topTimeValue":0,"bookupdateTimeValue":1664706439000,"recCode":"null1664726825666120","type":5},{"bookId":3421307,"bookName":"不灭造化决","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/07\/13\/3421307.jpg-189x272?v=1655708908000","authorId":41547791,"authorPenName":"言轻语","introduction":"异世大陆,强者为尊。\n少年陆泽惨遭背叛,却意外获得无上神功,从此龙游苍穹,鹰翱九霄。\n杀圣子,灭天骄,夺造化,逆天改命,强势崛起!\n一步一登天!\n一路披荆斩棘,一剑破万法!\n高歌猛进,无所不克,一直走到巅峰。","bookClass":{"id":2,"name":"男生"},"bookChannel":{"id":21,"name":"玄幻奇幻"},"bookCategory":{"id":8,"name":"东方玄幻"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47126575,"name":"第336章龙腾山,被魔兽追杀的小女孩","createTime":1664718112000,"updateTime":1664720366000,"isVIP":{"id":1,"name":"是"},"publishTime":1664718112000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633452000,"topTimeValue":0,"bookupdateTimeValue":1664720366000,"recCode":"null1664726825666120","type":5},{"bookId":3417179,"bookName":"穿书七零:作精女配靠玄学躺赢","coverImg":"https:\/\/cdn.static.17k.com\/book\/189x272\/79\/71\/3417179.jpg-189x272?v=1647830639000","authorId":80155009,"authorPenName":"一束清风","introduction":"玄学大佬宋柠,穿成年代文的同名作精假千金,刚穿越就惨遭公婆设计离婚。\n真千金和其养父母也趁机来找事,宋柠只好撸起袖子爬起来干架…\n本来以为老公是个糙汉军官,谁知乔博却英俊又贴心…\n宋柠:啧…老公真香!\n干回老本行的宋柠,运气出奇的好,干什么都顺利的不得了,随手做的事业也越做越大…\n宋柠:就离谱了…\n乔博:啧…软饭真香!","bookClass":{"id":3,"name":"女生"},"bookChannel":{"id":17,"name":"现代言情"},"bookCategory":{"id":136,"name":"年代种田"},"authLevel":{"id":4,"name":"VIP作品"},"progress":0,"lastUpdateChapter":{"id":47125267,"name":"第445章合作","createTime":1664699809000,"updateTime":1664714211000,"isVIP":{"id":1,"name":"是"},"publishTime":1664699809000},"status":{"id":4,"name":"正常"},"bookStatus":{"id":1,"name":"连载"},"isVIP":{"id":1,"name":"是"},"bookmarkChapterId":0,"bookmarkChapterName":"","bookmarkChapterVipFlag":0,"topFlag":0,"createTimeValue":1664633450000,"updateTimeValue":1664633451000,"topTimeValue":0,"bookupdateTimeValue":1664699871000,"recCode":"null1664726825666120","type":5}],"num":20,"curPage":1,"totalNum":6,"totalPage":1,"hasMore":0,"time":1664726825000}
 

会获得一样的结果,和上面的是一样的原理。

你可能感兴趣的:(python,入门,python,爬虫,服务器,pycharm)