DevelopmentRun Server

Run Server, App, and Docs

Healthy local product stack: Docker for Mongo + API + poller, host Next for the wallet UI.

Start orderProcessWhy it runs
1MongoDBPersists the local OCF mirror.
2API + pollerServes reads/automation and mirrors confirmed events.
3Product UIConnects the issuer ADMIN wallet for direct writes.
4Docs, optionalServes this reference locally.

Docker (Mongo + API)

Start services

pnpm bootstrap
# or: pnpm docker:up
# or mongo+server only: SKIP_APP=1 pnpm bootstrap

Rebuild after dependency, contract artifact, or Dockerfile changes: pnpm docker:build.

Check the API

curl http://localhost:8293/

The Docker server runs with the event poller enabled.

App and docs

GoalCommandURL
Product UI (preferred)pnpm app:devhttp://localhost:3000/app
App in Docker (optional)pnpm docker:uphttp://localhost:3000
Docspnpm docs:devhttp://localhost:3001

Wallet mint/manage needs app/.env.local (NEXT_PUBLIC_*). Docker app reads root .env interpolation from compose — keep both aligned if you use Docker app.

Local server hot-reload

pnpm docker:down
docker compose up -d mongodb
pnpm dev

pnpm dev starts the API with hot reload and the poller.

Event poller

The poller watches contract events and writes them into MongoDB. Without it, history and mirrored positions go stale.

CommandBehavior
pnpm devAPI + poller, hot reload
pnpm prodAPI only
pnpm prod-pollerStandalone finalized-only poller

A fresh Mongo does not auto-import every historical issuer on Plume. Use mint, Load from wallet, or issuer register/reindex for companies you care about.

Troubleshooting

SymptomCheck
Can't resolve '@tap/units' on :3000Docker app image must COPY packages/; or stop Docker app and run pnpm app:dev
Empty connect modal / no walletsInstall a browser extension wallet (Rabby, MetaMask, etc.) — EIP-6963, no cloud key needed
EADDRINUSEPort 8293 or 3000 already in use (lsof -i :3000)
History does not updatePoller running; issuer registered with deployed_to
Frontend API failsNEXT_PUBLIC_API_URL=http://localhost:8293 (host-reachable)
Factory misalignedMongo factories vs NEXT_PUBLIC_FACTORY_ADDRESS

Next: Deploy your transfer-agent factory, then create an issuer.