Skip to content

Commit a2e1b77

Browse files
feat: Implement Auth and Wallet system
This commit introduces the Auth and Wallet system, including API endpoints, database schema, and necessary dependencies. It also updates the .env.example file with new configuration options and adds related scripts and documentation. Co-authored-by: michaeljjudan <[email protected]>
1 parent d53388b commit a2e1b77

26 files changed

Lines changed: 15581 additions & 8 deletions

.env.example

Lines changed: 46 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,70 @@
11
# OAA API Library Environment Configuration
22
# Copy this file to .env.local and fill in your values
33

4-
# CORS Configuration (comma-separated list of allowed origins)
4+
# ==============================================================================
5+
# DATABASE (Required for Auth + Wallet)
6+
# ==============================================================================
7+
# PostgreSQL connection string (Render, Supabase, etc.)
8+
DATABASE_URL=postgresql://user:password@host:5432/database?schema=public
9+
10+
# ==============================================================================
11+
# AUTH CONFIGURATION (Required)
12+
# ==============================================================================
13+
# JWT signing secret - generate with: node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
14+
JWT_SECRET=your-jwt-secret-change-in-production
15+
16+
# App URL for magic links
17+
NEXT_PUBLIC_APP_URL=http://localhost:3000
18+
19+
# ==============================================================================
20+
# CORS Configuration
21+
# ==============================================================================
522
# Default origins (localhost:3000,5173,8080 and mobius-browser-shell.vercel.app) are always included
623
# Vercel preview deployments matching mobius-browser-shell-*.vercel.app are automatically allowed
724
ORIGINS=https://your-custom-domain.com,https://another-domain.com
825

26+
# ==============================================================================
927
# OAA Core Configuration
28+
# ==============================================================================
1029
OAA_HMAC_SECRET=your-hmac-secret-here
1130
EVE_HMAC_SECRET=your-eve-secret-here
1231

13-
# AI Provider API Keys (required for /api/tutor and /api/jade endpoints)
32+
# ==============================================================================
33+
# AI Provider API Keys
34+
# ==============================================================================
1435
# At least one of ANTHROPIC_API_KEY or OPENAI_API_KEY must be set
1536
OPENAI_API_KEY=sk-your-openai-key-here
1637
ANTHROPIC_API_KEY=sk-ant-your-anthropic-key-here
1738
DEEPSEEK_API_KEY=sk-your-deepseek-key-here
1839

40+
# ==============================================================================
41+
# EMAIL SERVICE (Optional - for magic links)
42+
# ==============================================================================
43+
# SMTP configuration for nodemailer
44+
# SMTP_HOST=smtp.gmail.com
45+
# SMTP_PORT=587
46+
47+
# SMTP_PASS=your-app-password
48+
# SMTP_FROM="Mobius <[email protected]>"
49+
50+
# ==============================================================================
51+
# INTEGRATIONS
52+
# ==============================================================================
1953
# Reflections API (for JADE memory bridge)
20-
# When set, JADE can access user reflections to surface patterns across cycles
2154
REFLECTIONS_API_BASE=https://reflections-app.onrender.com
2255

23-
# Optional: Ledger Configuration
56+
# Ledger Configuration
2457
LEDGER_BASE_URL=http://localhost:4000
2558
LEDGER_ADMIN_TOKEN=your-ledger-token-here
2659

27-
# Optional: Development Configuration
60+
# ==============================================================================
61+
# FOUNDER WALLET GENERATION
62+
# ==============================================================================
63+
# Set this when running generate-founder-wallet script
64+
# FOUNDER_HANDLE=kaizen
65+
66+
# ==============================================================================
67+
# Development Configuration
68+
# ==============================================================================
2869
OAA_BASE_URL=http://localhost:3000
2970
NODE_ENV=development

.eslintrc.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"extends": "next/core-web-vitals",
3+
"ignorePatterns": [
4+
"src/gic-indexer/**",
5+
"gic-indexer/**",
6+
"*.mjs",
7+
"oaa-central-hub/**"
8+
]
9+
}

0 commit comments

Comments
 (0)