Python SDK for Justice Augment
Project description
Justice Augment Python SDK
Python SDK for Justice Augment Project.
Development Setup
Set these local environment variables:
IAM_CLIENT_ID
- IAM client idIAM_CLIENT_SECRET
- IAM client secretADMIN_USERNAME
- (optional) user/admin usernameADMIN_PASSWORD
- (optional) user/admin password
Then run:
$ make build
It will create a docker image with env variables interpolated in tox.ini
file for testing.
To test it, run this command:
$ make test
After that, you can cleanup the working directory with this command:
$ make clean
How to use
To use this SDK you can install it from pip with this command:
$ pip install justice-augment-python-sdk
Alternatively, you can add justice-augment-python-sdk
as dependency in requirements.txt
.
Then you install it with this command:
$ pip install -r requirements.txt
After that you can import the package, and use it like this:
import os
from justice import Justice
endpoint = "https://demo.accelbyte.io"
namespace = 'accelbyte'
core = Justice(namespace, endpoint)
wallet_id = 'some-wallet-string-id'
resp = core.wallet.get_wallet(wallet_id)
my_wallet = resp.json()
print("Wallet balance: {0} {1}".format(my_wallet['balance'], my_wallet['currencyCode']))
Do not forget to set IAM_CLIENT_ID
and IAM_CLIENT_SECRET
in your local environment variables if you want to try it in your local machine.
Commit Message Guidelines
We use https://www.conventionalcommits.org/ as a guidelines to write commit message. You use this format to write your commit message:
<type>(optional scope): <description>
<BLANK LINE>
<optional-body>
<BLANK LINE>
<optional-footer>
Any line of the commit message cannot be longer than 100 characters!
Samples:
docs(changelog): update changelog to beta.5
fix(login): add the missing username field
We made login system without username field in our Database!
Type
Must be one of the following:
- build: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
- ci: Changes to our CI configuration files and scripts (example scopes: Circle, BrowserStack, SauceLabs)
- docs: Documentation only changes
- feat: A new feature
- fix: A bug fix
- perf: A code change that improves performance
- refactor: A code change that neither fixes a bug nor adds a feature
- test: Adding missing tests or correcting existing tests
- chore: Repository maintenance
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
Hashes for justice-augment-python-sdk-0.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 71c53e1d6566fe3fbd14b3ff97a0a8666096876b7df4118b5e85bddbf103c18a |
|
MD5 | 83271a0ecf0b7af3e536d9835622bb72 |
|
BLAKE2b-256 | 437a6c93006fb6beed0a99939df7eb15d7f06917d2789ff8e6ac4ebca528b6ac |
Hashes for justice_augment_python_sdk-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a5dc845739d50e3344d2e220d80fce2ff759e8418c0fdcbbed08227be8c934c1 |
|
MD5 | 6849a1bd3bf51b0b4aabf447ae6e4ff3 |
|
BLAKE2b-256 | 63735fbeef074cc6978e076a568455c549d7666b89f6f9fe789f8009fe7ba54d |