{"id":24509058,"url":"https://github.com/dgisolfi/rotatingproxybot","last_synced_at":"2025-10-08T17:46:06.540Z","repository":{"id":57462714,"uuid":"164777927","full_name":"dgisolfi/RotatingProxyBot","owner":"dgisolfi","description":"A Bot that uses a Rotating Proxy to simulate many clients making a request to a single server","archived":false,"fork":false,"pushed_at":"2019-01-16T16:55:58.000Z","size":20,"stargazers_count":2,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-22T00:19:17.028Z","etag":null,"topics":["bot","rotating-proxy"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/RotatingProxyBot/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dgisolfi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-09T03:12:54.000Z","updated_at":"2021-11-23T15:57:04.000Z","dependencies_parsed_at":"2022-09-05T17:21:51.205Z","dependency_job_id":null,"html_url":"https://github.com/dgisolfi/RotatingProxyBot","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgisolfi%2FRotatingProxyBot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgisolfi%2FRotatingProxyBot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgisolfi%2FRotatingProxyBot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgisolfi%2FRotatingProxyBot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dgisolfi","download_url":"https://codeload.github.com/dgisolfi/RotatingProxyBot/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243708464,"owners_count":20334841,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bot","rotating-proxy"],"created_at":"2025-01-22T00:19:12.418Z","updated_at":"2025-10-08T17:46:01.519Z","avatar_url":"https://github.com/dgisolfi.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RotatingProxyBot [![RotatingProxyBot version](https://img.shields.io/pypi/v/RotatingProxyBot.svg)](https://pypi.org/project/RotatingProxyBot)\nA Bot that uses a Rotating Proxy to simulate many clients making a request to a single server\n\n### Author\n\n**Daniel Gisolfi** - *All current work* - [dgisolfi](https://github.com/dgisolfi)\n\n## Usage\n\n```python\n#!/usr/bin/python3\nfrom RotatingProxyBot import ProxyBot\n\n# Create new custom bot\nbot = ProxyBot(\n    address='IP OR URL',\n    method='POST'\n    desired_reqs=10,\n    reqs_per_int=2,\n    wait_time=60 # 1min\n)\n# Start Submiting and rotating proxies\nbot.enable()\n```\n\n## Building a list of Proxies\n\nThe bot will need a list of proxies to use for making requests, it can use either an API to retrieve proxies or a file to import them from.\n\n### Proxies from an API\n\nBy default, the bot will retrieve a few thousand proxies from an [API](https://www.proxy-list.download/). To use a custom API tell the bot what address to reach the API at by passing in the following argument when creating a new instance `proxy_api='http://api.com'`.\n\n### Proxies from a File\n\nTo use a custom file of proxies rather than the default API, pass in the following argument to the bot constructor `proxy_file=filename.txt`\nFor the bot to be able to import the list of proxies, the file should have the following structure:\n\n```txt\n0.0.0.0:80\n1.1.1.1:90\n2.2.2.2:20\n```\n\n## Methods\n\nThe following are some useful methods that are a part of the package\n\n### ProxyBot\n\n* **getRequest(proxy)** - if passed a specific proxy, this method will perform a`GET` request using the specified proxy to the address set in the creation of the bot. EX: `getRequest('0.0.0.0:80')`\n* **postRequest(proxy)** - if passed a specific proxy, this method will perform a `POST` request using the specified proxy to the address set in the creation of the bot. EX: `postRequest('0.0.0.0:80')`\n* **preformRotate()** - if called the bot will request a new proxy from the RotatingProxy class and perform the specified request to the specified address, returning the response element\n* **enable()** - if called will initiate the main loop of the bot, making the specified requests to the address using the set number of intervals and wait time\n* **disable()** - if called will shut down the main loop of the program and delete the bot\n\n### RotatingProxy\n\n* **buildProxyList()** - when called will contact the set API(or default one) to retrieve a list of  up to date proxies in which it can pull from to make requests\n* **importProxyList()** - will attempt to build a list of proxies from the file name provided.\n* **rotate()** - will return the 0th proxy in the list and add it to the used proxy list.\n\n## Additional Arguments for the Constructor\n\nThe following are keyword arguments that can be passed into the constructor of the ProxyBot Class.\n\n* **id** - Assigns the instance of the ProxyBot with the given numeric ID\n\n  Example: `RotatingProxyBot(id=1)`\n\n* **address** - the IP or URL for the bot to contact, will default to a tester API\n\n  Example: `RotatingProxyBot(address='0.0.0.0')`\n\n* **method** - The request method to be used. Only `GET` and `POST` supported. The default is `GET`\n  Example: `RotatingProxyBot(method='POST')`\n\n* **params** - Parameters to be passed with the request, works with all request methods \n  Example: `RotatingProxyBot(params={'example':'test'})`\n\n* **desired_reqs** - Desired number of requests to be completed\n\n  Example: `RotatingProxyBot(desired_reqs=10)`\n\n* **keep_alive** - A boolean allow the bot to continue to make requests forever\n\n  *if set to `True` dont set `desired_reqs`*\n  Example: `RotatingProxyBot(keep_alive=True)`\n\n* **reqs_per_int** - Requests Per Interval, number of requests to be completed before waiting. This will prevent the server from being DOSed\n  Example: `RotatingProxyBot(reqs_per_int=2)`\n\n* **wait_time** - Amount of time in Seconds to wait until the next interval of requests\n  Example: `RotatingProxyBot(wait_time=600)`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdgisolfi%2Frotatingproxybot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdgisolfi%2Frotatingproxybot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdgisolfi%2Frotatingproxybot/lists"}