Scrapy Downloader Middleware that helps to integrate Scrapy with Nimble Web API.
Project description
Scrapy Nimble Middleware
scrapy-nimble
is a Scrapy Downloader Middleware that helps to integrate
Scrapy with Nimble Web API.
Install
You can install scrapy-nimble
as a regular Python package from
PyPI using:
pip install scrapy-nimble
Configuration
-
If you don't have it yet, open an account with Nimble.
-
Provide your credentials and enable the middleware through Scrapy settings.
# settings.py NIMBLE_ENABLED = True NIMBLE_USERNAME = "username" NIMBLE_PASSWORD = "password"
-
Add the downloader middleware to your
DOWNLOADER_MIDDLEWARES
Scrapy setting.# settings.py DOWNLOADER_MIDDLEWARES = { "scrapy_nimble.middlewares.NimbleWebApiMiddleware": 570, }
If you have
scrapy.downloadermiddlewares.httpcompression.HttpCompressionMiddleware
enabled (it is enabled by default in DOWNLOADER_MIDDLEWARES_BASE setting with default order equal to 590), configurescrapy-nimble
middleware before it.
Usage
Once the downloader middleware is properly configured, every request goes through the Nimble's Web API. There is no need to change anything in your spider's code.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for scrapy_nimble-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | caae0b08b868f94997d2381cd21e45703285b51237e7ac81c45fc515c25f4b55 |
|
MD5 | d034bf8b9437185cc2180a181891c9b3 |
|
BLAKE2b-256 | 7f977b24b7cf556953281e945e899983219b65826032dc6d2fc93c35a50072c9 |