Page MenuHomePhabricator

Curator reverts to a previous revision
Open, MediumPublic

Description

"As a Curator, I want to revert to a previous revision of a page, so that the best known revision of a page is always the current one."

POST /page/{title}/revert

Makes the content of the revision with ID in request body the current content of the page.

Request body: JSON object

  • id: ID of the revision to revert to
  • comment: comment about the rollback

Notable request headers: none

Status codes:
200 - OK, that worked
400 - client error, such as no such revision
403 - not authorized
404 - no such page

Notable response headers: none

Response body: JSON object, new revision created by the rollback

  • id: revision ID of the new revision created by the rollback, not the revision that was rolled-back-to
  • page: Object with these fields
    • id: ID of the page
    • title: current title of the page (might have been changed)
  • user: user who made the change, object with these fields
    • id: ID of the user or null for anonymous
    • name: name of the user or unique identifier for anonymous
  • comment: User comment ("edit summary") describing the change that generated this revision
  • timestamp: time the revision was made
  • size: size of the revision in "bogobytes" (as from DB, usually bytes)
  • delta: change from previous revision in "bogobytes" (as from DB, usually bytes)
  • minor: was this a minor revision? boolean

Event Timeline

eprodromou renamed this task from Curator rolls back to a previous version to Curator rolls back to a previous revision.Oct 11 2019, 1:31 AM
eprodromou updated the task description. (Show Details)
eprodromou updated the task description. (Show Details)Nov 6 2019, 8:22 PM
eprodromou updated the task description. (Show Details)
eprodromou updated the task description. (Show Details)
eprodromou removed a subscriber: CCicalese_WMF.
eprodromou triaged this task as Medium priority.Nov 6 2019, 9:05 PM

I have posted the first round of comments about this story in the undo story T237577#5645099cause they are very similar. I have more comments about this one, but we first need to go through the first round, that might make the rest of the comments not relevant.

eprodromou renamed this task from Curator rolls back to a previous revision to Curator reverts to a previous revision.Nov 10 2019, 2:42 PM
eprodromou updated the task description. (Show Details)
eprodromou updated the task description. (Show Details)

@Pchelolo I changed the endpoint name and description so that it doesn't conflict with the MediaWiki "rollback" concept. I'll create another user story for MW rollback.

JMinor added a subscriber: JMinor.Nov 12 2019, 9:15 PM