Skip to main content

submit url to baidu.

Project description

baidu-url-submit

Introduction

This tool help you to submit your url to baidu.

Only for python3.

The code is simple, I also use it to learn how to package python projects.

About the detail of submit url to baidu, you can visit: https://ziyuan.baidu.com/

Install

pip install baidu-url-submit

Demo

import baidu_url_submit

site = "blog.wansho.cn" # your site
token = "xxx" # from https://ziyuan.baidu.com/
urls = [
        "http://blog.wansho.cn/opinion/notes.html",
        "http://blog.wansho.cn/reading/movie-top.html",
    ] # urls to submit


result = 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

LICENSE

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

baidu-url-submit-1.0.0.tar.gz (2.2 kB view details)

Uploaded Source

Built Distribution

baidu_url_submit-1.0.0-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file baidu-url-submit-1.0.0.tar.gz.

File metadata

  • Download URL: baidu-url-submit-1.0.0.tar.gz
  • Upload date:
  • Size: 2.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for baidu-url-submit-1.0.0.tar.gz
Algorithm Hash digest
SHA256 a1ed6eee2c76714ce376cfe746bbd4e626be9b79bc6765d5ad1a93e17a76079a
MD5 9a13992a15aa5e3283fe34a0dced014e
BLAKE2b-256 128f4c051002564b88eb0854265c0113188f95ea9b6b83b32fb4adf9c8827d67

See more details on using hashes here.

File details

Details for the file baidu_url_submit-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: baidu_url_submit-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for baidu_url_submit-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f76dc1851d6698cdf744d4c96422a0371e9f8a81a4215cd79de55222949d6d3d
MD5 ffe0ec42441a2c77a7d5458b3d88f8b7
BLAKE2b-256 544606a719d354779a69e440b987ec61e04a41c196a33cb8c5bdca77f93795ee

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page