Getting started

Installation

pip install ovrl-sdk

For local development:

pip install -e .[dev]

Configuration

Set these environment variables before running the examples or your own scripts.

Variable

Purpose

OVRL_SECRET

Primary secret key that signs transactions.

OVRL_DESTINATION

Destination account for payment flows.

OVRL_NETWORK

Optional; PUBLIC / TESTNET / FUTURENET.

OVRL_CONTRACT_ID

Soroban token contract identifier for advanced flows.

See examples/shared.py for a helper that validates the configuration and lazily loads Friendbot funding when available.

Bootstrap an account

 1"""Bootstrap an OVRL account and trustline, then inspect the resulting status."""
 2
 3from __future__ import annotations
 4
 5import asyncio
 6
 7from stellar_sdk import Keypair
 8
 9from examples.shared import optional_env, ovrl_client, require_env
10
11
12async def main() -> None:
13    """Ensure the caller account exists, is funded, and holds the OVRL trustline."""
14
15    secret = require_env("OVRL_SECRET")
16    funding_secret = optional_env("OVRL_FUNDING_SECRET")
17    keypair = Keypair.from_secret(secret)
18
19    async with ovrl_client() as client:
20        metadata = client.asset_metadata()
21        print(f"OVRL issuer: {metadata.issuer} | max supply: {metadata.max_supply}")
22
23        before = await client.inspect_account(keypair.public_key)
24        print(
25            "Before bootstrap -> exists=%s trustline=%s"
26            % (before.exists, before.has_trustline)
27        )
28
29        status = await client.bootstrap_account(
30            account_secret=secret,
31            funding_secret=funding_secret,
32        )
33        print(
34            "After bootstrap  -> exists=%s trustline=%s friendbot=%s"
35            % (status.exists, status.has_trustline, status.needs_friendbot)
36        )
37
38        if status.balance:
39            print(
40                f"OVRL balance: {status.balance.balance} / limit {status.balance.limit or 'unbounded'}"
41            )
42        else:
43            print("OVRL trustline created; balance 0.0")
44
45
46if __name__ == "__main__":
47    asyncio.run(main())

The script:

  1. Funds an account via Friendbot (or a sponsor secret).

  2. Establishes the OVRL trustline.

  3. Returns an AccountStatus summary with balances and trustline info.

Next steps

  • Browse the API reference reference for low-level helpers.

  • Explore examples/ for payments, quoting, monitoring, and Soroban flows.

  • Enable sphinx.ext.autodoc in your own docs to reuse these docstrings.