Async SDK for OVRL on Stellar/Soroban with bootstrap, quoting, monitoring, and contract helpers
Project description
OVRL SDK
Production-ready, async-first helpers for working with the OVRL token (OVRL, issuer GBZH36ATUXJZKFRMQTAAW42MWNM34SOA4N6E7DQ62V3G5NVITC3QOVRL). This SDK layers ergonomic account management, payment flows, quoting, and Soroban integrations on top of stellar-sdk[aiohttp] so application developers can focus on product logic instead of Horizon plumbing.
Audience: Stellar/OVRL integrators who need a well-documented Python client with predictable behavior, Sphinx-ready docstrings, and runnable examples.
Table of contents
- Highlights
- Installation
- Quickstart
- Configuration & environment
- Usage recipes
- Examples
- Documentation (Sphinx)
- Testing & quality
- Support & contributions
- License
Highlights
- 🪙 Token-aware primitives – constants, trustline helpers, and payment builders hard-code the correct OVRL asset + issuer metadata.
- ⚙️ Async Horizon client – powered by
stellar-sdk[aiohttp]with sensible defaults for rate-friendly batching. - ✨ Soroban coverage – invoke contracts, approve allowances, mint/burn, and inspect return values with
SorobanToolkit/SorobanTokenClient. - 🚀 Network presets – ready-made configs for Public, Testnet, and Futurenet, complete with Friendbot URLs where available.
- Operational insight – inspect fee percentiles, circulating supply, top holders, and stream live payment events.
- 💱 Quoting & swaps – convert between USD and OVRL, fetch strict send/receive paths, and submit swap transactions—all via typed helpers.
- 🧰 Developer ergonomics – Sphinx-friendly docstrings, runnable example scripts, and a small helper module for common env setup.
Installation
pip install ovrl-sdk
For contributors or CI environments that need the test stack:
pip install -e .[dev]
Requires Python 3.10+. The package automatically installs
stellar-sdk[aiohttp].
Quickstart
import asyncio
from ovrl_sdk import NetworkPresets, OVRLClient
async def main() -> None:
client = OVRLClient(network=NetworkPresets.TESTNET)
await client.bootstrap_account(account_secret="SC...YOUR_SECRET...")
await client.pay(
source_secret="SC...YOUR_SECRET...",
destination="GD...RECIPIENT...",
amount="5",
memo="First OVRL transfer",
)
summary = await client.summarize_payments("GD...RECIPIENT...", max_pages=2)
print("Recent count:", summary.record_count, "total amount:", summary.total_amount)
price = await client.quote_ovrl_price()
print("Spot price per OVRL:", price)
await client.close()
if __name__ == "__main__":
asyncio.run(main())
Configuration & environment
Many workflows key off the following environment variables. These are optional unless otherwise noted, but setting them keeps example scripts and CI jobs consistent.
| Variable | Required | Description |
|---|---|---|
OVRL_SECRET |
✅ | Primary secret key used for signing transactions and Soroban invocations. |
OVRL_DESTINATION |
✅ for payment demos | Recipient address for payment/swap/allowance examples. |
OVRL_FUNDING_SECRET |
Optional | Alternate sponsor when Friendbot is unavailable. |
OVRL_CONTRACT_ID |
Soroban-only | Token contract ID consumed by SorobanTokenClient. |
OVRL_SPENDER |
Optional | Account to approve when testing allowances (defaults to destination). |
OVRL_WATCH_ACCOUNT |
Optional | Account watched by monitoring scripts; falls back to OVRL_SECRET's public key. |
OVRL_NETWORK |
Optional | PUBLIC, TESTNET, or FUTURENET (defaults to TESTNET). |
OVRL_EXECUTE_SWAPS |
Optional | Set to 1 to actually submit swap transactions in the quotes example. |
Use examples/shared.py for a ready-made resolver that enforces these expectations.
Usage recipes
- Account bootstrap:
OVRLClient.bootstrap_accountfunds an account (Friendbot or sponsor), creates the trustline, and returns anAccountStatusstruct summarizing what changed. - Payments & batching:
payemits single transfers;batch_paychunks up to 100 ops/tx and normalizes heterogeneous payloads into typedPaymentIntents. - Payment history: Use
list_payments_page+ cursors for pagination orpayment_watcherto poll and stream new records. - Quoting & conversions:
quote_ovrl_price,ovrl_to_usd,usd_to_ovrl, andquote_paths_*wrap strict send/receive path endpoints and return normalizedPathQuotes. - Swaps:
swap_from_ovrlandswap_to_ovrlautomatically discover intermediary assets and build strict send/receive operations. - Soroban token flows:
SorobanTokenClientwires balances, transfers, approvals, mint/burn, and allowance inspection into single-call helpers using the sharedSorobanToolkit.
Every public API features Sphinx field-list docstrings (:param, :returns:, :raises:) so IDEs and doc tooling surface the same guidance.
Examples
Richer, end-to-end scenarios live in examples/. Each script is runnable on its own:
| Script | Scenario |
|---|---|
bootstrap_trustline.py |
Ensure an account exists, is funded, and holds the OVRL trustline. |
payments_and_batches.py |
Send individual payments, chunk batch payouts, and summarize history. |
quotes_and_swaps.py |
Quote conversions and optionally execute swap transactions (opt-in via OVRL_EXECUTE_SWAPS). |
monitoring_and_reporting.py |
Report circulating supply, fee percentiles, and watch live payments for a target account. |
soroban_token_flow.py |
Exercise the Soroban token contract for balances, approvals, and transfers. |
Example invocation (PowerShell):
$env:OVRL_SECRET="SC..."; $env:OVRL_DESTINATION="GD..."; python examples\payments_and_batches.py
Documentation (Sphinx)
Autogenerated API docs live under docs/ and are built with Sphinx. We ship a ready-to-use configuration (docs/conf.py) that enables autodoc, autosummary, and napoleon, mocks heavy dependencies (stellar_sdk, aiohttp), and pulls the code directly from the working tree.
Build HTML docs locally:
sphinx-build -b html docs docs\_build\html
The resulting site (in docs/_build/html/index.html) can be published to GitHub Pages or uploaded to any static host.
Testing & quality
- Run automated tests:
pytest - Keep docstrings Sphinx-compatible (
:param/:returns:/:raises:) and update relevant example scripts when you change an API surface. - The repository follows standard
black/isortformatting conventions—configure your editor to respect 4-space indents and trailing commas.
Support & contributions
- File bugs or feature requests via GitHub Issues (include reproduction steps + network info).
- Pull Requests should include: tests (when applicable), updated docstrings, and—if the change touches user flows—an example refresh.
- For high-severity security disclosures, contact the maintainers privately before opening a public issue.
License
Licensed under the Apache License 2.0. You are free to use the SDK in commercial or open-source projects, but derivative works must retain the original copyright and license notices.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ovrl_sdk-0.1.0.tar.gz.
File metadata
- Download URL: ovrl_sdk-0.1.0.tar.gz
- Upload date:
- Size: 40.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
72e0fd5cc23bcf920c86c5c5d13e0036242e53ee3874d7a1695e531c6d87eb51
|
|
| MD5 |
00fb1f2f173c855e5e0525b97993d8e8
|
|
| BLAKE2b-256 |
1944e320bab38bc075d3edb110bbb7c91a1fdaf90c0295a35b4871290d3c97e9
|
Provenance
The following attestation bundles were made for ovrl_sdk-0.1.0.tar.gz:
Publisher:
publish.yml on Overlumens/ovrl-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ovrl_sdk-0.1.0.tar.gz -
Subject digest:
72e0fd5cc23bcf920c86c5c5d13e0036242e53ee3874d7a1695e531c6d87eb51 - Sigstore transparency entry: 705514197
- Sigstore integration time:
-
Permalink:
Overlumens/ovrl-sdk@36f9cc920fa4673a6630778a171b2557702e88cd -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Overlumens
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@36f9cc920fa4673a6630778a171b2557702e88cd -
Trigger Event:
release
-
Statement type:
File details
Details for the file ovrl_sdk-0.1.0-py3-none-any.whl.
File metadata
- Download URL: ovrl_sdk-0.1.0-py3-none-any.whl
- Upload date:
- Size: 29.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ce0ad30dd4f94afabeba4fedb27ae3b5445871880c3a5d916d92fe3f305b1b2f
|
|
| MD5 |
c0b4796e0d8f0bb3d7f8a74cfaefe698
|
|
| BLAKE2b-256 |
4b00614a7c379a1d2accbc99a55df6ab13a50e6a00c87bb3302ed1b748b9020d
|
Provenance
The following attestation bundles were made for ovrl_sdk-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on Overlumens/ovrl-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ovrl_sdk-0.1.0-py3-none-any.whl -
Subject digest:
ce0ad30dd4f94afabeba4fedb27ae3b5445871880c3a5d916d92fe3f305b1b2f - Sigstore transparency entry: 705514211
- Sigstore integration time:
-
Permalink:
Overlumens/ovrl-sdk@36f9cc920fa4673a6630778a171b2557702e88cd -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Overlumens
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@36f9cc920fa4673a6630778a171b2557702e88cd -
Trigger Event:
release
-
Statement type: