Name | poe-async-client JSON |
Version |
0.0.6
JSON |
| download |
home_page | None |
Summary | Async client to run simultaneous requests against the Path of Exile API without triggering rate limiting |
upload_time | 2024-10-07 21:02:30 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.11 |
license | None |
keywords |
path of exile
poe
api
client
ggg
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# PoEClient
Async client to run simultaneous requests against the Path of Exile API without triggering rate limiting
# Installation
```
pip install poe-async-client
```
# Example usage
```python
import asyncio
from poe_async_client.poe_client import PoEClient
async def fetch_stash_changes_simultaneously():
client = PoEClient(
max_requests_per_second=5,
user_agent="OAuth myapp/1.0.0 (Contact: Liberatorist@gmail.com)"
)
async with client:
token_response = await client.get_client_credentials(
client_id="myapp",
client_secret="super secret",
scope="service:psapi"
)
token = token_response["access_token"]
simultaneous_requests = [
client.get_public_stashes(token=token)
for _ in range(10)
]
responses = await asyncio.gather(*simultaneous_requests)
```
Raw data
{
"_id": null,
"home_page": null,
"name": "poe-async-client",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.11",
"maintainer_email": null,
"keywords": "Path of Exile, PoE, API, Client, GGG",
"author": null,
"author_email": "Liberatorist <Liberatorist@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/24/fc/28a880e100abb3527e31588cbadd14ea1f315a7823e227b9771d7d527ea5/poe_async_client-0.0.6.tar.gz",
"platform": null,
"description": "# PoEClient\n\nAsync client to run simultaneous requests against the Path of Exile API without triggering rate limiting\n\n# Installation\n\n```\npip install poe-async-client\n```\n\n# Example usage\n\n```python\nimport asyncio\nfrom poe_async_client.poe_client import PoEClient\n\nasync def fetch_stash_changes_simultaneously():\n client = PoEClient(\n max_requests_per_second=5,\n user_agent=\"OAuth myapp/1.0.0 (Contact: Liberatorist@gmail.com)\"\n )\n async with client:\n token_response = await client.get_client_credentials(\n client_id=\"myapp\",\n client_secret=\"super secret\",\n scope=\"service:psapi\"\n )\n token = token_response[\"access_token\"]\n\n simultaneous_requests = [\n client.get_public_stashes(token=token)\n for _ in range(10)\n ]\n\n responses = await asyncio.gather(*simultaneous_requests)\n\n```\n",
"bugtrack_url": null,
"license": null,
"summary": "Async client to run simultaneous requests against the Path of Exile API without triggering rate limiting",
"version": "0.0.6",
"project_urls": {
"Homepage": "https://github.com/Liberatorist/PoEClient",
"Issues": "https://github.com/Liberatorist/PoEClient/issues"
},
"split_keywords": [
"path of exile",
" poe",
" api",
" client",
" ggg"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "be5235a993885cf104621661cfbbc12cf36a9956d8b468952f53692c7de6b2b8",
"md5": "5b427ef4159420a64dc100822d3e1073",
"sha256": "0f5018053b5f8e6a2f13d426955b5cabfb902fb1b77992e8ed02155089d230da"
},
"downloads": -1,
"filename": "poe_async_client-0.0.6-py3-none-any.whl",
"has_sig": false,
"md5_digest": "5b427ef4159420a64dc100822d3e1073",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.11",
"size": 10958,
"upload_time": "2024-10-07T21:02:29",
"upload_time_iso_8601": "2024-10-07T21:02:29.654847Z",
"url": "https://files.pythonhosted.org/packages/be/52/35a993885cf104621661cfbbc12cf36a9956d8b468952f53692c7de6b2b8/poe_async_client-0.0.6-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "24fc28a880e100abb3527e31588cbadd14ea1f315a7823e227b9771d7d527ea5",
"md5": "c7171546800b7007440bdf94f0e91149",
"sha256": "9298612c472dcdb5974d14fc7dea9baca389766e71b7599fc7065b9ed459be76"
},
"downloads": -1,
"filename": "poe_async_client-0.0.6.tar.gz",
"has_sig": false,
"md5_digest": "c7171546800b7007440bdf94f0e91149",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.11",
"size": 9477,
"upload_time": "2024-10-07T21:02:30",
"upload_time_iso_8601": "2024-10-07T21:02:30.965070Z",
"url": "https://files.pythonhosted.org/packages/24/fc/28a880e100abb3527e31588cbadd14ea1f315a7823e227b9771d7d527ea5/poe_async_client-0.0.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-07 21:02:30",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Liberatorist",
"github_project": "PoEClient",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "poe-async-client"
}