stigg-api-client-v2
This library provides a Python wrapper to Stigg's GraphQL API based on the operations that are in use by the Stigg's Node.js SDK.
The ariadne-codegen code generator is used to generate a typesafe Python API client.
Documentation
TBD
Installation
pip install stigg-api-client-v2
Usage
Initialize the client:
import os
from stigg import Stigg
api_key = os.environ.get("STIGG_SERVER_API_KEY")
client = Stigg.create_async_client(api_key)
Provision a customer
import os
from stigg import Stigg
from stigg.generated import ProvisionCustomerInput
api_key = os.environ.get("STIGG_SERVER_API_KEY")
client = Stigg.create_async_client(api_key)
customer_input = ProvisionCustomerInput(
**{
"customer_id": "1661115567186116608", # mandatory, everything else is optional
"name": "Acme",
"email": "billing@acme.com",
"additional_meta_data": {"key": "value"},
"subscription_params": {"plan_id": "plan-acme-free"},
}
)
result = await client.provision_customer(customer_input)
print(result.provision_customer.customer)
Get a customer by ID
import os
from stigg import Stigg
from stigg.generated import GetCustomerByRefIdInput
api_key = os.environ.get("STIGG_SERVER_API_KEY")
client = Stigg.create_async_client(api_key)
result = await client.get_customer_by_id(GetCustomerByRefIdInput(**{"customer_id": "1661115567186116608"}))
print(result.get_customer_by_ref_id.name)
Metadata
Release files for stigg-api-client-v2 6.26.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| stigg_api_client_v2-6.26.0.tar.gz | 108.4 kB | Without provenance | Details for stigg_api_client_v2-6.26.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| stigg_api_client_v2-6.26.0-py3-none-any.whl | Python 3 | none | any | Details for stigg_api_client_v2-6.26.0-py3-none-any.whl |
Total release size: 240.6 kB
Release files / stigg_api_client_v2-6.26.0.tar.gz
| Download URL | stigg_api_client_v2-6.26.0.tar.gz |
|---|---|
| Size | 108.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
feccad624577a5996bd6254aaa34880442a46607a5d04a43954e3be632b8ce0a
|
|
BLAKE2b-256 checksum How to use checksums |
56e5b78f9717aedadd9fc104f57ded00a938417e8c9fcb8f7a39561449f4492c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.0 CPython/3.10.12 Linux/6.6.141
|
Release files / stigg_api_client_v2-6.26.0-py3-none-any.whl
| Download URL | stigg_api_client_v2-6.26.0-py3-none-any.whl |
|---|---|
| Size | 132.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
566249ca3cb045dab103a278fd8dee740d790c8199683a054a7c2e14d4e9cf32
|
|
BLAKE2b-256 checksum How to use checksums |
470a679c0adeb9eca12f8d7a849298cf714af474bf4b3386617cd40ba7888b81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.0 CPython/3.10.12 Linux/6.6.141
|
Security for stigg-api-client-v2 6.26.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.