This guide shows how to deploy the contract stack to Stellar testnet and verify the main entry points from the command line.
- Stellar account funded on testnet
sorobanCLI installedstellarCLI configured for testnetbackend/.envpopulated with the testnet RPC URL and contract ID after deploy
soroban keys generate --global contributor --network testnet
soroban keys fund contributor --network testnetcargo build --release --target wasm32-unknown-unknown -p escrow_contractUse the helper script for a repeatable deploy:
bash scripts/deploy-testnet.shOr deploy manually:
soroban contract deploy \
--source-account contributor \
--rpc-url "$SOROBAN_RPC_URL" \
--network-passphrase "$SOROBAN_NETWORK_PASSPHRASE" \
--wasm target/wasm32-unknown-unknown/release/escrow_contract.wasmAfter deployment, confirm the contract responds to its core entry points:
soroban contract invoke \
--source-account contributor \
--rpc-url "$SOROBAN_RPC_URL" \
--network-passphrase "$SOROBAN_NETWORK_PASSPHRASE" \
--id "$ESCROW_CONTRACT_ID" \
-- initializeRepeat with project-specific calls such as escrow creation, milestone approval, and dispute resolution once your local environment variables are in place.
Copy the deployed contract ID into backend/.env:
ESCROW_CONTRACT_ID=...
STELLAR_RPC_URL=...
STELLAR_NETWORK=testnet- If deploy fails, verify the account is funded and the RPC URL is reachable.
- If the app cannot read contract state, confirm
ESCROW_CONTRACT_IDmatches the value returned by deployment. - If testnet calls hang, check that the network passphrase matches testnet.