Guild Wars 2 API Python Wrapper
Project description
Guild Wars 2 API Python Wrapper
Installation
- Pre-requisites: Python >= 3.6
- Install the package from PyPi directly:
pip install gw2apy
Quickstart
- Create a client:
from gw2apy.client import Client
client = Client()
You can specify an API key to access authenticated endpoints, such as bank content or wallet:
client = Client(api_key="YOUR_API_KEY")
- Create an endpoint, e.g. Items:
from gw2apy.endpoints import Items
items_endpoint = Items(client=client)
- Request data from the endpoint:
# Returns the list of ids for all available items.
items_ids = items_endpoint.endpoint()
# Return the item associated to an id.
item = items_endpoint.id(id=28445)
# Return a list of item given a list of ids.
items = items_endpoint.ids(ids=[28445, 12452])
# Return a list of all the items.
all_items = items_endpoint.all()
Credits
This package is inspired from:
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
gw2apy-0.0.2.tar.gz
(12.0 kB
view details)
Built Distribution
File details
Details for the file gw2apy-0.0.2.tar.gz
.
File metadata
- Download URL: gw2apy-0.0.2.tar.gz
- Upload date:
- Size: 12.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 28511bf1dff701b2098d02092ba75bb43b6adf67fc111cbb34fe0040d9725718 |
|
MD5 | 867cee5c03670dc5c20dcd751eca0996 |
|
BLAKE2b-256 | 9bf0aa6a26d1bbc87a5318bd58b3d793e194e1203691e99dc5020c4d5c4ddf29 |
File details
Details for the file gw2apy-0.0.2-py2.py3-none-any.whl
.
File metadata
- Download URL: gw2apy-0.0.2-py2.py3-none-any.whl
- Upload date:
- Size: 25.3 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3ccc4a6df0212e2b8d622c5b31e98b6a1acbb0cf74e4c49ff5786a622a128422 |
|
MD5 | 19937f73e56bd35dc165598bde9ca09b |
|
BLAKE2b-256 | 5f8ace368b100dac7a0c2b0e0e9a157b851f6e08bc24873aede0bdeab572faaf |