Skip to main content

Python SDK for elcrawl

Project description

SDK for Python

The SDK for Python contains two parts:

  1. CLI Tool
  2. Utility Tools

CLI Tool

The CLI Tool is mainly designed for those who are more comfortable using command line tools.

The installation of the CLI Tool is:pip install elcrawlsdk

Then, you can use the elcrawl command in the command prompt. elcrawl --help

Utility Tools

Utility tools mainly provide some helper methods to make it easier for you to integrate your spiders into platform, e.g. saving results.

Scrapy Integration

In settings.py in your Scrapy project, find the variable named ITEM_PIPELINES (a dict variable). Add content below.

ITEM_PIPELINES = {
    'elcrawl.pipelines.ElcrawlMongoPipeline': 888,
}

Then, start the Scrapy spider. After it's done, you should be able to see scraped results in Task Detail -> Result

General Python Spider Integration

Please add below content to your spider files to save results.

# import result saving method
from elcrawl import save_item

# this is a result record, must be dict type
result = {'name': 'elcrawl'}

# call result saving method
save_item(result)

Then, start the spider. After it's done, you should be able to see scraped results in Task Detail -> Result

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

elcrawlsdk-1.0.0.tar.gz (10.7 kB view details)

Uploaded Source

Built Distribution

elcrawlsdk-1.0.0-py3-none-any.whl (13.8 kB view details)

Uploaded Python 3

File details

Details for the file elcrawlsdk-1.0.0.tar.gz.

File metadata

  • Download URL: elcrawlsdk-1.0.0.tar.gz
  • Upload date:
  • Size: 10.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.2

File hashes

Hashes for elcrawlsdk-1.0.0.tar.gz
Algorithm Hash digest
SHA256 79b6faec732c18e0bf1977f51848ad1405900d867e6842bfb9ce92357783eb92
MD5 9cc3f996ab7fa86d6594c8091d6d99de
BLAKE2b-256 addc60281a0eb8464e62d408040bc360ff89ec33d136661da37ed5a9b7e1c75f

See more details on using hashes here.

File details

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

File metadata

  • Download URL: elcrawlsdk-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 13.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.2

File hashes

Hashes for elcrawlsdk-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4112d1a693f43655eef80593d926e5d8f09d9c5f58af9d4da66cf18f7ac3cf05
MD5 a770800028e4546f57fc95c10f4bf805
BLAKE2b-256 f3a1f0b28044173714057aa9693aed0ea357f66a64a94c946b7f5447df922562

See more details on using hashes here.

Supported by

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