feat(backend): stabilize draft editor flow and complete smoke regression baseline

- add editor entry flow with editor context and ensure-draft bootstrap
- add draft summary read model and single-record draft read endpoints
- add typed draft, edit and publish conflicts with validation errors
- add pricing diagnostics and publish readiness endpoints
- fix Decimal serialization in seat price and test preview flows
- harden draft lifecycle guards for published vs draft current version
- update API map and smoke regression checklist
- add backend README and smoke regression script
This commit is contained in:
greebo
2026-03-19 22:23:46 +03:00
parent 77496dac46
commit 127c5bff71
5 changed files with 681 additions and 49 deletions

View File

@@ -21,6 +21,7 @@
- GET /api/v1/schemes/{scheme_id}/versions
- POST /api/v1/schemes/{scheme_id}/versions
- GET /api/v1/schemes/{scheme_id}/publish/validation
- GET /api/v1/schemes/{scheme_id}/draft/publish-readiness
- POST /api/v1/schemes/{scheme_id}/publish
- POST /api/v1/schemes/{scheme_id}/unpublish
- POST /api/v1/schemes/{scheme_id}/rollback
@@ -58,7 +59,6 @@
## app/api/routes/publish.py
- POST /api/v1/schemes/{scheme_id}/draft/pricing/snapshot
- GET /api/v1/schemes/{scheme_id}/draft/publish-preview
- GET /api/v1/schemes/{scheme_id}/draft/publish-readiness
- POST /api/v1/schemes/{scheme_id}/draft/remap/preview
- POST /api/v1/schemes/{scheme_id}/draft/remap/apply
@@ -94,4 +94,4 @@
- This file is an operational route index, not a generated OpenAPI export.
- Update this map in the same change set when adding, removing, renaming, or moving routes.
- Query guards such as expected_current_scheme_version_id / expected_scheme_version_id are part of the operational contract for optimistic concurrency on mutable flows.
- Draft/editor routes may legally return 409 draft_not_editable when current version is already published and no editable draft exists yet.
- Draft editor flow starts from editor/context and draft/ensure, not from direct blind mutation calls.