Trợ giúp về API MediaWiki

This is an auto-generated MediaWiki API documentation page.

Documentation and examples: https://www.mediawiki.org/wiki/Special:MyLanguage/API:Main_page

action=rollback

(main | rollback)
  • Mô đun này cần quyền đọc.
  • Mô đun này cần quyền ghi.
  • Mô đun này chỉ có nhận các yêu cầu POST.
  • Source: MediaWiki
  • License: GPL-2.0-or-later

Lùi lại sửa đổi cuối cùng của trang này.

Nếu người dùng cuối cùng đã sửa đổi trang này nhiều lần, tất cả chúng sẽ được lùi lại cùng một lúc.

Các tham số:
title

Title of the page to roll back. Cannot be used together with pageid.

pageid

Page ID of the page to roll back. Cannot be used together with title.

Type: integer
tags

Tags to apply to the rollback.

Các giá trị (phân tách bằng |):
user

Name of the user whose edits are to be rolled back.

This parameter is required.
Kiểu: người dùng, bằng một giá trị bất kỳ trong tên người dùng, địa chỉ IP, tên người dùng liên wiki (ví dụ “tiền tố>TênVíDụ”) và số người dùng (ví dụ “#12345”)
summary

Custom edit summary. If empty, default summary will be used.

Mặc định: (trống)
markbot

Mark the reverted edits and the revert as bot edits.

Type: boolean (details)
watchlist

Unconditionally add or remove the page from the current user's watchlist, use preferences (ignored for bot users) or do not change watch.

Một trong các giá trị: nochange, preferences, unwatch, watch
Default: preferences
token

A "rollback" token retrieved from action=query&meta=tokens

For compatibility, the token used in the web UI is also accepted.

This parameter is required.
Các ví dụ:
Roll back the last edits to page Main Page by user Example.
api.php?action=rollback&title=Main%20Page&user=Example&token=123ABC [open in sandbox]
Roll back the last edits to page Main Page by IP user 192.0.2.5 with summary Reverting vandalism, and mark those edits and the revert as bot edits.
api.php?action=rollback&title=Main%20Page&user=192.0.2.5&token=123ABC&summary=Reverting%20vandalism&markbot=1 [open in sandbox]