POST
/api/v1/households/{householdId}/candidates/generatePut a day's new dinner suggestions in the planning queue
Adults only; a Junior member gets 403. Answers 202 with the run's id (ADR-289): the model call is a background job, GET plans/runs/{jobId} says where it stands, and GET candidates for the day has the suggestions once it is done. Costs credits and replaces the day's current candidates, except one a plan entry still points at. A run that ends in candidate_pool_in_plan — somebody planned the week over these very candidates while they were being replaced (#533) — says so on its status; read the day again and ask once more.
Parametre
| Navn | Hvor | Type | Påkrevd | Beskrivelse |
|---|---|---|---|---|
householdId | path | string (uuid) | Påkrevd | — |
Forespørselskropp
Svar
- 202Accepted
application/jsonPlanRunAccepted- 400Bad Request
application/problem+jsonProblemDetails- 401No session, or the session is no longer valid.
application/problem+jsonProblemDetails- 404Not Found
application/problem+jsonProblemDetails- 426The build named in X-App-Version is below its platform's version floor (ADR-070). Problem type app-version-unsupported; the only way forward is the store. Callers without the header are never turned away.
application/problem+jsonProblemDetails- 429Too many calls in the window; Retry-After says how long.
application/problem+jsonProblemDetails- Hoder
Retry-After- — Seconds to wait when a rate limit answered, or an HTTP date when the household's AI is paused. Absent when the household's AI quota for the period is used up — that resets by itself.
Eksempel
curl -b "bryti_session=…" \
-X POST \
"https://bryti.app/api/v1/households/3fa85f64-5717-4562-b3fc-2c963f66afa6/candidates/generate" \
-H "Content-Type: application/json" \
-d '{"date":"2026-09-07","category":"Fish"}'Eksempel på svar
202
application/json{
"jobId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"weekStart": "2026-09-07"
}