Python library to interact with switcheo APIs
Project description
pyswitcheo is a simple python client to interact with Switcheo Decentralized Exchange
Current Stable Version
0.1.0
Installation
pip
$ pip install pyswitcheo
Getting Started
Client example
import json
from http import HTTPStatus
from pyswitcheo.api import SwitcheoApi
if __name__ == '__main__':
client = SwitcheoApi(base_url="https://test-api.switcheo.network")
resp = client.list_contracts()
if resp.status_code == HTTPStatus.OK:
print(json.loads(resp.text.encode("UTF-8")))
More examples are located at examples
Development Installation
This project uses pipenv for python environment management.
Download/Install pipenv like this pip install --user pipenv
Clone the project.
Inside the project directory run pipenv install.
This will create a python virtualenv which can be activated using pipenv shell.
Now install the application in editable mode and you are ready to start development
$ pip install -e .
Test
To run the tests:
make test
Documentation theme is highly inspired by Aiohttp.
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
File details
Details for the file pyswitcheo-0.1.0.tar.gz
.
File metadata
- Download URL: pyswitcheo-0.1.0.tar.gz
- Upload date:
- Size: 21.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 71a4c364cba7fd663a0f07a231f04be4f5a9cb746ed70e58764b8642f81e6568 |
|
MD5 | 254510667b1f1d63b005b39dbf56e97c |
|
BLAKE2b-256 | e8a55ffe0ad46580e2cbb859bd178780f6931af22139a9e5b85951a88004db35 |
File details
Details for the file pyswitcheo-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: pyswitcheo-0.1.0-py3-none-any.whl
- Upload date:
- Size: 33.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c185ef4cad81770e938097b77195c054b09f8b8044ed0d1912b83dbfce1499f |
|
MD5 | 4e5946ec15d12a850724ae06d789bc97 |
|
BLAKE2b-256 | 9c4873d893f4b21def6558f8efcb2c7e3d70abbcd66a223c8a3bbc5473a9f5f7 |