@tamago-labs/goji
v0.9.1
Published
Web3 corporate payments on Arc. Private P2P workspace for USDC payments and invoice approvals with verifiable proof.
Maintainers
Readme
Goji — Web3 Corporate Payments on Arc
Private Payments. Public Proof.
Private P2P workspace for USDC payments and invoice approvals. Every settlement creates verifiable proof of payment and document on Arc, enabling compliance-ready records for audit and accounting.
Quick Links
- Live App: https://goji.tamagolabs.com/
- Demo Video: https://youtu.be/QaZRVty_ViE
- Presentation: https://canva.link/7z2iw3keeii3uwc
- Architecture: ARCHITECTURE.md
Goji is a Web3 corporate payment workspace built on Arc.
Businesses run USDC payments, invoice approvals, and other settlements inside a private P2P workspace. Every payment creates verifiable proof anchored on Arc — ready for accounting, audit, and compliance.
The Problem
Business payments are managed across disconnected systems:
- Payroll & accounting software — isolated from other payment workflows
- Spreadsheets — manual, error-prone, and difficult to audit
- Email approvals — fragmented decisions with no shared history
- Banking systems — settlement without reusable financial proof
The result is fragmented payment history that's difficult to verify, expensive to audit, and impossible to reuse as financial infrastructure.
What Goji Does
Goji is a stablecoin-native payment workspace built on Arc, where businesses coordinate USDC payments, approvals, and proof anchoring through a private P2P network.
Private Layer: Payroll, contractor payments, invoices, vendor payments, documents, and approvals remain between authorized participants.
Verification Layer: Every settlement automatically generates Merkle proofs and audit records that can be independently verified without exposing sensitive business data.
Settlement Layer: Settle USDC through Circle Unified Balance and Circle Gateway, while anchoring cryptographic payment proofs on Arc.
How It Works
Goji runs as a local terminal that hosts a private workspace with an embedded web interface. The frontend is served directly from the terminal — no separate processes needed.
Host a Workspace
Run the company terminal:
npx @tamago-labs/gojiOpens at http://localhost:3001 with the full web interface.
The host terminal prints an invite code. Share it with the people who should join the workspace.
Join a Workspace
Run:
npx @tamago-labs/goji --joinGoji prompts for the invite code and connects the terminal to the existing workspace.
After joining, the company administrator assigns each participant a role from Organization → Members.
Development Mode
For development with hot reload:
npm start # CLI on port 3001 (API only)
cd frontend && npm run dev # Frontend on port 3000Workspace Roles
| Role | Access | | ------------- | ----------------------------------------- | | Company | Manages members, workflows, and payments | | Counterparty | Approves invoices and receives payments |
P2P Identity
On first launch, Goji creates a Keet identity using a 24-word mnemonic. Save this mnemonic securely because it is the portable identity for the P2P workspace.
This identity is:
- Not a wallet
- Not used for payment funds
- Used to identify the participant to workspace peers
- Used to associate messages and records with the real sender
The identity and room use encrypted Pear P2P communication over Hyperswarm. Only authorized members added to the workspace can participate.
A first host launch looks like this:
goji v0.1.0
mode: host
port: 3001
No identity found
1. Generate new identity
2. Import existing mnemonic
Choose (1 or 2): 1
New identity generated
Save this mnemonic: <24-word mnemonic>
Enter display name: <name>
Identity saved to ~/.goji/host/identity.json
invite: <invite-code>
share: npx @tamago-labs/goji --join <invite-code>Never publish your mnemonic or an active invite code in documentation, logs, screenshots, or issue reports.
Smart Contracts
Goji uses Arc smart contracts to anchor payment proofs on-chain.
GojiProof
GojiProof anchors Merkle roots for payment documents on Arc. The private document stays inside the P2P workspace; the contract stores its root, canvas connection reference, submitting address, and anchor timestamp. Anchoring is permissionless, each Merkle root can be anchored only once, and the contract emits a RootAnchored event.
anchorRoot(bytes32 merkleRoot, bytes32 connectionId)stores a proofisAnchored(bytes32 merkleRoot)verifies that a root existsgetDocument(bytes32 merkleRoot)returns the root, connection, submitter, and timestampgetRootByConnection(bytes32 connectionId)looks up a root from its canvas connectionhasDocument(bytes32 connectionId)checks whether a connection has an anchored document
Private Knowledge Base
Goji includes a private knowledge base for company documents. The employer terminal runs GTE-Large locally and keeps the vector index on the host. Authorized members search policies, invoices, and procedures through encrypted P2P requests.
- Employer management:
/start/organization/ai-assistant - Member search:
/start/knowledge - Sources: pasted text and website URLs
- Current model: GTE-Large embeddings and vector search
Source documents and embeddings are never replicated. Members receive only relevant search snippets while the employer host is online. The employer controls model lifecycle and document management.
| Component | Responsibility |
| -------------------- | -------------------------------------------------------------- |
| src/index.js | Terminal entrypoint, API, WebSocket, P2P room, and role checks |
| src/ragStore.js | Local document metadata, embeddings, and vector search |
| schema.js | HyperSchema records, HyperDB collections, and dispatch routes |
| spec/ | Generated schema, database, and dispatch specifications |
| frontend/app/start | Workspace application and role-based pages |
| contracts/src | GojiProof contract |
API Surface
| Endpoint | Purpose |
| ----------------------------------------------- | ----------------------------------------------------- |
| GET /api/health | Terminal status, identity, role, and peers |
| /api/boards, /api/cards, /api/connections | Visual workflow data |
| /api/flow-status | Payment execution status |
| /api/chat | P2P workspace chat |
| /api/wallets | Wallet registration and balances |
| /api/templates | Document template management |
| /api/knowledge/documents | Employer document management |
| /api/knowledge/model | Embedding model status and lifecycle |
| POST /api/knowledge/url | Fetch website text for ingestion |
| POST /api/knowledge/search | Local or P2P knowledge search |
| /api/members | Employer member and role management |
| ws://localhost:3001 | Live browser updates for the visual payment workspace |
Getting Started
Terminal
npm install
npm run build:specs
npm startTo join an existing workspace:
npm start -- --join <invite-code>Frontend
cd frontend
npm install
npm run devThe frontend runs on port 3000 and connects to http://localhost:3001 by default. The terminal and frontend are independent npm projects.
Operational Notes
- Hyperswarm peer discovery requires UDP access.
- Keep the employer terminal online for member knowledge searches.
- Frontend scripts use
--webpackbecause of the RainbowKit integration. - The first terminal run may create a Keet identity in the Goji storage directory.
- Use
npm run clean:storageonly when intentionally resetting local P2P state.
Arc Testnet Contracts
| Contract | Address |
| --------- | -------------------------------------------- |
| GojiProof | 0x9465a4C246D44F32F391Ebda165Acb12886746Ca |
- Chain: Arc Testnet, chain ID
5042002
Roadmap
Payments & Chains
- Multi-stablecoin settlement (EURC, cirBTC)
- Mainnet deployment on Arc
- Cross-chain payments
AI
- Local Qwen and Gemma assistant models with tool access to the current RAG knowledge search
Privacy
- On-chain privacy for payment records
Security
- Safe multisignature wallet support for company treasury
- Security audit of GojiProof contract
License
Apache License 2.0
