Update product schedule
suppco_update_product_scheduleDestructiveIdempotent
Use this when the user wants to change when or how they take a product that is already in their stack. Replaces that product's schedule: time-of-day amounts, daily, specific-days or every-other-day timing, as-needed, with food, and timing notes.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| schedule | Yes | JSON array of time-slot assignments, e.g. [{"activity":"morning","units":2},{"activity":"bedtime","units":1}]. "units" is the number of capsules/tablets/scoops for that time slot — NOT servings. Valid activities: morning, midday, evening, bedtime, workout, unscheduled. | |
| as_needed | No | Whether the product is taken as needed (true/false). Omit to keep the current value — only pass it when the user asked to change it. | |
| with_food | No | Whether the product should be taken with food (true/false). Omit to keep the current value — only pass it when the user asked to change it. | |
| product_id | Yes | Product slug or UUID | |
| schedule_days | No | Array of day names (e.g. ["monday","wednesday","friday"]) for specific_days schedule_type | |
| schedule_type | No | Schedule type: daily, specific_days, or every_other_day | |
| schedule_notes | No | Brief timing instructions that the schedule cannot capture (e.g., "take 2 hours apart from calcium", "take on empty stomach 30 min before bed"). Set to empty string to clear. | |
| change_daily_amount | No | Set true ONLY when the user asked to change how many units they take per day. Without it, a schedule whose total differs from the current daily amount is rejected, so timing changes keep the same total. | |
| every_other_day_start | No | When to start every_other_day schedule: "today" or "tomorrow" |