Skip to main content

Tianyancha SDK for python, which based on https://open.tianyancha.com/

Project description

tianyancha - 天眼查

Tianyancha SDK for python, which based on https://open.tianyancha.com/

install

pip install tianyancha

Usage

All API supported! please visit Supported methods for more information!

from tianyancha import Tianyancha
token = "TOKEN"
word = "北京百度网讯科技有限公司"

tyc = Tianyancha(token)
ret = tyc.search(word)
{
  "error_code": 0,
  "reason": "ok",
  "result": {
    "items": [
      {
        "regNumber": "110108002734659",
        "regStatus": "在业",
        "creditCode": "91110000802100433B",
        "estiblishTime": "2001-06-05 00:00:00.0",
        "regCapital": "1342128万人民币",
        "companyType": 1,
        "name": "<em>北京百度网讯科技有限公司</em>",
        "id": 22822,
        "orgNumber": "802100433",
        "type": 1,
        "base": "北京",
        "legalPersonName": "梁志祥"
      },
      {
        "regNumber": "440106000623068",
        "regStatus": "在业",
        "creditCode": "91440101675657502F",
        "estiblishTime": "2008-05-20 00:00:00.0",
        "regCapital": "-",
        "companyType": 1,
        "name": "<em>北京百度网讯科技有限公司</em>广州分公司",
        "id": 139572971,
        "orgNumber": "675657502",
        "type": 1,
        "base": "广东",
        "legalPersonName": "沈抖"
      },
      ...
    ],
    "total": 56
  }
}

More usages

ret = tyc.get('search/2.0', {'word': word})

Tests

just run pytest

Changelog

  • 2020-12-11 0.1.2 path bugfix and generate documents for all methods
  • 2020-12-11 0.1.1 support all methods
  • 2020-12-11 0.1.0 support basic search for tianyancha

Refs

Official API Document: https://open.tianyancha.com/api_list

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

tianyancha-0.1.2.tar.gz (4.3 kB view details)

Uploaded Source

Built Distributions

tianyancha-0.1.2-py3.7.egg (34.9 kB view details)

Uploaded Source

tianyancha-0.1.2-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file tianyancha-0.1.2.tar.gz.

File metadata

  • Download URL: tianyancha-0.1.2.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.5

File hashes

Hashes for tianyancha-0.1.2.tar.gz
Algorithm Hash digest
SHA256 ba8c4564ab87294c94d7b9ccc0b015117fdfd5e10370dd6e6cd0a2312af7f9d7
MD5 f53bbb13f49b4efc2204eee9d9051611
BLAKE2b-256 5aed6e39e4c8102ebe7f14ba4d829f4c9d1b399ea719ed3d6a7a24bdf9b1a405

See more details on using hashes here.

File details

Details for the file tianyancha-0.1.2-py3.7.egg.

File metadata

  • Download URL: tianyancha-0.1.2-py3.7.egg
  • Upload date:
  • Size: 34.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.5

File hashes

Hashes for tianyancha-0.1.2-py3.7.egg
Algorithm Hash digest
SHA256 9594fcf4f0b0fe233d236980a8934f862850fa39e416dfaf7fb39e1ce6c3047b
MD5 29d2d36b2c7bfb98d366b900fe4011e3
BLAKE2b-256 1ce4d6bb69431b1342e3dfe2d5fa486bb6b4abbb7e553de6704dfaa97bc10db2

See more details on using hashes here.

File details

Details for the file tianyancha-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: tianyancha-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.5

File hashes

Hashes for tianyancha-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ddbc4f84239e6ecf5fa11b4787ae9c5ce1a0bc2e602282e06b0d13ca37b22f08
MD5 fad9bc83d9e513bb16e55cf09f93b453
BLAKE2b-256 0a6254d4578831147dc1e8d958a3f3f119f2e3af710ca10c4d23445685d5af66

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