update_habit
Update an existing habit by changing only specified fields like name, reminders, or status, without affecting other properties.
Instructions
Update an existing habit. Only provided fields are changed
(read-modify-write under the hood — safe for partial updates).
[Category: Habits] [Auth: V2]
[Related: list_habits, create_habit, delete_habit]
Args:
habit_id: The habit ID to update.
name: New name.
goal: New target value (Real habits).
step: New increment step.
unit: New measurement unit.
color: New hex color.
status: 0=active, 2=archived.
section_id: Move to a different section.
repeat_rule: New RRULE (use build_recurrence_rule).
reminders: New reminder times list, e.g. ["08:00", "20:00"].
Pass [] to clear all reminders.
encouragement: New completion message.
target_days: New target days.
⚠️ CRITICAL — V2 /habits/batch is a FULL REPLACEMENT, not a PATCH:
Sending only {"id": ..., "reminders": [...]} will wipe name, color,
status and every other field to null/default. This tool prevents that
by fetching the current habit state first, then merging your changes
before sending the complete object. Never call client.batch_habits
with a partial habit dict directly.
Common uses:
Archive: update_habit(habit_id="...", status=2)
Rename: update_habit(habit_id="...", name="New Name")
Add reminders: update_habit(habit_id="...", reminders=["08:00", "20:00"])
Clear reminders: update_habit(habit_id="...", reminders=[])Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| habit_id | Yes | ||
| name | No | ||
| goal | No | ||
| step | No | ||
| unit | No | ||
| color | No | ||
| status | No | ||
| section_id | No | ||
| repeat_rule | No | ||
| reminders | No | ||
| encouragement | No | ||
| target_days | No |