🐾 Phauna Hub

api.euzo.ai

Agent API

The bridge between the agent swarm and the platform. RESTful endpoints for reading, writing, and orchestrating data across euzo.ai.

πŸ”¨ Building now β€” this page is the live spec

The Agent Swarm

12 specialized AI agents, orchestrated by Jellie, working in parallel to build and maintain euzo.ai.

πŸ‡JellieOpus
Orchestrator β€” dispatches work, talks to humans, manages everything
πŸ—οΈForemanSonnet
Accountability β€” watches capacity, auto-dispatches work, keeps queue moving
πŸ”ResearcherSonnet
Investigation β€” website crawling, 990 analysis, press research, PDF processing
πŸ“šOracleOpus
Knowledge β€” master org index, query engine, cross-org analysis
✍️WriterSonnet
Content β€” grant writeups, org profiles, report generation
🎭StylistSonnet
Formatting β€” Google Docs styling, brand spec, document polish
πŸ”—IntegratorSonnet
Sync β€” Airtable, Google Drive, cross-system data flow
πŸ“OrganizerSonnet
Files β€” Drive structure, folder management, Airtable architecture
πŸ’°FinancialSonnet
Finance β€” QuickBooks, budgets, investment tracking, Phauna's money
πŸ‘οΈObserverSonnet
Monitoring β€” system health, cost tracking, performance dashboards
🎨DesignerSonnet
Design β€” design system, tokens, themes, component patterns, accessibility
πŸ“ArchitectSonnet
Infrastructure β€” server, DB schema, monorepo, deployment, security

API Endpoints (Planned)

GET/entitiesList all entities with filters (type, status, search)
GET/entities/:idFull entity profile with related grants, contacts, interactions
POST/entitiesCreate new entity
GET/grantsList grants with filters (status, entity, date range, amount)
GET/grants/:idFull grant detail with payments, timeline, documents
POST/grantsCreate new grant record
PATCH/grants/:idUpdate grant status, amount, notes
GET/paymentsList payments with filters
GET/contactsList contacts, search by name/org
GET/searchFederated search across all data types
GET/directoryMovement directory β€” all orgs with research data
POST/tasksCreate task (replacing Asana)
POST/webhooksRegister webhook for real-time updates

Authentication

Cloudflare Access

Planned

Google Workspace SSO for team members. Sabina, Aidan, Owen, John β€” all authenticate via phaunaproject.org email.

API Keys

Planned

Per-agent API keys for programmatic access. Scoped permissions per agent role.

Webhook Signatures

Planned

HMAC-signed webhook payloads for secure event delivery.

Data Flow

1
Agent needs data β†’ hits api.euzo.ai endpoint
2
API authenticates, validates, queries PostgreSQL
3
Response returned with pagination, includes, links
4
Agent processes data, performs task
5
Agent writes results back via POST/PATCH
6
Webhooks fire to notify other agents/systems

Tech Stack

  • Next.js API routes (or standalone Express) β€” REST endpoints
  • PostgreSQL + Prisma 6 β€” shared database
  • Cloudflare Access β€” SSO authentication
  • Rate limiting β€” per-agent quotas
  • OpenAPI spec β€” auto-generated documentation
  • Webhook system β€” real-time event delivery
euzo.ai β€” Ξ΅α½– ΞΆαΏ·Built by Jellie πŸ‡ + 12 AI agents