Remove work package watcher
remove_work_package_watcherUnsubscribe a user from work package notifications to stop updates for those who no longer need them. Specify the work package and user ID to remove watch access.
Instructions
Unsubscribe a user from a work package's notifications.
Use this to stop notifying someone who no longer needs the updates. Returns the user, the watch state after the call (always not watching) and a confirmation message.
Pitfalls. OpenProject answers the same 204 whether or not the user was
watching, so changed comes back null — do not report "removed" as
proof that they were subscribed. Removing another user needs the
delete-work-package-watchers permission; removing yourself only needs
view access. A 404 means the user id is unknown (or the work package
is), not that they were not watching. This does not unassign anyone and
does not remove them from the project.
Cross-references: get_work_package(include=['watchers']) shows who
watches today; add_work_package_watcher is the reverse.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| user_id | Yes | Numeric id of the watcher to remove. get_work_package(include=['watchers']) lists the current watchers with their ids. The string 'me' is not accepted here. | |
| work_package_id | Yes | Work package to unsubscribe the user from. Ids come from search_work_packages, list_work_packages or get_work_package. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| user | No | The watcher. 'id' is the user id; 'name' is filled in only when OpenProject returned the user resource (it does on add, not on remove). | |
| changed | No | True when this call actually changed the watcher list, false when the user was already watching. Null when OpenProject does not report it — removals answer 204 whether or not the user was watching. | |
| message | Yes | Human-readable confirmation. | |
| watching | Yes | Watch state after the call: true after adding, false after removing. | |
| work_package_id | Yes | Work package whose watcher list was changed. |