Runnable examples for interacting with PayStream contracts from off-chain clients.
| Language | Directory | Run command |
|---|---|---|
| JavaScript | javascript/ | node stream.js |
| Python | python/ | python stream.py |
| Rust | rust/ | cargo run |
Each example reads contract IDs and keys from environment variables:
export EMPLOYER_SECRET="S..." # employer Stellar secret key
export EMPLOYEE_PUBLIC="G..." # employee Stellar public key
export TOKEN_CONTRACT_ID="C..." # SEP-41 token contract ID
export STREAM_CONTRACT_ID="C..." # PayStream stream contract IDDeploy contracts to testnet first: see docs/testnet.md.
- Creates a stream (3600 deposit, 1 stroop/second, no stop time)
- Queries the stream state
- Queries the claimable amount
For a full TypeScript frontend integration guide see docs/integration/frontend.md.