This issue will deliver a first set of REST endpoints, focused on the "propose a change" side of Change Request (e.g. the documentation-fixing agent use case): the review and merge steps still happen in the UI. The detailed design is in the linked "Change Request REST API plan".
Covered here:
Extraction of the change request edition logic (creation, adding a file change, metadata update, deletion) out of the UI resource handlers into a public Java API, used by both the UI and REST.
/rest/wikis/<wiki>/changerequests: list (filters: status, author, changed page; paginated) and create.
.../<id>/status: draft <-> ready for review, close, reopen.
Capabilities (can edit/review/merge/delete, mergeable, has conflicts) and links to the allowed next operations in every representation.
XML and JSON, Basic auth or session, rights enforced as in the UI.
Not covered here (follow-up issues will be created and linked):
Reviews and approvers (including delegate approvers).
Merge, rebase and split.
Discussions (on the change request and on diff locations).
Diff representation of a file change.
Attachments in file changes.
Exact total count when listing: results are filtered by view right after the query, so only "next" links are provided.
The ready for merging and merged statuses can't be set through the status endpoint: the first is computed from approvals, the second will only be reachable through the merge endpoint.
This message was sent by Atlassian Jira (v9.3.0#930000-sha1:287aeb6)
If image attachments aren't displayed, see this article.