MediaWiki API ヘルプ
このページは自動生成された MediaWiki API の説明文書ページです。
説明文書と例: https://www.mediawiki.org/wiki/Special:MyLanguage/API:Main_page
action=pollny
(main | pollny)
- このモジュールは読み取りの権限を必要とします。
- ソース: PollNY
- ライセンス: GPL-2.0-or-later
PollNY API - includes both user and admin functions.
パラメーター:
その他一般パラメーターが利用可能です。
- what
What to do?
- この変数は必須です。
- choiceID
Same as clicking the <choiceID>th choice via the GUI; only used when what=vote.
- 型: 整数
- pollID
Poll ID of the poll that is being deleted/updated/voted for.
- 型: 整数
- pageID
Page ID (only used when what=getPollResults).
- 型: 整数
- status
New status of the poll (when what=updateStatus); possible values are 0 (=closed), 1 and 2 (=flagged).
- 型: 整数
例:
- Deletes the poll #66
- api.php?action=pollny&what=delete&pollID=66 [サンドボックスで開く]
- Gets the results of the poll #666
- api.php?action=pollny&what=getPollResults&pollID=666 [サンドボックスで開く]
- Gets a random poll to which the current user hasn't answered yet
- api.php?action=pollny&what=getRandom [サンドボックスで開く]
- Sets the status of the poll #47 to 1 (=open); possible status values are 0 (=closed), 1 and 2 (=flagged)
- api.php?action=pollny&what=updateStatus&pollID=47&status=1 [サンドボックスで開く]
- Votes (answers) the poll #33 with the 4th choice
- api.php?action=pollny&what=vote&pollID=33&choiceID=4 [サンドボックスで開く]