This repository contains the full task spec and a completed React + TypeScript implementation.
| Item | Description |
|---|---|
| TASK.md | Full requirements and acceptance criteria |
| frontend/ | Implemented app (OpenAPI client, auth flow, blockchain integration) |
| docs/api-spec.json | OpenAPI schema used for API client generation |
| docs/postman-collection.json | Postman collection for manual API endpoint verification |
From the project root:
cd frontend
bun install
cp .env.example .env
# Edit .env: VITE_API_BASE_URL / VITE_CHAIN_ID / VITE_CONTRACT_ADDRESS
bun run generate
bun run dev- Default API base URL:
http://localhost:3000/api - Frontend auth uses JWT Bearer token (stored locally and attached to API requests)
- Import
docs/postman-collection.jsonin Postman and set:baseUrl(API URL)token(fromAuth / Loginresponse)userId(for detail/update/delete requests)
You can also use:
cd frontend
bun run dev:mockto start Prism mock API from docs/api-spec.json.
- Chain: Sepolia
- Chain ID: 11155111
- Contract address: configured with
VITE_CONTRACT_ADDRESS- Example default in
.env.example:0x1c7D4B196Cb0C7B01d743Fbc6116a902379C7238
- Example default in
In the app, use /blockchain to connect wallet, read token info/balance, and send transfer transactions.
cd frontend
bun run test # unit tests (Vitest)
bun run lint # lint + format check (Biome)
bun run build # TypeScript check + production buildFor implementation details and design notes, see:
frontend/README.mdfrontend/NOTES.md