A contract registry and package manager for the Soroban smart‑contract ecosystem on Stellar.
Soroban Registry lets developers publish, discover, and verify Soroban contracts across Stellar networks, similar to how npm and crates.io serve JavaScript and Rust communities.[cite:352]
Production: https://soroban-registry.vercel.app/
- Registry & Discovery – Search and browse contracts by network, tags, category, and publisher.
- Source Verification – Verify that on‑chain bytecode matches published source.
- Versioning & Changelogs – Track versions, semver compatibility, and breaking changes.
- Multi‑Network Support – Mainnet, Testnet, and Futurenet in a single registry.[cite:352]
- Publisher Profiles – Attach contracts to publishers and their deployment history.
- Analytics – Usage statistics and interaction metrics for contracts.
- Web App + CLI – Next.js frontend for browsing; Rust CLI for developer workflows.
soroban-registry/
├── backend/ # Rust backend services (Axum API, indexer, verifier)
├── frontend/ # Next.js web application
├── cli/ # Rust CLI tool
├── database/ # PostgreSQL migrations
└── examples/ # Example contracts
- Rust 1.75+ – https://rustup.rs/
- Node.js 20+ – https://nodejs.org/
- PostgreSQL 16+ – https://www.postgresql.org/download/
- Docker (optional, recommended for local all‑in‑one setup)[cite:352]
git clone https://github.com/ALIPHATICHYD/Soroban-Registry.git
cd Soroban-Registry
cp .env.example .envdocker-compose up -d
# API: http://localhost:3001
# Frontend: http://localhost:3000This starts PostgreSQL, the backend API, and the Next.js frontend with sensible defaults.[cite:352]
The backend uses SQLx's compile-time-checked query macros (sqlx::query!,
sqlx::query_as!, sqlx::query_scalar!). They require either a live
database reachable at DATABASE_URL or prepared offline query data under
backend/.sqlx/ (SQLX_OFFLINE=true). Without one of these, cargo build
fails with errors like "set DATABASE_URL to use query macros online, or run
cargo sqlx prepare to update the query cache".
# 1. Create the database
createdb soroban_registry
# 2. Export DATABASE_URL — needed at compile time AND at runtime
export DATABASE_URL="postgresql://postgres:postgres@localhost:5432/soroban_registry"
# 3. Install the SQLx CLI (one-time)
cargo install sqlx-cli --version 0.8.6 --no-default-features --features rustls,postgres --locked
# 4. Apply migrations so the schema matches what the query macros expect
sqlx migrate run --source database/migrations
# 5. (Optional) Verify the environment is ready to build
./scripts/check-sqlx-env.shIf your build environment cannot reach a Postgres instance (e.g. some CI runners, contributor laptops), generate offline query metadata once from a machine that can:
# From the backend workspace, with DATABASE_URL pointing at a fully
# migrated database
cd backend
cargo sqlx prepare --workspace -- --all-targets
git add .sqlxThen anyone (or any CI job) can build without a database by setting:
export SQLX_OFFLINE=trueRe-run cargo sqlx prepare whenever a query macro or migration changes.
The repository's docker-compose.yml defines a named volume, postgres_data, for the Postgres service. That means the database survives container restarts and docker-compose down; your data is only removed if you explicitly delete the volume.
# Start or reattach to the same database instance
docker-compose up -d postgres
# Apply migrations against the persistent database
docker-compose exec postgres psql -U postgres -d soroban_registry -c "SELECT 1"
sqlx migrate run --source database/migrations
# Stop services without deleting data
docker-compose down
# Remove the database data only if you want a clean slate
docker-compose down -vUse the same DATABASE_URL on future runs so the backend, SQLx checks, and any local tools all connect to the same persisted database.
cd backend
cargo build --release
cargo run --bin apiThe API server will listen on the address configured in your .env (commonly http://localhost:3001).[cite:352]
cd frontend
pnpm install
pnpm devVisit http://localhost:3000 to browse the registry UI.
The CLI lets you interact with the registry directly from your terminal.[cite:352]
# From the repo root
cargo install --path cliThis installs a soroban-registry binary into your Cargo bin directory.
# Search for contracts
soroban-registry search "token" --category defi --verified-only --network testnet,futurenet
# Get contract details
soroban-registry info <contract-id>
# Publish a contract
soroban-registry publish --contract-path ./my-contract
# Verify a contract against source
soroban-registry verify <contract-id> --source ./src
# View registry analytics for contracts
soroban-registry contract stats --network testnet --top-n 5 --format table
# Export contract registry data for backup or migration
soroban-registry contract export contracts.jsonl --format jsonl --network testnet --compressConfiguration is stored at ~/.soroban-registry/config.toml. A legacy ~/.soroban-registry.toml file is migrated automatically if present.[cite:352]
The backend exposes a REST API suitable for integration with dashboards, bots, and CI:
GET /api/contracts– List and search contractsGET /api/contracts/:id– Contract detailsPOST /api/contracts– Publish a new contractGET /api/contracts/:id/versions– Version historyGET /api/contracts/:id/changelog– Changelog with breaking‑change markersGET /api/publishers/:id– Publisher detailsGET /api/publishers/:id/contracts– Contracts by publisherGET /api/stats– Registry‑level statsGET /health– Health check endpoint[cite:352]
See the OpenAPI spec (coming soon) or the backend/api handlers for full details.
Contributions from the Stellar/Soroban community are welcome.
- Fork the repository.
- Create a branch:
git checkout -b feature/short-description - Make changes and add tests where appropriate.
- Run checks:
# Rust cargo fmt --all cargo test --all # TypeScript cd frontend pnpm lint pnpm test
- Commit:
git commit -m "feat: add <short description>" - Push and open a PR against
main.
Bug reports and feature requests can be filed as GitHub Issues: https://github.com/ALIPHATICHYD/Soroban-Registry/issues
- Soroban SDK – https://github.com/stellar/rs-soroban-sdk
- Stellar Docs – https://developers.stellar.org/
- Stellar Community Discord – https://discord.gg/stellar[cite:352]
Soroban Registry is licensed under the MIT License. See LICENSE for details.[cite:352]