reality 0.1.0.alpha → 0.1.0.alpha2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (127) hide show
  1. checksums.yaml +4 -4
  2. data/lib/reality/describers/wikidata.rb +2 -1
  3. data/lib/reality/describers/wikidata/sparql.rb +0 -1
  4. data/lib/reality/version.rb +1 -1
  5. metadata +2 -124
  6. data/lib/reality/describers/wikidata/actions/abusefiltercheckmatch.rb +0 -55
  7. data/lib/reality/describers/wikidata/actions/abusefilterchecksyntax.rb +0 -31
  8. data/lib/reality/describers/wikidata/actions/abusefilterevalexpression.rb +0 -31
  9. data/lib/reality/describers/wikidata/actions/abusefilterunblockautopromote.rb +0 -39
  10. data/lib/reality/describers/wikidata/actions/aggregategroups.rb +0 -76
  11. data/lib/reality/describers/wikidata/actions/antispoof.rb +0 -31
  12. data/lib/reality/describers/wikidata/actions/block.rb +0 -132
  13. data/lib/reality/describers/wikidata/actions/bouncehandler.rb +0 -31
  14. data/lib/reality/describers/wikidata/actions/categorytree.rb +0 -39
  15. data/lib/reality/describers/wikidata/actions/centralauthtoken.rb +0 -25
  16. data/lib/reality/describers/wikidata/actions/centralnoticechoicedata.rb +0 -39
  17. data/lib/reality/describers/wikidata/actions/centralnoticequerycampaign.rb +0 -31
  18. data/lib/reality/describers/wikidata/actions/changeauthenticationdata.rb +0 -39
  19. data/lib/reality/describers/wikidata/actions/checktoken.rb +0 -52
  20. data/lib/reality/describers/wikidata/actions/cirrus-config-dump.rb +0 -25
  21. data/lib/reality/describers/wikidata/actions/cirrus-mapping-dump.rb +0 -25
  22. data/lib/reality/describers/wikidata/actions/cirrus-settings-dump.rb +0 -25
  23. data/lib/reality/describers/wikidata/actions/clearhasmsg.rb +0 -25
  24. data/lib/reality/describers/wikidata/actions/clientlogin.rb +0 -86
  25. data/lib/reality/describers/wikidata/actions/compare.rb +0 -71
  26. data/lib/reality/describers/wikidata/actions/createaccount.rb +0 -86
  27. data/lib/reality/describers/wikidata/actions/cspreport.rb +0 -38
  28. data/lib/reality/describers/wikidata/actions/delete.rb +0 -103
  29. data/lib/reality/describers/wikidata/actions/deleteglobalaccount.rb +0 -47
  30. data/lib/reality/describers/wikidata/actions/echomarkread.rb +0 -77
  31. data/lib/reality/describers/wikidata/actions/echomarkseen.rb +0 -57
  32. data/lib/reality/describers/wikidata/actions/edit.rb +0 -266
  33. data/lib/reality/describers/wikidata/actions/editmassmessagelist.rb +0 -65
  34. data/lib/reality/describers/wikidata/actions/emailuser.rb +0 -62
  35. data/lib/reality/describers/wikidata/actions/expandtemplates.rb +0 -129
  36. data/lib/reality/describers/wikidata/actions/fancycaptchareload.rb +0 -25
  37. data/lib/reality/describers/wikidata/actions/featuredfeed.rb +0 -57
  38. data/lib/reality/describers/wikidata/actions/feedcontributions.rb +0 -121
  39. data/lib/reality/describers/wikidata/actions/feedrecentchanges.rb +0 -159
  40. data/lib/reality/describers/wikidata/actions/feedwatchlist.rb +0 -108
  41. data/lib/reality/describers/wikidata/actions/filerevert.rb +0 -55
  42. data/lib/reality/describers/wikidata/actions/flow-parsoid-utils.rb +0 -73
  43. data/lib/reality/describers/wikidata/actions/flow.rb +0 -72
  44. data/lib/reality/describers/wikidata/actions/flowthank.rb +0 -39
  45. data/lib/reality/describers/wikidata/actions/globalblock.rb +0 -76
  46. data/lib/reality/describers/wikidata/actions/globaluserrights.rb +0 -94
  47. data/lib/reality/describers/wikidata/actions/graph.rb +0 -47
  48. data/lib/reality/describers/wikidata/actions/groupreview.rb +0 -55
  49. data/lib/reality/describers/wikidata/actions/help.rb +0 -64
  50. data/lib/reality/describers/wikidata/actions/imagerotate.rb +0 -25
  51. data/lib/reality/describers/wikidata/actions/import.rb +0 -116
  52. data/lib/reality/describers/wikidata/actions/jsonconfig.rb +0 -60
  53. data/lib/reality/describers/wikidata/actions/jsondata.rb +0 -31
  54. data/lib/reality/describers/wikidata/actions/languagesearch.rb +0 -39
  55. data/lib/reality/describers/wikidata/actions/linkaccount.rb +0 -79
  56. data/lib/reality/describers/wikidata/actions/login.rb +0 -55
  57. data/lib/reality/describers/wikidata/actions/logout.rb +0 -25
  58. data/lib/reality/describers/wikidata/actions/managetags.rb +0 -80
  59. data/lib/reality/describers/wikidata/actions/massmessage.rb +0 -55
  60. data/lib/reality/describers/wikidata/actions/mergehistory.rb +0 -79
  61. data/lib/reality/describers/wikidata/actions/mobileview.rb +0 -170
  62. data/lib/reality/describers/wikidata/actions/move.rb +0 -131
  63. data/lib/reality/describers/wikidata/actions/oathvalidate.rb +0 -47
  64. data/lib/reality/describers/wikidata/actions/opensearch.rb +0 -92
  65. data/lib/reality/describers/wikidata/actions/options.rb +0 -80
  66. data/lib/reality/describers/wikidata/actions/paraminfo.rb +0 -91
  67. data/lib/reality/describers/wikidata/actions/parsoid-batch.rb +0 -31
  68. data/lib/reality/describers/wikidata/actions/patrol.rb +0 -60
  69. data/lib/reality/describers/wikidata/actions/protect.rb +0 -121
  70. data/lib/reality/describers/wikidata/actions/purge.rb +0 -152
  71. data/lib/reality/describers/wikidata/actions/removeauthenticationdata.rb +0 -39
  72. data/lib/reality/describers/wikidata/actions/resetpassword.rb +0 -47
  73. data/lib/reality/describers/wikidata/actions/revisiondelete.rb +0 -125
  74. data/lib/reality/describers/wikidata/actions/rollback.rb +0 -96
  75. data/lib/reality/describers/wikidata/actions/rsd.rb +0 -25
  76. data/lib/reality/describers/wikidata/actions/sanitize-mapdata.rb +0 -39
  77. data/lib/reality/describers/wikidata/actions/scribunto-console.rb +0 -62
  78. data/lib/reality/describers/wikidata/actions/searchtranslations.rb +0 -113
  79. data/lib/reality/describers/wikidata/actions/setglobalaccountstatus.rb +0 -81
  80. data/lib/reality/describers/wikidata/actions/setnotificationtimestamp.rb +0 -177
  81. data/lib/reality/describers/wikidata/actions/setpagelanguage.rb +0 -81
  82. data/lib/reality/describers/wikidata/actions/shortenurl.rb +0 -31
  83. data/lib/reality/describers/wikidata/actions/sitematrix.rb +0 -91
  84. data/lib/reality/describers/wikidata/actions/spamblacklist.rb +0 -36
  85. data/lib/reality/describers/wikidata/actions/stashedit.rb +0 -113
  86. data/lib/reality/describers/wikidata/actions/strikevote.rb +0 -60
  87. data/lib/reality/describers/wikidata/actions/tag.rb +0 -117
  88. data/lib/reality/describers/wikidata/actions/templatedata.rb +0 -145
  89. data/lib/reality/describers/wikidata/actions/thank.rb +0 -47
  90. data/lib/reality/describers/wikidata/actions/titleblacklist.rb +0 -51
  91. data/lib/reality/describers/wikidata/actions/tokens.rb +0 -36
  92. data/lib/reality/describers/wikidata/actions/transcodereset.rb +0 -47
  93. data/lib/reality/describers/wikidata/actions/translatesandbox.rb +0 -81
  94. data/lib/reality/describers/wikidata/actions/translationaids.rb +0 -52
  95. data/lib/reality/describers/wikidata/actions/translationreview.rb +0 -39
  96. data/lib/reality/describers/wikidata/actions/translationstash.rb +0 -76
  97. data/lib/reality/describers/wikidata/actions/ttmserver.rb +0 -60
  98. data/lib/reality/describers/wikidata/actions/ulslocalization.rb +0 -31
  99. data/lib/reality/describers/wikidata/actions/unblock.rb +0 -76
  100. data/lib/reality/describers/wikidata/actions/undelete.rb +0 -99
  101. data/lib/reality/describers/wikidata/actions/unlinkaccount.rb +0 -39
  102. data/lib/reality/describers/wikidata/actions/upload.rb +0 -172
  103. data/lib/reality/describers/wikidata/actions/userrights.rb +0 -107
  104. data/lib/reality/describers/wikidata/actions/validatepassword.rb +0 -55
  105. data/lib/reality/describers/wikidata/actions/visualeditor.rb +0 -96
  106. data/lib/reality/describers/wikidata/actions/visualeditoredit.rb +0 -164
  107. data/lib/reality/describers/wikidata/actions/watch.rb +0 -161
  108. data/lib/reality/describers/wikidata/actions/wbavailablebadges.rb +0 -25
  109. data/lib/reality/describers/wikidata/actions/wbcheckconstraints.rb +0 -62
  110. data/lib/reality/describers/wikidata/actions/wbcreateclaim.rb +0 -91
  111. data/lib/reality/describers/wikidata/actions/wbcreateredirect.rb +0 -54
  112. data/lib/reality/describers/wikidata/actions/wbeditentity.rb +0 -111
  113. data/lib/reality/describers/wikidata/actions/wblinktitles.rb +0 -80
  114. data/lib/reality/describers/wikidata/actions/wbmergeitems.rb +0 -75
  115. data/lib/reality/describers/wikidata/actions/wbremoveclaims.rb +0 -67
  116. data/lib/reality/describers/wikidata/actions/wbremovequalifiers.rb +0 -75
  117. data/lib/reality/describers/wikidata/actions/wbremovereferences.rb +0 -75
  118. data/lib/reality/describers/wikidata/actions/wbsetaliases.rb +0 -148
  119. data/lib/reality/describers/wikidata/actions/wbsetclaim.rb +0 -70
  120. data/lib/reality/describers/wikidata/actions/wbsetclaimvalue.rb +0 -83
  121. data/lib/reality/describers/wikidata/actions/wbsetdescription.rb +0 -117
  122. data/lib/reality/describers/wikidata/actions/wbsetlabel.rb +0 -117
  123. data/lib/reality/describers/wikidata/actions/wbsetqualifier.rb +0 -99
  124. data/lib/reality/describers/wikidata/actions/wbsetreference.rb +0 -94
  125. data/lib/reality/describers/wikidata/actions/wbsetsitelink.rb +0 -130
  126. data/lib/reality/describers/wikidata/actions/wbsgetsuggestions.rb +0 -94
  127. data/lib/reality/describers/wikidata/actions/webapp-manifest.rb +0 -25
@@ -1,77 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Reality::Describers::Wikidata::Impl
4
- module Actions
5
- # Mark notifications as read for the current user.
6
- #
7
- # Usage:
8
- #
9
- # ```ruby
10
- # api.echomarkread.list(value).perform # returns string with raw output
11
- # # or
12
- # api.echomarkread.list(value).response # returns output parsed and wrapped into Response object
13
- # ```
14
- #
15
- # See {Base} for generic explanation of working with MediaWiki actions and
16
- # {Reality::Describers::Wikidata::Impl::Response} for working with action responses.
17
- #
18
- # All action's parameters are documented as its public methods, see below.
19
- #
20
- class Echomarkread < Reality::Describers::Wikidata::Impl::Actions::Post
21
-
22
- # A list of notification IDs to mark as read.
23
- #
24
- # @param values [Array<String>]
25
- # @return [self]
26
- def list(*values)
27
- values.inject(self) { |res, val| res._list(val) }
28
- end
29
-
30
- # @private
31
- def _list(value)
32
- merge(list: value.to_s, replace: false)
33
- end
34
-
35
- # A list of notification IDs to mark as unread.
36
- #
37
- # @param values [Array<String>]
38
- # @return [self]
39
- def unreadlist(*values)
40
- values.inject(self) { |res, val| res._unreadlist(val) }
41
- end
42
-
43
- # @private
44
- def _unreadlist(value)
45
- merge(unreadlist: value.to_s, replace: false)
46
- end
47
-
48
- # If set, marks all of a user's notifications as read.
49
- #
50
- # @return [self]
51
- def all()
52
- merge(all: 'true')
53
- end
54
-
55
- # A list of sections to mark as read.
56
- #
57
- # @param values [Array<String>] Allowed values: "alert", "message".
58
- # @return [self]
59
- def sections(*values)
60
- values.inject(self) { |res, val| res._sections(val) or fail ArgumentError, "Unknown value for sections: #{val}" }
61
- end
62
-
63
- # @private
64
- def _sections(value)
65
- defined?(super) && super || ["alert", "message"].include?(value.to_s) && merge(sections: value.to_s, replace: false)
66
- end
67
-
68
- # A "csrf" token retrieved from action=query&meta=tokens
69
- #
70
- # @param value [String]
71
- # @return [self]
72
- def token(value)
73
- merge(token: value.to_s)
74
- end
75
- end
76
- end
77
- end
@@ -1,57 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Reality::Describers::Wikidata::Impl
4
- module Actions
5
- # Mark notifications as seen for the current user.
6
- #
7
- # Usage:
8
- #
9
- # ```ruby
10
- # api.echomarkseen.token(value).perform # returns string with raw output
11
- # # or
12
- # api.echomarkseen.token(value).response # returns output parsed and wrapped into Response object
13
- # ```
14
- #
15
- # See {Base} for generic explanation of working with MediaWiki actions and
16
- # {Reality::Describers::Wikidata::Impl::Response} for working with action responses.
17
- #
18
- # All action's parameters are documented as its public methods, see below.
19
- #
20
- class Echomarkseen < Reality::Describers::Wikidata::Impl::Actions::Post
21
-
22
- # A "csrf" token retrieved from action=query&meta=tokens
23
- #
24
- # @param value [String]
25
- # @return [self]
26
- def token(value)
27
- merge(token: value.to_s)
28
- end
29
-
30
- # Type of notifications to mark as seen: 'alert', 'message' or 'all'.
31
- #
32
- # @param value [String] One of "alert", "message", "all".
33
- # @return [self]
34
- def type(value)
35
- _type(value) or fail ArgumentError, "Unknown value for type: #{value}"
36
- end
37
-
38
- # @private
39
- def _type(value)
40
- defined?(super) && super || ["alert", "message", "all"].include?(value.to_s) && merge(type: value.to_s)
41
- end
42
-
43
- # Timestamp format to use for output, 'ISO_8601' or 'MW'. 'MW' is deprecated here, so all clients should switch to 'ISO_8601'. This parameter will be removed, and 'ISO_8601' will become the only output format.
44
- #
45
- # @param value [String] One of "ISO_8601", "MW".
46
- # @return [self]
47
- def timestampFormat(value)
48
- _timestampFormat(value) or fail ArgumentError, "Unknown value for timestampFormat: #{value}"
49
- end
50
-
51
- # @private
52
- def _timestampFormat(value)
53
- defined?(super) && super || ["ISO_8601", "MW"].include?(value.to_s) && merge(timestampFormat: value.to_s)
54
- end
55
- end
56
- end
57
- end
@@ -1,266 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Reality::Describers::Wikidata::Impl
4
- module Actions
5
- # Create and edit pages.
6
- #
7
- # Usage:
8
- #
9
- # ```ruby
10
- # api.edit.title(value).perform # returns string with raw output
11
- # # or
12
- # api.edit.title(value).response # returns output parsed and wrapped into Response object
13
- # ```
14
- #
15
- # See {Base} for generic explanation of working with MediaWiki actions and
16
- # {Reality::Describers::Wikidata::Impl::Response} for working with action responses.
17
- #
18
- # All action's parameters are documented as its public methods, see below.
19
- #
20
- class Edit < Reality::Describers::Wikidata::Impl::Actions::Post
21
-
22
- # Title of the page to edit. Cannot be used together with pageid.
23
- #
24
- # @param value [String]
25
- # @return [self]
26
- def title(value)
27
- merge(title: value.to_s)
28
- end
29
-
30
- # Page ID of the page to edit. Cannot be used together with title.
31
- #
32
- # @param value [Integer]
33
- # @return [self]
34
- def pageid(value)
35
- merge(pageid: value.to_s)
36
- end
37
-
38
- # Section number. 0 for the top section, new for a new section.
39
- #
40
- # @param value [String]
41
- # @return [self]
42
- def section(value)
43
- merge(section: value.to_s)
44
- end
45
-
46
- # The title for a new section.
47
- #
48
- # @param value [String]
49
- # @return [self]
50
- def sectiontitle(value)
51
- merge(sectiontitle: value.to_s)
52
- end
53
-
54
- # Page content.
55
- #
56
- # @param value [String]
57
- # @return [self]
58
- def text(value)
59
- merge(text: value.to_s)
60
- end
61
-
62
- # Edit summary. Also section title when section=new and sectiontitle is not set.
63
- #
64
- # @param value [String]
65
- # @return [self]
66
- def summary(value)
67
- merge(summary: value.to_s)
68
- end
69
-
70
- # Change tags to apply to the revision.
71
- #
72
- # @param values [Array<String>] Allowed values: "InfoboxExport gadget", "WE-Framework gadget".
73
- # @return [self]
74
- def tags(*values)
75
- values.inject(self) { |res, val| res._tags(val) or fail ArgumentError, "Unknown value for tags: #{val}" }
76
- end
77
-
78
- # @private
79
- def _tags(value)
80
- defined?(super) && super || ["InfoboxExport gadget", "WE-Framework gadget"].include?(value.to_s) && merge(tags: value.to_s, replace: false)
81
- end
82
-
83
- # Minor edit.
84
- #
85
- # @return [self]
86
- def minor()
87
- merge(minor: 'true')
88
- end
89
-
90
- # Non-minor edit.
91
- #
92
- # @return [self]
93
- def notminor()
94
- merge(notminor: 'true')
95
- end
96
-
97
- # Mark this edit as a bot edit.
98
- #
99
- # @return [self]
100
- def bot()
101
- merge(bot: 'true')
102
- end
103
-
104
- # Timestamp of the base revision, used to detect edit conflicts. May be obtained through action=query&prop=revisions&rvprop=timestamp.
105
- #
106
- # @param value [Time]
107
- # @return [self]
108
- def basetimestamp(value)
109
- merge(basetimestamp: value.iso8601)
110
- end
111
-
112
- # Timestamp when the editing process began, used to detect edit conflicts. An appropriate value may be obtained using curtimestamp when beginning the edit process (e.g. when loading the page content to edit).
113
- #
114
- # @param value [Time]
115
- # @return [self]
116
- def starttimestamp(value)
117
- merge(starttimestamp: value.iso8601)
118
- end
119
-
120
- # Override any errors about the page having been deleted in the meantime.
121
- #
122
- # @return [self]
123
- def recreate()
124
- merge(recreate: 'true')
125
- end
126
-
127
- # Don't edit the page if it exists already.
128
- #
129
- # @return [self]
130
- def createonly()
131
- merge(createonly: 'true')
132
- end
133
-
134
- # Throw an error if the page doesn't exist.
135
- #
136
- # @return [self]
137
- def nocreate()
138
- merge(nocreate: 'true')
139
- end
140
-
141
- # Add the page to the current user's watchlist.
142
- #
143
- # @return [self]
144
- def watch()
145
- merge(watch: 'true')
146
- end
147
-
148
- # Remove the page from the current user's watchlist.
149
- #
150
- # @return [self]
151
- def unwatch()
152
- merge(unwatch: 'true')
153
- end
154
-
155
- # Unconditionally add or remove the page from the current user's watchlist, use preferences or do not change watch.
156
- #
157
- # @param value [String] One of "watch", "unwatch", "preferences", "nochange".
158
- # @return [self]
159
- def watchlist(value)
160
- _watchlist(value) or fail ArgumentError, "Unknown value for watchlist: #{value}"
161
- end
162
-
163
- # @private
164
- def _watchlist(value)
165
- defined?(super) && super || ["watch", "unwatch", "preferences", "nochange"].include?(value.to_s) && merge(watchlist: value.to_s)
166
- end
167
-
168
- # The MD5 hash of the text parameter, or the prependtext and appendtext parameters concatenated. If set, the edit won't be done unless the hash is correct.
169
- #
170
- # @param value [String]
171
- # @return [self]
172
- def md5(value)
173
- merge(md5: value.to_s)
174
- end
175
-
176
- # Add this text to the beginning of the page. Overrides text.
177
- #
178
- # @param value [String]
179
- # @return [self]
180
- def prependtext(value)
181
- merge(prependtext: value.to_s)
182
- end
183
-
184
- # Add this text to the end of the page. Overrides text.
185
- #
186
- # @param value [String]
187
- # @return [self]
188
- def appendtext(value)
189
- merge(appendtext: value.to_s)
190
- end
191
-
192
- # Undo this revision. Overrides text, prependtext and appendtext.
193
- #
194
- # @param value [Integer]
195
- # @return [self]
196
- def undo(value)
197
- merge(undo: value.to_s)
198
- end
199
-
200
- # Undo all revisions from undo to this one. If not set, just undo one revision.
201
- #
202
- # @param value [Integer]
203
- # @return [self]
204
- def undoafter(value)
205
- merge(undoafter: value.to_s)
206
- end
207
-
208
- # Automatically resolve redirects.
209
- #
210
- # @return [self]
211
- def redirect()
212
- merge(redirect: 'true')
213
- end
214
-
215
- # Content serialization format used for the input text.
216
- #
217
- # @param value [String] One of "application/json", "text/x-wiki", "text/javascript", "text/css", "text/plain", "application/vnd.php.serialized".
218
- # @return [self]
219
- def contentformat(value)
220
- _contentformat(value) or fail ArgumentError, "Unknown value for contentformat: #{value}"
221
- end
222
-
223
- # @private
224
- def _contentformat(value)
225
- defined?(super) && super || ["application/json", "text/x-wiki", "text/javascript", "text/css", "text/plain", "application/vnd.php.serialized"].include?(value.to_s) && merge(contentformat: value.to_s)
226
- end
227
-
228
- # Content model of the new content.
229
- #
230
- # @param value [String] One of "GadgetDefinition", "SecurePoll", "MassMessageListContent", "flow-board", "JsonSchema", "wikitext", "javascript", "json", "css", "text", "Scribunto", "wikibase-item", "wikibase-property".
231
- # @return [self]
232
- def contentmodel(value)
233
- _contentmodel(value) or fail ArgumentError, "Unknown value for contentmodel: #{value}"
234
- end
235
-
236
- # @private
237
- def _contentmodel(value)
238
- defined?(super) && super || ["GadgetDefinition", "SecurePoll", "MassMessageListContent", "flow-board", "JsonSchema", "wikitext", "javascript", "json", "css", "text", "Scribunto", "wikibase-item", "wikibase-property"].include?(value.to_s) && merge(contentmodel: value.to_s)
239
- end
240
-
241
- # A "csrf" token retrieved from action=query&meta=tokens
242
- #
243
- # @param value [String]
244
- # @return [self]
245
- def token(value)
246
- merge(token: value.to_s)
247
- end
248
-
249
- # Answer to the CAPTCHA
250
- #
251
- # @param value [String]
252
- # @return [self]
253
- def captchaword(value)
254
- merge(captchaword: value.to_s)
255
- end
256
-
257
- # CAPTCHA ID from previous request
258
- #
259
- # @param value [String]
260
- # @return [self]
261
- def captchaid(value)
262
- merge(captchaid: value.to_s)
263
- end
264
- end
265
- end
266
- end
@@ -1,65 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Reality::Describers::Wikidata::Impl
4
- module Actions
5
- # Edit a mass message delivery list.
6
- #
7
- # Usage:
8
- #
9
- # ```ruby
10
- # api.editmassmessagelist.spamlist(value).perform # returns string with raw output
11
- # # or
12
- # api.editmassmessagelist.spamlist(value).response # returns output parsed and wrapped into Response object
13
- # ```
14
- #
15
- # See {Base} for generic explanation of working with MediaWiki actions and
16
- # {Reality::Describers::Wikidata::Impl::Response} for working with action responses.
17
- #
18
- # All action's parameters are documented as its public methods, see below.
19
- #
20
- class Editmassmessagelist < Reality::Describers::Wikidata::Impl::Actions::Post
21
-
22
- # Title of the delivery list to update.
23
- #
24
- # @param value [String]
25
- # @return [self]
26
- def spamlist(value)
27
- merge(spamlist: value.to_s)
28
- end
29
-
30
- # Titles to add to the list.
31
- #
32
- # @param values [Array<String>]
33
- # @return [self]
34
- def add(*values)
35
- values.inject(self) { |res, val| res._add(val) }
36
- end
37
-
38
- # @private
39
- def _add(value)
40
- merge(add: value.to_s, replace: false)
41
- end
42
-
43
- # Titles to remove from the list.
44
- #
45
- # @param values [Array<String>]
46
- # @return [self]
47
- def remove(*values)
48
- values.inject(self) { |res, val| res._remove(val) }
49
- end
50
-
51
- # @private
52
- def _remove(value)
53
- merge(remove: value.to_s, replace: false)
54
- end
55
-
56
- # A "csrf" token retrieved from action=query&meta=tokens
57
- #
58
- # @param value [String]
59
- # @return [self]
60
- def token(value)
61
- merge(token: value.to_s)
62
- end
63
- end
64
- end
65
- end