This guide walks through setting up Accord Protocol for local development on macOS, Linux, and Windows.
| Tool | Version | Purpose |
|---|---|---|
| Git | Any | Version control |
| Rust | stable | Soroban contracts |
| Node.js | 20 LTS | Frontend |
| Stellar CLI | latest | Build, test, and deploy contracts |
| Docker | optional | Local Soroban node |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source "$HOME/.cargo/env"
# Add the WASM target required by Soroban
rustup target add wasm32v1-noneVerify: rustc --version
cargo install --locked stellar-cli --features optVerify: stellar --version
Use nvm (recommended) or download from nodejs.org:
nvm install 20
nvm use 20Verify: node --version
git clone https://github.com/thegreatfeez/accord-protocol.git
cd accord-protocol
# Copy environment templates
cp .env.example .env
cp .env.example frontend/.env.localEdit frontend/.env.local and fill in VITE_CONTRACT_ADDRESS after deploying (see docs/DEPLOYMENT.md).
cd frontend
npm ci
npm run dev # starts at http://localhost:5173Other useful commands:
npm run build # type-check + production build
npm run lint # ESLintThe Accord frontend uses the Freighter browser extension wallet to sign transactions. Install and configure it before interacting with proposals.
- Chrome / Brave / Edge: Install from the Chrome Web Store
- Firefox: Install from the Firefox Add-ons store
After installing, create a new wallet or import an existing one by following the extension's onboarding flow.
- Click the Freighter icon in your browser toolbar.
- Open Settings (gear icon) → Network.
- Select Testnet from the dropdown.
- The icon badge should now read TESTNET.
The Accord frontend only connects to Testnet. If Freighter is set to Mainnet or Pubnet the app will not detect the wallet.
- Start the frontend:
cd frontend && npm run dev - Open
http://localhost:5173in your browser. - Freighter should prompt you to approve a connection. If not, click Connect Wallet in the app header.
- Once connected, your public key (G…) appears in the header.
| Problem | Fix |
|---|---|
| Freighter not detected by the app | Reload the page. Ensure Freighter has permission to access localhost (Chrome: extension icon → right-click → Inspect popup → check console for errors; ensure Allow access to file URLs is enabled in extension settings). |
| Wrong network selected | Open Freighter → Settings → Network → switch to Testnet. The app will ignore connections on Mainnet or Pubnet. |
| Extension not appearing after install | Restart your browser. Freighter requires Chrome 88+, Firefox 109+, or any Chromium-based browser; it does not support Safari or mobile browsers. |
From the repository root:
# Build all contracts in the workspace
stellar contract build
# Run contract tests
stellar contract test
# or equivalently from the contract directory:
cd contracts/accord && cargo testA docker-compose.yml at the repo root starts a standalone Soroban node:
docker compose up- Soroban RPC:
http://localhost:8000 - Horizon:
http://localhost:8001
Update .env to point SOROBAN_RPC_URL at http://localhost:8000 when developing locally.
The Stellar CLI uses local key aliases (no browser extension needed for deployment):
stellar keys generate accord-deployer
stellar keys public-key accord-deployerThis prints a G… public key. Fund it with testnet XLM:
stellar network use testnet
stellar keys fund accord-deployer --network testnetOr use Friendbot directly.
If you are a regular user (not deploying contracts), fund your Freighter wallet via Friendbot instead:
- Copy your Freighter wallet address (the
G…public key displayed in the extension). - Open the following URL in your browser, replacing
G…with your address:https://friendbot.stellar.org?addr=G… - Friendbot returns a JSON response with a
"hash"field — this is the transaction hash of the funding operation. - Your wallet now has 10,000 test XLM. Check the balance in Freighter.
The CLI
stellar keys fundcommand is for deployer identities. Regular users should always use the Friendbot URL above. Friendbot is rate-limited to one request per 60 seconds per IP.
# From repo root
stellar contract test # all Rust tests should pass
cd frontend
npm run lint && npm run build # should exit 0 with no errorsIf both commands succeed, your environment is ready. See docs/DEPLOYMENT.md to deploy to testnet.
You can develop on Windows using either WSL2 (recommended) or a native Windows setup.
- Run all commands inside a WSL2 terminal (Ubuntu recommended).
- Docker Desktop for Windows with WSL2 integration enabled is required for the local node.
- Node.js and Rust should be installed inside WSL2, not on the Windows host.
- Rust: Download and run
rustup-init.exefrom rustup.rs, then follow the standard installer prompts. - Node.js: Download the LTS installer from nodejs.org or install via
winget install OpenJS.NodeJS.LTS. - Stellar CLI: Open a terminal and run
cargo install stellar-cli. The Rust WASM target (wasm32v1-none) is added automatically by the Stellar CLI installer on Windows — if it is not, runrustup target add wasm32v1-nonemanually. - Docker: Optional. Skip if you are using a remote Testnet RPC endpoint (the default). Docker Desktop for Windows is only required if you want a local Soroban node.
Known limitations: The local Soroban node (Docker) is not well-tested on Windows native. If you encounter issues, switch to WSL2 or use the remote Testnet.
| Problem | Fix |
|---|---|
wasm32v1-none target not found |
Run rustup target add wasm32v1-none |
stellar: command not found |
Ensure ~/.cargo/bin is in your $PATH |
npm ci fails with peer errors |
Ensure you are on Node.js 20+ |
| Friendbot rate-limit | Wait 60s and retry, or use Stellar Lab account tools |