Context
The onboarding API contract must be the single source of truth for frontend ↔ backend onboarding interactions. It must be explicit and verifiable (real JSON, real states, real action values).
Affected paths
- docs/ai/api/CONTRACT_onboarding_action.md
Steps
- Add a clear State Machine section:
- list canonical states for
onboarding_basic: start, ask_name, ask_goal, summary, end
- allowed transitions and what triggers them
- Add an Actions section with the real enum used by the client (e.g.
START, SUBMIT_TEXT, SELECT_OPTION) and explain:
- when each action is valid
- what
value contains for each action
- Add request/response JSON examples per state (valid JSON):
- happy path
- invalid action
- invalid/empty value
- Add explicit rule: no extra questions in
summary and end.
- Add a small “Error responses” section (shape + examples).
- Ensure this contract does not silently define states that are not in
onboarding_basic (design-only flows must be clearly labeled as out-of-scope for this Epic).
Definition of Done
- Contract includes a state table and action table
- All JSON examples are valid JSON and match the described schema
- Canonical states for
onboarding_basic are explicitly documented
- Summary/end rule (“no extra questions”) is explicit
- No contradictions with
docs/ai/workflows/onboarding_basic.yaml and docs/ai/tests/onboarding_basic.md
Context
The onboarding API contract must be the single source of truth for frontend ↔ backend onboarding interactions. It must be explicit and verifiable (real JSON, real states, real action values).
Affected paths
Steps
onboarding_basic:start,ask_name,ask_goal,summary,endSTART,SUBMIT_TEXT,SELECT_OPTION) and explain:valuecontains for each actionsummaryandend.onboarding_basic(design-only flows must be clearly labeled as out-of-scope for this Epic).Definition of Done
onboarding_basicare explicitly documenteddocs/ai/workflows/onboarding_basic.yamlanddocs/ai/tests/onboarding_basic.md