教程(暂无)完整代码# -*- coding : utf-8 -*- import requests import re import json import subprocess import os # 必须 "referer": "https://message.bilibili.com/" headers = { "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.90 Safari/537.36", "referer": "https://message.bilibili.com/" } def send_request(url): response = requests.get(url=url, headers=headers) return respo
获取B站up的全部视频aid、cid 代码比较乱,请轻喷import requests import json def get_json(UserUid): # UserUid = '2026561407' # up主主页url url_data = 'https://api.bilibili.com/x/space/acc/info?mid=' + UserUid + '&jsonp=jsonp' # 视频集合页url url_video = 'https://api.bilibili.com/x/space/arc/search?mid=' + UserUid + '&pn=1&ps=25&index=1&jsonp=jsonp' headers = {'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64)