mediawiktory 0.0.3 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (558) hide show
  1. checksums.yaml +4 -4
  2. data/.dokaz +1 -0
  3. data/.rubocop_todo.yml +16 -0
  4. data/.yardopts +2 -0
  5. data/CHANGELOG.md +10 -4
  6. data/CONTRIBUTING.md +6 -9
  7. data/README.md +153 -72
  8. data/bin/mediawiktory-gen +35 -0
  9. data/lib/media_wiktory.rb +2 -0
  10. data/lib/mediawiktory.rb +13 -14
  11. data/lib/mediawiktory/generator.rb +107 -0
  12. data/lib/mediawiktory/generator/api.rb +75 -0
  13. data/lib/mediawiktory/generator/module.rb +105 -0
  14. data/lib/mediawiktory/generator/param.rb +271 -0
  15. data/lib/mediawiktory/generator/renderable.rb +59 -0
  16. data/lib/mediawiktory/generator/templates/_action_method.erb +20 -0
  17. data/lib/mediawiktory/generator/templates/_module_in_param_docs.erb +2 -0
  18. data/lib/mediawiktory/generator/templates/_param_impl_boolean.erb +1 -0
  19. data/lib/mediawiktory/generator/templates/_param_impl_enum.erb +1 -0
  20. data/lib/mediawiktory/generator/templates/_param_impl_enum_of_modules.erb +1 -0
  21. data/lib/mediawiktory/generator/templates/_param_impl_string.erb +1 -0
  22. data/lib/mediawiktory/generator/templates/_param_impl_timestamp.erb +1 -0
  23. data/lib/mediawiktory/generator/templates/_param_method.erb +14 -0
  24. data/lib/mediawiktory/generator/templates/action.rb.erb +204 -0
  25. data/lib/mediawiktory/generator/templates/action_class.rb.erb +30 -0
  26. data/lib/mediawiktory/generator/templates/actions.rb.erb +31 -0
  27. data/lib/mediawiktory/generator/templates/api.rb.erb +65 -0
  28. data/lib/mediawiktory/{client.rb → generator/templates/client.rb.erb} +24 -10
  29. data/lib/mediawiktory/generator/templates/module_class.rb.erb +22 -0
  30. data/lib/mediawiktory/generator/templates/response.rb.erb +122 -0
  31. data/lib/mediawiktory/version.rb +4 -2
  32. data/lib/mediawiktory/wikipedia/actions.rb +2296 -0
  33. data/lib/mediawiktory/wikipedia/actions/abusefiltercheckmatch.rb +55 -0
  34. data/lib/mediawiktory/wikipedia/actions/abusefilterchecksyntax.rb +31 -0
  35. data/lib/mediawiktory/wikipedia/actions/abusefilterevalexpression.rb +31 -0
  36. data/lib/mediawiktory/wikipedia/actions/abusefilterunblockautopromote.rb +39 -0
  37. data/lib/mediawiktory/wikipedia/actions/addstudents.rb +52 -0
  38. data/lib/mediawiktory/wikipedia/actions/antispoof.rb +31 -0
  39. data/lib/mediawiktory/wikipedia/actions/base.rb +351 -0
  40. data/lib/mediawiktory/wikipedia/actions/block.rb +132 -0
  41. data/lib/mediawiktory/wikipedia/actions/bouncehandler.rb +31 -0
  42. data/lib/mediawiktory/wikipedia/actions/categorytree.rb +39 -0
  43. data/lib/mediawiktory/wikipedia/actions/centralauthtoken.rb +25 -0
  44. data/lib/mediawiktory/wikipedia/actions/centralnoticechoicedata.rb +39 -0
  45. data/lib/mediawiktory/wikipedia/actions/centralnoticequerycampaign.rb +31 -0
  46. data/lib/mediawiktory/wikipedia/actions/changeauthenticationdata.rb +39 -0
  47. data/lib/mediawiktory/wikipedia/actions/checktoken.rb +52 -0
  48. data/lib/mediawiktory/wikipedia/actions/cirrus-config-dump.rb +25 -0
  49. data/lib/mediawiktory/wikipedia/actions/cirrus-mapping-dump.rb +25 -0
  50. data/lib/mediawiktory/wikipedia/actions/cirrus-settings-dump.rb +25 -0
  51. data/lib/mediawiktory/wikipedia/actions/clearhasmsg.rb +25 -0
  52. data/lib/mediawiktory/wikipedia/actions/clientlogin.rb +86 -0
  53. data/lib/mediawiktory/wikipedia/actions/compare.rb +71 -0
  54. data/lib/mediawiktory/wikipedia/actions/createaccount.rb +86 -0
  55. data/lib/mediawiktory/wikipedia/actions/cspreport.rb +38 -0
  56. data/lib/mediawiktory/wikipedia/actions/cxconfiguration.rb +39 -0
  57. data/lib/mediawiktory/wikipedia/actions/cxdelete.rb +55 -0
  58. data/lib/mediawiktory/wikipedia/actions/cxpublish.rb +95 -0
  59. data/lib/mediawiktory/wikipedia/actions/cxsave.rb +87 -0
  60. data/lib/mediawiktory/wikipedia/actions/cxsuggestionlist.rb +81 -0
  61. data/lib/mediawiktory/wikipedia/actions/cxtoken.rb +31 -0
  62. data/lib/mediawiktory/wikipedia/actions/delete.rb +103 -0
  63. data/lib/mediawiktory/wikipedia/actions/deleteeducation.rb +65 -0
  64. data/lib/mediawiktory/wikipedia/actions/deleteglobalaccount.rb +47 -0
  65. data/lib/mediawiktory/wikipedia/actions/echomarkread.rb +77 -0
  66. data/lib/mediawiktory/wikipedia/actions/echomarkseen.rb +57 -0
  67. data/lib/mediawiktory/wikipedia/actions/edit.rb +266 -0
  68. data/lib/mediawiktory/wikipedia/actions/editmassmessagelist.rb +65 -0
  69. data/lib/mediawiktory/wikipedia/actions/emailuser.rb +62 -0
  70. data/lib/mediawiktory/wikipedia/actions/enlist.rb +89 -0
  71. data/lib/mediawiktory/wikipedia/actions/expandtemplates.rb +129 -0
  72. data/lib/mediawiktory/wikipedia/actions/fancycaptchareload.rb +25 -0
  73. data/lib/mediawiktory/wikipedia/actions/featuredfeed.rb +57 -0
  74. data/lib/mediawiktory/wikipedia/actions/feedcontributions.rb +121 -0
  75. data/lib/mediawiktory/wikipedia/actions/feedrecentchanges.rb +159 -0
  76. data/lib/mediawiktory/wikipedia/actions/feedwatchlist.rb +108 -0
  77. data/lib/mediawiktory/wikipedia/actions/filerevert.rb +55 -0
  78. data/lib/mediawiktory/wikipedia/actions/flagconfig.rb +25 -0
  79. data/lib/mediawiktory/wikipedia/actions/globalblock.rb +76 -0
  80. data/lib/mediawiktory/wikipedia/actions/globaluserrights.rb +94 -0
  81. data/lib/mediawiktory/wikipedia/actions/graph.rb +47 -0
  82. data/lib/mediawiktory/wikipedia/actions/help.rb +64 -0
  83. data/lib/mediawiktory/wikipedia/actions/imagerotate.rb +25 -0
  84. data/lib/mediawiktory/wikipedia/actions/import.rb +116 -0
  85. data/lib/mediawiktory/wikipedia/actions/jsonconfig.rb +60 -0
  86. data/lib/mediawiktory/wikipedia/actions/jsondata.rb +31 -0
  87. data/lib/mediawiktory/wikipedia/actions/languagesearch.rb +39 -0
  88. data/lib/mediawiktory/wikipedia/actions/linkaccount.rb +79 -0
  89. data/lib/mediawiktory/wikipedia/actions/liststudents.rb +63 -0
  90. data/lib/mediawiktory/wikipedia/actions/login.rb +55 -0
  91. data/lib/mediawiktory/wikipedia/actions/logout.rb +25 -0
  92. data/lib/mediawiktory/wikipedia/actions/managetags.rb +80 -0
  93. data/lib/mediawiktory/wikipedia/actions/massmessage.rb +55 -0
  94. data/lib/mediawiktory/wikipedia/actions/mergehistory.rb +79 -0
  95. data/lib/mediawiktory/wikipedia/actions/mobileview.rb +170 -0
  96. data/lib/mediawiktory/wikipedia/actions/move.rb +131 -0
  97. data/lib/mediawiktory/wikipedia/actions/oathvalidate.rb +47 -0
  98. data/lib/mediawiktory/wikipedia/actions/opensearch.rb +105 -0
  99. data/lib/mediawiktory/wikipedia/actions/options.rb +80 -0
  100. data/lib/mediawiktory/wikipedia/actions/pagetriageaction.rb +67 -0
  101. data/lib/mediawiktory/wikipedia/actions/pagetriagelist.rb +142 -0
  102. data/lib/mediawiktory/wikipedia/actions/pagetriagestats.rb +59 -0
  103. data/lib/mediawiktory/wikipedia/actions/pagetriagetagging.rb +83 -0
  104. data/lib/mediawiktory/wikipedia/actions/pagetriagetemplate.rb +39 -0
  105. data/lib/mediawiktory/wikipedia/actions/paraminfo.rb +91 -0
  106. data/lib/mediawiktory/wikipedia/actions/parse.rb +286 -0
  107. data/lib/mediawiktory/wikipedia/actions/parsoid-batch.rb +31 -0
  108. data/lib/mediawiktory/wikipedia/actions/patrol.rb +60 -0
  109. data/lib/mediawiktory/wikipedia/actions/protect.rb +121 -0
  110. data/lib/mediawiktory/wikipedia/actions/purge.rb +155 -0
  111. data/lib/mediawiktory/wikipedia/actions/query.rb +325 -0
  112. data/lib/mediawiktory/wikipedia/actions/refresheducation.rb +57 -0
  113. data/lib/mediawiktory/wikipedia/actions/removeauthenticationdata.rb +39 -0
  114. data/lib/mediawiktory/wikipedia/actions/resetpassword.rb +47 -0
  115. data/lib/mediawiktory/wikipedia/actions/review.rb +54 -0
  116. data/lib/mediawiktory/wikipedia/actions/reviewactivity.rb +60 -0
  117. data/lib/mediawiktory/wikipedia/actions/revisiondelete.rb +125 -0
  118. data/lib/mediawiktory/wikipedia/actions/rollback.rb +96 -0
  119. data/lib/mediawiktory/wikipedia/actions/rsd.rb +25 -0
  120. data/lib/mediawiktory/wikipedia/actions/sanitize-mapdata.rb +39 -0
  121. data/lib/mediawiktory/wikipedia/actions/scribunto-console.rb +62 -0
  122. data/lib/mediawiktory/wikipedia/actions/setglobalaccountstatus.rb +81 -0
  123. data/lib/mediawiktory/wikipedia/actions/setnotificationtimestamp.rb +180 -0
  124. data/lib/mediawiktory/wikipedia/actions/setpagelanguage.rb +81 -0
  125. data/lib/mediawiktory/wikipedia/actions/shortenurl.rb +31 -0
  126. data/lib/mediawiktory/wikipedia/actions/sitematrix.rb +91 -0
  127. data/lib/mediawiktory/wikipedia/actions/spamblacklist.rb +36 -0
  128. data/lib/mediawiktory/wikipedia/actions/stabilize.rb +76 -0
  129. data/lib/mediawiktory/wikipedia/actions/stashedit.rb +113 -0
  130. data/lib/mediawiktory/wikipedia/actions/strikevote.rb +60 -0
  131. data/lib/mediawiktory/wikipedia/actions/tag.rb +117 -0
  132. data/lib/mediawiktory/wikipedia/actions/templatedata.rb +148 -0
  133. data/lib/mediawiktory/wikipedia/actions/thank.rb +47 -0
  134. data/lib/mediawiktory/wikipedia/actions/titleblacklist.rb +51 -0
  135. data/lib/mediawiktory/wikipedia/actions/tokens.rb +36 -0
  136. data/lib/mediawiktory/wikipedia/actions/transcodereset.rb +47 -0
  137. data/lib/mediawiktory/wikipedia/actions/ulslocalization.rb +31 -0
  138. data/lib/mediawiktory/wikipedia/actions/unblock.rb +76 -0
  139. data/lib/mediawiktory/wikipedia/actions/undelete.rb +99 -0
  140. data/lib/mediawiktory/wikipedia/actions/unlinkaccount.rb +39 -0
  141. data/lib/mediawiktory/wikipedia/actions/upload.rb +172 -0
  142. data/lib/mediawiktory/wikipedia/actions/userrights.rb +107 -0
  143. data/lib/mediawiktory/wikipedia/actions/validatepassword.rb +55 -0
  144. data/lib/mediawiktory/wikipedia/actions/visualeditor.rb +96 -0
  145. data/lib/mediawiktory/wikipedia/actions/visualeditoredit.rb +164 -0
  146. data/lib/mediawiktory/wikipedia/actions/watch.rb +164 -0
  147. data/lib/mediawiktory/wikipedia/actions/webapp-manifest.rb +25 -0
  148. data/lib/mediawiktory/wikipedia/actions/wikilove.rb +79 -0
  149. data/lib/mediawiktory/wikipedia/actions/zeroconfig.rb +44 -0
  150. data/lib/mediawiktory/wikipedia/api.rb +80 -0
  151. data/lib/mediawiktory/wikipedia/client.rb +61 -0
  152. data/lib/mediawiktory/wikipedia/modules/abusefilters.rb +85 -0
  153. data/lib/mediawiktory/wikipedia/modules/abuselog.rb +101 -0
  154. data/lib/mediawiktory/wikipedia/modules/allcategories.rb +104 -0
  155. data/lib/mediawiktory/wikipedia/modules/alldeletedrevisions.rb +213 -0
  156. data/lib/mediawiktory/wikipedia/modules/allfileusages.rb +95 -0
  157. data/lib/mediawiktory/wikipedia/modules/allimages.rb +183 -0
  158. data/lib/mediawiktory/wikipedia/modules/alllinks.rb +108 -0
  159. data/lib/mediawiktory/wikipedia/modules/allmessages.rb +143 -0
  160. data/lib/mediawiktory/wikipedia/modules/allpages.rb +182 -0
  161. data/lib/mediawiktory/wikipedia/modules/allredirects.rb +108 -0
  162. data/lib/mediawiktory/wikipedia/modules/allrevisions.rb +181 -0
  163. data/lib/mediawiktory/wikipedia/modules/alltransclusions.rb +108 -0
  164. data/lib/mediawiktory/wikipedia/modules/allusers.rb +141 -0
  165. data/lib/mediawiktory/wikipedia/modules/authmanagerinfo.rb +63 -0
  166. data/lib/mediawiktory/wikipedia/modules/babel.rb +30 -0
  167. data/lib/mediawiktory/wikipedia/modules/backlinks.rb +100 -0
  168. data/lib/mediawiktory/wikipedia/modules/betafeatures.rb +30 -0
  169. data/lib/mediawiktory/wikipedia/modules/blocks.rb +127 -0
  170. data/lib/mediawiktory/wikipedia/modules/categories.rb +90 -0
  171. data/lib/mediawiktory/wikipedia/modules/categoryinfo.rb +30 -0
  172. data/lib/mediawiktory/wikipedia/modules/categorymembers.rb +183 -0
  173. data/lib/mediawiktory/wikipedia/modules/centralnoticelogs.rb +70 -0
  174. data/lib/mediawiktory/wikipedia/modules/checkuser.rb +83 -0
  175. data/lib/mediawiktory/wikipedia/modules/checkuserlog.rb +83 -0
  176. data/lib/mediawiktory/wikipedia/modules/contenttranslation.rb +83 -0
  177. data/lib/mediawiktory/wikipedia/modules/contenttranslationcorpora.rb +50 -0
  178. data/lib/mediawiktory/wikipedia/modules/contenttranslationlangtrend.rb +51 -0
  179. data/lib/mediawiktory/wikipedia/modules/contenttranslationstats.rb +22 -0
  180. data/lib/mediawiktory/wikipedia/modules/contenttranslationsuggestions.rb +70 -0
  181. data/lib/mediawiktory/wikipedia/modules/contributors.rb +90 -0
  182. data/lib/mediawiktory/wikipedia/modules/coordinates.rb +80 -0
  183. data/lib/mediawiktory/wikipedia/modules/cxpublishedtranslations.rb +54 -0
  184. data/lib/mediawiktory/wikipedia/modules/cxtranslatorstats.rb +30 -0
  185. data/lib/mediawiktory/wikipedia/modules/deletedrevisions.rb +169 -0
  186. data/lib/mediawiktory/wikipedia/modules/deletedrevs.rb +148 -0
  187. data/lib/mediawiktory/wikipedia/modules/duplicatefiles.rb +58 -0
  188. data/lib/mediawiktory/wikipedia/modules/embeddedin.rb +93 -0
  189. data/lib/mediawiktory/wikipedia/modules/extlinks.rb +66 -0
  190. data/lib/mediawiktory/wikipedia/modules/extracts.rb +81 -0
  191. data/lib/mediawiktory/wikipedia/modules/exturlusage.rb +92 -0
  192. data/lib/mediawiktory/wikipedia/modules/featureusage.rb +59 -0
  193. data/lib/mediawiktory/wikipedia/modules/filearchive.rb +104 -0
  194. data/lib/mediawiktory/wikipedia/modules/filerepoinfo.rb +35 -0
  195. data/lib/mediawiktory/wikipedia/modules/fileusage.rb +77 -0
  196. data/lib/mediawiktory/wikipedia/modules/flagged.rb +22 -0
  197. data/lib/mediawiktory/wikipedia/modules/g-allcategories.rb +91 -0
  198. data/lib/mediawiktory/wikipedia/modules/g-alldeletedrevisions.rb +200 -0
  199. data/lib/mediawiktory/wikipedia/modules/g-allfileusages.rb +82 -0
  200. data/lib/mediawiktory/wikipedia/modules/g-allimages.rb +170 -0
  201. data/lib/mediawiktory/wikipedia/modules/g-alllinks.rb +95 -0
  202. data/lib/mediawiktory/wikipedia/modules/g-allpages.rb +182 -0
  203. data/lib/mediawiktory/wikipedia/modules/g-allredirects.rb +95 -0
  204. data/lib/mediawiktory/wikipedia/modules/g-allrevisions.rb +168 -0
  205. data/lib/mediawiktory/wikipedia/modules/g-alltransclusions.rb +95 -0
  206. data/lib/mediawiktory/wikipedia/modules/g-backlinks.rb +100 -0
  207. data/lib/mediawiktory/wikipedia/modules/g-categories.rb +77 -0
  208. data/lib/mediawiktory/wikipedia/modules/g-categorymembers.rb +170 -0
  209. data/lib/mediawiktory/wikipedia/modules/g-contenttranslation.rb +83 -0
  210. data/lib/mediawiktory/wikipedia/modules/g-contenttranslationsuggestions.rb +70 -0
  211. data/lib/mediawiktory/wikipedia/modules/g-deletedrevisions.rb +156 -0
  212. data/lib/mediawiktory/wikipedia/modules/g-duplicatefiles.rb +58 -0
  213. data/lib/mediawiktory/wikipedia/modules/g-embeddedin.rb +93 -0
  214. data/lib/mediawiktory/wikipedia/modules/g-exturlusage.rb +79 -0
  215. data/lib/mediawiktory/wikipedia/modules/g-fileusage.rb +64 -0
  216. data/lib/mediawiktory/wikipedia/modules/g-geosearch.rb +116 -0
  217. data/lib/mediawiktory/wikipedia/modules/g-gettingstartedgetpages.rb +46 -0
  218. data/lib/mediawiktory/wikipedia/modules/g-images.rb +64 -0
  219. data/lib/mediawiktory/wikipedia/modules/g-imageusage.rb +100 -0
  220. data/lib/mediawiktory/wikipedia/modules/g-iwbacklinks.rb +67 -0
  221. data/lib/mediawiktory/wikipedia/modules/g-langbacklinks.rb +67 -0
  222. data/lib/mediawiktory/wikipedia/modules/g-links.rb +77 -0
  223. data/lib/mediawiktory/wikipedia/modules/g-linkshere.rb +64 -0
  224. data/lib/mediawiktory/wikipedia/modules/g-mostviewed.rb +51 -0
  225. data/lib/mediawiktory/wikipedia/modules/g-oldreviewedpages.rb +114 -0
  226. data/lib/mediawiktory/wikipedia/modules/g-pageswithprop.rb +59 -0
  227. data/lib/mediawiktory/wikipedia/modules/g-prefixsearch.rb +72 -0
  228. data/lib/mediawiktory/wikipedia/modules/g-projectpages.rb +58 -0
  229. data/lib/mediawiktory/wikipedia/modules/g-protectedtitles.rb +93 -0
  230. data/lib/mediawiktory/wikipedia/modules/g-querypage.rb +51 -0
  231. data/lib/mediawiktory/wikipedia/modules/g-random.rb +71 -0
  232. data/lib/mediawiktory/wikipedia/modules/g-recentchanges.rb +157 -0
  233. data/lib/mediawiktory/wikipedia/modules/g-redirects.rb +64 -0
  234. data/lib/mediawiktory/wikipedia/modules/g-revisions.rb +185 -0
  235. data/lib/mediawiktory/wikipedia/modules/g-search.rb +112 -0
  236. data/lib/mediawiktory/wikipedia/modules/g-templates.rb +77 -0
  237. data/lib/mediawiktory/wikipedia/modules/g-transcludedin.rb +64 -0
  238. data/lib/mediawiktory/wikipedia/modules/g-watchlist.rb +145 -0
  239. data/lib/mediawiktory/wikipedia/modules/g-watchlistraw.rb +109 -0
  240. data/lib/mediawiktory/wikipedia/modules/g-wblistentityusage.rb +64 -0
  241. data/lib/mediawiktory/wikipedia/modules/gadgetcategories.rb +48 -0
  242. data/lib/mediawiktory/wikipedia/modules/gadgets.rb +75 -0
  243. data/lib/mediawiktory/wikipedia/modules/geosearch.rb +129 -0
  244. data/lib/mediawiktory/wikipedia/modules/gettingstartedgetpages.rb +46 -0
  245. data/lib/mediawiktory/wikipedia/modules/globalallusers.rb +106 -0
  246. data/lib/mediawiktory/wikipedia/modules/globalblocks.rb +106 -0
  247. data/lib/mediawiktory/wikipedia/modules/globalgroups.rb +35 -0
  248. data/lib/mediawiktory/wikipedia/modules/globalusage.rb +58 -0
  249. data/lib/mediawiktory/wikipedia/modules/globaluserinfo.rb +43 -0
  250. data/lib/mediawiktory/wikipedia/modules/imageinfo.rb +142 -0
  251. data/lib/mediawiktory/wikipedia/modules/images.rb +64 -0
  252. data/lib/mediawiktory/wikipedia/modules/imageusage.rb +100 -0
  253. data/lib/mediawiktory/wikipedia/modules/info.rb +69 -0
  254. data/lib/mediawiktory/wikipedia/modules/iwbacklinks.rb +80 -0
  255. data/lib/mediawiktory/wikipedia/modules/iwlinks.rb +87 -0
  256. data/lib/mediawiktory/wikipedia/modules/json.rb +57 -0
  257. data/lib/mediawiktory/wikipedia/modules/jsonfm.rb +64 -0
  258. data/lib/mediawiktory/wikipedia/modules/langbacklinks.rb +80 -0
  259. data/lib/mediawiktory/wikipedia/modules/langlinks.rb +95 -0
  260. data/lib/mediawiktory/wikipedia/modules/links.rb +77 -0
  261. data/lib/mediawiktory/wikipedia/modules/linkshere.rb +77 -0
  262. data/lib/mediawiktory/wikipedia/modules/logevents.rb +151 -0
  263. data/lib/mediawiktory/wikipedia/modules/mapdata.rb +46 -0
  264. data/lib/mediawiktory/wikipedia/modules/mmsites.rb +30 -0
  265. data/lib/mediawiktory/wikipedia/modules/mostviewed.rb +51 -0
  266. data/lib/mediawiktory/wikipedia/modules/mystashedfiles.rb +51 -0
  267. data/lib/mediawiktory/wikipedia/modules/none.rb +22 -0
  268. data/lib/mediawiktory/wikipedia/modules/notifications.rb +174 -0
  269. data/lib/mediawiktory/wikipedia/modules/oath.rb +30 -0
  270. data/lib/mediawiktory/wikipedia/modules/oldreviewedpages.rb +114 -0
  271. data/lib/mediawiktory/wikipedia/modules/ores.rb +22 -0
  272. data/lib/mediawiktory/wikipedia/modules/pageassessments.rb +45 -0
  273. data/lib/mediawiktory/wikipedia/modules/pageimages.rb +72 -0
  274. data/lib/mediawiktory/wikipedia/modules/pagepropnames.rb +38 -0
  275. data/lib/mediawiktory/wikipedia/modules/pageprops.rb +43 -0
  276. data/lib/mediawiktory/wikipedia/modules/pageswithprop.rb +72 -0
  277. data/lib/mediawiktory/wikipedia/modules/pageterms.rb +43 -0
  278. data/lib/mediawiktory/wikipedia/modules/pageviews.rb +51 -0
  279. data/lib/mediawiktory/wikipedia/modules/php.rb +35 -0
  280. data/lib/mediawiktory/wikipedia/modules/phpfm.rb +42 -0
  281. data/lib/mediawiktory/wikipedia/modules/prefixsearch.rb +72 -0
  282. data/lib/mediawiktory/wikipedia/modules/projectpages.rb +58 -0
  283. data/lib/mediawiktory/wikipedia/modules/projects.rb +29 -0
  284. data/lib/mediawiktory/wikipedia/modules/protectedtitles.rb +106 -0
  285. data/lib/mediawiktory/wikipedia/modules/querypage.rb +51 -0
  286. data/lib/mediawiktory/wikipedia/modules/random.rb +71 -0
  287. data/lib/mediawiktory/wikipedia/modules/rawfm.rb +29 -0
  288. data/lib/mediawiktory/wikipedia/modules/recentchanges.rb +170 -0
  289. data/lib/mediawiktory/wikipedia/modules/redirects.rb +77 -0
  290. data/lib/mediawiktory/wikipedia/modules/references.rb +30 -0
  291. data/lib/mediawiktory/wikipedia/modules/revisions.rb +198 -0
  292. data/lib/mediawiktory/wikipedia/modules/search.rb +125 -0
  293. data/lib/mediawiktory/wikipedia/modules/siteinfo.rb +70 -0
  294. data/lib/mediawiktory/wikipedia/modules/siteviews.rb +43 -0
  295. data/lib/mediawiktory/wikipedia/modules/stashimageinfo.rb +85 -0
  296. data/lib/mediawiktory/wikipedia/modules/tags.rb +51 -0
  297. data/lib/mediawiktory/wikipedia/modules/templates.rb +77 -0
  298. data/lib/mediawiktory/wikipedia/modules/tokens.rb +35 -0
  299. data/lib/mediawiktory/wikipedia/modules/transcludedin.rb +77 -0
  300. data/lib/mediawiktory/wikipedia/modules/transcodestatus.rb +22 -0
  301. data/lib/mediawiktory/wikipedia/modules/unreadnotificationpages.rb +50 -0
  302. data/lib/mediawiktory/wikipedia/modules/usercontribs.rb +155 -0
  303. data/lib/mediawiktory/wikipedia/modules/userinfo.rb +43 -0
  304. data/lib/mediawiktory/wikipedia/modules/users.rb +82 -0
  305. data/lib/mediawiktory/wikipedia/modules/videoinfo.rb +143 -0
  306. data/lib/mediawiktory/wikipedia/modules/watchlist.rb +158 -0
  307. data/lib/mediawiktory/wikipedia/modules/watchlistraw.rb +122 -0
  308. data/lib/mediawiktory/wikipedia/modules/wbentityusage.rb +77 -0
  309. data/lib/mediawiktory/wikipedia/modules/wblistentityusage.rb +77 -0
  310. data/lib/mediawiktory/wikipedia/modules/wikibase.rb +35 -0
  311. data/lib/mediawiktory/wikipedia/modules/wikisets.rb +58 -0
  312. data/lib/mediawiktory/wikipedia/modules/xml.rb +37 -0
  313. data/lib/mediawiktory/wikipedia/modules/xmlfm.rb +44 -0
  314. data/lib/mediawiktory/wikipedia/response.rb +122 -0
  315. data/lib/nokogiri/more.rb +12 -12
  316. data/mediawiktory.gemspec +4 -0
  317. metadata +350 -257
  318. data/bin/mediawiktory +0 -13
  319. data/doc/mediawiki_api_types.md +0 -14
  320. data/examples/query.rb +0 -15
  321. data/examples/query_generator.rb +0 -15
  322. data/lib/faraday/naive_cache.rb +0 -40
  323. data/lib/mediawiktory/action.rb +0 -61
  324. data/lib/mediawiktory/generated/abusefiltercheckmatch.rb +0 -9
  325. data/lib/mediawiktory/generated/abusefilterchecksyntax.rb +0 -6
  326. data/lib/mediawiktory/generated/abusefilterevalexpression.rb +0 -6
  327. data/lib/mediawiktory/generated/abusefilters.rb +0 -12
  328. data/lib/mediawiktory/generated/abusefilterunblockautopromote.rb +0 -8
  329. data/lib/mediawiktory/generated/abuselog.rb +0 -14
  330. data/lib/mediawiktory/generated/actions_mixin.rb +0 -352
  331. data/lib/mediawiktory/generated/addstudents.rb +0 -9
  332. data/lib/mediawiktory/generated/allcategories.rb +0 -15
  333. data/lib/mediawiktory/generated/alldeletedrevisions.rb +0 -28
  334. data/lib/mediawiktory/generated/allfileusages.rb +0 -14
  335. data/lib/mediawiktory/generated/allimages.rb +0 -23
  336. data/lib/mediawiktory/generated/alllinks.rb +0 -15
  337. data/lib/mediawiktory/generated/allmessages.rb +0 -19
  338. data/lib/mediawiktory/generated/allpages.rb +0 -21
  339. data/lib/mediawiktory/generated/allredirects.rb +0 -15
  340. data/lib/mediawiktory/generated/allrevisions.rb +0 -24
  341. data/lib/mediawiktory/generated/alltransclusions.rb +0 -15
  342. data/lib/mediawiktory/generated/allusers.rb +0 -18
  343. data/lib/mediawiktory/generated/antispoof.rb +0 -6
  344. data/lib/mediawiktory/generated/authmanagerinfo.rb +0 -10
  345. data/lib/mediawiktory/generated/babel.rb +0 -7
  346. data/lib/mediawiktory/generated/backlinks.rb +0 -14
  347. data/lib/mediawiktory/generated/betafeatures.rb +0 -7
  348. data/lib/mediawiktory/generated/block.rb +0 -20
  349. data/lib/mediawiktory/generated/blocks.rb +0 -16
  350. data/lib/mediawiktory/generated/bouncehandler.rb +0 -7
  351. data/lib/mediawiktory/generated/categories.rb +0 -12
  352. data/lib/mediawiktory/generated/categoryinfo.rb +0 -7
  353. data/lib/mediawiktory/generated/categorymembers.rb +0 -23
  354. data/lib/mediawiktory/generated/categorytree.rb +0 -7
  355. data/lib/mediawiktory/generated/centralauthtoken.rb +0 -5
  356. data/lib/mediawiktory/generated/centralnoticechoicedata.rb +0 -7
  357. data/lib/mediawiktory/generated/centralnoticelogs.rb +0 -11
  358. data/lib/mediawiktory/generated/centralnoticequerycampaign.rb +0 -6
  359. data/lib/mediawiktory/generated/changeauthenticationdata.rb +0 -10
  360. data/lib/mediawiktory/generated/checktoken.rb +0 -8
  361. data/lib/mediawiktory/generated/checkuser.rb +0 -14
  362. data/lib/mediawiktory/generated/checkuserlog.rb +0 -13
  363. data/lib/mediawiktory/generated/cirrus-config-dump.rb +0 -5
  364. data/lib/mediawiktory/generated/cirrus-mapping-dump.rb +0 -5
  365. data/lib/mediawiktory/generated/cirrus-settings-dump.rb +0 -5
  366. data/lib/mediawiktory/generated/clearhasmsg.rb +0 -6
  367. data/lib/mediawiktory/generated/clientlogin.rb +0 -15
  368. data/lib/mediawiktory/generated/compare.rb +0 -11
  369. data/lib/mediawiktory/generated/contenttranslation.rb +0 -12
  370. data/lib/mediawiktory/generated/contenttranslationcorpora.rb +0 -8
  371. data/lib/mediawiktory/generated/contenttranslationlangtrend.rb +0 -8
  372. data/lib/mediawiktory/generated/contenttranslationstats.rb +0 -5
  373. data/lib/mediawiktory/generated/contenttranslationsuggestions.rb +0 -11
  374. data/lib/mediawiktory/generated/contributors.rb +0 -12
  375. data/lib/mediawiktory/generated/coordinates.rb +0 -12
  376. data/lib/mediawiktory/generated/createaccount.rb +0 -15
  377. data/lib/mediawiktory/generated/cspreport.rb +0 -8
  378. data/lib/mediawiktory/generated/cxconfiguration.rb +0 -7
  379. data/lib/mediawiktory/generated/cxdelete.rb +0 -10
  380. data/lib/mediawiktory/generated/cxpublish.rb +0 -15
  381. data/lib/mediawiktory/generated/cxpublishedtranslations.rb +0 -9
  382. data/lib/mediawiktory/generated/cxsave.rb +0 -14
  383. data/lib/mediawiktory/generated/cxsuggestionlist.rb +0 -12
  384. data/lib/mediawiktory/generated/cxtoken.rb +0 -7
  385. data/lib/mediawiktory/generated/cxtranslatorstats.rb +0 -6
  386. data/lib/mediawiktory/generated/delete.rb +0 -15
  387. data/lib/mediawiktory/generated/deletedrevisions.rb +0 -23
  388. data/lib/mediawiktory/generated/deletedrevs.rb +0 -20
  389. data/lib/mediawiktory/generated/deleteeducation.rb +0 -10
  390. data/lib/mediawiktory/generated/deleteglobalaccount.rb +0 -9
  391. data/lib/mediawiktory/generated/duplicatefiles.rb +0 -10
  392. data/lib/mediawiktory/generated/echomarkread.rb +0 -11
  393. data/lib/mediawiktory/generated/echomarkseen.rb +0 -9
  394. data/lib/mediawiktory/generated/edit.rb +0 -35
  395. data/lib/mediawiktory/generated/editmassmessagelist.rb +0 -10
  396. data/lib/mediawiktory/generated/emailuser.rb +0 -11
  397. data/lib/mediawiktory/generated/embeddedin.rb +0 -13
  398. data/lib/mediawiktory/generated/enlist.rb +0 -13
  399. data/lib/mediawiktory/generated/expandtemplates.rb +0 -16
  400. data/lib/mediawiktory/generated/extlinks.rb +0 -11
  401. data/lib/mediawiktory/generated/extracts.rb +0 -13
  402. data/lib/mediawiktory/generated/exturlusage.rb +0 -13
  403. data/lib/mediawiktory/generated/fancycaptchareload.rb +0 -5
  404. data/lib/mediawiktory/generated/featuredfeed.rb +0 -8
  405. data/lib/mediawiktory/generated/featureusage.rb +0 -10
  406. data/lib/mediawiktory/generated/feedcontributions.rb +0 -16
  407. data/lib/mediawiktory/generated/feedrecentchanges.rb +0 -22
  408. data/lib/mediawiktory/generated/feedwatchlist.rb +0 -14
  409. data/lib/mediawiktory/generated/filearchive.rb +0 -15
  410. data/lib/mediawiktory/generated/filerepoinfo.rb +0 -7
  411. data/lib/mediawiktory/generated/filerevert.rb +0 -10
  412. data/lib/mediawiktory/generated/fileusage.rb +0 -11
  413. data/lib/mediawiktory/generated/flagconfig.rb +0 -5
  414. data/lib/mediawiktory/generated/flagged.rb +0 -5
  415. data/lib/mediawiktory/generated/gadgetcategories.rb +0 -8
  416. data/lib/mediawiktory/generated/gadgets.rb +0 -11
  417. data/lib/mediawiktory/generated/geosearch.rb +0 -17
  418. data/lib/mediawiktory/generated/gettingstartedgetpages.rb +0 -9
  419. data/lib/mediawiktory/generated/globalallusers.rb +0 -14
  420. data/lib/mediawiktory/generated/globalblock.rb +0 -13
  421. data/lib/mediawiktory/generated/globalblocks.rb +0 -14
  422. data/lib/mediawiktory/generated/globalgroups.rb +0 -7
  423. data/lib/mediawiktory/generated/globalusage.rb +0 -10
  424. data/lib/mediawiktory/generated/globaluserinfo.rb +0 -8
  425. data/lib/mediawiktory/generated/globaluserrights.rb +0 -13
  426. data/lib/mediawiktory/generated/graph.rb +0 -8
  427. data/lib/mediawiktory/generated/help.rb +0 -10
  428. data/lib/mediawiktory/generated/imageinfo.rb +0 -20
  429. data/lib/mediawiktory/generated/imagerotate.rb +0 -5
  430. data/lib/mediawiktory/generated/images.rb +0 -10
  431. data/lib/mediawiktory/generated/imageusage.rb +0 -14
  432. data/lib/mediawiktory/generated/import.rb +0 -16
  433. data/lib/mediawiktory/generated/info.rb +0 -10
  434. data/lib/mediawiktory/generated/iwbacklinks.rb +0 -12
  435. data/lib/mediawiktory/generated/iwlinks.rb +0 -13
  436. data/lib/mediawiktory/generated/jsonconfig.rb +0 -9
  437. data/lib/mediawiktory/generated/jsondata.rb +0 -6
  438. data/lib/mediawiktory/generated/langbacklinks.rb +0 -12
  439. data/lib/mediawiktory/generated/langlinks.rb +0 -14
  440. data/lib/mediawiktory/generated/languagesearch.rb +0 -7
  441. data/lib/mediawiktory/generated/linkaccount.rb +0 -14
  442. data/lib/mediawiktory/generated/links.rb +0 -11
  443. data/lib/mediawiktory/generated/linkshere.rb +0 -11
  444. data/lib/mediawiktory/generated/liststudents.rb +0 -9
  445. data/lib/mediawiktory/generated/logevents.rb +0 -19
  446. data/lib/mediawiktory/generated/login.rb +0 -11
  447. data/lib/mediawiktory/generated/logout.rb +0 -5
  448. data/lib/mediawiktory/generated/managetags.rb +0 -12
  449. data/lib/mediawiktory/generated/mapdata.rb +0 -9
  450. data/lib/mediawiktory/generated/massmessage.rb +0 -10
  451. data/lib/mediawiktory/generated/mergehistory.rb +0 -13
  452. data/lib/mediawiktory/generated/mmsites.rb +0 -6
  453. data/lib/mediawiktory/generated/mobileview.rb +0 -22
  454. data/lib/mediawiktory/generated/mostviewed.rb +0 -9
  455. data/lib/mediawiktory/generated/move.rb +0 -19
  456. data/lib/mediawiktory/generated/mystashedfiles.rb +0 -9
  457. data/lib/mediawiktory/generated/notifications.rb +0 -22
  458. data/lib/mediawiktory/generated/oath.rb +0 -7
  459. data/lib/mediawiktory/generated/oathvalidate.rb +0 -9
  460. data/lib/mediawiktory/generated/oldreviewedpages.rb +0 -15
  461. data/lib/mediawiktory/generated/opensearch.rb +0 -12
  462. data/lib/mediawiktory/generated/options.rb +0 -12
  463. data/lib/mediawiktory/generated/ores.rb +0 -6
  464. data/lib/mediawiktory/generated/pageassessments.rb +0 -9
  465. data/lib/mediawiktory/generated/pageimages.rb +0 -11
  466. data/lib/mediawiktory/generated/pagepropnames.rb +0 -8
  467. data/lib/mediawiktory/generated/pageprops.rb +0 -8
  468. data/lib/mediawiktory/generated/pageswithprop.rb +0 -11
  469. data/lib/mediawiktory/generated/pageterms.rb +0 -8
  470. data/lib/mediawiktory/generated/pagetriageaction.rb +0 -11
  471. data/lib/mediawiktory/generated/pagetriagelist.rb +0 -21
  472. data/lib/mediawiktory/generated/pagetriagestats.rb +0 -10
  473. data/lib/mediawiktory/generated/pagetriagetagging.rb +0 -13
  474. data/lib/mediawiktory/generated/pagetriagetemplate.rb +0 -7
  475. data/lib/mediawiktory/generated/pageviews.rb +0 -9
  476. data/lib/mediawiktory/generated/paraminfo.rb +0 -11
  477. data/lib/mediawiktory/generated/parse.rb +0 -36
  478. data/lib/mediawiktory/generated/parsoid-batch.rb +0 -6
  479. data/lib/mediawiktory/generated/patrol.rb +0 -10
  480. data/lib/mediawiktory/generated/prefixsearch.rb +0 -10
  481. data/lib/mediawiktory/generated/projectpages.rb +0 -10
  482. data/lib/mediawiktory/generated/projects.rb +0 -7
  483. data/lib/mediawiktory/generated/protect.rb +0 -16
  484. data/lib/mediawiktory/generated/protectedtitles.rb +0 -14
  485. data/lib/mediawiktory/generated/purge.rb +0 -15
  486. data/lib/mediawiktory/generated/query.rb +0 -20
  487. data/lib/mediawiktory/generated/querypage.rb +0 -9
  488. data/lib/mediawiktory/generated/random.rb +0 -11
  489. data/lib/mediawiktory/generated/recentchanges.rb +0 -21
  490. data/lib/mediawiktory/generated/redirects.rb +0 -11
  491. data/lib/mediawiktory/generated/references.rb +0 -7
  492. data/lib/mediawiktory/generated/refresheducation.rb +0 -9
  493. data/lib/mediawiktory/generated/removeauthenticationdata.rb +0 -8
  494. data/lib/mediawiktory/generated/resetpassword.rb +0 -9
  495. data/lib/mediawiktory/generated/review.rb +0 -10
  496. data/lib/mediawiktory/generated/reviewactivity.rb +0 -10
  497. data/lib/mediawiktory/generated/revisiondelete.rb +0 -15
  498. data/lib/mediawiktory/generated/revisions.rb +0 -26
  499. data/lib/mediawiktory/generated/rollback.rb +0 -14
  500. data/lib/mediawiktory/generated/rsd.rb +0 -5
  501. data/lib/mediawiktory/generated/sanitize-mapdata.rb +0 -8
  502. data/lib/mediawiktory/generated/scribunto-console.rb +0 -10
  503. data/lib/mediawiktory/generated/search.rb +0 -16
  504. data/lib/mediawiktory/generated/setglobalaccountstatus.rb +0 -12
  505. data/lib/mediawiktory/generated/setnotificationtimestamp.rb +0 -18
  506. data/lib/mediawiktory/generated/setpagelanguage.rb +0 -12
  507. data/lib/mediawiktory/generated/shortenurl.rb +0 -7
  508. data/lib/mediawiktory/generated/siteinfo.rb +0 -11
  509. data/lib/mediawiktory/generated/sitematrix.rb +0 -12
  510. data/lib/mediawiktory/generated/siteviews.rb +0 -8
  511. data/lib/mediawiktory/generated/spamblacklist.rb +0 -6
  512. data/lib/mediawiktory/generated/stabilize.rb +0 -12
  513. data/lib/mediawiktory/generated/stashedit.rb +0 -16
  514. data/lib/mediawiktory/generated/stashimageinfo.rb +0 -12
  515. data/lib/mediawiktory/generated/strikevote.rb +0 -10
  516. data/lib/mediawiktory/generated/tag.rb +0 -14
  517. data/lib/mediawiktory/generated/tags.rb +0 -9
  518. data/lib/mediawiktory/generated/templatedata.rb +0 -12
  519. data/lib/mediawiktory/generated/templates.rb +0 -11
  520. data/lib/mediawiktory/generated/thank.rb +0 -9
  521. data/lib/mediawiktory/generated/titleblacklist.rb +0 -9
  522. data/lib/mediawiktory/generated/tokens.rb +0 -6
  523. data/lib/mediawiktory/generated/transcludedin.rb +0 -11
  524. data/lib/mediawiktory/generated/transcodereset.rb +0 -9
  525. data/lib/mediawiktory/generated/transcodestatus.rb +0 -5
  526. data/lib/mediawiktory/generated/ulslocalization.rb +0 -6
  527. data/lib/mediawiktory/generated/unblock.rb +0 -12
  528. data/lib/mediawiktory/generated/undelete.rb +0 -13
  529. data/lib/mediawiktory/generated/unlinkaccount.rb +0 -8
  530. data/lib/mediawiktory/generated/unreadnotificationpages.rb +0 -9
  531. data/lib/mediawiktory/generated/upload.rb +0 -24
  532. data/lib/mediawiktory/generated/usercontribs.rb +0 -19
  533. data/lib/mediawiktory/generated/userinfo.rb +0 -8
  534. data/lib/mediawiktory/generated/userrights.rb +0 -13
  535. data/lib/mediawiktory/generated/users.rb +0 -11
  536. data/lib/mediawiktory/generated/validatepassword.rb +0 -10
  537. data/lib/mediawiktory/generated/videoinfo.rb +0 -20
  538. data/lib/mediawiktory/generated/visualeditor.rb +0 -13
  539. data/lib/mediawiktory/generated/visualeditoredit.rb +0 -23
  540. data/lib/mediawiktory/generated/watch.rb +0 -16
  541. data/lib/mediawiktory/generated/watchlist.rb +0 -20
  542. data/lib/mediawiktory/generated/watchlistraw.rb +0 -16
  543. data/lib/mediawiktory/generated/wbentityusage.rb +0 -11
  544. data/lib/mediawiktory/generated/wblistentityusage.rb +0 -11
  545. data/lib/mediawiktory/generated/webapp-manifest.rb +0 -5
  546. data/lib/mediawiktory/generated/wikibase.rb +0 -7
  547. data/lib/mediawiktory/generated/wikilove.rb +0 -13
  548. data/lib/mediawiktory/generated/wikisets.rb +0 -10
  549. data/lib/mediawiktory/generated/zeroconfig.rb +0 -7
  550. data/lib/mediawiktory/mw_module.rb +0 -324
  551. data/lib/mediawiktory/page.rb +0 -50
  552. data/lib/mediawiktory/query.rb +0 -58
  553. data/script/data/api.yaml +0 -40414
  554. data/script/lib/api.rb +0 -14
  555. data/script/lib/module.rb +0 -132
  556. data/script/lib/parameter.rb +0 -133
  557. data/script/parse_api.rb +0 -21
  558. data/test/cache.rb +0 -15
@@ -1,11 +1,22 @@
1
- require_relative 'generated/actions_mixin'
2
-
3
- module MediaWiktory
1
+ # frozen_string_literal: true
2
+
3
+ require 'addressable'
4
+ require 'faraday'
5
+ require 'faraday_middleware'
6
+
7
+ module <%= @namespace %>
8
+ # Internal low-level client class, used by {Api}.
9
+ #
10
+ # Uses [Faraday](https://github.com/lostisland/faraday) library inside (and will expose it's settings
11
+ # in future).
12
+ #
13
+ # You should not use it directly, all you need is in {Api}.
4
14
  class Client
5
15
  # Default MediaWiktory User-Agent header.
6
16
  #
7
17
  # You can set yours as an option to {#initialize}
8
- UA = "MediaWiktory/#{MediaWiktory::VERSION} (https://github.com/molybdenum-99/mediawiktory; zverok.offline@gmail.com)"
18
+ UA = 'MediaWiktory/0.1.0 '\
19
+ '(https://github.com/molybdenum-99/mediawiktory; zverok.offline@gmail.com)'
9
20
 
10
21
  class << self
11
22
  # User agent getter/setter.
@@ -17,15 +28,20 @@ module MediaWiktory
17
28
  end
18
29
 
19
30
  attr_reader :url
20
-
31
+
21
32
  def initialize(url, **options)
22
33
  @url = Addressable::URI.parse(url)
34
+ @options = options
23
35
  @faraday = Faraday.new(url) do |f|
24
36
  f.request :url_encoded
25
37
  f.use FaradayMiddleware::FollowRedirects, limit: 5
26
38
  f.adapter Faraday.default_adapter
27
39
  end
28
- @faraday.headers.merge!(headers(options))
40
+ @faraday.headers.merge!(headers)
41
+ end
42
+
43
+ def user_agent
44
+ @options[:user_agent] || @options[:ua] || self.class.user_agent || UA
29
45
  end
30
46
 
31
47
  def get(params)
@@ -36,12 +52,10 @@ module MediaWiktory
36
52
  @faraday.post('', params).body
37
53
  end
38
54
 
39
- include ActionsMixin
40
-
41
55
  private
42
56
 
43
- def headers(options)
44
- {'User-Agent' => options[:user_agent] || options[:ua] || self.class.user_agent || UA}
57
+ def headers
58
+ {'User-Agent' => user_agent}
45
59
  end
46
60
  end
47
61
  end
@@ -0,0 +1,22 @@
1
+ # frozen_string_literal: true
2
+
3
+ module <%= @namespace %>
4
+ module Modules
5
+ # <%= description %>
6
+ #
7
+ # The "submodule" (MediaWiki API term) is included in action after setting some param, providing
8
+ # additional tweaking for this param. Example (for {<%= @namespace %>::Actions::Query} and
9
+ # its submodules):
10
+ #
11
+ # ```ruby
12
+ # api.query # returns Actions::Query
13
+ # .prop(:revisions) # adds prop=revisions to action URL, and includes Modules::Revisions into action
14
+ # .limit(10) # method of Modules::Revisions, adds rvlimit=10 to URL
15
+ # ```
16
+ #
17
+ # All submodule's parameters are documented as its public methods, see below.
18
+ #
19
+ module <%= class_name %>
20
+ <% params.each { |param| %><%= partial '_param_method', param %><% } %> end
21
+ end
22
+ end
@@ -0,0 +1,122 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'json'
4
+
5
+ module <%= @namespace %>
6
+ # Thin wrapper around MediaWiki API response.
7
+ #
8
+ # It provides services for separating metadata of response of its essential data, continuing multi-
9
+ # page responses, and converting response errors into exceptions.
10
+ #
11
+ # You should not instantiate this class, it is obtained by some {Actions Action}'s {Actions::Base#response #response}.
12
+ class Response
13
+ # Response fail was returned by target MediaWiki API.
14
+ Error = Class.new(RuntimeError)
15
+
16
+ # @private
17
+ METADATA_KEYS = %w[error warnings batchcomplete continue success limits].freeze
18
+
19
+ # @private
20
+ def self.parse(action, response_body)
21
+ new(action, JSON.parse(response_body))
22
+ end
23
+
24
+ # Entire response "as is", including contents and metadata parts.
25
+ #
26
+ # See {#to_h} for content part of the response and {#metadata} for metadata part.
27
+ #
28
+ # @return [Hash]
29
+ attr_reader :raw
30
+
31
+ # Metadata part of the response, keys like "error", "warnings", "continue".
32
+ #
33
+ # See {#to_h} for content part of the response and {#raw} for entire response.
34
+ #
35
+ # @return [Hash]
36
+ attr_reader :metadata
37
+
38
+ # @private
39
+ def initialize(action, response_hash)
40
+ @action = action
41
+ @raw = response_hash.freeze
42
+ @metadata, @data = response_hash.partition { |key, _| METADATA_KEYS.include?(key) }.map(&:to_h).map(&:freeze)
43
+ error! if @metadata['error']
44
+ end
45
+
46
+ # "Content" part of the response as a plain Ruby Hash.
47
+ #
48
+ # @return [Hash]
49
+ def to_h
50
+ # For most of actions, like query, all response is inside additional "query" key,
51
+ # ...but not for all.
52
+ @data.key?(@action.name) ? @data.fetch(@action.name) : @data
53
+ end
54
+
55
+ # Fetches a key from response content.
56
+ #
57
+ # @param key [String] Key name.
58
+ def [](key)
59
+ to_h[key]
60
+ end
61
+
62
+ # Digs for a keys from response content.
63
+ #
64
+ # @param keys [Array<String>] Key names.
65
+ def dig(*keys)
66
+ hash_dig(to_h, *keys)
67
+ end
68
+
69
+ # Returns `true` if there is next pages of response. See also {#continue}
70
+ def continue?
71
+ @metadata.key?('continue')
72
+ end
73
+
74
+ # Continues current request and returns current & next pages merged. (Merging is necessary
75
+ # because MediaWiki tends to return the same object's data continued on the next request page.)
76
+ #
77
+ # @return [Response]
78
+ def continue
79
+ fail 'This is the last page' unless continue?
80
+
81
+ action = @action.merge(@metadata.fetch('continue'))
82
+
83
+ self.class.new(action, merge_responses(JSON.parse(action.perform)))
84
+ end
85
+
86
+ # @return [String]
87
+ def inspect
88
+ "#<#{self.class.name}(#{@action.name}): #{to_h.keys.join(', ')}#{' (can continue)' if continue?}>"
89
+ end
90
+
91
+ private
92
+
93
+ def merge_responses(new_response)
94
+ merger = lambda do |_k, v1, v2|
95
+ if v1.is_a?(Hash) && v2.is_a?(Hash)
96
+ v1.merge(v2, &merger)
97
+ elsif v1.is_a?(Array) && v2.is_a?(Array)
98
+ v1 + v2
99
+ else
100
+ v2
101
+ end
102
+ end
103
+
104
+ # Newest page is responsible for all metadata, so we take entire new response and only data
105
+ # part of old one.
106
+ #
107
+ # Deep recursive merge is necessary because MediaWiki could split response in parts unpredicatably
108
+ # (like ['query']['pages'][some_page_id] can be present on several pages, providing different
109
+ # parts of a page).
110
+ @data.merge(new_response, &merger)
111
+ end
112
+
113
+ def error!
114
+ fail Error, hash_dig(@metadata, 'error', 'info')
115
+ end
116
+
117
+ # TODO: replace with Hash#dig when minimal Ruby version would be 2.3
118
+ def hash_dig(hash, *keys)
119
+ keys.inject(hash) { |res, key| res[key] or return nil }
120
+ end
121
+ end
122
+ end
@@ -1,6 +1,8 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module MediaWiktory
2
4
  MAJOR = 0
3
- MINOR = 0
4
- PATCH = 3
5
+ MINOR = 1
6
+ PATCH = 0
5
7
  VERSION = [MAJOR, MINOR, PATCH].join('.')
6
8
  end
@@ -0,0 +1,2296 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative './actions/base'
4
+
5
+ module MediaWiktory::Wikipedia
6
+ # Methods of this module contains all actions that can be used on {Api}.
7
+ # You use them like this:
8
+ #
9
+ # ```ruby
10
+ # api = MediaWiktory::Wikipedia::Api.new
11
+ #
12
+ # api.query # method of Api, returning Actions::Query
13
+ # .titles('Argentina', 'Bolivia') # methods of Actions::Query...
14
+ # .prop(:revisions).prop(:content) # ...to set action options
15
+ # .response
16
+ # # => performs action and returns Response instance
17
+ # ```
18
+ #
19
+ # See also:
20
+ # * {Api} for starting;
21
+ # * {Actions::Base} for details of working with actions;
22
+ # * and {Response}.
23
+ #
24
+ # Note that for each MediaWiki site the main method for **data extraction** (pages, categories,
25
+ # meta-information) is {#query}.
26
+ #
27
+ module Actions
28
+
29
+ # Check to see if an AbuseFilter matches a set of variables, editor logged AbuseFilter event.
30
+ #
31
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Abusefiltercheckmatch} action.
32
+ #
33
+ # Action parameters could be passed or by subsequent
34
+ # {MediaWiktory::Wikipedia::Actions::Abusefiltercheckmatch} method calls, like
35
+ #
36
+ # ```ruby
37
+ # api.abusefiltercheckmatch.filter('value')
38
+ # ```
39
+ #
40
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
41
+ # {MediaWiktory::Wikipedia::Actions::Abusefiltercheckmatch} class for a list of parameters and usage.
42
+ #
43
+ # @return [MediaWiktory::Wikipedia::Actions::Abusefiltercheckmatch]
44
+ #
45
+ def abusefiltercheckmatch
46
+ Abusefiltercheckmatch.new(client, @defaults)
47
+ end
48
+
49
+ # Check syntax of an AbuseFilter filter.
50
+ #
51
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Abusefilterchecksyntax} action.
52
+ #
53
+ # Action parameters could be passed or by subsequent
54
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterchecksyntax} method calls, like
55
+ #
56
+ # ```ruby
57
+ # api.abusefilterchecksyntax.filter('value')
58
+ # ```
59
+ #
60
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
61
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterchecksyntax} class for a list of parameters and usage.
62
+ #
63
+ # @return [MediaWiktory::Wikipedia::Actions::Abusefilterchecksyntax]
64
+ #
65
+ def abusefilterchecksyntax
66
+ Abusefilterchecksyntax.new(client, @defaults)
67
+ end
68
+
69
+ # Evaluates an AbuseFilter expression.
70
+ #
71
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Abusefilterevalexpression} action.
72
+ #
73
+ # Action parameters could be passed or by subsequent
74
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterevalexpression} method calls, like
75
+ #
76
+ # ```ruby
77
+ # api.abusefilterevalexpression.expression('value')
78
+ # ```
79
+ #
80
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
81
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterevalexpression} class for a list of parameters and usage.
82
+ #
83
+ # @return [MediaWiktory::Wikipedia::Actions::Abusefilterevalexpression]
84
+ #
85
+ def abusefilterevalexpression
86
+ Abusefilterevalexpression.new(client, @defaults)
87
+ end
88
+
89
+ # Unblocks a user from receiving autopromotions due to an abusefilter consequence.
90
+ #
91
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Abusefilterunblockautopromote} action.
92
+ #
93
+ # Action parameters could be passed or by subsequent
94
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterunblockautopromote} method calls, like
95
+ #
96
+ # ```ruby
97
+ # api.abusefilterunblockautopromote.user('value')
98
+ # ```
99
+ #
100
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
101
+ # {MediaWiktory::Wikipedia::Actions::Abusefilterunblockautopromote} class for a list of parameters and usage.
102
+ #
103
+ # @return [MediaWiktory::Wikipedia::Actions::Abusefilterunblockautopromote]
104
+ #
105
+ def abusefilterunblockautopromote
106
+ Abusefilterunblockautopromote.new(client, @defaults)
107
+ end
108
+
109
+ # Add multiple students to a course.
110
+ #
111
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Addstudents} action.
112
+ #
113
+ # Action parameters could be passed or by subsequent
114
+ # {MediaWiktory::Wikipedia::Actions::Addstudents} method calls, like
115
+ #
116
+ # ```ruby
117
+ # api.addstudents.studentusernames('value')
118
+ # ```
119
+ #
120
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
121
+ # {MediaWiktory::Wikipedia::Actions::Addstudents} class for a list of parameters and usage.
122
+ #
123
+ # @return [MediaWiktory::Wikipedia::Actions::Addstudents]
124
+ #
125
+ def addstudents
126
+ Addstudents.new(client, @defaults)
127
+ end
128
+
129
+ # Check a username against AntiSpoof's normalisation checks.
130
+ #
131
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Antispoof} action.
132
+ #
133
+ # Action parameters could be passed or by subsequent
134
+ # {MediaWiktory::Wikipedia::Actions::Antispoof} method calls, like
135
+ #
136
+ # ```ruby
137
+ # api.antispoof.username('value')
138
+ # ```
139
+ #
140
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
141
+ # {MediaWiktory::Wikipedia::Actions::Antispoof} class for a list of parameters and usage.
142
+ #
143
+ # @return [MediaWiktory::Wikipedia::Actions::Antispoof]
144
+ #
145
+ def antispoof
146
+ Antispoof.new(client, @defaults)
147
+ end
148
+
149
+ # Block a user.
150
+ #
151
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Block} action.
152
+ #
153
+ # Action parameters could be passed or by subsequent
154
+ # {MediaWiktory::Wikipedia::Actions::Block} method calls, like
155
+ #
156
+ # ```ruby
157
+ # api.block.user('value')
158
+ # ```
159
+ #
160
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
161
+ # {MediaWiktory::Wikipedia::Actions::Block} class for a list of parameters and usage.
162
+ #
163
+ # @return [MediaWiktory::Wikipedia::Actions::Block]
164
+ #
165
+ def block
166
+ Block.new(client, @defaults)
167
+ end
168
+
169
+ # Receive a bounce email and process it to handle the failing recipient.
170
+ #
171
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Bouncehandler} action.
172
+ #
173
+ # Action parameters could be passed or by subsequent
174
+ # {MediaWiktory::Wikipedia::Actions::Bouncehandler} method calls, like
175
+ #
176
+ # ```ruby
177
+ # api.bouncehandler.email('value')
178
+ # ```
179
+ #
180
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
181
+ # {MediaWiktory::Wikipedia::Actions::Bouncehandler} class for a list of parameters and usage.
182
+ #
183
+ # @return [MediaWiktory::Wikipedia::Actions::Bouncehandler]
184
+ #
185
+ def bouncehandler
186
+ Bouncehandler.new(client, @defaults)
187
+ end
188
+
189
+ # Internal module for the CategoryTree extension.
190
+ #
191
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Categorytree} action.
192
+ #
193
+ # Action parameters could be passed or by subsequent
194
+ # {MediaWiktory::Wikipedia::Actions::Categorytree} method calls, like
195
+ #
196
+ # ```ruby
197
+ # api.categorytree.category('value')
198
+ # ```
199
+ #
200
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
201
+ # {MediaWiktory::Wikipedia::Actions::Categorytree} class for a list of parameters and usage.
202
+ #
203
+ # @return [MediaWiktory::Wikipedia::Actions::Categorytree]
204
+ #
205
+ def categorytree
206
+ Categorytree.new(client, @defaults)
207
+ end
208
+
209
+ # Fetch a centralauthtoken for making an authenticated request to an attached wiki.
210
+ #
211
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Centralauthtoken} action.
212
+ #
213
+
214
+ #
215
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
216
+ # {MediaWiktory::Wikipedia::Actions::Centralauthtoken} class for a list of parameters and usage.
217
+ #
218
+ # @return [MediaWiktory::Wikipedia::Actions::Centralauthtoken]
219
+ #
220
+ def centralauthtoken
221
+ Centralauthtoken.new(client, @defaults)
222
+ end
223
+
224
+ # Get data needed to choose a banner for a given project and language
225
+ #
226
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Centralnoticechoicedata} action.
227
+ #
228
+ # Action parameters could be passed or by subsequent
229
+ # {MediaWiktory::Wikipedia::Actions::Centralnoticechoicedata} method calls, like
230
+ #
231
+ # ```ruby
232
+ # api.centralnoticechoicedata.project('value')
233
+ # ```
234
+ #
235
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
236
+ # {MediaWiktory::Wikipedia::Actions::Centralnoticechoicedata} class for a list of parameters and usage.
237
+ #
238
+ # @return [MediaWiktory::Wikipedia::Actions::Centralnoticechoicedata]
239
+ #
240
+ def centralnoticechoicedata
241
+ Centralnoticechoicedata.new(client, @defaults)
242
+ end
243
+
244
+ # Get all configuration settings for a campaign.
245
+ #
246
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Centralnoticequerycampaign} action.
247
+ #
248
+ # Action parameters could be passed or by subsequent
249
+ # {MediaWiktory::Wikipedia::Actions::Centralnoticequerycampaign} method calls, like
250
+ #
251
+ # ```ruby
252
+ # api.centralnoticequerycampaign.campaign('value')
253
+ # ```
254
+ #
255
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
256
+ # {MediaWiktory::Wikipedia::Actions::Centralnoticequerycampaign} class for a list of parameters and usage.
257
+ #
258
+ # @return [MediaWiktory::Wikipedia::Actions::Centralnoticequerycampaign]
259
+ #
260
+ def centralnoticequerycampaign
261
+ Centralnoticequerycampaign.new(client, @defaults)
262
+ end
263
+
264
+ # Change authentication data for the current user.
265
+ #
266
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Changeauthenticationdata} action.
267
+ #
268
+ # Action parameters could be passed or by subsequent
269
+ # {MediaWiktory::Wikipedia::Actions::Changeauthenticationdata} method calls, like
270
+ #
271
+ # ```ruby
272
+ # api.changeauthenticationdata.request('value')
273
+ # ```
274
+ #
275
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
276
+ # {MediaWiktory::Wikipedia::Actions::Changeauthenticationdata} class for a list of parameters and usage.
277
+ #
278
+ # @return [MediaWiktory::Wikipedia::Actions::Changeauthenticationdata]
279
+ #
280
+ def changeauthenticationdata
281
+ Changeauthenticationdata.new(client, @defaults)
282
+ end
283
+
284
+ # Check the validity of a token from action=query&meta=tokens.
285
+ #
286
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Checktoken} action.
287
+ #
288
+ # Action parameters could be passed or by subsequent
289
+ # {MediaWiktory::Wikipedia::Actions::Checktoken} method calls, like
290
+ #
291
+ # ```ruby
292
+ # api.checktoken.type('value')
293
+ # ```
294
+ #
295
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
296
+ # {MediaWiktory::Wikipedia::Actions::Checktoken} class for a list of parameters and usage.
297
+ #
298
+ # @return [MediaWiktory::Wikipedia::Actions::Checktoken]
299
+ #
300
+ def checktoken
301
+ Checktoken.new(client, @defaults)
302
+ end
303
+
304
+ # Dump of CirrusSearch configuration.
305
+ #
306
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::CirrusConfigDump} action.
307
+ #
308
+
309
+ #
310
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
311
+ # {MediaWiktory::Wikipedia::Actions::CirrusConfigDump} class for a list of parameters and usage.
312
+ #
313
+ # @return [MediaWiktory::Wikipedia::Actions::CirrusConfigDump]
314
+ #
315
+ def cirrus_config_dump
316
+ CirrusConfigDump.new(client, @defaults)
317
+ end
318
+
319
+ # Dump of CirrusSearch mapping for this wiki.
320
+ #
321
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::CirrusMappingDump} action.
322
+ #
323
+
324
+ #
325
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
326
+ # {MediaWiktory::Wikipedia::Actions::CirrusMappingDump} class for a list of parameters and usage.
327
+ #
328
+ # @return [MediaWiktory::Wikipedia::Actions::CirrusMappingDump]
329
+ #
330
+ def cirrus_mapping_dump
331
+ CirrusMappingDump.new(client, @defaults)
332
+ end
333
+
334
+ # Dump of CirrusSearch settings for this wiki.
335
+ #
336
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::CirrusSettingsDump} action.
337
+ #
338
+
339
+ #
340
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
341
+ # {MediaWiktory::Wikipedia::Actions::CirrusSettingsDump} class for a list of parameters and usage.
342
+ #
343
+ # @return [MediaWiktory::Wikipedia::Actions::CirrusSettingsDump]
344
+ #
345
+ def cirrus_settings_dump
346
+ CirrusSettingsDump.new(client, @defaults)
347
+ end
348
+
349
+ # Clears the hasmsg flag for the current user.
350
+ #
351
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Clearhasmsg} action.
352
+ #
353
+
354
+ #
355
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
356
+ # {MediaWiktory::Wikipedia::Actions::Clearhasmsg} class for a list of parameters and usage.
357
+ #
358
+ # @return [MediaWiktory::Wikipedia::Actions::Clearhasmsg]
359
+ #
360
+ def clearhasmsg
361
+ Clearhasmsg.new(client, @defaults)
362
+ end
363
+
364
+ # Log in to the wiki using the interactive flow.
365
+ #
366
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Clientlogin} action.
367
+ #
368
+ # Action parameters could be passed or by subsequent
369
+ # {MediaWiktory::Wikipedia::Actions::Clientlogin} method calls, like
370
+ #
371
+ # ```ruby
372
+ # api.clientlogin.requests('value')
373
+ # ```
374
+ #
375
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
376
+ # {MediaWiktory::Wikipedia::Actions::Clientlogin} class for a list of parameters and usage.
377
+ #
378
+ # @return [MediaWiktory::Wikipedia::Actions::Clientlogin]
379
+ #
380
+ def clientlogin
381
+ Clientlogin.new(client, @defaults)
382
+ end
383
+
384
+ # Get the difference between 2 pages.
385
+ #
386
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Compare} action.
387
+ #
388
+ # Action parameters could be passed or by subsequent
389
+ # {MediaWiktory::Wikipedia::Actions::Compare} method calls, like
390
+ #
391
+ # ```ruby
392
+ # api.compare.fromtitle('value')
393
+ # ```
394
+ #
395
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
396
+ # {MediaWiktory::Wikipedia::Actions::Compare} class for a list of parameters and usage.
397
+ #
398
+ # @return [MediaWiktory::Wikipedia::Actions::Compare]
399
+ #
400
+ def compare
401
+ Compare.new(client, @defaults)
402
+ end
403
+
404
+ # Create a new user account.
405
+ #
406
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Createaccount} action.
407
+ #
408
+ # Action parameters could be passed or by subsequent
409
+ # {MediaWiktory::Wikipedia::Actions::Createaccount} method calls, like
410
+ #
411
+ # ```ruby
412
+ # api.createaccount.requests('value')
413
+ # ```
414
+ #
415
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
416
+ # {MediaWiktory::Wikipedia::Actions::Createaccount} class for a list of parameters and usage.
417
+ #
418
+ # @return [MediaWiktory::Wikipedia::Actions::Createaccount]
419
+ #
420
+ def createaccount
421
+ Createaccount.new(client, @defaults)
422
+ end
423
+
424
+ # Used by browsers to report violations of the Content Security Policy. This module should never be used, except when used automatically by a CSP compliant web browser.
425
+ #
426
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cspreport} action.
427
+ #
428
+ # Action parameters could be passed or by subsequent
429
+ # {MediaWiktory::Wikipedia::Actions::Cspreport} method calls, like
430
+ #
431
+ # ```ruby
432
+ # api.cspreport.reportonly('value')
433
+ # ```
434
+ #
435
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
436
+ # {MediaWiktory::Wikipedia::Actions::Cspreport} class for a list of parameters and usage.
437
+ #
438
+ # @return [MediaWiktory::Wikipedia::Actions::Cspreport]
439
+ #
440
+ def cspreport
441
+ Cspreport.new(client, @defaults)
442
+ end
443
+
444
+ # Fetch the Content Translation configuration json for the given language pair.
445
+ #
446
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxconfiguration} action.
447
+ #
448
+ # Action parameters could be passed or by subsequent
449
+ # {MediaWiktory::Wikipedia::Actions::Cxconfiguration} method calls, like
450
+ #
451
+ # ```ruby
452
+ # api.cxconfiguration.from('value')
453
+ # ```
454
+ #
455
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
456
+ # {MediaWiktory::Wikipedia::Actions::Cxconfiguration} class for a list of parameters and usage.
457
+ #
458
+ # @return [MediaWiktory::Wikipedia::Actions::Cxconfiguration]
459
+ #
460
+ def cxconfiguration
461
+ Cxconfiguration.new(client, @defaults)
462
+ end
463
+
464
+ # Delete a draft translation created using the Content Translation extension.
465
+ #
466
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxdelete} action.
467
+ #
468
+ # Action parameters could be passed or by subsequent
469
+ # {MediaWiktory::Wikipedia::Actions::Cxdelete} method calls, like
470
+ #
471
+ # ```ruby
472
+ # api.cxdelete.from('value')
473
+ # ```
474
+ #
475
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
476
+ # {MediaWiktory::Wikipedia::Actions::Cxdelete} class for a list of parameters and usage.
477
+ #
478
+ # @return [MediaWiktory::Wikipedia::Actions::Cxdelete]
479
+ #
480
+ def cxdelete
481
+ Cxdelete.new(client, @defaults)
482
+ end
483
+
484
+ # Save a page created using the Content Translation extension.
485
+ #
486
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxpublish} action.
487
+ #
488
+ # Action parameters could be passed or by subsequent
489
+ # {MediaWiktory::Wikipedia::Actions::Cxpublish} method calls, like
490
+ #
491
+ # ```ruby
492
+ # api.cxpublish.title('value')
493
+ # ```
494
+ #
495
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
496
+ # {MediaWiktory::Wikipedia::Actions::Cxpublish} class for a list of parameters and usage.
497
+ #
498
+ # @return [MediaWiktory::Wikipedia::Actions::Cxpublish]
499
+ #
500
+ def cxpublish
501
+ Cxpublish.new(client, @defaults)
502
+ end
503
+
504
+ # This module allows to save draft translations by section to save bandwidth and to collect parallel corpora.
505
+ #
506
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxsave} action.
507
+ #
508
+ # Action parameters could be passed or by subsequent
509
+ # {MediaWiktory::Wikipedia::Actions::Cxsave} method calls, like
510
+ #
511
+ # ```ruby
512
+ # api.cxsave.from('value')
513
+ # ```
514
+ #
515
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
516
+ # {MediaWiktory::Wikipedia::Actions::Cxsave} class for a list of parameters and usage.
517
+ #
518
+ # @return [MediaWiktory::Wikipedia::Actions::Cxsave]
519
+ #
520
+ def cxsave
521
+ Cxsave.new(client, @defaults)
522
+ end
523
+
524
+ # Manage the suggestion lists. Add suggestions to lists and remove them.
525
+ #
526
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxsuggestionlist} action.
527
+ #
528
+ # Action parameters could be passed or by subsequent
529
+ # {MediaWiktory::Wikipedia::Actions::Cxsuggestionlist} method calls, like
530
+ #
531
+ # ```ruby
532
+ # api.cxsuggestionlist.listname('value')
533
+ # ```
534
+ #
535
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
536
+ # {MediaWiktory::Wikipedia::Actions::Cxsuggestionlist} class for a list of parameters and usage.
537
+ #
538
+ # @return [MediaWiktory::Wikipedia::Actions::Cxsuggestionlist]
539
+ #
540
+ def cxsuggestionlist
541
+ Cxsuggestionlist.new(client, @defaults)
542
+ end
543
+
544
+ # Get JWT tokens to authenticate with cxserver.
545
+ #
546
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Cxtoken} action.
547
+ #
548
+ # Action parameters could be passed or by subsequent
549
+ # {MediaWiktory::Wikipedia::Actions::Cxtoken} method calls, like
550
+ #
551
+ # ```ruby
552
+ # api.cxtoken.token('value')
553
+ # ```
554
+ #
555
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
556
+ # {MediaWiktory::Wikipedia::Actions::Cxtoken} class for a list of parameters and usage.
557
+ #
558
+ # @return [MediaWiktory::Wikipedia::Actions::Cxtoken]
559
+ #
560
+ def cxtoken
561
+ Cxtoken.new(client, @defaults)
562
+ end
563
+
564
+ # Delete a page.
565
+ #
566
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Delete} action.
567
+ #
568
+ # Action parameters could be passed or by subsequent
569
+ # {MediaWiktory::Wikipedia::Actions::Delete} method calls, like
570
+ #
571
+ # ```ruby
572
+ # api.delete.title('value')
573
+ # ```
574
+ #
575
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
576
+ # {MediaWiktory::Wikipedia::Actions::Delete} class for a list of parameters and usage.
577
+ #
578
+ # @return [MediaWiktory::Wikipedia::Actions::Delete]
579
+ #
580
+ def delete
581
+ Delete.new(client, @defaults)
582
+ end
583
+
584
+ # Delete Education Program objects.
585
+ #
586
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Deleteeducation} action.
587
+ #
588
+ # Action parameters could be passed or by subsequent
589
+ # {MediaWiktory::Wikipedia::Actions::Deleteeducation} method calls, like
590
+ #
591
+ # ```ruby
592
+ # api.deleteeducation.ids('value')
593
+ # ```
594
+ #
595
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
596
+ # {MediaWiktory::Wikipedia::Actions::Deleteeducation} class for a list of parameters and usage.
597
+ #
598
+ # @return [MediaWiktory::Wikipedia::Actions::Deleteeducation]
599
+ #
600
+ def deleteeducation
601
+ Deleteeducation.new(client, @defaults)
602
+ end
603
+
604
+ # Delete a global user.
605
+ #
606
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Deleteglobalaccount} action.
607
+ #
608
+ # Action parameters could be passed or by subsequent
609
+ # {MediaWiktory::Wikipedia::Actions::Deleteglobalaccount} method calls, like
610
+ #
611
+ # ```ruby
612
+ # api.deleteglobalaccount.user('value')
613
+ # ```
614
+ #
615
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
616
+ # {MediaWiktory::Wikipedia::Actions::Deleteglobalaccount} class for a list of parameters and usage.
617
+ #
618
+ # @return [MediaWiktory::Wikipedia::Actions::Deleteglobalaccount]
619
+ #
620
+ def deleteglobalaccount
621
+ Deleteglobalaccount.new(client, @defaults)
622
+ end
623
+
624
+ # Mark notifications as read for the current user.
625
+ #
626
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Echomarkread} action.
627
+ #
628
+ # Action parameters could be passed or by subsequent
629
+ # {MediaWiktory::Wikipedia::Actions::Echomarkread} method calls, like
630
+ #
631
+ # ```ruby
632
+ # api.echomarkread.list('value')
633
+ # ```
634
+ #
635
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
636
+ # {MediaWiktory::Wikipedia::Actions::Echomarkread} class for a list of parameters and usage.
637
+ #
638
+ # @return [MediaWiktory::Wikipedia::Actions::Echomarkread]
639
+ #
640
+ def echomarkread
641
+ Echomarkread.new(client, @defaults)
642
+ end
643
+
644
+ # Mark notifications as seen for the current user.
645
+ #
646
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Echomarkseen} action.
647
+ #
648
+ # Action parameters could be passed or by subsequent
649
+ # {MediaWiktory::Wikipedia::Actions::Echomarkseen} method calls, like
650
+ #
651
+ # ```ruby
652
+ # api.echomarkseen.token('value')
653
+ # ```
654
+ #
655
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
656
+ # {MediaWiktory::Wikipedia::Actions::Echomarkseen} class for a list of parameters and usage.
657
+ #
658
+ # @return [MediaWiktory::Wikipedia::Actions::Echomarkseen]
659
+ #
660
+ def echomarkseen
661
+ Echomarkseen.new(client, @defaults)
662
+ end
663
+
664
+ # Create and edit pages.
665
+ #
666
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Edit} action.
667
+ #
668
+ # Action parameters could be passed or by subsequent
669
+ # {MediaWiktory::Wikipedia::Actions::Edit} method calls, like
670
+ #
671
+ # ```ruby
672
+ # api.edit.title('value')
673
+ # ```
674
+ #
675
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
676
+ # {MediaWiktory::Wikipedia::Actions::Edit} class for a list of parameters and usage.
677
+ #
678
+ # @return [MediaWiktory::Wikipedia::Actions::Edit]
679
+ #
680
+ def edit
681
+ Edit.new(client, @defaults)
682
+ end
683
+
684
+ # Edit a mass message delivery list.
685
+ #
686
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Editmassmessagelist} action.
687
+ #
688
+ # Action parameters could be passed or by subsequent
689
+ # {MediaWiktory::Wikipedia::Actions::Editmassmessagelist} method calls, like
690
+ #
691
+ # ```ruby
692
+ # api.editmassmessagelist.spamlist('value')
693
+ # ```
694
+ #
695
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
696
+ # {MediaWiktory::Wikipedia::Actions::Editmassmessagelist} class for a list of parameters and usage.
697
+ #
698
+ # @return [MediaWiktory::Wikipedia::Actions::Editmassmessagelist]
699
+ #
700
+ def editmassmessagelist
701
+ Editmassmessagelist.new(client, @defaults)
702
+ end
703
+
704
+ # Email a user.
705
+ #
706
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Emailuser} action.
707
+ #
708
+ # Action parameters could be passed or by subsequent
709
+ # {MediaWiktory::Wikipedia::Actions::Emailuser} method calls, like
710
+ #
711
+ # ```ruby
712
+ # api.emailuser.target('value')
713
+ # ```
714
+ #
715
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
716
+ # {MediaWiktory::Wikipedia::Actions::Emailuser} class for a list of parameters and usage.
717
+ #
718
+ # @return [MediaWiktory::Wikipedia::Actions::Emailuser]
719
+ #
720
+ def emailuser
721
+ Emailuser.new(client, @defaults)
722
+ end
723
+
724
+ # Associate or disassociate a user as instructor or volunteer for a course.
725
+ #
726
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Enlist} action.
727
+ #
728
+ # Action parameters could be passed or by subsequent
729
+ # {MediaWiktory::Wikipedia::Actions::Enlist} method calls, like
730
+ #
731
+ # ```ruby
732
+ # api.enlist.subaction('value')
733
+ # ```
734
+ #
735
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
736
+ # {MediaWiktory::Wikipedia::Actions::Enlist} class for a list of parameters and usage.
737
+ #
738
+ # @return [MediaWiktory::Wikipedia::Actions::Enlist]
739
+ #
740
+ def enlist
741
+ Enlist.new(client, @defaults)
742
+ end
743
+
744
+ # Expands all templates within wikitext.
745
+ #
746
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Expandtemplates} action.
747
+ #
748
+ # Action parameters could be passed or by subsequent
749
+ # {MediaWiktory::Wikipedia::Actions::Expandtemplates} method calls, like
750
+ #
751
+ # ```ruby
752
+ # api.expandtemplates.title('value')
753
+ # ```
754
+ #
755
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
756
+ # {MediaWiktory::Wikipedia::Actions::Expandtemplates} class for a list of parameters and usage.
757
+ #
758
+ # @return [MediaWiktory::Wikipedia::Actions::Expandtemplates]
759
+ #
760
+ def expandtemplates
761
+ Expandtemplates.new(client, @defaults)
762
+ end
763
+
764
+ # Get a new FancyCaptcha.
765
+ #
766
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Fancycaptchareload} action.
767
+ #
768
+
769
+ #
770
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
771
+ # {MediaWiktory::Wikipedia::Actions::Fancycaptchareload} class for a list of parameters and usage.
772
+ #
773
+ # @return [MediaWiktory::Wikipedia::Actions::Fancycaptchareload]
774
+ #
775
+ def fancycaptchareload
776
+ Fancycaptchareload.new(client, @defaults)
777
+ end
778
+
779
+ # Returns a featured content feed.
780
+ #
781
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Featuredfeed} action.
782
+ #
783
+ # Action parameters could be passed or by subsequent
784
+ # {MediaWiktory::Wikipedia::Actions::Featuredfeed} method calls, like
785
+ #
786
+ # ```ruby
787
+ # api.featuredfeed.feedformat('value')
788
+ # ```
789
+ #
790
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
791
+ # {MediaWiktory::Wikipedia::Actions::Featuredfeed} class for a list of parameters and usage.
792
+ #
793
+ # @return [MediaWiktory::Wikipedia::Actions::Featuredfeed]
794
+ #
795
+ def featuredfeed
796
+ Featuredfeed.new(client, @defaults)
797
+ end
798
+
799
+ # Returns a user contributions feed.
800
+ #
801
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Feedcontributions} action.
802
+ #
803
+ # Action parameters could be passed or by subsequent
804
+ # {MediaWiktory::Wikipedia::Actions::Feedcontributions} method calls, like
805
+ #
806
+ # ```ruby
807
+ # api.feedcontributions.feedformat('value')
808
+ # ```
809
+ #
810
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
811
+ # {MediaWiktory::Wikipedia::Actions::Feedcontributions} class for a list of parameters and usage.
812
+ #
813
+ # @return [MediaWiktory::Wikipedia::Actions::Feedcontributions]
814
+ #
815
+ def feedcontributions
816
+ Feedcontributions.new(client, @defaults)
817
+ end
818
+
819
+ # Returns a recent changes feed.
820
+ #
821
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Feedrecentchanges} action.
822
+ #
823
+ # Action parameters could be passed or by subsequent
824
+ # {MediaWiktory::Wikipedia::Actions::Feedrecentchanges} method calls, like
825
+ #
826
+ # ```ruby
827
+ # api.feedrecentchanges.feedformat('value')
828
+ # ```
829
+ #
830
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
831
+ # {MediaWiktory::Wikipedia::Actions::Feedrecentchanges} class for a list of parameters and usage.
832
+ #
833
+ # @return [MediaWiktory::Wikipedia::Actions::Feedrecentchanges]
834
+ #
835
+ def feedrecentchanges
836
+ Feedrecentchanges.new(client, @defaults)
837
+ end
838
+
839
+ # Returns a watchlist feed.
840
+ #
841
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Feedwatchlist} action.
842
+ #
843
+ # Action parameters could be passed or by subsequent
844
+ # {MediaWiktory::Wikipedia::Actions::Feedwatchlist} method calls, like
845
+ #
846
+ # ```ruby
847
+ # api.feedwatchlist.feedformat('value')
848
+ # ```
849
+ #
850
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
851
+ # {MediaWiktory::Wikipedia::Actions::Feedwatchlist} class for a list of parameters and usage.
852
+ #
853
+ # @return [MediaWiktory::Wikipedia::Actions::Feedwatchlist]
854
+ #
855
+ def feedwatchlist
856
+ Feedwatchlist.new(client, @defaults)
857
+ end
858
+
859
+ # Revert a file to an old version.
860
+ #
861
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Filerevert} action.
862
+ #
863
+ # Action parameters could be passed or by subsequent
864
+ # {MediaWiktory::Wikipedia::Actions::Filerevert} method calls, like
865
+ #
866
+ # ```ruby
867
+ # api.filerevert.filename('value')
868
+ # ```
869
+ #
870
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
871
+ # {MediaWiktory::Wikipedia::Actions::Filerevert} class for a list of parameters and usage.
872
+ #
873
+ # @return [MediaWiktory::Wikipedia::Actions::Filerevert]
874
+ #
875
+ def filerevert
876
+ Filerevert.new(client, @defaults)
877
+ end
878
+
879
+ # Get basic information about review flag configuration for this site.
880
+ #
881
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Flagconfig} action.
882
+ #
883
+
884
+ #
885
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
886
+ # {MediaWiktory::Wikipedia::Actions::Flagconfig} class for a list of parameters and usage.
887
+ #
888
+ # @return [MediaWiktory::Wikipedia::Actions::Flagconfig]
889
+ #
890
+ def flagconfig
891
+ Flagconfig.new(client, @defaults)
892
+ end
893
+
894
+ # Globally block or unblock a user.
895
+ #
896
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Globalblock} action.
897
+ #
898
+ # Action parameters could be passed or by subsequent
899
+ # {MediaWiktory::Wikipedia::Actions::Globalblock} method calls, like
900
+ #
901
+ # ```ruby
902
+ # api.globalblock.target('value')
903
+ # ```
904
+ #
905
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
906
+ # {MediaWiktory::Wikipedia::Actions::Globalblock} class for a list of parameters and usage.
907
+ #
908
+ # @return [MediaWiktory::Wikipedia::Actions::Globalblock]
909
+ #
910
+ def globalblock
911
+ Globalblock.new(client, @defaults)
912
+ end
913
+
914
+ # Add/remove a user to/from global groups.
915
+ #
916
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Globaluserrights} action.
917
+ #
918
+ # Action parameters could be passed or by subsequent
919
+ # {MediaWiktory::Wikipedia::Actions::Globaluserrights} method calls, like
920
+ #
921
+ # ```ruby
922
+ # api.globaluserrights.user('value')
923
+ # ```
924
+ #
925
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
926
+ # {MediaWiktory::Wikipedia::Actions::Globaluserrights} class for a list of parameters and usage.
927
+ #
928
+ # @return [MediaWiktory::Wikipedia::Actions::Globaluserrights]
929
+ #
930
+ def globaluserrights
931
+ Globaluserrights.new(client, @defaults)
932
+ end
933
+
934
+ # Access graph tag functionality.
935
+ #
936
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Graph} action.
937
+ #
938
+ # Action parameters could be passed or by subsequent
939
+ # {MediaWiktory::Wikipedia::Actions::Graph} method calls, like
940
+ #
941
+ # ```ruby
942
+ # api.graph.hash('value')
943
+ # ```
944
+ #
945
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
946
+ # {MediaWiktory::Wikipedia::Actions::Graph} class for a list of parameters and usage.
947
+ #
948
+ # @return [MediaWiktory::Wikipedia::Actions::Graph]
949
+ #
950
+ def graph
951
+ Graph.new(client, @defaults)
952
+ end
953
+
954
+ # Display help for the specified modules.
955
+ #
956
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Help} action.
957
+ #
958
+ # Action parameters could be passed or by subsequent
959
+ # {MediaWiktory::Wikipedia::Actions::Help} method calls, like
960
+ #
961
+ # ```ruby
962
+ # api.help.modules('value')
963
+ # ```
964
+ #
965
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
966
+ # {MediaWiktory::Wikipedia::Actions::Help} class for a list of parameters and usage.
967
+ #
968
+ # @return [MediaWiktory::Wikipedia::Actions::Help]
969
+ #
970
+ def help
971
+ Help.new(client, @defaults)
972
+ end
973
+
974
+ # This module has been disabled.
975
+ #
976
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Imagerotate} action.
977
+ #
978
+
979
+ #
980
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
981
+ # {MediaWiktory::Wikipedia::Actions::Imagerotate} class for a list of parameters and usage.
982
+ #
983
+ # @return [MediaWiktory::Wikipedia::Actions::Imagerotate]
984
+ #
985
+ def imagerotate
986
+ Imagerotate.new(client, @defaults)
987
+ end
988
+
989
+ # Import a page from another wiki, or from an XML file.
990
+ #
991
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Import} action.
992
+ #
993
+ # Action parameters could be passed or by subsequent
994
+ # {MediaWiktory::Wikipedia::Actions::Import} method calls, like
995
+ #
996
+ # ```ruby
997
+ # api.import.summary('value')
998
+ # ```
999
+ #
1000
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1001
+ # {MediaWiktory::Wikipedia::Actions::Import} class for a list of parameters and usage.
1002
+ #
1003
+ # @return [MediaWiktory::Wikipedia::Actions::Import]
1004
+ #
1005
+ def import
1006
+ Import.new(client, @defaults)
1007
+ end
1008
+
1009
+ # Allows direct access to JsonConfig subsystem.
1010
+ #
1011
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Jsonconfig} action.
1012
+ #
1013
+ # Action parameters could be passed or by subsequent
1014
+ # {MediaWiktory::Wikipedia::Actions::Jsonconfig} method calls, like
1015
+ #
1016
+ # ```ruby
1017
+ # api.jsonconfig.command('value')
1018
+ # ```
1019
+ #
1020
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1021
+ # {MediaWiktory::Wikipedia::Actions::Jsonconfig} class for a list of parameters and usage.
1022
+ #
1023
+ # @return [MediaWiktory::Wikipedia::Actions::Jsonconfig]
1024
+ #
1025
+ def jsonconfig
1026
+ Jsonconfig.new(client, @defaults)
1027
+ end
1028
+
1029
+ # Retrieve localized JSON data.
1030
+ #
1031
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Jsondata} action.
1032
+ #
1033
+ # Action parameters could be passed or by subsequent
1034
+ # {MediaWiktory::Wikipedia::Actions::Jsondata} method calls, like
1035
+ #
1036
+ # ```ruby
1037
+ # api.jsondata.title('value')
1038
+ # ```
1039
+ #
1040
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1041
+ # {MediaWiktory::Wikipedia::Actions::Jsondata} class for a list of parameters and usage.
1042
+ #
1043
+ # @return [MediaWiktory::Wikipedia::Actions::Jsondata]
1044
+ #
1045
+ def jsondata
1046
+ Jsondata.new(client, @defaults)
1047
+ end
1048
+
1049
+ # Search for language names in any script.
1050
+ #
1051
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Languagesearch} action.
1052
+ #
1053
+ # Action parameters could be passed or by subsequent
1054
+ # {MediaWiktory::Wikipedia::Actions::Languagesearch} method calls, like
1055
+ #
1056
+ # ```ruby
1057
+ # api.languagesearch.search('value')
1058
+ # ```
1059
+ #
1060
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1061
+ # {MediaWiktory::Wikipedia::Actions::Languagesearch} class for a list of parameters and usage.
1062
+ #
1063
+ # @return [MediaWiktory::Wikipedia::Actions::Languagesearch]
1064
+ #
1065
+ def languagesearch
1066
+ Languagesearch.new(client, @defaults)
1067
+ end
1068
+
1069
+ # Link an account from a third-party provider to the current user.
1070
+ #
1071
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Linkaccount} action.
1072
+ #
1073
+ # Action parameters could be passed or by subsequent
1074
+ # {MediaWiktory::Wikipedia::Actions::Linkaccount} method calls, like
1075
+ #
1076
+ # ```ruby
1077
+ # api.linkaccount.requests('value')
1078
+ # ```
1079
+ #
1080
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1081
+ # {MediaWiktory::Wikipedia::Actions::Linkaccount} class for a list of parameters and usage.
1082
+ #
1083
+ # @return [MediaWiktory::Wikipedia::Actions::Linkaccount]
1084
+ #
1085
+ def linkaccount
1086
+ Linkaccount.new(client, @defaults)
1087
+ end
1088
+
1089
+ # Get the usernames and other information for students enrolled in one or more courses.
1090
+ #
1091
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Liststudents} action.
1092
+ #
1093
+ # Action parameters could be passed or by subsequent
1094
+ # {MediaWiktory::Wikipedia::Actions::Liststudents} method calls, like
1095
+ #
1096
+ # ```ruby
1097
+ # api.liststudents.courseids('value')
1098
+ # ```
1099
+ #
1100
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1101
+ # {MediaWiktory::Wikipedia::Actions::Liststudents} class for a list of parameters and usage.
1102
+ #
1103
+ # @return [MediaWiktory::Wikipedia::Actions::Liststudents]
1104
+ #
1105
+ def liststudents
1106
+ Liststudents.new(client, @defaults)
1107
+ end
1108
+
1109
+ # Log in and get authentication cookies.
1110
+ #
1111
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Login} action.
1112
+ #
1113
+ # Action parameters could be passed or by subsequent
1114
+ # {MediaWiktory::Wikipedia::Actions::Login} method calls, like
1115
+ #
1116
+ # ```ruby
1117
+ # api.login.name('value')
1118
+ # ```
1119
+ #
1120
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1121
+ # {MediaWiktory::Wikipedia::Actions::Login} class for a list of parameters and usage.
1122
+ #
1123
+ # @return [MediaWiktory::Wikipedia::Actions::Login]
1124
+ #
1125
+ def login
1126
+ Login.new(client, @defaults)
1127
+ end
1128
+
1129
+ # Log out and clear session data.
1130
+ #
1131
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Logout} action.
1132
+ #
1133
+
1134
+ #
1135
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1136
+ # {MediaWiktory::Wikipedia::Actions::Logout} class for a list of parameters and usage.
1137
+ #
1138
+ # @return [MediaWiktory::Wikipedia::Actions::Logout]
1139
+ #
1140
+ def logout
1141
+ Logout.new(client, @defaults)
1142
+ end
1143
+
1144
+ # Perform management tasks relating to change tags.
1145
+ #
1146
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Managetags} action.
1147
+ #
1148
+ # Action parameters could be passed or by subsequent
1149
+ # {MediaWiktory::Wikipedia::Actions::Managetags} method calls, like
1150
+ #
1151
+ # ```ruby
1152
+ # api.managetags.operation('value')
1153
+ # ```
1154
+ #
1155
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1156
+ # {MediaWiktory::Wikipedia::Actions::Managetags} class for a list of parameters and usage.
1157
+ #
1158
+ # @return [MediaWiktory::Wikipedia::Actions::Managetags]
1159
+ #
1160
+ def managetags
1161
+ Managetags.new(client, @defaults)
1162
+ end
1163
+
1164
+ # Send a message to a list of pages.
1165
+ #
1166
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Massmessage} action.
1167
+ #
1168
+ # Action parameters could be passed or by subsequent
1169
+ # {MediaWiktory::Wikipedia::Actions::Massmessage} method calls, like
1170
+ #
1171
+ # ```ruby
1172
+ # api.massmessage.spamlist('value')
1173
+ # ```
1174
+ #
1175
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1176
+ # {MediaWiktory::Wikipedia::Actions::Massmessage} class for a list of parameters and usage.
1177
+ #
1178
+ # @return [MediaWiktory::Wikipedia::Actions::Massmessage]
1179
+ #
1180
+ def massmessage
1181
+ Massmessage.new(client, @defaults)
1182
+ end
1183
+
1184
+ # Merge page histories.
1185
+ #
1186
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Mergehistory} action.
1187
+ #
1188
+ # Action parameters could be passed or by subsequent
1189
+ # {MediaWiktory::Wikipedia::Actions::Mergehistory} method calls, like
1190
+ #
1191
+ # ```ruby
1192
+ # api.mergehistory.from('value')
1193
+ # ```
1194
+ #
1195
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1196
+ # {MediaWiktory::Wikipedia::Actions::Mergehistory} class for a list of parameters and usage.
1197
+ #
1198
+ # @return [MediaWiktory::Wikipedia::Actions::Mergehistory]
1199
+ #
1200
+ def mergehistory
1201
+ Mergehistory.new(client, @defaults)
1202
+ end
1203
+
1204
+ # Returns data needed for mobile views.
1205
+ #
1206
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Mobileview} action.
1207
+ #
1208
+ # Action parameters could be passed or by subsequent
1209
+ # {MediaWiktory::Wikipedia::Actions::Mobileview} method calls, like
1210
+ #
1211
+ # ```ruby
1212
+ # api.mobileview.page('value')
1213
+ # ```
1214
+ #
1215
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1216
+ # {MediaWiktory::Wikipedia::Actions::Mobileview} class for a list of parameters and usage.
1217
+ #
1218
+ # @return [MediaWiktory::Wikipedia::Actions::Mobileview]
1219
+ #
1220
+ def mobileview
1221
+ Mobileview.new(client, @defaults)
1222
+ end
1223
+
1224
+ # Move a page.
1225
+ #
1226
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Move} action.
1227
+ #
1228
+ # Action parameters could be passed or by subsequent
1229
+ # {MediaWiktory::Wikipedia::Actions::Move} method calls, like
1230
+ #
1231
+ # ```ruby
1232
+ # api.move.from('value')
1233
+ # ```
1234
+ #
1235
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1236
+ # {MediaWiktory::Wikipedia::Actions::Move} class for a list of parameters and usage.
1237
+ #
1238
+ # @return [MediaWiktory::Wikipedia::Actions::Move]
1239
+ #
1240
+ def move
1241
+ Move.new(client, @defaults)
1242
+ end
1243
+
1244
+ # Validate a two-factor authentication (OATH) token.
1245
+ #
1246
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Oathvalidate} action.
1247
+ #
1248
+ # Action parameters could be passed or by subsequent
1249
+ # {MediaWiktory::Wikipedia::Actions::Oathvalidate} method calls, like
1250
+ #
1251
+ # ```ruby
1252
+ # api.oathvalidate.user('value')
1253
+ # ```
1254
+ #
1255
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1256
+ # {MediaWiktory::Wikipedia::Actions::Oathvalidate} class for a list of parameters and usage.
1257
+ #
1258
+ # @return [MediaWiktory::Wikipedia::Actions::Oathvalidate]
1259
+ #
1260
+ def oathvalidate
1261
+ Oathvalidate.new(client, @defaults)
1262
+ end
1263
+
1264
+ # Search the wiki using the OpenSearch protocol.
1265
+ #
1266
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Opensearch} action.
1267
+ #
1268
+ # Action parameters could be passed or by subsequent
1269
+ # {MediaWiktory::Wikipedia::Actions::Opensearch} method calls, like
1270
+ #
1271
+ # ```ruby
1272
+ # api.opensearch.search('value')
1273
+ # ```
1274
+ #
1275
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1276
+ # {MediaWiktory::Wikipedia::Actions::Opensearch} class for a list of parameters and usage.
1277
+ #
1278
+ # @return [MediaWiktory::Wikipedia::Actions::Opensearch]
1279
+ #
1280
+ def opensearch
1281
+ Opensearch.new(client, @defaults)
1282
+ end
1283
+
1284
+ # Change preferences of the current user.
1285
+ #
1286
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Options} action.
1287
+ #
1288
+ # Action parameters could be passed or by subsequent
1289
+ # {MediaWiktory::Wikipedia::Actions::Options} method calls, like
1290
+ #
1291
+ # ```ruby
1292
+ # api.options.reset('value')
1293
+ # ```
1294
+ #
1295
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1296
+ # {MediaWiktory::Wikipedia::Actions::Options} class for a list of parameters and usage.
1297
+ #
1298
+ # @return [MediaWiktory::Wikipedia::Actions::Options]
1299
+ #
1300
+ def options
1301
+ Options.new(client, @defaults)
1302
+ end
1303
+
1304
+ # Mark an article as reviewed or unreviewed.
1305
+ #
1306
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Pagetriageaction} action.
1307
+ #
1308
+ # Action parameters could be passed or by subsequent
1309
+ # {MediaWiktory::Wikipedia::Actions::Pagetriageaction} method calls, like
1310
+ #
1311
+ # ```ruby
1312
+ # api.pagetriageaction.pageid('value')
1313
+ # ```
1314
+ #
1315
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1316
+ # {MediaWiktory::Wikipedia::Actions::Pagetriageaction} class for a list of parameters and usage.
1317
+ #
1318
+ # @return [MediaWiktory::Wikipedia::Actions::Pagetriageaction]
1319
+ #
1320
+ def pagetriageaction
1321
+ Pagetriageaction.new(client, @defaults)
1322
+ end
1323
+
1324
+ # Get a list of page IDs for building a PageTriage queue.
1325
+ #
1326
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Pagetriagelist} action.
1327
+ #
1328
+ # Action parameters could be passed or by subsequent
1329
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagelist} method calls, like
1330
+ #
1331
+ # ```ruby
1332
+ # api.pagetriagelist.page_id('value')
1333
+ # ```
1334
+ #
1335
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1336
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagelist} class for a list of parameters and usage.
1337
+ #
1338
+ # @return [MediaWiktory::Wikipedia::Actions::Pagetriagelist]
1339
+ #
1340
+ def pagetriagelist
1341
+ Pagetriagelist.new(client, @defaults)
1342
+ end
1343
+
1344
+ # Get the stats for page triage.
1345
+ #
1346
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Pagetriagestats} action.
1347
+ #
1348
+ # Action parameters could be passed or by subsequent
1349
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagestats} method calls, like
1350
+ #
1351
+ # ```ruby
1352
+ # api.pagetriagestats.namespace('value')
1353
+ # ```
1354
+ #
1355
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1356
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagestats} class for a list of parameters and usage.
1357
+ #
1358
+ # @return [MediaWiktory::Wikipedia::Actions::Pagetriagestats]
1359
+ #
1360
+ def pagetriagestats
1361
+ Pagetriagestats.new(client, @defaults)
1362
+ end
1363
+
1364
+ # Add tags to an article.
1365
+ #
1366
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Pagetriagetagging} action.
1367
+ #
1368
+ # Action parameters could be passed or by subsequent
1369
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagetagging} method calls, like
1370
+ #
1371
+ # ```ruby
1372
+ # api.pagetriagetagging.pageid('value')
1373
+ # ```
1374
+ #
1375
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1376
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagetagging} class for a list of parameters and usage.
1377
+ #
1378
+ # @return [MediaWiktory::Wikipedia::Actions::Pagetriagetagging]
1379
+ #
1380
+ def pagetriagetagging
1381
+ Pagetriagetagging.new(client, @defaults)
1382
+ end
1383
+
1384
+ # Fetch templates that are used within the PageTriage application.
1385
+ #
1386
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Pagetriagetemplate} action.
1387
+ #
1388
+ # Action parameters could be passed or by subsequent
1389
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagetemplate} method calls, like
1390
+ #
1391
+ # ```ruby
1392
+ # api.pagetriagetemplate.view('value')
1393
+ # ```
1394
+ #
1395
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1396
+ # {MediaWiktory::Wikipedia::Actions::Pagetriagetemplate} class for a list of parameters and usage.
1397
+ #
1398
+ # @return [MediaWiktory::Wikipedia::Actions::Pagetriagetemplate]
1399
+ #
1400
+ def pagetriagetemplate
1401
+ Pagetriagetemplate.new(client, @defaults)
1402
+ end
1403
+
1404
+ # Obtain information about API modules.
1405
+ #
1406
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Paraminfo} action.
1407
+ #
1408
+ # Action parameters could be passed or by subsequent
1409
+ # {MediaWiktory::Wikipedia::Actions::Paraminfo} method calls, like
1410
+ #
1411
+ # ```ruby
1412
+ # api.paraminfo.modules('value')
1413
+ # ```
1414
+ #
1415
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1416
+ # {MediaWiktory::Wikipedia::Actions::Paraminfo} class for a list of parameters and usage.
1417
+ #
1418
+ # @return [MediaWiktory::Wikipedia::Actions::Paraminfo]
1419
+ #
1420
+ def paraminfo
1421
+ Paraminfo.new(client, @defaults)
1422
+ end
1423
+
1424
+ # Parses content and returns parser output.
1425
+ #
1426
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Parse} action.
1427
+ #
1428
+ # Action parameters could be passed or by subsequent
1429
+ # {MediaWiktory::Wikipedia::Actions::Parse} method calls, like
1430
+ #
1431
+ # ```ruby
1432
+ # api.parse.title('value')
1433
+ # ```
1434
+ #
1435
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1436
+ # {MediaWiktory::Wikipedia::Actions::Parse} class for a list of parameters and usage.
1437
+ #
1438
+ # @return [MediaWiktory::Wikipedia::Actions::Parse]
1439
+ #
1440
+ def parse
1441
+ Parse.new(client, @defaults)
1442
+ end
1443
+
1444
+ #
1445
+ #
1446
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::ParsoidBatch} action.
1447
+ #
1448
+ # Action parameters could be passed or by subsequent
1449
+ # {MediaWiktory::Wikipedia::Actions::ParsoidBatch} method calls, like
1450
+ #
1451
+ # ```ruby
1452
+ # api.parsoid_batch.batch('value')
1453
+ # ```
1454
+ #
1455
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1456
+ # {MediaWiktory::Wikipedia::Actions::ParsoidBatch} class for a list of parameters and usage.
1457
+ #
1458
+ # @return [MediaWiktory::Wikipedia::Actions::ParsoidBatch]
1459
+ #
1460
+ def parsoid_batch
1461
+ ParsoidBatch.new(client, @defaults)
1462
+ end
1463
+
1464
+ # Patrol a page or revision.
1465
+ #
1466
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Patrol} action.
1467
+ #
1468
+ # Action parameters could be passed or by subsequent
1469
+ # {MediaWiktory::Wikipedia::Actions::Patrol} method calls, like
1470
+ #
1471
+ # ```ruby
1472
+ # api.patrol.rcid('value')
1473
+ # ```
1474
+ #
1475
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1476
+ # {MediaWiktory::Wikipedia::Actions::Patrol} class for a list of parameters and usage.
1477
+ #
1478
+ # @return [MediaWiktory::Wikipedia::Actions::Patrol]
1479
+ #
1480
+ def patrol
1481
+ Patrol.new(client, @defaults)
1482
+ end
1483
+
1484
+ # Change the protection level of a page.
1485
+ #
1486
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Protect} action.
1487
+ #
1488
+ # Action parameters could be passed or by subsequent
1489
+ # {MediaWiktory::Wikipedia::Actions::Protect} method calls, like
1490
+ #
1491
+ # ```ruby
1492
+ # api.protect.title('value')
1493
+ # ```
1494
+ #
1495
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1496
+ # {MediaWiktory::Wikipedia::Actions::Protect} class for a list of parameters and usage.
1497
+ #
1498
+ # @return [MediaWiktory::Wikipedia::Actions::Protect]
1499
+ #
1500
+ def protect
1501
+ Protect.new(client, @defaults)
1502
+ end
1503
+
1504
+ # Purge the cache for the given titles.
1505
+ #
1506
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Purge} action.
1507
+ #
1508
+ # Action parameters could be passed or by subsequent
1509
+ # {MediaWiktory::Wikipedia::Actions::Purge} method calls, like
1510
+ #
1511
+ # ```ruby
1512
+ # api.purge.forcelinkupdate('value')
1513
+ # ```
1514
+ #
1515
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1516
+ # {MediaWiktory::Wikipedia::Actions::Purge} class for a list of parameters and usage.
1517
+ #
1518
+ # @return [MediaWiktory::Wikipedia::Actions::Purge]
1519
+ #
1520
+ def purge
1521
+ Purge.new(client, @defaults)
1522
+ end
1523
+
1524
+ # Fetch data from and about MediaWiki.
1525
+ #
1526
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Query} action.
1527
+ #
1528
+ # Action parameters could be passed or by subsequent
1529
+ # {MediaWiktory::Wikipedia::Actions::Query} method calls, like
1530
+ #
1531
+ # ```ruby
1532
+ # api.query.prop('value')
1533
+ # ```
1534
+ #
1535
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1536
+ # {MediaWiktory::Wikipedia::Actions::Query} class for a list of parameters and usage.
1537
+ #
1538
+ # @return [MediaWiktory::Wikipedia::Actions::Query]
1539
+ #
1540
+ def query
1541
+ Query.new(client, @defaults)
1542
+ end
1543
+
1544
+ # Rebuild summary data of Education Program objects.
1545
+ #
1546
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Refresheducation} action.
1547
+ #
1548
+ # Action parameters could be passed or by subsequent
1549
+ # {MediaWiktory::Wikipedia::Actions::Refresheducation} method calls, like
1550
+ #
1551
+ # ```ruby
1552
+ # api.refresheducation.ids('value')
1553
+ # ```
1554
+ #
1555
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1556
+ # {MediaWiktory::Wikipedia::Actions::Refresheducation} class for a list of parameters and usage.
1557
+ #
1558
+ # @return [MediaWiktory::Wikipedia::Actions::Refresheducation]
1559
+ #
1560
+ def refresheducation
1561
+ Refresheducation.new(client, @defaults)
1562
+ end
1563
+
1564
+ # Remove authentication data for the current user.
1565
+ #
1566
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Removeauthenticationdata} action.
1567
+ #
1568
+ # Action parameters could be passed or by subsequent
1569
+ # {MediaWiktory::Wikipedia::Actions::Removeauthenticationdata} method calls, like
1570
+ #
1571
+ # ```ruby
1572
+ # api.removeauthenticationdata.request('value')
1573
+ # ```
1574
+ #
1575
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1576
+ # {MediaWiktory::Wikipedia::Actions::Removeauthenticationdata} class for a list of parameters and usage.
1577
+ #
1578
+ # @return [MediaWiktory::Wikipedia::Actions::Removeauthenticationdata]
1579
+ #
1580
+ def removeauthenticationdata
1581
+ Removeauthenticationdata.new(client, @defaults)
1582
+ end
1583
+
1584
+ # Send a password reset email to a user.
1585
+ #
1586
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Resetpassword} action.
1587
+ #
1588
+ # Action parameters could be passed or by subsequent
1589
+ # {MediaWiktory::Wikipedia::Actions::Resetpassword} method calls, like
1590
+ #
1591
+ # ```ruby
1592
+ # api.resetpassword.user('value')
1593
+ # ```
1594
+ #
1595
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1596
+ # {MediaWiktory::Wikipedia::Actions::Resetpassword} class for a list of parameters and usage.
1597
+ #
1598
+ # @return [MediaWiktory::Wikipedia::Actions::Resetpassword]
1599
+ #
1600
+ def resetpassword
1601
+ Resetpassword.new(client, @defaults)
1602
+ end
1603
+
1604
+ # Review a revision by approving or de-approving it.
1605
+ #
1606
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Review} action.
1607
+ #
1608
+ # Action parameters could be passed or by subsequent
1609
+ # {MediaWiktory::Wikipedia::Actions::Review} method calls, like
1610
+ #
1611
+ # ```ruby
1612
+ # api.review.revid('value')
1613
+ # ```
1614
+ #
1615
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1616
+ # {MediaWiktory::Wikipedia::Actions::Review} class for a list of parameters and usage.
1617
+ #
1618
+ # @return [MediaWiktory::Wikipedia::Actions::Review]
1619
+ #
1620
+ def review
1621
+ Review.new(client, @defaults)
1622
+ end
1623
+
1624
+ # Advertise or de-advertise yourself as reviewing an unreviewed page or unreviewed changes.
1625
+ #
1626
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Reviewactivity} action.
1627
+ #
1628
+ # Action parameters could be passed or by subsequent
1629
+ # {MediaWiktory::Wikipedia::Actions::Reviewactivity} method calls, like
1630
+ #
1631
+ # ```ruby
1632
+ # api.reviewactivity.previd('value')
1633
+ # ```
1634
+ #
1635
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1636
+ # {MediaWiktory::Wikipedia::Actions::Reviewactivity} class for a list of parameters and usage.
1637
+ #
1638
+ # @return [MediaWiktory::Wikipedia::Actions::Reviewactivity]
1639
+ #
1640
+ def reviewactivity
1641
+ Reviewactivity.new(client, @defaults)
1642
+ end
1643
+
1644
+ # Delete and undelete revisions.
1645
+ #
1646
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Revisiondelete} action.
1647
+ #
1648
+ # Action parameters could be passed or by subsequent
1649
+ # {MediaWiktory::Wikipedia::Actions::Revisiondelete} method calls, like
1650
+ #
1651
+ # ```ruby
1652
+ # api.revisiondelete.type('value')
1653
+ # ```
1654
+ #
1655
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1656
+ # {MediaWiktory::Wikipedia::Actions::Revisiondelete} class for a list of parameters and usage.
1657
+ #
1658
+ # @return [MediaWiktory::Wikipedia::Actions::Revisiondelete]
1659
+ #
1660
+ def revisiondelete
1661
+ Revisiondelete.new(client, @defaults)
1662
+ end
1663
+
1664
+ # Undo the last edit to the page.
1665
+ #
1666
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Rollback} action.
1667
+ #
1668
+ # Action parameters could be passed or by subsequent
1669
+ # {MediaWiktory::Wikipedia::Actions::Rollback} method calls, like
1670
+ #
1671
+ # ```ruby
1672
+ # api.rollback.title('value')
1673
+ # ```
1674
+ #
1675
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1676
+ # {MediaWiktory::Wikipedia::Actions::Rollback} class for a list of parameters and usage.
1677
+ #
1678
+ # @return [MediaWiktory::Wikipedia::Actions::Rollback]
1679
+ #
1680
+ def rollback
1681
+ Rollback.new(client, @defaults)
1682
+ end
1683
+
1684
+ # Export an RSD (Really Simple Discovery) schema.
1685
+ #
1686
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Rsd} action.
1687
+ #
1688
+
1689
+ #
1690
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1691
+ # {MediaWiktory::Wikipedia::Actions::Rsd} class for a list of parameters and usage.
1692
+ #
1693
+ # @return [MediaWiktory::Wikipedia::Actions::Rsd]
1694
+ #
1695
+ def rsd
1696
+ Rsd.new(client, @defaults)
1697
+ end
1698
+
1699
+ # Performs data validation for Kartographer extension
1700
+ #
1701
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::SanitizeMapdata} action.
1702
+ #
1703
+ # Action parameters could be passed or by subsequent
1704
+ # {MediaWiktory::Wikipedia::Actions::SanitizeMapdata} method calls, like
1705
+ #
1706
+ # ```ruby
1707
+ # api.sanitize_mapdata.title('value')
1708
+ # ```
1709
+ #
1710
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1711
+ # {MediaWiktory::Wikipedia::Actions::SanitizeMapdata} class for a list of parameters and usage.
1712
+ #
1713
+ # @return [MediaWiktory::Wikipedia::Actions::SanitizeMapdata]
1714
+ #
1715
+ def sanitize_mapdata
1716
+ SanitizeMapdata.new(client, @defaults)
1717
+ end
1718
+
1719
+ # Internal module for servicing XHR requests from the Scribunto console.
1720
+ #
1721
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::ScribuntoConsole} action.
1722
+ #
1723
+ # Action parameters could be passed or by subsequent
1724
+ # {MediaWiktory::Wikipedia::Actions::ScribuntoConsole} method calls, like
1725
+ #
1726
+ # ```ruby
1727
+ # api.scribunto_console.title('value')
1728
+ # ```
1729
+ #
1730
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1731
+ # {MediaWiktory::Wikipedia::Actions::ScribuntoConsole} class for a list of parameters and usage.
1732
+ #
1733
+ # @return [MediaWiktory::Wikipedia::Actions::ScribuntoConsole]
1734
+ #
1735
+ def scribunto_console
1736
+ ScribuntoConsole.new(client, @defaults)
1737
+ end
1738
+
1739
+ # Set a global user's status.
1740
+ #
1741
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Setglobalaccountstatus} action.
1742
+ #
1743
+ # Action parameters could be passed or by subsequent
1744
+ # {MediaWiktory::Wikipedia::Actions::Setglobalaccountstatus} method calls, like
1745
+ #
1746
+ # ```ruby
1747
+ # api.setglobalaccountstatus.user('value')
1748
+ # ```
1749
+ #
1750
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1751
+ # {MediaWiktory::Wikipedia::Actions::Setglobalaccountstatus} class for a list of parameters and usage.
1752
+ #
1753
+ # @return [MediaWiktory::Wikipedia::Actions::Setglobalaccountstatus]
1754
+ #
1755
+ def setglobalaccountstatus
1756
+ Setglobalaccountstatus.new(client, @defaults)
1757
+ end
1758
+
1759
+ # Update the notification timestamp for watched pages.
1760
+ #
1761
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Setnotificationtimestamp} action.
1762
+ #
1763
+ # Action parameters could be passed or by subsequent
1764
+ # {MediaWiktory::Wikipedia::Actions::Setnotificationtimestamp} method calls, like
1765
+ #
1766
+ # ```ruby
1767
+ # api.setnotificationtimestamp.entirewatchlist('value')
1768
+ # ```
1769
+ #
1770
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1771
+ # {MediaWiktory::Wikipedia::Actions::Setnotificationtimestamp} class for a list of parameters and usage.
1772
+ #
1773
+ # @return [MediaWiktory::Wikipedia::Actions::Setnotificationtimestamp]
1774
+ #
1775
+ def setnotificationtimestamp
1776
+ Setnotificationtimestamp.new(client, @defaults)
1777
+ end
1778
+
1779
+ # Changing the language of a page is not allowed on this wiki.
1780
+ #
1781
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Setpagelanguage} action.
1782
+ #
1783
+ # Action parameters could be passed or by subsequent
1784
+ # {MediaWiktory::Wikipedia::Actions::Setpagelanguage} method calls, like
1785
+ #
1786
+ # ```ruby
1787
+ # api.setpagelanguage.title('value')
1788
+ # ```
1789
+ #
1790
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1791
+ # {MediaWiktory::Wikipedia::Actions::Setpagelanguage} class for a list of parameters and usage.
1792
+ #
1793
+ # @return [MediaWiktory::Wikipedia::Actions::Setpagelanguage]
1794
+ #
1795
+ def setpagelanguage
1796
+ Setpagelanguage.new(client, @defaults)
1797
+ end
1798
+
1799
+ # Shorten a long URL into a shorter one.
1800
+ #
1801
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Shortenurl} action.
1802
+ #
1803
+ # Action parameters could be passed or by subsequent
1804
+ # {MediaWiktory::Wikipedia::Actions::Shortenurl} method calls, like
1805
+ #
1806
+ # ```ruby
1807
+ # api.shortenurl.url('value')
1808
+ # ```
1809
+ #
1810
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1811
+ # {MediaWiktory::Wikipedia::Actions::Shortenurl} class for a list of parameters and usage.
1812
+ #
1813
+ # @return [MediaWiktory::Wikipedia::Actions::Shortenurl]
1814
+ #
1815
+ def shortenurl
1816
+ Shortenurl.new(client, @defaults)
1817
+ end
1818
+
1819
+ # Get Wikimedia sites list.
1820
+ #
1821
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Sitematrix} action.
1822
+ #
1823
+ # Action parameters could be passed or by subsequent
1824
+ # {MediaWiktory::Wikipedia::Actions::Sitematrix} method calls, like
1825
+ #
1826
+ # ```ruby
1827
+ # api.sitematrix.type('value')
1828
+ # ```
1829
+ #
1830
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1831
+ # {MediaWiktory::Wikipedia::Actions::Sitematrix} class for a list of parameters and usage.
1832
+ #
1833
+ # @return [MediaWiktory::Wikipedia::Actions::Sitematrix]
1834
+ #
1835
+ def sitematrix
1836
+ Sitematrix.new(client, @defaults)
1837
+ end
1838
+
1839
+ # Validate one or more URLs against the SpamBlacklist.
1840
+ #
1841
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Spamblacklist} action.
1842
+ #
1843
+ # Action parameters could be passed or by subsequent
1844
+ # {MediaWiktory::Wikipedia::Actions::Spamblacklist} method calls, like
1845
+ #
1846
+ # ```ruby
1847
+ # api.spamblacklist.url('value')
1848
+ # ```
1849
+ #
1850
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1851
+ # {MediaWiktory::Wikipedia::Actions::Spamblacklist} class for a list of parameters and usage.
1852
+ #
1853
+ # @return [MediaWiktory::Wikipedia::Actions::Spamblacklist]
1854
+ #
1855
+ def spamblacklist
1856
+ Spamblacklist.new(client, @defaults)
1857
+ end
1858
+
1859
+ # Configure review-protection settings for a page.
1860
+ #
1861
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Stabilize} action.
1862
+ #
1863
+ # Action parameters could be passed or by subsequent
1864
+ # {MediaWiktory::Wikipedia::Actions::Stabilize} method calls, like
1865
+ #
1866
+ # ```ruby
1867
+ # api.stabilize.protectlevel('value')
1868
+ # ```
1869
+ #
1870
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1871
+ # {MediaWiktory::Wikipedia::Actions::Stabilize} class for a list of parameters and usage.
1872
+ #
1873
+ # @return [MediaWiktory::Wikipedia::Actions::Stabilize]
1874
+ #
1875
+ def stabilize
1876
+ Stabilize.new(client, @defaults)
1877
+ end
1878
+
1879
+ # Prepare an edit in shared cache.
1880
+ #
1881
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Stashedit} action.
1882
+ #
1883
+ # Action parameters could be passed or by subsequent
1884
+ # {MediaWiktory::Wikipedia::Actions::Stashedit} method calls, like
1885
+ #
1886
+ # ```ruby
1887
+ # api.stashedit.title('value')
1888
+ # ```
1889
+ #
1890
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1891
+ # {MediaWiktory::Wikipedia::Actions::Stashedit} class for a list of parameters and usage.
1892
+ #
1893
+ # @return [MediaWiktory::Wikipedia::Actions::Stashedit]
1894
+ #
1895
+ def stashedit
1896
+ Stashedit.new(client, @defaults)
1897
+ end
1898
+
1899
+ # Allows admins to strike or unstrike a vote.
1900
+ #
1901
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Strikevote} action.
1902
+ #
1903
+ # Action parameters could be passed or by subsequent
1904
+ # {MediaWiktory::Wikipedia::Actions::Strikevote} method calls, like
1905
+ #
1906
+ # ```ruby
1907
+ # api.strikevote.option('value')
1908
+ # ```
1909
+ #
1910
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1911
+ # {MediaWiktory::Wikipedia::Actions::Strikevote} class for a list of parameters and usage.
1912
+ #
1913
+ # @return [MediaWiktory::Wikipedia::Actions::Strikevote]
1914
+ #
1915
+ def strikevote
1916
+ Strikevote.new(client, @defaults)
1917
+ end
1918
+
1919
+ # Add or remove change tags from individual revisions or log entries.
1920
+ #
1921
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Tag} action.
1922
+ #
1923
+ # Action parameters could be passed or by subsequent
1924
+ # {MediaWiktory::Wikipedia::Actions::Tag} method calls, like
1925
+ #
1926
+ # ```ruby
1927
+ # api.tag.rcid('value')
1928
+ # ```
1929
+ #
1930
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1931
+ # {MediaWiktory::Wikipedia::Actions::Tag} class for a list of parameters and usage.
1932
+ #
1933
+ # @return [MediaWiktory::Wikipedia::Actions::Tag]
1934
+ #
1935
+ def tag
1936
+ Tag.new(client, @defaults)
1937
+ end
1938
+
1939
+ # Fetch data stored by the TemplateData extension.
1940
+ #
1941
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Templatedata} action.
1942
+ #
1943
+ # Action parameters could be passed or by subsequent
1944
+ # {MediaWiktory::Wikipedia::Actions::Templatedata} method calls, like
1945
+ #
1946
+ # ```ruby
1947
+ # api.templatedata.titles('value')
1948
+ # ```
1949
+ #
1950
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1951
+ # {MediaWiktory::Wikipedia::Actions::Templatedata} class for a list of parameters and usage.
1952
+ #
1953
+ # @return [MediaWiktory::Wikipedia::Actions::Templatedata]
1954
+ #
1955
+ def templatedata
1956
+ Templatedata.new(client, @defaults)
1957
+ end
1958
+
1959
+ # Send a thank-you notification to an editor.
1960
+ #
1961
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Thank} action.
1962
+ #
1963
+ # Action parameters could be passed or by subsequent
1964
+ # {MediaWiktory::Wikipedia::Actions::Thank} method calls, like
1965
+ #
1966
+ # ```ruby
1967
+ # api.thank.rev('value')
1968
+ # ```
1969
+ #
1970
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1971
+ # {MediaWiktory::Wikipedia::Actions::Thank} class for a list of parameters and usage.
1972
+ #
1973
+ # @return [MediaWiktory::Wikipedia::Actions::Thank]
1974
+ #
1975
+ def thank
1976
+ Thank.new(client, @defaults)
1977
+ end
1978
+
1979
+ # Validate an article title, filename, or username against the TitleBlacklist.
1980
+ #
1981
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Titleblacklist} action.
1982
+ #
1983
+ # Action parameters could be passed or by subsequent
1984
+ # {MediaWiktory::Wikipedia::Actions::Titleblacklist} method calls, like
1985
+ #
1986
+ # ```ruby
1987
+ # api.titleblacklist.title('value')
1988
+ # ```
1989
+ #
1990
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
1991
+ # {MediaWiktory::Wikipedia::Actions::Titleblacklist} class for a list of parameters and usage.
1992
+ #
1993
+ # @return [MediaWiktory::Wikipedia::Actions::Titleblacklist]
1994
+ #
1995
+ def titleblacklist
1996
+ Titleblacklist.new(client, @defaults)
1997
+ end
1998
+
1999
+ # Get tokens for data-modifying actions.
2000
+ #
2001
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Tokens} action.
2002
+ #
2003
+ # Action parameters could be passed or by subsequent
2004
+ # {MediaWiktory::Wikipedia::Actions::Tokens} method calls, like
2005
+ #
2006
+ # ```ruby
2007
+ # api.tokens.type('value')
2008
+ # ```
2009
+ #
2010
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2011
+ # {MediaWiktory::Wikipedia::Actions::Tokens} class for a list of parameters and usage.
2012
+ #
2013
+ # @return [MediaWiktory::Wikipedia::Actions::Tokens]
2014
+ #
2015
+ def tokens
2016
+ Tokens.new(client, @defaults)
2017
+ end
2018
+
2019
+ # Users with the 'transcode-reset' right can reset and re-run a transcode job.
2020
+ #
2021
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Transcodereset} action.
2022
+ #
2023
+ # Action parameters could be passed or by subsequent
2024
+ # {MediaWiktory::Wikipedia::Actions::Transcodereset} method calls, like
2025
+ #
2026
+ # ```ruby
2027
+ # api.transcodereset.title('value')
2028
+ # ```
2029
+ #
2030
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2031
+ # {MediaWiktory::Wikipedia::Actions::Transcodereset} class for a list of parameters and usage.
2032
+ #
2033
+ # @return [MediaWiktory::Wikipedia::Actions::Transcodereset]
2034
+ #
2035
+ def transcodereset
2036
+ Transcodereset.new(client, @defaults)
2037
+ end
2038
+
2039
+ # Get the localization of ULS in the given language.
2040
+ #
2041
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Ulslocalization} action.
2042
+ #
2043
+ # Action parameters could be passed or by subsequent
2044
+ # {MediaWiktory::Wikipedia::Actions::Ulslocalization} method calls, like
2045
+ #
2046
+ # ```ruby
2047
+ # api.ulslocalization.language('value')
2048
+ # ```
2049
+ #
2050
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2051
+ # {MediaWiktory::Wikipedia::Actions::Ulslocalization} class for a list of parameters and usage.
2052
+ #
2053
+ # @return [MediaWiktory::Wikipedia::Actions::Ulslocalization]
2054
+ #
2055
+ def ulslocalization
2056
+ Ulslocalization.new(client, @defaults)
2057
+ end
2058
+
2059
+ # Unblock a user.
2060
+ #
2061
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Unblock} action.
2062
+ #
2063
+ # Action parameters could be passed or by subsequent
2064
+ # {MediaWiktory::Wikipedia::Actions::Unblock} method calls, like
2065
+ #
2066
+ # ```ruby
2067
+ # api.unblock.id('value')
2068
+ # ```
2069
+ #
2070
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2071
+ # {MediaWiktory::Wikipedia::Actions::Unblock} class for a list of parameters and usage.
2072
+ #
2073
+ # @return [MediaWiktory::Wikipedia::Actions::Unblock]
2074
+ #
2075
+ def unblock
2076
+ Unblock.new(client, @defaults)
2077
+ end
2078
+
2079
+ # Restore revisions of a deleted page.
2080
+ #
2081
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Undelete} action.
2082
+ #
2083
+ # Action parameters could be passed or by subsequent
2084
+ # {MediaWiktory::Wikipedia::Actions::Undelete} method calls, like
2085
+ #
2086
+ # ```ruby
2087
+ # api.undelete.title('value')
2088
+ # ```
2089
+ #
2090
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2091
+ # {MediaWiktory::Wikipedia::Actions::Undelete} class for a list of parameters and usage.
2092
+ #
2093
+ # @return [MediaWiktory::Wikipedia::Actions::Undelete]
2094
+ #
2095
+ def undelete
2096
+ Undelete.new(client, @defaults)
2097
+ end
2098
+
2099
+ # Remove a linked third-party account from the current user.
2100
+ #
2101
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Unlinkaccount} action.
2102
+ #
2103
+ # Action parameters could be passed or by subsequent
2104
+ # {MediaWiktory::Wikipedia::Actions::Unlinkaccount} method calls, like
2105
+ #
2106
+ # ```ruby
2107
+ # api.unlinkaccount.request('value')
2108
+ # ```
2109
+ #
2110
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2111
+ # {MediaWiktory::Wikipedia::Actions::Unlinkaccount} class for a list of parameters and usage.
2112
+ #
2113
+ # @return [MediaWiktory::Wikipedia::Actions::Unlinkaccount]
2114
+ #
2115
+ def unlinkaccount
2116
+ Unlinkaccount.new(client, @defaults)
2117
+ end
2118
+
2119
+ # Upload a file, or get the status of pending uploads.
2120
+ #
2121
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Upload} action.
2122
+ #
2123
+ # Action parameters could be passed or by subsequent
2124
+ # {MediaWiktory::Wikipedia::Actions::Upload} method calls, like
2125
+ #
2126
+ # ```ruby
2127
+ # api.upload.filename('value')
2128
+ # ```
2129
+ #
2130
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2131
+ # {MediaWiktory::Wikipedia::Actions::Upload} class for a list of parameters and usage.
2132
+ #
2133
+ # @return [MediaWiktory::Wikipedia::Actions::Upload]
2134
+ #
2135
+ def upload
2136
+ Upload.new(client, @defaults)
2137
+ end
2138
+
2139
+ # Change a user's group membership.
2140
+ #
2141
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Userrights} action.
2142
+ #
2143
+ # Action parameters could be passed or by subsequent
2144
+ # {MediaWiktory::Wikipedia::Actions::Userrights} method calls, like
2145
+ #
2146
+ # ```ruby
2147
+ # api.userrights.user('value')
2148
+ # ```
2149
+ #
2150
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2151
+ # {MediaWiktory::Wikipedia::Actions::Userrights} class for a list of parameters and usage.
2152
+ #
2153
+ # @return [MediaWiktory::Wikipedia::Actions::Userrights]
2154
+ #
2155
+ def userrights
2156
+ Userrights.new(client, @defaults)
2157
+ end
2158
+
2159
+ # Validate a password against the wiki's password policies.
2160
+ #
2161
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Validatepassword} action.
2162
+ #
2163
+ # Action parameters could be passed or by subsequent
2164
+ # {MediaWiktory::Wikipedia::Actions::Validatepassword} method calls, like
2165
+ #
2166
+ # ```ruby
2167
+ # api.validatepassword.password('value')
2168
+ # ```
2169
+ #
2170
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2171
+ # {MediaWiktory::Wikipedia::Actions::Validatepassword} class for a list of parameters and usage.
2172
+ #
2173
+ # @return [MediaWiktory::Wikipedia::Actions::Validatepassword]
2174
+ #
2175
+ def validatepassword
2176
+ Validatepassword.new(client, @defaults)
2177
+ end
2178
+
2179
+ # Returns HTML5 for a page from the Parsoid service.
2180
+ #
2181
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Visualeditor} action.
2182
+ #
2183
+ # Action parameters could be passed or by subsequent
2184
+ # {MediaWiktory::Wikipedia::Actions::Visualeditor} method calls, like
2185
+ #
2186
+ # ```ruby
2187
+ # api.visualeditor.page('value')
2188
+ # ```
2189
+ #
2190
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2191
+ # {MediaWiktory::Wikipedia::Actions::Visualeditor} class for a list of parameters and usage.
2192
+ #
2193
+ # @return [MediaWiktory::Wikipedia::Actions::Visualeditor]
2194
+ #
2195
+ def visualeditor
2196
+ Visualeditor.new(client, @defaults)
2197
+ end
2198
+
2199
+ # Save an HTML5 page to MediaWiki (converted to wikitext via the Parsoid service).
2200
+ #
2201
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Visualeditoredit} action.
2202
+ #
2203
+ # Action parameters could be passed or by subsequent
2204
+ # {MediaWiktory::Wikipedia::Actions::Visualeditoredit} method calls, like
2205
+ #
2206
+ # ```ruby
2207
+ # api.visualeditoredit.paction('value')
2208
+ # ```
2209
+ #
2210
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2211
+ # {MediaWiktory::Wikipedia::Actions::Visualeditoredit} class for a list of parameters and usage.
2212
+ #
2213
+ # @return [MediaWiktory::Wikipedia::Actions::Visualeditoredit]
2214
+ #
2215
+ def visualeditoredit
2216
+ Visualeditoredit.new(client, @defaults)
2217
+ end
2218
+
2219
+ # Add or remove pages from the current user's watchlist.
2220
+ #
2221
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Watch} action.
2222
+ #
2223
+ # Action parameters could be passed or by subsequent
2224
+ # {MediaWiktory::Wikipedia::Actions::Watch} method calls, like
2225
+ #
2226
+ # ```ruby
2227
+ # api.watch.title('value')
2228
+ # ```
2229
+ #
2230
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2231
+ # {MediaWiktory::Wikipedia::Actions::Watch} class for a list of parameters and usage.
2232
+ #
2233
+ # @return [MediaWiktory::Wikipedia::Actions::Watch]
2234
+ #
2235
+ def watch
2236
+ Watch.new(client, @defaults)
2237
+ end
2238
+
2239
+ # Returns a webapp manifest.
2240
+ #
2241
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::WebappManifest} action.
2242
+ #
2243
+
2244
+ #
2245
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2246
+ # {MediaWiktory::Wikipedia::Actions::WebappManifest} class for a list of parameters and usage.
2247
+ #
2248
+ # @return [MediaWiktory::Wikipedia::Actions::WebappManifest]
2249
+ #
2250
+ def webapp_manifest
2251
+ WebappManifest.new(client, @defaults)
2252
+ end
2253
+
2254
+ # Give WikiLove to another user.
2255
+ #
2256
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Wikilove} action.
2257
+ #
2258
+ # Action parameters could be passed or by subsequent
2259
+ # {MediaWiktory::Wikipedia::Actions::Wikilove} method calls, like
2260
+ #
2261
+ # ```ruby
2262
+ # api.wikilove.title('value')
2263
+ # ```
2264
+ #
2265
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2266
+ # {MediaWiktory::Wikipedia::Actions::Wikilove} class for a list of parameters and usage.
2267
+ #
2268
+ # @return [MediaWiktory::Wikipedia::Actions::Wikilove]
2269
+ #
2270
+ def wikilove
2271
+ Wikilove.new(client, @defaults)
2272
+ end
2273
+
2274
+ # Get configuration of the Zero extension.
2275
+ #
2276
+ # This method creates an instance of {MediaWiktory::Wikipedia::Actions::Zeroconfig} action.
2277
+ #
2278
+ # Action parameters could be passed or by subsequent
2279
+ # {MediaWiktory::Wikipedia::Actions::Zeroconfig} method calls, like
2280
+ #
2281
+ # ```ruby
2282
+ # api.zeroconfig.type('value')
2283
+ # ```
2284
+ #
2285
+ # See {MediaWiktory::Wikipedia::Actions::Base} for generic explanation of working with MediaWiki actions and
2286
+ # {MediaWiktory::Wikipedia::Actions::Zeroconfig} class for a list of parameters and usage.
2287
+ #
2288
+ # @return [MediaWiktory::Wikipedia::Actions::Zeroconfig]
2289
+ #
2290
+ def zeroconfig
2291
+ Zeroconfig.new(client, @defaults)
2292
+ end
2293
+ end
2294
+ end
2295
+
2296
+ Dir[File.expand_path('../{actions,modules}/*.rb', __FILE__)].each { |f| require f }