MediaWiki API help
This is an auto-generated MediaWiki API documentation page.
Documentation and examples: https://www.mediawiki.org/wiki/Special:MyLanguage/API:Main_page
action=bpmassedit
(main | bpmassedit)
- This module requires read rights.
- This module requires write rights.
- This module only accepts POST requests.
- Source: BP-MassEdit
- License: proprietary
Specific parameters:
Other general parameters are available.
- input_format
- ⧼apihelp-bpmassedit-param-input_format⧽
- One of the following values: json-batch, standard
- Default: standard
- operation
- ⧼apihelp-bpmassedit-param-operation⧽
- One of the following values: append, create, find-replace, prepend, replace-section
- pages
- ⧼apihelp-bpmassedit-param-pages⧽
- summary
- ⧼apihelp-bpmassedit-param-summary⧽
- Default: Mass edit
- find
- ⧼apihelp-bpmassedit-param-find⧽
- replace
- ⧼apihelp-bpmassedit-param-replace⧽
- text
- ⧼apihelp-bpmassedit-param-text⧽
- section
- ⧼apihelp-bpmassedit-param-section⧽
- batch_data
- ⧼apihelp-bpmassedit-param-batch_data⧽
- defaulttext
- ⧼apihelp-bpmassedit-param-defaulttext⧽
- token
A "csrf" token retrieved from action=query&meta=tokens
- This parameter is required.
Examples:
- ⧼Find and replace text across multiple pages⧽
- api.php?action=bpmassedit&operation=find-replace&pages=Page1|Page2&find=old text&replace=new text&token=TOKEN [open in sandbox]
- ⧼Append text to multiple pages⧽
- api.php?action=bpmassedit&operation=append&pages=Page1|Page2&text=[[Category:Example]]&token=TOKEN [open in sandbox]
- ⧼Append text to the References section of multiple pages⧽
- api.php?action=bpmassedit&operation=append&pages=Page1|Page2&text=New content§ion=References&token=TOKEN [open in sandbox]
- ⧼Replace section content on a page⧽
- api.php?action=bpmassedit&operation=replace-section&pages=Page1§ion=References&text=New content&token=TOKEN [open in sandbox]
- ⧼Submit a JSON batch with different operations per page⧽
- api.php?action=bpmassedit&format=json-batch&batch_data=[{"page":"Page1","operation":"find-replace","find":"old","replace":"new"},{"page":"Page2","operation":"append","text":"content"}]&token=TOKEN [open in sandbox]