Meals
The week's plan, the dishes you eat, who's eating what, and what to buy for it.
Commands
- PostAdd a dish to the household's dish list
meals.dish.createAdds a dish such as "chicken quesadilla". - PostReplace one dish with another everywhere, then delete it
meals.dish.mergeEvery meal that has dish_id gets into_dish_id instead, in the same place (a meal that already has both just loses dish_id). into_dish_id keeps its own recipe; if it has none and dish_id has one, it takes that recipe and its own ingredients are deleted (a dish with a recipe has none). - PostMake a new icon for a dish
meals.dish.regenerate_iconAsks for a new icon for the dish. - PostDelete a dish no meal uses
meals.dish.removeDeletes the dish, its ingredients and any plate icons that include it. - PostSet what to buy for a dish
meals.dish.set_ingredientsReplaces what to buy for the dish with items, in order, so the week's groceries can be worked out. - PostRename a dish, link or unlink its recipe, or mark it as eaten away from home
meals.dish.updateSets only the fields given. - PostMove a meal to another date or slot
meals.meal.moveMoves the meal. - PostPlan a meal for some people
meals.meal.planPlans one meal: a date, a slot, who it is for and its dishes. - PostDelete a meal
meals.meal.removeDeletes the meal for everyone it was for. - PostTake one person out of a meal
meals.meal.remove_personFor "Theo is at grandma's on Saturday": removes the person from the meal and leaves the others. - PostChange a meal's people, dishes or note
meals.meal.updateSets only what is given. person_ids replaces who the meal is for (anyone added is taken out of their other meal at that date and slot). dishes replaces the dishes, as in meals.meal.plan (including { recipe_id }). note replaces the kitchen note; null clears it. - PostChange when Rigel plans the week, or when a plan week starts
meals.setting.updateSets only the fields given: planning_weekday and planning_time (when Rigel fills the coming week, in the household's time zone), week_starts_on (the first day of a plan week), and is_auto_planning_on (false stops Rigel planning on its own). - PostPlan many meals at once without replacing any
meals.week.fillPlans a batch of meals (up to 200) in one step, only where people are open.
Queries
- GetOne dish, with what to buy for it
meals.dish.getThe dish with its name, whether it's eaten away from home, its icon, its recipe (id and title) and what to buy for it (products in order, with amount notes). - GetFind dishes by name
meals.dish.searchDishes whose name contains the text (ignoring case), names that start with it first, then the most often planned. - GetWhat people ate (or are planned to eat) between two dates
meals.eaten.listMeals from from to to, oldest first, up to 84 days apart. - GetMeal planning settings and which week is current
meals.setting.getThe effective settings (the defaults until someone changes them), plus current_week_start, the first day of the plan week containing today in the household's time zone, and next_week_start, the week after it. - GetWhat changed in a week's plan, and who changed it
meals.week.changesThe commands that changed the week's meals, newest first, from the command log: when, who (a person, Rigel, or an outside account), what was done in words, and the affected meals as they were before and after. - GetThe meal plan for a week
meals.week.getFor each of the 7 days from week_start and each slot (breakfast, lunch, dinner, snack): the meals planned, each with its people, dishes, note and icon, and which people have nothing planned in that slot (open_for). - GetWhat a week's meals need from the store
meals.week.groceriesOne item per product across the week's meals, with the amount notes, which meals need it, whether it's a staple, and what inventory has recorded of it.