velxio/backend/app
David Montero Crespo 5f0e7523ed feat(backend): subscription state columns on users table
Adds 4 nullable columns to the users table so deployments that wire an
external billing system (e.g. velxio.dev with Odoo) have a place to cache
subscription status. Self-hosters never write these — defaults are safe
(no paid features unlock).

- models/user.py: is_paid_subscriber (bool, default false), subscription_status
  (str|None), subscription_period_end (datetime|None), odoo_partner_id
  (int|None, indexed).
- main.py: 4 ALTER TABLE statements appended to the legacy_migrations list
  so existing deployments auto-migrate on next boot.
- schemas/auth.py: extend UserResponse with the 3 user-visible fields
  (is_paid_subscriber, subscription_status, subscription_period_end). The
  frontend useAuthStore already persists the whole UserResponse, so these
  surface automatically without any frontend changes upstream.
  odoo_partner_id stays internal — clients don't need it.

Zero behavioural change for existing OSS deployments.
2026-05-05 10:21:37 -03:00
..
api Merge pull request #137 from davidmonterocrespo24/esp32-cam 2026-05-02 22:40:06 -03:00
core
database
mcp feat: integrate MCP (Model Context Protocol) for agent compatibility 2026-03-11 15:29:55 +00:00
models feat(backend): subscription state columns on users table 2026-05-05 10:21:37 -03:00
schemas feat(backend): subscription state columns on users table 2026-05-05 10:21:37 -03:00
services fix(espidf): include non-utility subdirs for libs without src/ layout 2026-05-04 15:41:53 +02:00
utils feat(metrics): add usage analytics dashboard with country tracking 2026-04-25 19:47:40 -03:00
__init__.py
main.py feat(backend): subscription state columns on users table 2026-05-05 10:21:37 -03:00