עזרה של MediaWiki API

זהו דף תיעוד של API שנוצר באופן אוטומטי.

תיעוד ודוגמאות: https://www.mediawiki.org/wiki/API

action=tag

(main | tag)
  • יחידה זו דורשת הרשאות קריאה.
  • יחידה זו דורשת הרשאות כתיבה.
  • יחידה זו מקבלת רק בקשות POST.

Add or remove change tags from individual revisions or log entries.

פרמטרים:
rcid

One or more recent changes IDs from which to add or remove the tag.

הפרדה בין ערכים נעשית באמצעות | מספר הערכים המרבי הוא 50 (עבור בוטים – 500).
revid

One or more revision IDs from which to add or remove the tag.

הפרדה בין ערכים נעשית באמצעות | מספר הערכים המרבי הוא 50 (עבור בוטים – 500).
logid

One or more log entry IDs from which to add or remove the tag.

הפרדה בין ערכים נעשית באמצעות | מספר הערכים המרבי הוא 50 (עבור בוטים – 500).
add

Tags to add. Only manually defined tags can be added.

ערכים (מופרדים באמצעות "|"):
remove

Tags to remove. Only tags that are either manually defined or completely undefined can be removed.

הפרדה בין ערכים נעשית באמצעות | מספר הערכים המרבי הוא 50 (עבור בוטים – 500).
reason

Reason for the change.

ברירת מחדל: (ריק)
token

אסימון "csrf" אוחזר מ־action=query&meta=tokens

פרמטר זה נדרש.
דוגמאות:
Add the vandalism tag from revision ID 123 without specifying a reason
api.php?action=tag&revid=123&add=vandalism&token=123ABC
Remove the spam tag from log entry ID 123 with the reason Wrongly applied
api.php?action=tag&logid=123&remove=spam&reason=Wrongly+applied&token=123ABC