How johanprise/restok-app works
Restock is a shared household inventory app. A member uses the mobile shelf, shopping list, or recipe screens; persisted/offline queries call the authenticated NestJS API, which applies group permissions and updates inventory state in PostgreSQL. Missing stock feeds shopping, while recipes are searchable from Wikibooks and ranked client-side against cached items. Item actions dispatch events to the shared journal and notifications. The tree and README document these integrations; several service internals were not sampled, so those links remain intentionally broad.
Components 17
Mobile app
- Mobile screens
mobile/app - Query cache
mobile/src/api/query-client.ts - Client logic
mobile/src/lib - Localization
mobile/src/i18n
Identity and groups
- Authentication
backend/src/auth/auth.service.ts - Groups and members
backend/src/groups/groups.controller.ts
Inventory and shopping
- Inventory actions
backend/src/items/items.controller.ts - Shopping list
backend/src/shopping/shopping.controller.ts
Recipes and audit
- Recipe service
backend/src/recipes/recipes.controller.ts - Domain events
backend/src/app.module.ts - Action journal
backend/src/action-history/action-history.controller.ts
Notifications and mail
- Push notifications
backend/src/notifications/notifications.module.ts - Mail delivery
backend/src/mail/mail.module.ts
Other components
- Member
- PostgreSQL
- Wikibooks catalogue
- Expo push API
Connections 23
- Member → Mobile screens: uses
- Mobile screens → Query cache: reads and writes
- Mobile screens → Localization: renders text
- Query cache → Authentication: HTTPS requests
- Query cache → Groups and members: HTTPS requests
- Query cache → Inventory actions: HTTPS requests
- Query cache → Shopping list: HTTPS requests
- Query cache → Recipe service: HTTPS requests
- Query cache → Action journal: HTTPS requests
- Query cache → Client logic: provides cache
- Client logic → Mobile screens: returns feasibility
- Authentication → PostgreSQL: reads and writes
- Groups and members → PostgreSQL: reads and writes
- Inventory actions → PostgreSQL: reads and writes
- Shopping list → PostgreSQL: reads and writes
- Recipe service → PostgreSQL: reads and writes
- Shopping list → Inventory actions: reads stock
- Recipe service → Wikibooks catalogue: searches catalogue
- Inventory actions → Domain events: dispatches events
- Domain events → Action journal: records actions
- Domain events → Push notifications: dispatches alerts
- Push notifications → Expo push API: sends pushes
- Authentication → Mail delivery: sends reset code