向百度提交网址。
baidu-url-submit的Python项目详细描述
百度网址提交
简介
这个工具帮助你提交你的网址百度。
只对Python3。
代码很简单,我还用它来学习如何打包python项目。
关于向百度提交URL的详细信息,您可以访问:https://ziyuan.baidu.com/
安装
pip install baidu-url-submit
演示
importbaidu_url_submitsite="blog.wansho.cn"# your sitetoken="xxx"# from https://ziyuan.baidu.com/urls=["http://blog.wansho.cn/opinion/notes.html","http://blog.wansho.cn/reading/movie-top.html",]# urls to submitresult=baidu_url_submit.submit(site,token,urls)# if result == 2, it means two url submit success.# if result < 2, it means some urls submit fail.# # The reason why submit fail:# 1. The submitted url is not the url of this site.# 2. invalid url