Documentation Index
Fetch the complete documentation index at: https://docs.ownafarm.xyz/llms.txt
Use this file to discover all available pages before exploring further.
OwnaFarm consists of three layers: frontend, backend, and blockchain.
Frontend layer
Farmer portal
| Route | Function |
|---|
/ | Landing page |
/register-farm | Multi-step farmer registration |
/admin | Invoice management |
Investor app
| Route | Function |
|---|
/ | Homepage with active crops |
/shop | Seed marketplace |
/farm | Personal garden view |
/leaderboard | Investor rankings |
/profile | User stats |
Backend layer
Responsibilities
| Area | Function |
|---|
| User management | Profiles, authentication, KYC |
| Game state | XP, levels, water points |
| Document storage | Farmer documents to R2 |
| Event indexing | Sync blockchain events |
Data stores
| Store | Purpose |
|---|
| PostgreSQL | Primary database |
| Valkey | Caching and sessions |
| Cloudflare R2 | Document storage |
Blockchain layer
Smart contracts
| Contract | Standard | Purpose |
|---|
| GoldToken | ERC-20 | Platform currency |
| GoldFaucet | — | Testnet distribution |
| OwnaFarmNFT | ERC-1155 | Invoice tokens |
| OwnaFarmVault | — | Yield reserve |
Why Mantle
| Feature | Benefit |
|---|
| Layer 2 | Low gas fees |
| EVM compatible | Standard tooling |
| Fast finality | Quick confirmations |
Data distribution
| Data type | Location | Reason |
|---|
| Financial state | Blockchain | Immutable, trustless |
| User identity | Database | Privacy, compliance |
| Game mechanics | Database | Flexibility |
| Documents | Cloud storage | Size, access |
Communication patterns
REST API (JSON)
POST /api/farmers/register
GET /api/user/profile
POST /api/game/water