Prerequisites
Before deploying Vowena, ensure you have the following installed:
- Rust (latest stable) - rustup.rs
- wasm32 target -
rustup target add wasm32-unknown-unknown - Stellar CLI -
cargo install stellar-clior via Stellar docs - A funded Stellar account (testnet faucet or mainnet XLM for fees)
Build and Deploy
Build the WASM binary
Compile the Soroban smart contract to WebAssembly:This produces the optimized WASM binary at
target/wasm32v1-none/release/vowena.wasm.Deploy to the network
- Testnet
- Mainnet
Initialize the contract
After deployment, initialize the contract with an admin address:
- Testnet
- Mainnet
The admin address is used only for TTL management (
extend_ttl). It cannot access funds, modify plans, or interfere with subscriptions. See Security for details.Verify the deployment
Confirm the contract is live by calling a read-only function:This should return an error like
- Testnet
- Mainnet
Plan not found - which confirms the contract is deployed and responding. No plans exist yet because none have been created.Testing
The Vowena contract includes a comprehensive test suite:Test coverage
Test coverage
The test suite includes 29 tests covering:
- Plan creation and validation
- Subscription lifecycle (create, cancel, expire)
- Billing flow (charge, trial periods, grace periods)
- Failed charge handling and pre-check logic
- Migration request, accept, and reject flows
- Refund processing
- TTL extension
- Edge cases (double charge, early charge, unauthorized access)
Running specific tests
Running specific tests
Contract Specifications
| Property | Value |
|---|---|
| WASM size | ~18.5 KB |
| Exported functions | 17 |
| Storage types | Instance + Persistent |
| Token standard | SEP-41 (SAC) |
| Soroban SDK | Latest stable |
Environment Variables Reference
For convenience, set these in your shell when working with the contract:What’s Next
TypeScript SDK
Install the SDK and start building integrations.
Keeper Setup
Set up a keeper bot to automate billing.
API Reference
Complete reference for every contract function.
Architecture
Review the contract architecture and data models.