Py文件
import time import requests url = "http://static.cninfo.com.cn/finalpage/2021-04-17/1209711009.PDF" results = requests.post(req_url,json=yaml_case['body'],headers=headers, verify=False) if results.status_code == 200: with open(r"E:\pdf文档\%s.pdf" % name, "wb") as code: code.write(results.content) time.sleep(5) # 防止访问速度过快,可以灵活的调整时间
标签:code,url,results,接口,headers,import,PDF,下载 From: https://www.cnblogs.com/brf-test/p/16847569.html