Community engagement
recommendation_requests
"Ask locals" — a question posted for a city, answered by recommendations (which write into `reviews` with source='recommendation').
Columns
| Column | Type | Null | Default | Keys |
|---|---|---|---|---|
| id | uuid | no | gen_random_uuid() | PK |
| city_slug | text | no | — | |
| asker_id | uuid | no | — | |
| question | text | no | — | |
| status | text openclosed | no | "open" | |
| created_at | timestamp | yes | now() |
Value lists come from .$type<'a' | 'b'>() in the schema — enforced in TypeScript only, not by the database.
Keys, constraints & indexes
Unique
None besides the primary key.
Indexes
No secondary indexes.
Foreign keys
- asker_id → dancers.id on delete no action
Used by
Code that reads or writes this table, found by static analysis of the tRPC routers and API handlers (including helpers they call).
tRPC procedures
REST & webhooks
- ANY /mcp
- ANY /mcp/public
Relations
Rendering diagram…
Diagram source
erDiagram
dancers {
uuid id PK
text email UK
text neon_auth_id UK
text username UK
}
recommendation_requests {
uuid id PK
uuid asker_id FK
}
dancers ||--o{ recommendation_requests : "asker_id" Defined at server/database/schema.ts:314 as recommendationRequests.