Update news
update_newsCorrect or rewrite a published news entry: fix a headline, refresh a weekly report, or clear a stale teaser with targeted field updates.
Instructions
Correct or rewrite a published news entry.
Use it to fix a headline, refresh a weekly report in place, or clear a stale teaser. Only the parameters you pass are sent, so a concurrent edit to another field survives.
Returns the updated entry in the same shape as get_news.
Pitfalls: summary and description REPLACE the stored text — there is no
append. The entry's project and author are fixed at creation and cannot be updated
here; publish a new entry instead. News carries no lockVersion upstream, so there
is nothing to echo and no lock parameter: a simultaneous edit by somebody else is
silently overwritten, which is why reading with get_news first is worth it. The
'manage news' permission is required, so a 403 is about the account or a disabled
news module.
Cross-references: get_news for the current text and for can_manage;
delete_news when the entry should disappear entirely; create_news to publish
a follow-up instead of rewriting history.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | New headline, up to 256 characters. Omit to leave it alone; it cannot be cleared, because news requires a title. | |
| news_id | Yes | Numeric news id from list_news or get_news. | |
| summary | No | New teaser (plain text, up to 255 characters); REPLACES the existing one. Pass null or an empty string to clear it. Omit the parameter entirely (the default) to leave it untouched. | __unchanged__ |
| description | No | New markdown body; REPLACES the existing text rather than appending to it, so read the current one with get_news first if you mean to extend it. Pass null or an empty string to clear it. Omit to leave it untouched. | __unchanged__ |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | News id — what get_news, update_news and delete_news consume. | |
| title | No | Headline of the announcement. | |
| author | No | User who published it ({id, name}); set by the server. | |
| project | No | Project the announcement belongs to ({id, name}). | |
| summary | No | Short teaser OpenProject shows under the headline; may be empty. The full body is NOT here — read it with get_news(news_id=...). | |
| can_manage | No | True when this account may change or delete this entry (OpenProject renders the update/delete links only with the 'manage news' permission). False means update_news and delete_news would fail with 403. | |
| created_at | No | ISO 8601 UTC publication timestamp. | |
| updated_at | No | ISO 8601 UTC timestamp. | |
| description | No | The announcement body as markdown (raw); html is dropped. Empty string when the entry has only a headline and summary. |