|
| 1 | +# Juice Interface Sitemap & Route Structure |
| 2 | + |
| 3 | +## 🗺️ Route Hierarchy |
| 4 | + |
| 5 | +### 🏠 Static Routes |
| 6 | + |
| 7 | +``` |
| 8 | +/ # Home page |
| 9 | +├── /about # About page |
| 10 | +├── /projects # Projects discovery page |
| 11 | +├── /activity # Activity feed |
| 12 | +├── /create # Create new project |
| 13 | +├── /contact # Contact form |
| 14 | +├── /legal # Legal information |
| 15 | +├── /privacy # Privacy policy |
| 16 | +└── /experimental/flags # Feature flags (experimental) |
| 17 | +``` |
| 18 | + |
| 19 | +### 📖 Success Stories |
| 20 | +``` |
| 21 | +/success-stories/ |
| 22 | +├── constitutiondao # ConstitutionDAO case study |
| 23 | +├── moondao # MoonDAO case study |
| 24 | +├── sharkdao # SharkDAO case study |
| 25 | +└── studiodao # StudioDAO case study |
| 26 | +``` |
| 27 | + |
| 28 | +### 👤 Account Routes |
| 29 | +``` |
| 30 | +/account/ |
| 31 | +└── [addressOrEnsName]/ # Dynamic: User profile by address or ENS |
| 32 | + ├── (index) # View profile |
| 33 | + └── edit # Edit profile |
| 34 | +``` |
| 35 | + |
| 36 | +### 🎯 Project Routes (by Handle) |
| 37 | +``` |
| 38 | +/p/ |
| 39 | +└── [handle]/ # Dynamic: Project by handle |
| 40 | + ├── (index) # Project dashboard |
| 41 | + └── safe/ # Safe (multi-sig) interface |
| 42 | +``` |
| 43 | + |
| 44 | +### 📊 V2/V3 Project Routes |
| 45 | +``` |
| 46 | +/v2/p/ |
| 47 | +└── [projectId]/ # Dynamic: V2/V3 project by ID |
| 48 | + ├── (index) # Project dashboard |
| 49 | + ├── safe/ # Safe interface |
| 50 | + ├── contracts/ # Contract information |
| 51 | + └── settings/ # Settings dashboard |
| 52 | + └── [settingsPage] # Dynamic settings pages |
| 53 | +``` |
| 54 | + |
| 55 | +### 🚀 V4 Project Routes |
| 56 | +``` |
| 57 | +/v4/ |
| 58 | +└── [jbUrn]/ # Dynamic: V4 project URN format (chainId:projectId) |
| 59 | + ├── (index) # Project dashboard |
| 60 | + └── settings/ # Settings dashboard |
| 61 | + ├── (index) # Settings overview |
| 62 | + └── [settingsPage] # Dynamic settings pages |
| 63 | +``` |
| 64 | + |
| 65 | +### 🆕 V5 Project Routes |
| 66 | +``` |
| 67 | +/v5/ |
| 68 | +└── [jbUrn]/ # Dynamic: V5 project URN format (chainId:projectId) |
| 69 | + ├── (index) # Project dashboard |
| 70 | + └── settings/ # Settings dashboard |
| 71 | + ├── (index) # Settings overview |
| 72 | + └── [settingsPage] # Dynamic settings pages |
| 73 | +``` |
| 74 | + |
| 75 | +## 🔌 API Routes Structure |
| 76 | + |
| 77 | +### Authentication & Account |
| 78 | +``` |
| 79 | +/api/ |
| 80 | +├── auth/ |
| 81 | +│ ├── challenge-message # Get auth challenge |
| 82 | +│ └── wallet-sign-in # Wallet authentication |
| 83 | +├── account/ |
| 84 | +│ ├── [address] # Get account details |
| 85 | +│ ├── update-details # Update account info |
| 86 | +│ └── update-email # Update email |
| 87 | +``` |
| 88 | + |
| 89 | +### Juicebox Core APIs |
| 90 | +``` |
| 91 | +/api/juicebox/ |
| 92 | +├── project/ |
| 93 | +│ └── [projectHandle] # Get project by handle |
| 94 | +├── projectHandle/ |
| 95 | +│ └── [projectId] # Get handle by project ID |
| 96 | +├── prices/ |
| 97 | +│ └── ethusd # ETH/USD price feed |
| 98 | +├── jb-721-delegate/ |
| 99 | +│ └── [dataSourceAddress] # NFT delegate info |
| 100 | +├── pv/[pv]/project/[projectId]/ |
| 101 | +│ ├── logo # Project logo |
| 102 | +│ └── refreshMetadata # Refresh metadata |
| 103 | +└── v4/ |
| 104 | + ├── project/[projectId]/ |
| 105 | + │ └── sucker-pairs # Sucker pairs info |
| 106 | + └── terminal/[terminalAddress]/ |
| 107 | + └── jb-terminal-store # Terminal store data |
| 108 | +``` |
| 109 | + |
| 110 | +### Projects Discovery |
| 111 | +``` |
| 112 | +/api/projects/ |
| 113 | +├── (index) # List projects |
| 114 | +├── health # Health check |
| 115 | +├── tag-counts # Tag statistics |
| 116 | +├── trending # Trending projects |
| 117 | +├── update # Update project data |
| 118 | +└── update-retry-ipfs # Retry IPFS updates |
| 119 | +``` |
| 120 | + |
| 121 | +### Utility APIs |
| 122 | +``` |
| 123 | +/api/ |
| 124 | +├── ens/resolve/[address] # Resolve ENS names |
| 125 | +├── ipfs/ |
| 126 | +│ ├── [cid] # Get IPFS content |
| 127 | +│ └── pinJSON # Pin JSON to IPFS |
| 128 | +├── image/[url] # Image proxy |
| 129 | +├── discord/contact # Discord notifications |
| 130 | +├── ofac/validate/[address] # OFAC compliance check |
| 131 | +└── nextjs/revalidate-project # Revalidate cache |
| 132 | +``` |
| 133 | + |
| 134 | +### Event Webhooks |
| 135 | +``` |
| 136 | +/api/events/ |
| 137 | +├── on-pay # Payment events |
| 138 | +├── on-payout-distributed # Payout events |
| 139 | +└── on-user-update # User update events |
| 140 | +``` |
| 141 | + |
| 142 | +## 🔗 URL Formats |
| 143 | + |
| 144 | +### Project URN Format (v4/v5) |
| 145 | +``` |
| 146 | +/v4/{chain}:{projectId} |
| 147 | +/v5/{chain}:{projectId} |
| 148 | +
|
| 149 | +Examples: |
| 150 | +- /v4/ethereum:123 # Ethereum mainnet project 123 |
| 151 | +- /v5/sepolia:456 # Sepolia testnet project 456 |
| 152 | +- /v4/optimism:789 # Optimism project 789 |
| 153 | +``` |
| 154 | + |
| 155 | +### Supported Chains |
| 156 | +- `ethereum` (mainnet) |
| 157 | +- `sepolia` (testnet) |
| 158 | +- `optimism` |
| 159 | +- `optimism-sepolia` |
| 160 | +- `base` |
| 161 | +- `base-sepolia` |
| 162 | +- `arbitrum` |
| 163 | +- `arbitrum-sepolia` |
| 164 | + |
| 165 | +## 🔄 Route Versioning |
| 166 | + |
| 167 | +The app supports multiple protocol versions: |
| 168 | + |
| 169 | +1. **V2/V3**: Legacy projects at `/v2/p/[projectId]` |
| 170 | +2. **V4**: Current stable at `/v4/[jbUrn]` |
| 171 | +3. **V5**: Latest version at `/v5/[jbUrn]` |
| 172 | +4. **Handle-based**: Version-agnostic at `/p/[handle]` |
| 173 | + |
| 174 | +## 📝 Settings Pages |
| 175 | + |
| 176 | +Common settings pages (available for v2/v3, v4, and v5): |
| 177 | +- General settings |
| 178 | +- Funding cycle configuration |
| 179 | +- Token settings |
| 180 | +- NFT rewards |
| 181 | +- Payouts & reserved tokens |
| 182 | +- Transfer ownership |
| 183 | +- Archive project |
| 184 | + |
| 185 | +## 🌐 Sitemap Access |
| 186 | + |
| 187 | +The sitemap.xml is automatically generated and available at: |
| 188 | +``` |
| 189 | +https://juicebox.money/sitemap.xml |
| 190 | +``` |
| 191 | + |
| 192 | +## 🔍 Navigation Patterns |
| 193 | + |
| 194 | +1. **Project Discovery**: `/projects` → `/v4/[jbUrn]` or `/v5/[jbUrn]` |
| 195 | +2. **Direct Access**: Use handle (`/p/[handle]`) or URN (`/v4/[jbUrn]`) |
| 196 | +3. **Settings Flow**: Project page → Settings → Specific setting page |
| 197 | +4. **Account Flow**: `/account/[address]` → `/account/[address]/edit` |
| 198 | + |
| 199 | +## 🎯 Key User Journeys |
| 200 | + |
| 201 | +1. **Create Project**: Home → `/create` → Deploy → `/v5/[jbUrn]` |
| 202 | +2. **Discover Projects**: Home → `/projects` → Filter/Search → Project page |
| 203 | +3. **Manage Project**: Project page → Settings → Configure → Save |
| 204 | +4. **View Activity**: `/activity` → Transaction details |
| 205 | +5. **User Profile**: `/account/[address]` → View projects/contributions |
0 commit comments