scrapy / scrapyd-client

Command line client for Scrapyd server
BSD 3-Clause "New" or "Revised" License
770 stars 146 forks source link

Add a client for python #120

Closed mxdev88 closed 1 year ago

mxdev88 commented 1 year ago

I would like to access a scrapyd instance from within python code directly.

I would propose something like below:

from scrapyd_client import ScrapydClient

client = ScrapydClient(url='http://localhost:6800')

client.projects()

The API would expose the commands already implemented within scrapyd-client. scrapyd-client already has most of the code necessary to accomplish this with little effort. most of it would be wrapper around lib.

Does it make sense? If so, happy to contribute a PR.

jpmckinney commented 1 year ago

Makes sense!