当前位置:网站首页>b站视频链接快速获取
b站视频链接快速获取
2022-07-06 12:56:00 【聆听我的召唤,菜鸟进化】
from lxml import etree
import time
import json
import requests
import csv
import random
import os
from fake_useragent import UserAgent
headers={
'User-Agent':UserAgent().random
}
for i in range(1,35):
url='https://api.bilibili.com/x/web-interface/search/type?__refresh__=true&_extra=&context=&page={}&page_size=42&from_source=&from_spmid=333.337&platform=pc&highlight=1&single_column=0&keyword=%E8%8E%8E%E5%A3%AB%E6%AF%94%E4%BA%9A%E6%88%8F%E5%89%A7%E8%A1%A8%E6%BC%94&category_id=&search_type=video&dynamic_offset=72&preload=true&com2co=true'.format(i)
response=requests.get(url=url,headers=headers)
data=response.json()
cards=data['data']['result']
print(i)
for card in cards:
li=[]
link=card["arcurl"]#评分
times=card["duration"]#影名
description=card["title"]#url
li.append(link)
li.append(times)
li.append(description)
print(li)
with open('biliok.csv', 'a', newline='', encoding='utf-8-sig') as fp:
writer = csv.writer(fp)
writer.writerow(li)
time.sleep(float(format(random.uniform(0,3), '.2f')))
边栏推荐
- document. Usage of write () - write text - modify style and position control
- Laravel notes - add the function of locking accounts after 5 login failures in user-defined login (improve system security)
- @Detailed differences among getmapping, @postmapping and @requestmapping, with actual combat code (all)
- Taylor series fast Fourier transform (FFT)
- 【mysql】触发器
- Comprehensive evaluation and recommendation of the most comprehensive knowledge base management tools in the whole network: flowus, baklib, jiandaoyun, ones wiki, pingcode, seed, mebox, Yifang cloud,
- SAP UI5 框架的 manifest.json
- Notes - detailed steps of training, testing and verification of yolo-v4-tiny source code
- 硬件开发笔记(十): 硬件开发基本流程,制作一个USB转RS232的模块(九):创建CH340G/MAX232封装库sop-16并关联原理图元器件
- OneNote 深度评测:使用资源、插件、模版
猜你喜欢
3D face reconstruction: from basic knowledge to recognition / reconstruction methods!
Comprehensive evaluation and recommendation of the most comprehensive knowledge base management tools in the whole network: flowus, baklib, jiandaoyun, ones wiki, pingcode, seed, mebox, Yifang cloud,
039. (2.8) thoughts in the ward
Is it profitable to host an Olympic Games?
【mysql】触发器
2022菲尔兹奖揭晓!首位韩裔许埈珥上榜,四位80后得奖,乌克兰女数学家成史上唯二获奖女性
ICML 2022 | Flowformer: 任务通用的线性复杂度Transformer
1_ Introduction to go language
嵌入式开发的7大原罪
None of the strongest kings in the monitoring industry!
随机推荐
Math symbols in lists
The use method of string is startwith () - start with XX, endswith () - end with XX, trim () - delete spaces at both ends
R language visualizes the relationship between more than two classification (category) variables, uses mosaic function in VCD package to create mosaic plots, and visualizes the relationship between tw
Vim 基本配置和经常使用的命令
3D face reconstruction: from basic knowledge to recognition / reconstruction methods!
Reference frame generation based on deep learning
JS operation DOM element (I) -- six ways to obtain DOM nodes
Spark SQL chasing Wife Series (initial understanding)
Yyds dry goods count re comb this of arrow function
数据湖(八):Iceberg数据存储格式
Nodejs tutorial expressjs article quick start
039. (2.8) thoughts in the ward
ICML 2022 | flowformer: task generic linear complexity transformer
[MySQL] basic use of cursor
#yyds干货盘点#重新梳理箭头函数的this
js中,字符串和数组互转(一)——字符串转为数组的方法
el-table表格——获取单击的是第几行和第几列 & 表格排序之el-table与sort-change、el-table-column与sort-method & 清除排序-clearSort
New database, multidimensional table platform inventory note, flowus, airtable, seatable, Vig table Vika, Feishu multidimensional table, heipayun, Zhixin information, YuQue
Select data Column subset in table R [duplicate] - select subset of columns in data table R [duplicate]
document.write()的用法-写入文本——修改样式、位置控制