google-api-client 0.9.8 → 0.9.20

Sign up to get free protection for your applications and to get access to all the features.
Files changed (238) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +37 -0
  3. data/Gemfile +9 -1
  4. data/README.md +10 -2
  5. data/api_names.yaml +63 -110
  6. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +35 -0
  7. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +298 -0
  8. data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +122 -0
  9. data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +458 -0
  10. data/generated/google/apis/adexchangebuyer_v1_4.rb +1 -1
  11. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +260 -13
  12. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +81 -0
  13. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +60 -8
  14. data/generated/google/apis/adexchangeseller_v2_0.rb +2 -3
  15. data/generated/google/apis/adexchangeseller_v2_0/service.rb +1 -2
  16. data/generated/google/apis/admin_directory_v1.rb +1 -1
  17. data/generated/google/apis/admin_directory_v1/classes.rb +86 -0
  18. data/generated/google/apis/admin_directory_v1/representations.rb +24 -0
  19. data/generated/google/apis/admin_directory_v1/service.rb +41 -2
  20. data/generated/google/apis/admin_reports_v1.rb +3 -3
  21. data/generated/google/apis/admin_reports_v1/service.rb +2 -2
  22. data/generated/google/apis/adsense_v1_4.rb +1 -1
  23. data/generated/google/apis/adsense_v1_4/classes.rb +1 -1
  24. data/generated/google/apis/adsensehost_v4_1.rb +1 -1
  25. data/generated/google/apis/adsensehost_v4_1/classes.rb +1 -2
  26. data/generated/google/apis/analytics_v3.rb +1 -1
  27. data/generated/google/apis/analytics_v3/classes.rb +379 -3
  28. data/generated/google/apis/analytics_v3/representations.rb +136 -0
  29. data/generated/google/apis/analytics_v3/service.rb +217 -0
  30. data/generated/google/apis/analyticsreporting_v4.rb +1 -1
  31. data/generated/google/apis/analyticsreporting_v4/classes.rb +50 -22
  32. data/generated/google/apis/androidenterprise_v1.rb +1 -1
  33. data/generated/google/apis/androidenterprise_v1/classes.rb +813 -49
  34. data/generated/google/apis/androidenterprise_v1/representations.rb +336 -0
  35. data/generated/google/apis/androidenterprise_v1/service.rb +1234 -145
  36. data/generated/google/apis/androidpublisher_v2.rb +1 -1
  37. data/generated/google/apis/androidpublisher_v2/classes.rb +47 -8
  38. data/generated/google/apis/androidpublisher_v2/representations.rb +27 -0
  39. data/generated/google/apis/androidpublisher_v2/service.rb +55 -0
  40. data/generated/google/apis/appengine_v1beta5.rb +7 -1
  41. data/generated/google/apis/appengine_v1beta5/classes.rb +516 -313
  42. data/generated/google/apis/appengine_v1beta5/representations.rb +115 -22
  43. data/generated/google/apis/appengine_v1beta5/service.rb +329 -33
  44. data/generated/google/apis/appsactivity_v1.rb +1 -1
  45. data/generated/google/apis/appsactivity_v1/classes.rb +7 -0
  46. data/generated/google/apis/appsactivity_v1/representations.rb +1 -0
  47. data/generated/google/apis/appstate_v1.rb +1 -1
  48. data/generated/google/apis/bigquery_v2.rb +1 -1
  49. data/generated/google/apis/bigquery_v2/classes.rb +277 -20
  50. data/generated/google/apis/bigquery_v2/representations.rb +86 -0
  51. data/generated/google/apis/bigquery_v2/service.rb +8 -2
  52. data/generated/google/apis/books_v1.rb +2 -2
  53. data/generated/google/apis/books_v1/classes.rb +79 -1
  54. data/generated/google/apis/books_v1/representations.rb +34 -0
  55. data/generated/google/apis/books_v1/service.rb +7 -3
  56. data/generated/google/apis/calendar_v3.rb +1 -1
  57. data/generated/google/apis/civicinfo_v2.rb +3 -2
  58. data/generated/google/apis/civicinfo_v2/classes.rb +377 -5
  59. data/generated/google/apis/civicinfo_v2/representations.rb +149 -0
  60. data/generated/google/apis/civicinfo_v2/service.rb +27 -6
  61. data/generated/google/apis/classroom_v1.rb +1 -1
  62. data/generated/google/apis/classroom_v1/classes.rb +183 -37
  63. data/generated/google/apis/classroom_v1/representations.rb +74 -9
  64. data/generated/google/apis/classroom_v1/service.rb +403 -38
  65. data/generated/google/apis/cloudbuild_v1.rb +1 -1
  66. data/generated/google/apis/cloudbuild_v1/classes.rb +381 -17
  67. data/generated/google/apis/cloudbuild_v1/representations.rb +137 -2
  68. data/generated/google/apis/cloudbuild_v1/service.rb +174 -1
  69. data/generated/google/apis/clouddebugger_v2.rb +3 -6
  70. data/generated/google/apis/clouddebugger_v2/service.rb +4 -4
  71. data/generated/google/apis/cloudmonitoring_v2beta2.rb +1 -1
  72. data/generated/google/apis/cloudresourcemanager_v1.rb +1 -1
  73. data/generated/google/apis/cloudresourcemanager_v1/classes.rb +502 -111
  74. data/generated/google/apis/cloudresourcemanager_v1/representations.rb +162 -24
  75. data/generated/google/apis/cloudresourcemanager_v1/service.rb +274 -30
  76. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +1 -1
  77. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +121 -9
  78. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +46 -0
  79. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +71 -58
  80. data/generated/google/apis/compute_beta.rb +1 -1
  81. data/generated/google/apis/compute_beta/classes.rb +2299 -434
  82. data/generated/google/apis/compute_beta/representations.rb +752 -33
  83. data/generated/google/apis/compute_beta/service.rb +6067 -3153
  84. data/generated/google/apis/compute_v1.rb +1 -1
  85. data/generated/google/apis/compute_v1/classes.rb +1681 -207
  86. data/generated/google/apis/compute_v1/representations.rb +552 -0
  87. data/generated/google/apis/compute_v1/service.rb +2797 -1171
  88. data/generated/google/apis/content_v2.rb +1 -1
  89. data/generated/google/apis/content_v2/classes.rb +757 -1
  90. data/generated/google/apis/content_v2/representations.rb +337 -0
  91. data/generated/google/apis/content_v2/service.rb +244 -0
  92. data/generated/google/apis/dataflow_v1b3.rb +38 -0
  93. data/generated/google/apis/dataflow_v1b3/classes.rb +4053 -0
  94. data/generated/google/apis/dataflow_v1b3/representations.rb +1736 -0
  95. data/generated/google/apis/dataflow_v1b3/service.rb +875 -0
  96. data/generated/google/apis/dataproc_v1.rb +2 -2
  97. data/generated/google/apis/dataproc_v1/classes.rb +213 -68
  98. data/generated/google/apis/dataproc_v1/representations.rb +38 -0
  99. data/generated/google/apis/dataproc_v1/service.rb +78 -48
  100. data/generated/google/apis/datastore_v1.rb +38 -0
  101. data/generated/google/apis/datastore_v1/classes.rb +1284 -0
  102. data/generated/google/apis/datastore_v1/representations.rb +572 -0
  103. data/generated/google/apis/datastore_v1/service.rb +259 -0
  104. data/generated/google/apis/datastore_v1beta3.rb +38 -0
  105. data/generated/google/apis/datastore_v1beta3/classes.rb +1284 -0
  106. data/generated/google/apis/datastore_v1beta3/representations.rb +572 -0
  107. data/generated/google/apis/datastore_v1beta3/service.rb +259 -0
  108. data/generated/google/apis/deploymentmanager_v2.rb +1 -1
  109. data/generated/google/apis/deploymentmanager_v2/classes.rb +384 -2
  110. data/generated/google/apis/deploymentmanager_v2/representations.rb +161 -0
  111. data/generated/google/apis/deploymentmanager_v2/service.rb +217 -55
  112. data/generated/google/apis/dfareporting_v2_5.rb +40 -0
  113. data/generated/google/apis/dfareporting_v2_5/classes.rb +11225 -0
  114. data/generated/google/apis/dfareporting_v2_5/representations.rb +3982 -0
  115. data/generated/google/apis/dfareporting_v2_5/service.rb +8755 -0
  116. data/generated/google/apis/dfareporting_v2_6.rb +40 -0
  117. data/generated/google/apis/dfareporting_v2_6/classes.rb +11586 -0
  118. data/generated/google/apis/dfareporting_v2_6/representations.rb +4119 -0
  119. data/generated/google/apis/dfareporting_v2_6/service.rb +9025 -0
  120. data/generated/google/apis/dns_v1.rb +1 -1
  121. data/generated/google/apis/dns_v1/classes.rb +1 -1
  122. data/generated/google/apis/doubleclickbidmanager_v1.rb +1 -1
  123. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +79 -86
  124. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +25 -28
  125. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +10 -8
  126. data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
  127. data/generated/google/apis/drive_v2.rb +1 -1
  128. data/generated/google/apis/drive_v2/classes.rb +27 -3
  129. data/generated/google/apis/drive_v2/representations.rb +4 -0
  130. data/generated/google/apis/drive_v2/service.rb +16 -3
  131. data/generated/google/apis/drive_v3.rb +1 -1
  132. data/generated/google/apis/drive_v3/classes.rb +50 -16
  133. data/generated/google/apis/drive_v3/representations.rb +4 -0
  134. data/generated/google/apis/drive_v3/service.rb +12 -2
  135. data/generated/google/apis/fitness_v1.rb +8 -2
  136. data/generated/google/apis/fitness_v1/classes.rb +64 -6
  137. data/generated/google/apis/fitness_v1/representations.rb +20 -0
  138. data/generated/google/apis/fitness_v1/service.rb +17 -18
  139. data/generated/google/apis/fusiontables_v2.rb +1 -1
  140. data/generated/google/apis/fusiontables_v2/classes.rb +4 -3
  141. data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
  142. data/generated/google/apis/games_management_v1management.rb +1 -1
  143. data/generated/google/apis/games_v1.rb +1 -1
  144. data/generated/google/apis/genomics_v1.rb +2 -4
  145. data/generated/google/apis/genomics_v1/classes.rb +143 -34
  146. data/generated/google/apis/genomics_v1/representations.rb +48 -11
  147. data/generated/google/apis/genomics_v1/service.rb +35 -37
  148. data/generated/google/apis/gmail_v1.rb +10 -1
  149. data/generated/google/apis/gmail_v1/classes.rb +542 -4
  150. data/generated/google/apis/gmail_v1/representations.rb +213 -0
  151. data/generated/google/apis/gmail_v1/service.rb +898 -1
  152. data/generated/google/apis/groupssettings_v1.rb +1 -1
  153. data/generated/google/apis/groupssettings_v1/classes.rb +12 -0
  154. data/generated/google/apis/groupssettings_v1/representations.rb +2 -0
  155. data/generated/google/apis/iam_v1.rb +2 -2
  156. data/generated/google/apis/iam_v1/classes.rb +181 -206
  157. data/generated/google/apis/iam_v1/representations.rb +36 -45
  158. data/generated/google/apis/iam_v1/service.rb +101 -67
  159. data/generated/google/apis/identitytoolkit_v3.rb +4 -1
  160. data/generated/google/apis/identitytoolkit_v3/classes.rb +171 -1
  161. data/generated/google/apis/identitytoolkit_v3/representations.rb +26 -0
  162. data/generated/google/apis/language_v1beta1.rb +36 -0
  163. data/generated/google/apis/language_v1beta1/classes.rb +599 -0
  164. data/generated/google/apis/language_v1beta1/representations.rb +289 -0
  165. data/generated/google/apis/language_v1beta1/service.rb +152 -0
  166. data/generated/google/apis/logging_v2beta1.rb +6 -6
  167. data/generated/google/apis/logging_v2beta1/classes.rb +760 -731
  168. data/generated/google/apis/logging_v2beta1/representations.rb +136 -147
  169. data/generated/google/apis/logging_v2beta1/service.rb +290 -209
  170. data/generated/google/apis/mirror_v1.rb +2 -2
  171. data/generated/google/apis/mirror_v1/service.rb +1 -1
  172. data/generated/google/apis/monitoring_v3.rb +45 -0
  173. data/generated/google/apis/monitoring_v3/classes.rb +1337 -0
  174. data/generated/google/apis/monitoring_v3/representations.rb +516 -0
  175. data/generated/google/apis/monitoring_v3/service.rb +711 -0
  176. data/generated/google/apis/oauth2_v2.rb +1 -1
  177. data/generated/google/apis/pagespeedonline_v2.rb +1 -1
  178. data/generated/google/apis/plus_domains_v1.rb +1 -1
  179. data/generated/google/apis/plus_v1.rb +1 -1
  180. data/generated/google/apis/pubsub_v1.rb +1 -1
  181. data/generated/google/apis/pubsub_v1/classes.rb +10 -9
  182. data/generated/google/apis/pubsub_v1/service.rb +128 -27
  183. data/generated/google/apis/qpx_express_v1.rb +1 -1
  184. data/generated/google/apis/qpx_express_v1/classes.rb +6 -0
  185. data/generated/google/apis/qpx_express_v1/representations.rb +1 -0
  186. data/generated/google/apis/replicapool_v1beta2.rb +1 -1
  187. data/generated/google/apis/replicapoolupdater_v1beta1.rb +4 -2
  188. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +3 -1
  189. data/generated/google/apis/script_v1.rb +1 -1
  190. data/generated/google/apis/script_v1/classes.rb +6 -0
  191. data/generated/google/apis/script_v1/representations.rb +1 -0
  192. data/generated/google/apis/sheets_v4.rb +1 -1
  193. data/generated/google/apis/sheets_v4/classes.rb +910 -89
  194. data/generated/google/apis/sheets_v4/representations.rb +194 -10
  195. data/generated/google/apis/sheets_v4/service.rb +216 -49
  196. data/generated/google/apis/slides_v1.rb +49 -0
  197. data/generated/google/apis/slides_v1/classes.rb +3926 -0
  198. data/generated/google/apis/slides_v1/representations.rb +1722 -0
  199. data/generated/google/apis/slides_v1/service.rb +202 -0
  200. data/generated/google/apis/speech_v1beta1.rb +34 -0
  201. data/generated/google/apis/speech_v1beta1/classes.rb +511 -0
  202. data/generated/google/apis/speech_v1beta1/representations.rb +218 -0
  203. data/generated/google/apis/speech_v1beta1/service.rb +271 -0
  204. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  205. data/generated/google/apis/sqladmin_v1beta4/classes.rb +32 -8
  206. data/generated/google/apis/sqladmin_v1beta4/representations.rb +3 -0
  207. data/generated/google/apis/sqladmin_v1beta4/service.rb +42 -0
  208. data/generated/google/apis/storage_v1.rb +1 -1
  209. data/generated/google/apis/storage_v1/classes.rb +43 -18
  210. data/generated/google/apis/storage_v1/representations.rb +4 -1
  211. data/generated/google/apis/storage_v1/service.rb +5 -2
  212. data/generated/google/apis/translate_v2.rb +2 -2
  213. data/generated/google/apis/translate_v2/service.rb +1 -1
  214. data/generated/google/apis/vision_v1.rb +1 -1
  215. data/generated/google/apis/vision_v1/classes.rb +12 -11
  216. data/generated/google/apis/youtube_analytics_v1.rb +1 -1
  217. data/generated/google/apis/youtube_partner_v1.rb +1 -1
  218. data/generated/google/apis/youtube_partner_v1/classes.rb +6 -0
  219. data/generated/google/apis/youtube_partner_v1/representations.rb +2 -0
  220. data/generated/google/apis/youtube_partner_v1/service.rb +15 -3
  221. data/generated/google/apis/youtube_v3.rb +1 -1
  222. data/generated/google/apis/youtube_v3/classes.rb +183 -21
  223. data/generated/google/apis/youtube_v3/representations.rb +85 -4
  224. data/generated/google/apis/youtube_v3/service.rb +41 -5
  225. data/generated/google/apis/youtubereporting_v1.rb +1 -1
  226. data/google-api-client.gemspec +2 -1
  227. data/lib/google/apis/core/api_command.rb +4 -0
  228. data/lib/google/apis/core/base_service.rb +10 -4
  229. data/lib/google/apis/core/download.rb +7 -2
  230. data/lib/google/apis/core/http_command.rb +5 -1
  231. data/lib/google/apis/core/upload.rb +7 -1
  232. data/lib/google/apis/errors.rb +2 -2
  233. data/lib/google/apis/generator/annotator.rb +6 -0
  234. data/lib/google/apis/version.rb +1 -1
  235. data/samples/cli/lib/samples/bigquery.rb +101 -0
  236. data/samples/cli/lib/samples/sheets.rb +61 -0
  237. data/sync.rb +71 -0
  238. metadata +55 -13
@@ -22,6 +22,12 @@ module Google
22
22
  module Apis
23
23
  module GmailV1
24
24
 
25
+ class AutoForwarding
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
25
31
  class BatchDeleteMessagesRequest
26
32
  class Representation < Google::Apis::Core::JsonRepresentation; end
27
33
 
@@ -34,6 +40,30 @@ module Google
34
40
  include Google::Apis::Core::JsonObjectSupport
35
41
  end
36
42
 
43
+ class Filter
44
+ class Representation < Google::Apis::Core::JsonRepresentation; end
45
+
46
+ include Google::Apis::Core::JsonObjectSupport
47
+ end
48
+
49
+ class FilterAction
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
55
+ class FilterCriteria
56
+ class Representation < Google::Apis::Core::JsonRepresentation; end
57
+
58
+ include Google::Apis::Core::JsonObjectSupport
59
+ end
60
+
61
+ class ForwardingAddress
62
+ class Representation < Google::Apis::Core::JsonRepresentation; end
63
+
64
+ include Google::Apis::Core::JsonObjectSupport
65
+ end
66
+
37
67
  class History
38
68
  class Representation < Google::Apis::Core::JsonRepresentation; end
39
69
 
@@ -64,6 +94,12 @@ module Google
64
94
  include Google::Apis::Core::JsonObjectSupport
65
95
  end
66
96
 
97
+ class ImapSettings
98
+ class Representation < Google::Apis::Core::JsonRepresentation; end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
67
103
  class Label
68
104
  class Representation < Google::Apis::Core::JsonRepresentation; end
69
105
 
@@ -76,6 +112,18 @@ module Google
76
112
  include Google::Apis::Core::JsonObjectSupport
77
113
  end
78
114
 
115
+ class ListFiltersResponse
116
+ class Representation < Google::Apis::Core::JsonRepresentation; end
117
+
118
+ include Google::Apis::Core::JsonObjectSupport
119
+ end
120
+
121
+ class ListForwardingAddressesResponse
122
+ class Representation < Google::Apis::Core::JsonRepresentation; end
123
+
124
+ include Google::Apis::Core::JsonObjectSupport
125
+ end
126
+
79
127
  class ListHistoryResponse
80
128
  class Representation < Google::Apis::Core::JsonRepresentation; end
81
129
 
@@ -94,6 +142,12 @@ module Google
94
142
  include Google::Apis::Core::JsonObjectSupport
95
143
  end
96
144
 
145
+ class ListSendAsResponse
146
+ class Representation < Google::Apis::Core::JsonRepresentation; end
147
+
148
+ include Google::Apis::Core::JsonObjectSupport
149
+ end
150
+
97
151
  class ListThreadsResponse
98
152
  class Representation < Google::Apis::Core::JsonRepresentation; end
99
153
 
@@ -136,18 +190,42 @@ module Google
136
190
  include Google::Apis::Core::JsonObjectSupport
137
191
  end
138
192
 
193
+ class PopSettings
194
+ class Representation < Google::Apis::Core::JsonRepresentation; end
195
+
196
+ include Google::Apis::Core::JsonObjectSupport
197
+ end
198
+
139
199
  class Profile
140
200
  class Representation < Google::Apis::Core::JsonRepresentation; end
141
201
 
142
202
  include Google::Apis::Core::JsonObjectSupport
143
203
  end
144
204
 
205
+ class SendAs
206
+ class Representation < Google::Apis::Core::JsonRepresentation; end
207
+
208
+ include Google::Apis::Core::JsonObjectSupport
209
+ end
210
+
211
+ class SmtpMsa
212
+ class Representation < Google::Apis::Core::JsonRepresentation; end
213
+
214
+ include Google::Apis::Core::JsonObjectSupport
215
+ end
216
+
145
217
  class Thread
146
218
  class Representation < Google::Apis::Core::JsonRepresentation; end
147
219
 
148
220
  include Google::Apis::Core::JsonObjectSupport
149
221
  end
150
222
 
223
+ class VacationSettings
224
+ class Representation < Google::Apis::Core::JsonRepresentation; end
225
+
226
+ include Google::Apis::Core::JsonObjectSupport
227
+ end
228
+
151
229
  class WatchRequest
152
230
  class Representation < Google::Apis::Core::JsonRepresentation; end
153
231
 
@@ -160,6 +238,15 @@ module Google
160
238
  include Google::Apis::Core::JsonObjectSupport
161
239
  end
162
240
 
241
+ class AutoForwarding
242
+ # @private
243
+ class Representation < Google::Apis::Core::JsonRepresentation
244
+ property :disposition, as: 'disposition'
245
+ property :email_address, as: 'emailAddress'
246
+ property :enabled, as: 'enabled'
247
+ end
248
+ end
249
+
163
250
  class BatchDeleteMessagesRequest
164
251
  # @private
165
252
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -176,6 +263,49 @@ module Google
176
263
  end
177
264
  end
178
265
 
266
+ class Filter
267
+ # @private
268
+ class Representation < Google::Apis::Core::JsonRepresentation
269
+ property :action, as: 'action', class: Google::Apis::GmailV1::FilterAction, decorator: Google::Apis::GmailV1::FilterAction::Representation
270
+
271
+ property :criteria, as: 'criteria', class: Google::Apis::GmailV1::FilterCriteria, decorator: Google::Apis::GmailV1::FilterCriteria::Representation
272
+
273
+ property :id, as: 'id'
274
+ end
275
+ end
276
+
277
+ class FilterAction
278
+ # @private
279
+ class Representation < Google::Apis::Core::JsonRepresentation
280
+ collection :add_label_ids, as: 'addLabelIds'
281
+ property :forward, as: 'forward'
282
+ collection :remove_label_ids, as: 'removeLabelIds'
283
+ end
284
+ end
285
+
286
+ class FilterCriteria
287
+ # @private
288
+ class Representation < Google::Apis::Core::JsonRepresentation
289
+ property :exclude_chats, as: 'excludeChats'
290
+ property :from, as: 'from'
291
+ property :has_attachment, as: 'hasAttachment'
292
+ property :negated_query, as: 'negatedQuery'
293
+ property :query, as: 'query'
294
+ property :size, as: 'size'
295
+ property :size_comparison, as: 'sizeComparison'
296
+ property :subject, as: 'subject'
297
+ property :to, as: 'to'
298
+ end
299
+ end
300
+
301
+ class ForwardingAddress
302
+ # @private
303
+ class Representation < Google::Apis::Core::JsonRepresentation
304
+ property :forwarding_email, as: 'forwardingEmail'
305
+ property :verification_status, as: 'verificationStatus'
306
+ end
307
+ end
308
+
179
309
  class History
180
310
  # @private
181
311
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -227,6 +357,16 @@ module Google
227
357
  end
228
358
  end
229
359
 
360
+ class ImapSettings
361
+ # @private
362
+ class Representation < Google::Apis::Core::JsonRepresentation
363
+ property :auto_expunge, as: 'autoExpunge'
364
+ property :enabled, as: 'enabled'
365
+ property :expunge_behavior, as: 'expungeBehavior'
366
+ property :max_folder_size, as: 'maxFolderSize'
367
+ end
368
+ end
369
+
230
370
  class Label
231
371
  # @private
232
372
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -252,6 +392,22 @@ module Google
252
392
  end
253
393
  end
254
394
 
395
+ class ListFiltersResponse
396
+ # @private
397
+ class Representation < Google::Apis::Core::JsonRepresentation
398
+ collection :filter, as: 'filter', class: Google::Apis::GmailV1::Filter, decorator: Google::Apis::GmailV1::Filter::Representation
399
+
400
+ end
401
+ end
402
+
403
+ class ListForwardingAddressesResponse
404
+ # @private
405
+ class Representation < Google::Apis::Core::JsonRepresentation
406
+ collection :forwarding_addresses, as: 'forwardingAddresses', class: Google::Apis::GmailV1::ForwardingAddress, decorator: Google::Apis::GmailV1::ForwardingAddress::Representation
407
+
408
+ end
409
+ end
410
+
255
411
  class ListHistoryResponse
256
412
  # @private
257
413
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -280,6 +436,14 @@ module Google
280
436
  end
281
437
  end
282
438
 
439
+ class ListSendAsResponse
440
+ # @private
441
+ class Representation < Google::Apis::Core::JsonRepresentation
442
+ collection :send_as, as: 'sendAs', class: Google::Apis::GmailV1::SendAs, decorator: Google::Apis::GmailV1::SendAs::Representation
443
+
444
+ end
445
+ end
446
+
283
447
  class ListThreadsResponse
284
448
  # @private
285
449
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -354,6 +518,14 @@ module Google
354
518
  end
355
519
  end
356
520
 
521
+ class PopSettings
522
+ # @private
523
+ class Representation < Google::Apis::Core::JsonRepresentation
524
+ property :access_window, as: 'accessWindow'
525
+ property :disposition, as: 'disposition'
526
+ end
527
+ end
528
+
357
529
  class Profile
358
530
  # @private
359
531
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -364,6 +536,33 @@ module Google
364
536
  end
365
537
  end
366
538
 
539
+ class SendAs
540
+ # @private
541
+ class Representation < Google::Apis::Core::JsonRepresentation
542
+ property :display_name, as: 'displayName'
543
+ property :is_default, as: 'isDefault'
544
+ property :is_primary, as: 'isPrimary'
545
+ property :reply_to_address, as: 'replyToAddress'
546
+ property :send_as_email, as: 'sendAsEmail'
547
+ property :signature, as: 'signature'
548
+ property :smtp_msa, as: 'smtpMsa', class: Google::Apis::GmailV1::SmtpMsa, decorator: Google::Apis::GmailV1::SmtpMsa::Representation
549
+
550
+ property :treat_as_alias, as: 'treatAsAlias'
551
+ property :verification_status, as: 'verificationStatus'
552
+ end
553
+ end
554
+
555
+ class SmtpMsa
556
+ # @private
557
+ class Representation < Google::Apis::Core::JsonRepresentation
558
+ property :host, as: 'host'
559
+ property :password, as: 'password'
560
+ property :port, as: 'port'
561
+ property :security_mode, as: 'securityMode'
562
+ property :username, as: 'username'
563
+ end
564
+ end
565
+
367
566
  class Thread
368
567
  # @private
369
568
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -375,6 +574,20 @@ module Google
375
574
  end
376
575
  end
377
576
 
577
+ class VacationSettings
578
+ # @private
579
+ class Representation < Google::Apis::Core::JsonRepresentation
580
+ property :enable_auto_reply, as: 'enableAutoReply'
581
+ property :end_time, as: 'endTime'
582
+ property :response_body_html, as: 'responseBodyHtml'
583
+ property :response_body_plain_text, as: 'responseBodyPlainText'
584
+ property :response_subject, as: 'responseSubject'
585
+ property :restrict_to_contacts, as: 'restrictToContacts'
586
+ property :restrict_to_domain, as: 'restrictToDomain'
587
+ property :start_time, as: 'startTime'
588
+ end
589
+ end
590
+
378
591
  class WatchRequest
379
592
  # @private
380
593
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -300,6 +300,10 @@ module Google
300
300
  # Maximum number of drafts to return.
301
301
  # @param [String] page_token
302
302
  # Page token to retrieve a specific page of results in the list.
303
+ # @param [String] q
304
+ # Only return draft messages matching the specified query. Supports the same
305
+ # query format as the Gmail search box. For example, "from:someuser@example.com
306
+ # rfc822msgid: is:unread".
303
307
  # @param [String] fields
304
308
  # Selector specifying which fields to include in a partial response.
305
309
  # @param [String] quota_user
@@ -321,7 +325,7 @@ module Google
321
325
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
322
326
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
323
327
  # @raise [Google::Apis::AuthorizationError] Authorization is required
324
- def list_user_drafts(user_id, include_spam_trash: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
328
+ def list_user_drafts(user_id, include_spam_trash: nil, max_results: nil, page_token: nil, q: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
325
329
  command = make_simple_command(:get, '{userId}/drafts', options)
326
330
  command.response_representation = Google::Apis::GmailV1::ListDraftsResponse::Representation
327
331
  command.response_class = Google::Apis::GmailV1::ListDraftsResponse
@@ -329,6 +333,7 @@ module Google
329
333
  command.query['includeSpamTrash'] = include_spam_trash unless include_spam_trash.nil?
330
334
  command.query['maxResults'] = max_results unless max_results.nil?
331
335
  command.query['pageToken'] = page_token unless page_token.nil?
336
+ command.query['q'] = q unless q.nil?
332
337
  command.query['fields'] = fields unless fields.nil?
333
338
  command.query['quotaUser'] = quota_user unless quota_user.nil?
334
339
  command.query['userIp'] = user_ip unless user_ip.nil?
@@ -1241,6 +1246,898 @@ module Google
1241
1246
  execute_or_queue_command(command, &block)
1242
1247
  end
1243
1248
 
1249
+ # Gets the auto-forwarding setting for the specified account.
1250
+ # @param [String] user_id
1251
+ # User's email address. The special value "me" can be used to indicate the
1252
+ # authenticated user.
1253
+ # @param [String] fields
1254
+ # Selector specifying which fields to include in a partial response.
1255
+ # @param [String] quota_user
1256
+ # Available to use for quota purposes for server-side applications. Can be any
1257
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1258
+ # Overrides userIp if both are provided.
1259
+ # @param [String] user_ip
1260
+ # IP address of the site where the request originates. Use this if you want to
1261
+ # enforce per-user limits.
1262
+ # @param [Google::Apis::RequestOptions] options
1263
+ # Request-specific options
1264
+ #
1265
+ # @yield [result, err] Result & error if block supplied
1266
+ # @yieldparam result [Google::Apis::GmailV1::AutoForwarding] parsed result object
1267
+ # @yieldparam err [StandardError] error object if request failed
1268
+ #
1269
+ # @return [Google::Apis::GmailV1::AutoForwarding]
1270
+ #
1271
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1272
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1273
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1274
+ def get_user_setting_auto_forwarding(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1275
+ command = make_simple_command(:get, '{userId}/settings/autoForwarding', options)
1276
+ command.response_representation = Google::Apis::GmailV1::AutoForwarding::Representation
1277
+ command.response_class = Google::Apis::GmailV1::AutoForwarding
1278
+ command.params['userId'] = user_id unless user_id.nil?
1279
+ command.query['fields'] = fields unless fields.nil?
1280
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1281
+ command.query['userIp'] = user_ip unless user_ip.nil?
1282
+ execute_or_queue_command(command, &block)
1283
+ end
1284
+
1285
+ # Gets IMAP settings.
1286
+ # @param [String] user_id
1287
+ # User's email address. The special value "me" can be used to indicate the
1288
+ # authenticated user.
1289
+ # @param [String] fields
1290
+ # Selector specifying which fields to include in a partial response.
1291
+ # @param [String] quota_user
1292
+ # Available to use for quota purposes for server-side applications. Can be any
1293
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1294
+ # Overrides userIp if both are provided.
1295
+ # @param [String] user_ip
1296
+ # IP address of the site where the request originates. Use this if you want to
1297
+ # enforce per-user limits.
1298
+ # @param [Google::Apis::RequestOptions] options
1299
+ # Request-specific options
1300
+ #
1301
+ # @yield [result, err] Result & error if block supplied
1302
+ # @yieldparam result [Google::Apis::GmailV1::ImapSettings] parsed result object
1303
+ # @yieldparam err [StandardError] error object if request failed
1304
+ #
1305
+ # @return [Google::Apis::GmailV1::ImapSettings]
1306
+ #
1307
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1308
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1309
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1310
+ def get_user_setting_imap(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1311
+ command = make_simple_command(:get, '{userId}/settings/imap', options)
1312
+ command.response_representation = Google::Apis::GmailV1::ImapSettings::Representation
1313
+ command.response_class = Google::Apis::GmailV1::ImapSettings
1314
+ command.params['userId'] = user_id unless user_id.nil?
1315
+ command.query['fields'] = fields unless fields.nil?
1316
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1317
+ command.query['userIp'] = user_ip unless user_ip.nil?
1318
+ execute_or_queue_command(command, &block)
1319
+ end
1320
+
1321
+ # Gets POP settings.
1322
+ # @param [String] user_id
1323
+ # User's email address. The special value "me" can be used to indicate the
1324
+ # authenticated user.
1325
+ # @param [String] fields
1326
+ # Selector specifying which fields to include in a partial response.
1327
+ # @param [String] quota_user
1328
+ # Available to use for quota purposes for server-side applications. Can be any
1329
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1330
+ # Overrides userIp if both are provided.
1331
+ # @param [String] user_ip
1332
+ # IP address of the site where the request originates. Use this if you want to
1333
+ # enforce per-user limits.
1334
+ # @param [Google::Apis::RequestOptions] options
1335
+ # Request-specific options
1336
+ #
1337
+ # @yield [result, err] Result & error if block supplied
1338
+ # @yieldparam result [Google::Apis::GmailV1::PopSettings] parsed result object
1339
+ # @yieldparam err [StandardError] error object if request failed
1340
+ #
1341
+ # @return [Google::Apis::GmailV1::PopSettings]
1342
+ #
1343
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1344
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1345
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1346
+ def get_user_setting_pop(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1347
+ command = make_simple_command(:get, '{userId}/settings/pop', options)
1348
+ command.response_representation = Google::Apis::GmailV1::PopSettings::Representation
1349
+ command.response_class = Google::Apis::GmailV1::PopSettings
1350
+ command.params['userId'] = user_id unless user_id.nil?
1351
+ command.query['fields'] = fields unless fields.nil?
1352
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1353
+ command.query['userIp'] = user_ip unless user_ip.nil?
1354
+ execute_or_queue_command(command, &block)
1355
+ end
1356
+
1357
+ # Gets vacation responder settings.
1358
+ # @param [String] user_id
1359
+ # User's email address. The special value "me" can be used to indicate the
1360
+ # authenticated user.
1361
+ # @param [String] fields
1362
+ # Selector specifying which fields to include in a partial response.
1363
+ # @param [String] quota_user
1364
+ # Available to use for quota purposes for server-side applications. Can be any
1365
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1366
+ # Overrides userIp if both are provided.
1367
+ # @param [String] user_ip
1368
+ # IP address of the site where the request originates. Use this if you want to
1369
+ # enforce per-user limits.
1370
+ # @param [Google::Apis::RequestOptions] options
1371
+ # Request-specific options
1372
+ #
1373
+ # @yield [result, err] Result & error if block supplied
1374
+ # @yieldparam result [Google::Apis::GmailV1::VacationSettings] parsed result object
1375
+ # @yieldparam err [StandardError] error object if request failed
1376
+ #
1377
+ # @return [Google::Apis::GmailV1::VacationSettings]
1378
+ #
1379
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1380
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1381
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1382
+ def get_user_setting_vacation(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1383
+ command = make_simple_command(:get, '{userId}/settings/vacation', options)
1384
+ command.response_representation = Google::Apis::GmailV1::VacationSettings::Representation
1385
+ command.response_class = Google::Apis::GmailV1::VacationSettings
1386
+ command.params['userId'] = user_id unless user_id.nil?
1387
+ command.query['fields'] = fields unless fields.nil?
1388
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1389
+ command.query['userIp'] = user_ip unless user_ip.nil?
1390
+ execute_or_queue_command(command, &block)
1391
+ end
1392
+
1393
+ # Updates the auto-forwarding setting for the specified account. A verified
1394
+ # forwarding address must be specified when auto-forwarding is enabled.
1395
+ # @param [String] user_id
1396
+ # User's email address. The special value "me" can be used to indicate the
1397
+ # authenticated user.
1398
+ # @param [Google::Apis::GmailV1::AutoForwarding] auto_forwarding_object
1399
+ # @param [String] fields
1400
+ # Selector specifying which fields to include in a partial response.
1401
+ # @param [String] quota_user
1402
+ # Available to use for quota purposes for server-side applications. Can be any
1403
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1404
+ # Overrides userIp if both are provided.
1405
+ # @param [String] user_ip
1406
+ # IP address of the site where the request originates. Use this if you want to
1407
+ # enforce per-user limits.
1408
+ # @param [Google::Apis::RequestOptions] options
1409
+ # Request-specific options
1410
+ #
1411
+ # @yield [result, err] Result & error if block supplied
1412
+ # @yieldparam result [Google::Apis::GmailV1::AutoForwarding] parsed result object
1413
+ # @yieldparam err [StandardError] error object if request failed
1414
+ #
1415
+ # @return [Google::Apis::GmailV1::AutoForwarding]
1416
+ #
1417
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1418
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1419
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1420
+ def update_user_setting_auto_forwarding(user_id, auto_forwarding_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1421
+ command = make_simple_command(:put, '{userId}/settings/autoForwarding', options)
1422
+ command.request_representation = Google::Apis::GmailV1::AutoForwarding::Representation
1423
+ command.request_object = auto_forwarding_object
1424
+ command.response_representation = Google::Apis::GmailV1::AutoForwarding::Representation
1425
+ command.response_class = Google::Apis::GmailV1::AutoForwarding
1426
+ command.params['userId'] = user_id unless user_id.nil?
1427
+ command.query['fields'] = fields unless fields.nil?
1428
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1429
+ command.query['userIp'] = user_ip unless user_ip.nil?
1430
+ execute_or_queue_command(command, &block)
1431
+ end
1432
+
1433
+ # Updates IMAP settings.
1434
+ # @param [String] user_id
1435
+ # User's email address. The special value "me" can be used to indicate the
1436
+ # authenticated user.
1437
+ # @param [Google::Apis::GmailV1::ImapSettings] imap_settings_object
1438
+ # @param [String] fields
1439
+ # Selector specifying which fields to include in a partial response.
1440
+ # @param [String] quota_user
1441
+ # Available to use for quota purposes for server-side applications. Can be any
1442
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1443
+ # Overrides userIp if both are provided.
1444
+ # @param [String] user_ip
1445
+ # IP address of the site where the request originates. Use this if you want to
1446
+ # enforce per-user limits.
1447
+ # @param [Google::Apis::RequestOptions] options
1448
+ # Request-specific options
1449
+ #
1450
+ # @yield [result, err] Result & error if block supplied
1451
+ # @yieldparam result [Google::Apis::GmailV1::ImapSettings] parsed result object
1452
+ # @yieldparam err [StandardError] error object if request failed
1453
+ #
1454
+ # @return [Google::Apis::GmailV1::ImapSettings]
1455
+ #
1456
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1457
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1458
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1459
+ def update_user_setting_imap(user_id, imap_settings_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1460
+ command = make_simple_command(:put, '{userId}/settings/imap', options)
1461
+ command.request_representation = Google::Apis::GmailV1::ImapSettings::Representation
1462
+ command.request_object = imap_settings_object
1463
+ command.response_representation = Google::Apis::GmailV1::ImapSettings::Representation
1464
+ command.response_class = Google::Apis::GmailV1::ImapSettings
1465
+ command.params['userId'] = user_id unless user_id.nil?
1466
+ command.query['fields'] = fields unless fields.nil?
1467
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1468
+ command.query['userIp'] = user_ip unless user_ip.nil?
1469
+ execute_or_queue_command(command, &block)
1470
+ end
1471
+
1472
+ # Updates POP settings.
1473
+ # @param [String] user_id
1474
+ # User's email address. The special value "me" can be used to indicate the
1475
+ # authenticated user.
1476
+ # @param [Google::Apis::GmailV1::PopSettings] pop_settings_object
1477
+ # @param [String] fields
1478
+ # Selector specifying which fields to include in a partial response.
1479
+ # @param [String] quota_user
1480
+ # Available to use for quota purposes for server-side applications. Can be any
1481
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1482
+ # Overrides userIp if both are provided.
1483
+ # @param [String] user_ip
1484
+ # IP address of the site where the request originates. Use this if you want to
1485
+ # enforce per-user limits.
1486
+ # @param [Google::Apis::RequestOptions] options
1487
+ # Request-specific options
1488
+ #
1489
+ # @yield [result, err] Result & error if block supplied
1490
+ # @yieldparam result [Google::Apis::GmailV1::PopSettings] parsed result object
1491
+ # @yieldparam err [StandardError] error object if request failed
1492
+ #
1493
+ # @return [Google::Apis::GmailV1::PopSettings]
1494
+ #
1495
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1496
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1497
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1498
+ def update_user_setting_pop(user_id, pop_settings_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1499
+ command = make_simple_command(:put, '{userId}/settings/pop', options)
1500
+ command.request_representation = Google::Apis::GmailV1::PopSettings::Representation
1501
+ command.request_object = pop_settings_object
1502
+ command.response_representation = Google::Apis::GmailV1::PopSettings::Representation
1503
+ command.response_class = Google::Apis::GmailV1::PopSettings
1504
+ command.params['userId'] = user_id unless user_id.nil?
1505
+ command.query['fields'] = fields unless fields.nil?
1506
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1507
+ command.query['userIp'] = user_ip unless user_ip.nil?
1508
+ execute_or_queue_command(command, &block)
1509
+ end
1510
+
1511
+ # Updates vacation responder settings.
1512
+ # @param [String] user_id
1513
+ # User's email address. The special value "me" can be used to indicate the
1514
+ # authenticated user.
1515
+ # @param [Google::Apis::GmailV1::VacationSettings] vacation_settings_object
1516
+ # @param [String] fields
1517
+ # Selector specifying which fields to include in a partial response.
1518
+ # @param [String] quota_user
1519
+ # Available to use for quota purposes for server-side applications. Can be any
1520
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1521
+ # Overrides userIp if both are provided.
1522
+ # @param [String] user_ip
1523
+ # IP address of the site where the request originates. Use this if you want to
1524
+ # enforce per-user limits.
1525
+ # @param [Google::Apis::RequestOptions] options
1526
+ # Request-specific options
1527
+ #
1528
+ # @yield [result, err] Result & error if block supplied
1529
+ # @yieldparam result [Google::Apis::GmailV1::VacationSettings] parsed result object
1530
+ # @yieldparam err [StandardError] error object if request failed
1531
+ #
1532
+ # @return [Google::Apis::GmailV1::VacationSettings]
1533
+ #
1534
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1535
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1536
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1537
+ def update_user_setting_vacation(user_id, vacation_settings_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1538
+ command = make_simple_command(:put, '{userId}/settings/vacation', options)
1539
+ command.request_representation = Google::Apis::GmailV1::VacationSettings::Representation
1540
+ command.request_object = vacation_settings_object
1541
+ command.response_representation = Google::Apis::GmailV1::VacationSettings::Representation
1542
+ command.response_class = Google::Apis::GmailV1::VacationSettings
1543
+ command.params['userId'] = user_id unless user_id.nil?
1544
+ command.query['fields'] = fields unless fields.nil?
1545
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1546
+ command.query['userIp'] = user_ip unless user_ip.nil?
1547
+ execute_or_queue_command(command, &block)
1548
+ end
1549
+
1550
+ # Creates a filter.
1551
+ # @param [String] user_id
1552
+ # User's email address. The special value "me" can be used to indicate the
1553
+ # authenticated user.
1554
+ # @param [Google::Apis::GmailV1::Filter] filter_object
1555
+ # @param [String] fields
1556
+ # Selector specifying which fields to include in a partial response.
1557
+ # @param [String] quota_user
1558
+ # Available to use for quota purposes for server-side applications. Can be any
1559
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1560
+ # Overrides userIp if both are provided.
1561
+ # @param [String] user_ip
1562
+ # IP address of the site where the request originates. Use this if you want to
1563
+ # enforce per-user limits.
1564
+ # @param [Google::Apis::RequestOptions] options
1565
+ # Request-specific options
1566
+ #
1567
+ # @yield [result, err] Result & error if block supplied
1568
+ # @yieldparam result [Google::Apis::GmailV1::Filter] parsed result object
1569
+ # @yieldparam err [StandardError] error object if request failed
1570
+ #
1571
+ # @return [Google::Apis::GmailV1::Filter]
1572
+ #
1573
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1574
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1575
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1576
+ def create_user_setting_filter(user_id, filter_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1577
+ command = make_simple_command(:post, '{userId}/settings/filters', options)
1578
+ command.request_representation = Google::Apis::GmailV1::Filter::Representation
1579
+ command.request_object = filter_object
1580
+ command.response_representation = Google::Apis::GmailV1::Filter::Representation
1581
+ command.response_class = Google::Apis::GmailV1::Filter
1582
+ command.params['userId'] = user_id unless user_id.nil?
1583
+ command.query['fields'] = fields unless fields.nil?
1584
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1585
+ command.query['userIp'] = user_ip unless user_ip.nil?
1586
+ execute_or_queue_command(command, &block)
1587
+ end
1588
+
1589
+ # Deletes a filter.
1590
+ # @param [String] user_id
1591
+ # User's email address. The special value "me" can be used to indicate the
1592
+ # authenticated user.
1593
+ # @param [String] id
1594
+ # The ID of the filter to be deleted.
1595
+ # @param [String] fields
1596
+ # Selector specifying which fields to include in a partial response.
1597
+ # @param [String] quota_user
1598
+ # Available to use for quota purposes for server-side applications. Can be any
1599
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1600
+ # Overrides userIp if both are provided.
1601
+ # @param [String] user_ip
1602
+ # IP address of the site where the request originates. Use this if you want to
1603
+ # enforce per-user limits.
1604
+ # @param [Google::Apis::RequestOptions] options
1605
+ # Request-specific options
1606
+ #
1607
+ # @yield [result, err] Result & error if block supplied
1608
+ # @yieldparam result [NilClass] No result returned for this method
1609
+ # @yieldparam err [StandardError] error object if request failed
1610
+ #
1611
+ # @return [void]
1612
+ #
1613
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1614
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1615
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1616
+ def delete_user_setting_filter(user_id, id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1617
+ command = make_simple_command(:delete, '{userId}/settings/filters/{id}', options)
1618
+ command.params['userId'] = user_id unless user_id.nil?
1619
+ command.params['id'] = id unless id.nil?
1620
+ command.query['fields'] = fields unless fields.nil?
1621
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1622
+ command.query['userIp'] = user_ip unless user_ip.nil?
1623
+ execute_or_queue_command(command, &block)
1624
+ end
1625
+
1626
+ # Gets a filter.
1627
+ # @param [String] user_id
1628
+ # User's email address. The special value "me" can be used to indicate the
1629
+ # authenticated user.
1630
+ # @param [String] id
1631
+ # The ID of the filter to be fetched.
1632
+ # @param [String] fields
1633
+ # Selector specifying which fields to include in a partial response.
1634
+ # @param [String] quota_user
1635
+ # Available to use for quota purposes for server-side applications. Can be any
1636
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1637
+ # Overrides userIp if both are provided.
1638
+ # @param [String] user_ip
1639
+ # IP address of the site where the request originates. Use this if you want to
1640
+ # enforce per-user limits.
1641
+ # @param [Google::Apis::RequestOptions] options
1642
+ # Request-specific options
1643
+ #
1644
+ # @yield [result, err] Result & error if block supplied
1645
+ # @yieldparam result [Google::Apis::GmailV1::Filter] parsed result object
1646
+ # @yieldparam err [StandardError] error object if request failed
1647
+ #
1648
+ # @return [Google::Apis::GmailV1::Filter]
1649
+ #
1650
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1651
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1652
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1653
+ def get_user_setting_filter(user_id, id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1654
+ command = make_simple_command(:get, '{userId}/settings/filters/{id}', options)
1655
+ command.response_representation = Google::Apis::GmailV1::Filter::Representation
1656
+ command.response_class = Google::Apis::GmailV1::Filter
1657
+ command.params['userId'] = user_id unless user_id.nil?
1658
+ command.params['id'] = id unless id.nil?
1659
+ command.query['fields'] = fields unless fields.nil?
1660
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1661
+ command.query['userIp'] = user_ip unless user_ip.nil?
1662
+ execute_or_queue_command(command, &block)
1663
+ end
1664
+
1665
+ # Lists the message filters of a Gmail user.
1666
+ # @param [String] user_id
1667
+ # User's email address. The special value "me" can be used to indicate the
1668
+ # authenticated user.
1669
+ # @param [String] fields
1670
+ # Selector specifying which fields to include in a partial response.
1671
+ # @param [String] quota_user
1672
+ # Available to use for quota purposes for server-side applications. Can be any
1673
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1674
+ # Overrides userIp if both are provided.
1675
+ # @param [String] user_ip
1676
+ # IP address of the site where the request originates. Use this if you want to
1677
+ # enforce per-user limits.
1678
+ # @param [Google::Apis::RequestOptions] options
1679
+ # Request-specific options
1680
+ #
1681
+ # @yield [result, err] Result & error if block supplied
1682
+ # @yieldparam result [Google::Apis::GmailV1::ListFiltersResponse] parsed result object
1683
+ # @yieldparam err [StandardError] error object if request failed
1684
+ #
1685
+ # @return [Google::Apis::GmailV1::ListFiltersResponse]
1686
+ #
1687
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1688
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1689
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1690
+ def list_user_setting_filters(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1691
+ command = make_simple_command(:get, '{userId}/settings/filters', options)
1692
+ command.response_representation = Google::Apis::GmailV1::ListFiltersResponse::Representation
1693
+ command.response_class = Google::Apis::GmailV1::ListFiltersResponse
1694
+ command.params['userId'] = user_id unless user_id.nil?
1695
+ command.query['fields'] = fields unless fields.nil?
1696
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1697
+ command.query['userIp'] = user_ip unless user_ip.nil?
1698
+ execute_or_queue_command(command, &block)
1699
+ end
1700
+
1701
+ # Creates a forwarding address. If ownership verification is required, a message
1702
+ # will be sent to the recipient and the resource's verification status will be
1703
+ # set to pending; otherwise, the resource will be created with verification
1704
+ # status set to accepted.
1705
+ # @param [String] user_id
1706
+ # User's email address. The special value "me" can be used to indicate the
1707
+ # authenticated user.
1708
+ # @param [Google::Apis::GmailV1::ForwardingAddress] forwarding_address_object
1709
+ # @param [String] fields
1710
+ # Selector specifying which fields to include in a partial response.
1711
+ # @param [String] quota_user
1712
+ # Available to use for quota purposes for server-side applications. Can be any
1713
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1714
+ # Overrides userIp if both are provided.
1715
+ # @param [String] user_ip
1716
+ # IP address of the site where the request originates. Use this if you want to
1717
+ # enforce per-user limits.
1718
+ # @param [Google::Apis::RequestOptions] options
1719
+ # Request-specific options
1720
+ #
1721
+ # @yield [result, err] Result & error if block supplied
1722
+ # @yieldparam result [Google::Apis::GmailV1::ForwardingAddress] parsed result object
1723
+ # @yieldparam err [StandardError] error object if request failed
1724
+ #
1725
+ # @return [Google::Apis::GmailV1::ForwardingAddress]
1726
+ #
1727
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1728
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1729
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1730
+ def create_user_setting_forwarding_address(user_id, forwarding_address_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1731
+ command = make_simple_command(:post, '{userId}/settings/forwardingAddresses', options)
1732
+ command.request_representation = Google::Apis::GmailV1::ForwardingAddress::Representation
1733
+ command.request_object = forwarding_address_object
1734
+ command.response_representation = Google::Apis::GmailV1::ForwardingAddress::Representation
1735
+ command.response_class = Google::Apis::GmailV1::ForwardingAddress
1736
+ command.params['userId'] = user_id unless user_id.nil?
1737
+ command.query['fields'] = fields unless fields.nil?
1738
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1739
+ command.query['userIp'] = user_ip unless user_ip.nil?
1740
+ execute_or_queue_command(command, &block)
1741
+ end
1742
+
1743
+ # Deletes the specified forwarding address and revokes any verification that may
1744
+ # have been required.
1745
+ # @param [String] user_id
1746
+ # User's email address. The special value "me" can be used to indicate the
1747
+ # authenticated user.
1748
+ # @param [String] forwarding_email
1749
+ # The forwarding address to be deleted.
1750
+ # @param [String] fields
1751
+ # Selector specifying which fields to include in a partial response.
1752
+ # @param [String] quota_user
1753
+ # Available to use for quota purposes for server-side applications. Can be any
1754
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1755
+ # Overrides userIp if both are provided.
1756
+ # @param [String] user_ip
1757
+ # IP address of the site where the request originates. Use this if you want to
1758
+ # enforce per-user limits.
1759
+ # @param [Google::Apis::RequestOptions] options
1760
+ # Request-specific options
1761
+ #
1762
+ # @yield [result, err] Result & error if block supplied
1763
+ # @yieldparam result [NilClass] No result returned for this method
1764
+ # @yieldparam err [StandardError] error object if request failed
1765
+ #
1766
+ # @return [void]
1767
+ #
1768
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1769
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1770
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1771
+ def delete_user_setting_forwarding_address(user_id, forwarding_email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1772
+ command = make_simple_command(:delete, '{userId}/settings/forwardingAddresses/{forwardingEmail}', options)
1773
+ command.params['userId'] = user_id unless user_id.nil?
1774
+ command.params['forwardingEmail'] = forwarding_email unless forwarding_email.nil?
1775
+ command.query['fields'] = fields unless fields.nil?
1776
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1777
+ command.query['userIp'] = user_ip unless user_ip.nil?
1778
+ execute_or_queue_command(command, &block)
1779
+ end
1780
+
1781
+ # Gets the specified forwarding address.
1782
+ # @param [String] user_id
1783
+ # User's email address. The special value "me" can be used to indicate the
1784
+ # authenticated user.
1785
+ # @param [String] forwarding_email
1786
+ # The forwarding address to be retrieved.
1787
+ # @param [String] fields
1788
+ # Selector specifying which fields to include in a partial response.
1789
+ # @param [String] quota_user
1790
+ # Available to use for quota purposes for server-side applications. Can be any
1791
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1792
+ # Overrides userIp if both are provided.
1793
+ # @param [String] user_ip
1794
+ # IP address of the site where the request originates. Use this if you want to
1795
+ # enforce per-user limits.
1796
+ # @param [Google::Apis::RequestOptions] options
1797
+ # Request-specific options
1798
+ #
1799
+ # @yield [result, err] Result & error if block supplied
1800
+ # @yieldparam result [Google::Apis::GmailV1::ForwardingAddress] parsed result object
1801
+ # @yieldparam err [StandardError] error object if request failed
1802
+ #
1803
+ # @return [Google::Apis::GmailV1::ForwardingAddress]
1804
+ #
1805
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1806
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1807
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1808
+ def get_user_setting_forwarding_address(user_id, forwarding_email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1809
+ command = make_simple_command(:get, '{userId}/settings/forwardingAddresses/{forwardingEmail}', options)
1810
+ command.response_representation = Google::Apis::GmailV1::ForwardingAddress::Representation
1811
+ command.response_class = Google::Apis::GmailV1::ForwardingAddress
1812
+ command.params['userId'] = user_id unless user_id.nil?
1813
+ command.params['forwardingEmail'] = forwarding_email unless forwarding_email.nil?
1814
+ command.query['fields'] = fields unless fields.nil?
1815
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1816
+ command.query['userIp'] = user_ip unless user_ip.nil?
1817
+ execute_or_queue_command(command, &block)
1818
+ end
1819
+
1820
+ # Lists the forwarding addresses for the specified account.
1821
+ # @param [String] user_id
1822
+ # User's email address. The special value "me" can be used to indicate the
1823
+ # authenticated user.
1824
+ # @param [String] fields
1825
+ # Selector specifying which fields to include in a partial response.
1826
+ # @param [String] quota_user
1827
+ # Available to use for quota purposes for server-side applications. Can be any
1828
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1829
+ # Overrides userIp if both are provided.
1830
+ # @param [String] user_ip
1831
+ # IP address of the site where the request originates. Use this if you want to
1832
+ # enforce per-user limits.
1833
+ # @param [Google::Apis::RequestOptions] options
1834
+ # Request-specific options
1835
+ #
1836
+ # @yield [result, err] Result & error if block supplied
1837
+ # @yieldparam result [Google::Apis::GmailV1::ListForwardingAddressesResponse] parsed result object
1838
+ # @yieldparam err [StandardError] error object if request failed
1839
+ #
1840
+ # @return [Google::Apis::GmailV1::ListForwardingAddressesResponse]
1841
+ #
1842
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1843
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1844
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1845
+ def list_user_setting_forwarding_addresses(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1846
+ command = make_simple_command(:get, '{userId}/settings/forwardingAddresses', options)
1847
+ command.response_representation = Google::Apis::GmailV1::ListForwardingAddressesResponse::Representation
1848
+ command.response_class = Google::Apis::GmailV1::ListForwardingAddressesResponse
1849
+ command.params['userId'] = user_id unless user_id.nil?
1850
+ command.query['fields'] = fields unless fields.nil?
1851
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1852
+ command.query['userIp'] = user_ip unless user_ip.nil?
1853
+ execute_or_queue_command(command, &block)
1854
+ end
1855
+
1856
+ # Creates a custom "from" send-as alias. If an SMTP MSA is specified, Gmail will
1857
+ # attempt to connect to the SMTP service to validate the configuration before
1858
+ # creating the alias. If ownership verification is required for the alias, a
1859
+ # message will be sent to the email address and the resource's verification
1860
+ # status will be set to pending; otherwise, the resource will be created with
1861
+ # verification status set to accepted. If a signature is provided, Gmail will
1862
+ # sanitize the HTML before saving it with the alias.
1863
+ # @param [String] user_id
1864
+ # User's email address. The special value "me" can be used to indicate the
1865
+ # authenticated user.
1866
+ # @param [Google::Apis::GmailV1::SendAs] send_as_object
1867
+ # @param [String] fields
1868
+ # Selector specifying which fields to include in a partial response.
1869
+ # @param [String] quota_user
1870
+ # Available to use for quota purposes for server-side applications. Can be any
1871
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1872
+ # Overrides userIp if both are provided.
1873
+ # @param [String] user_ip
1874
+ # IP address of the site where the request originates. Use this if you want to
1875
+ # enforce per-user limits.
1876
+ # @param [Google::Apis::RequestOptions] options
1877
+ # Request-specific options
1878
+ #
1879
+ # @yield [result, err] Result & error if block supplied
1880
+ # @yieldparam result [Google::Apis::GmailV1::SendAs] parsed result object
1881
+ # @yieldparam err [StandardError] error object if request failed
1882
+ #
1883
+ # @return [Google::Apis::GmailV1::SendAs]
1884
+ #
1885
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1886
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1887
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1888
+ def create_user_setting_send_as(user_id, send_as_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1889
+ command = make_simple_command(:post, '{userId}/settings/sendAs', options)
1890
+ command.request_representation = Google::Apis::GmailV1::SendAs::Representation
1891
+ command.request_object = send_as_object
1892
+ command.response_representation = Google::Apis::GmailV1::SendAs::Representation
1893
+ command.response_class = Google::Apis::GmailV1::SendAs
1894
+ command.params['userId'] = user_id unless user_id.nil?
1895
+ command.query['fields'] = fields unless fields.nil?
1896
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1897
+ command.query['userIp'] = user_ip unless user_ip.nil?
1898
+ execute_or_queue_command(command, &block)
1899
+ end
1900
+
1901
+ # Deletes the specified send-as alias. Revokes any verification that may have
1902
+ # been required for using it.
1903
+ # @param [String] user_id
1904
+ # User's email address. The special value "me" can be used to indicate the
1905
+ # authenticated user.
1906
+ # @param [String] send_as_email
1907
+ # The send-as alias to be deleted.
1908
+ # @param [String] fields
1909
+ # Selector specifying which fields to include in a partial response.
1910
+ # @param [String] quota_user
1911
+ # Available to use for quota purposes for server-side applications. Can be any
1912
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1913
+ # Overrides userIp if both are provided.
1914
+ # @param [String] user_ip
1915
+ # IP address of the site where the request originates. Use this if you want to
1916
+ # enforce per-user limits.
1917
+ # @param [Google::Apis::RequestOptions] options
1918
+ # Request-specific options
1919
+ #
1920
+ # @yield [result, err] Result & error if block supplied
1921
+ # @yieldparam result [NilClass] No result returned for this method
1922
+ # @yieldparam err [StandardError] error object if request failed
1923
+ #
1924
+ # @return [void]
1925
+ #
1926
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1927
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1928
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1929
+ def delete_user_setting_send_as(user_id, send_as_email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1930
+ command = make_simple_command(:delete, '{userId}/settings/sendAs/{sendAsEmail}', options)
1931
+ command.params['userId'] = user_id unless user_id.nil?
1932
+ command.params['sendAsEmail'] = send_as_email unless send_as_email.nil?
1933
+ command.query['fields'] = fields unless fields.nil?
1934
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1935
+ command.query['userIp'] = user_ip unless user_ip.nil?
1936
+ execute_or_queue_command(command, &block)
1937
+ end
1938
+
1939
+ # Gets the specified send-as alias. Fails with an HTTP 404 error if the
1940
+ # specified address is not a member of the collection.
1941
+ # @param [String] user_id
1942
+ # User's email address. The special value "me" can be used to indicate the
1943
+ # authenticated user.
1944
+ # @param [String] send_as_email
1945
+ # The send-as alias to be retrieved.
1946
+ # @param [String] fields
1947
+ # Selector specifying which fields to include in a partial response.
1948
+ # @param [String] quota_user
1949
+ # Available to use for quota purposes for server-side applications. Can be any
1950
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1951
+ # Overrides userIp if both are provided.
1952
+ # @param [String] user_ip
1953
+ # IP address of the site where the request originates. Use this if you want to
1954
+ # enforce per-user limits.
1955
+ # @param [Google::Apis::RequestOptions] options
1956
+ # Request-specific options
1957
+ #
1958
+ # @yield [result, err] Result & error if block supplied
1959
+ # @yieldparam result [Google::Apis::GmailV1::SendAs] parsed result object
1960
+ # @yieldparam err [StandardError] error object if request failed
1961
+ #
1962
+ # @return [Google::Apis::GmailV1::SendAs]
1963
+ #
1964
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1965
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1966
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1967
+ def get_user_setting_send_as(user_id, send_as_email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1968
+ command = make_simple_command(:get, '{userId}/settings/sendAs/{sendAsEmail}', options)
1969
+ command.response_representation = Google::Apis::GmailV1::SendAs::Representation
1970
+ command.response_class = Google::Apis::GmailV1::SendAs
1971
+ command.params['userId'] = user_id unless user_id.nil?
1972
+ command.params['sendAsEmail'] = send_as_email unless send_as_email.nil?
1973
+ command.query['fields'] = fields unless fields.nil?
1974
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1975
+ command.query['userIp'] = user_ip unless user_ip.nil?
1976
+ execute_or_queue_command(command, &block)
1977
+ end
1978
+
1979
+ # Lists the send-as aliases for the specified account. The result includes the
1980
+ # primary send-as address associated with the account as well as any custom "
1981
+ # from" aliases.
1982
+ # @param [String] user_id
1983
+ # User's email address. The special value "me" can be used to indicate the
1984
+ # authenticated user.
1985
+ # @param [String] fields
1986
+ # Selector specifying which fields to include in a partial response.
1987
+ # @param [String] quota_user
1988
+ # Available to use for quota purposes for server-side applications. Can be any
1989
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1990
+ # Overrides userIp if both are provided.
1991
+ # @param [String] user_ip
1992
+ # IP address of the site where the request originates. Use this if you want to
1993
+ # enforce per-user limits.
1994
+ # @param [Google::Apis::RequestOptions] options
1995
+ # Request-specific options
1996
+ #
1997
+ # @yield [result, err] Result & error if block supplied
1998
+ # @yieldparam result [Google::Apis::GmailV1::ListSendAsResponse] parsed result object
1999
+ # @yieldparam err [StandardError] error object if request failed
2000
+ #
2001
+ # @return [Google::Apis::GmailV1::ListSendAsResponse]
2002
+ #
2003
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2004
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2005
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2006
+ def list_user_setting_send_as(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2007
+ command = make_simple_command(:get, '{userId}/settings/sendAs', options)
2008
+ command.response_representation = Google::Apis::GmailV1::ListSendAsResponse::Representation
2009
+ command.response_class = Google::Apis::GmailV1::ListSendAsResponse
2010
+ command.params['userId'] = user_id unless user_id.nil?
2011
+ command.query['fields'] = fields unless fields.nil?
2012
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2013
+ command.query['userIp'] = user_ip unless user_ip.nil?
2014
+ execute_or_queue_command(command, &block)
2015
+ end
2016
+
2017
+ # Updates a send-as alias. If a signature is provided, Gmail will sanitize the
2018
+ # HTML before saving it with the alias. This method supports patch semantics.
2019
+ # @param [String] user_id
2020
+ # User's email address. The special value "me" can be used to indicate the
2021
+ # authenticated user.
2022
+ # @param [String] send_as_email
2023
+ # The send-as alias to be updated.
2024
+ # @param [Google::Apis::GmailV1::SendAs] send_as_object
2025
+ # @param [String] fields
2026
+ # Selector specifying which fields to include in a partial response.
2027
+ # @param [String] quota_user
2028
+ # Available to use for quota purposes for server-side applications. Can be any
2029
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2030
+ # Overrides userIp if both are provided.
2031
+ # @param [String] user_ip
2032
+ # IP address of the site where the request originates. Use this if you want to
2033
+ # enforce per-user limits.
2034
+ # @param [Google::Apis::RequestOptions] options
2035
+ # Request-specific options
2036
+ #
2037
+ # @yield [result, err] Result & error if block supplied
2038
+ # @yieldparam result [Google::Apis::GmailV1::SendAs] parsed result object
2039
+ # @yieldparam err [StandardError] error object if request failed
2040
+ #
2041
+ # @return [Google::Apis::GmailV1::SendAs]
2042
+ #
2043
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2044
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2045
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2046
+ def patch_user_setting_send_as(user_id, send_as_email, send_as_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2047
+ command = make_simple_command(:patch, '{userId}/settings/sendAs/{sendAsEmail}', options)
2048
+ command.request_representation = Google::Apis::GmailV1::SendAs::Representation
2049
+ command.request_object = send_as_object
2050
+ command.response_representation = Google::Apis::GmailV1::SendAs::Representation
2051
+ command.response_class = Google::Apis::GmailV1::SendAs
2052
+ command.params['userId'] = user_id unless user_id.nil?
2053
+ command.params['sendAsEmail'] = send_as_email unless send_as_email.nil?
2054
+ command.query['fields'] = fields unless fields.nil?
2055
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2056
+ command.query['userIp'] = user_ip unless user_ip.nil?
2057
+ execute_or_queue_command(command, &block)
2058
+ end
2059
+
2060
+ # Updates a send-as alias. If a signature is provided, Gmail will sanitize the
2061
+ # HTML before saving it with the alias.
2062
+ # @param [String] user_id
2063
+ # User's email address. The special value "me" can be used to indicate the
2064
+ # authenticated user.
2065
+ # @param [String] send_as_email
2066
+ # The send-as alias to be updated.
2067
+ # @param [Google::Apis::GmailV1::SendAs] send_as_object
2068
+ # @param [String] fields
2069
+ # Selector specifying which fields to include in a partial response.
2070
+ # @param [String] quota_user
2071
+ # Available to use for quota purposes for server-side applications. Can be any
2072
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2073
+ # Overrides userIp if both are provided.
2074
+ # @param [String] user_ip
2075
+ # IP address of the site where the request originates. Use this if you want to
2076
+ # enforce per-user limits.
2077
+ # @param [Google::Apis::RequestOptions] options
2078
+ # Request-specific options
2079
+ #
2080
+ # @yield [result, err] Result & error if block supplied
2081
+ # @yieldparam result [Google::Apis::GmailV1::SendAs] parsed result object
2082
+ # @yieldparam err [StandardError] error object if request failed
2083
+ #
2084
+ # @return [Google::Apis::GmailV1::SendAs]
2085
+ #
2086
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2087
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2088
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2089
+ def update_user_setting_send_as(user_id, send_as_email, send_as_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2090
+ command = make_simple_command(:put, '{userId}/settings/sendAs/{sendAsEmail}', options)
2091
+ command.request_representation = Google::Apis::GmailV1::SendAs::Representation
2092
+ command.request_object = send_as_object
2093
+ command.response_representation = Google::Apis::GmailV1::SendAs::Representation
2094
+ command.response_class = Google::Apis::GmailV1::SendAs
2095
+ command.params['userId'] = user_id unless user_id.nil?
2096
+ command.params['sendAsEmail'] = send_as_email unless send_as_email.nil?
2097
+ command.query['fields'] = fields unless fields.nil?
2098
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2099
+ command.query['userIp'] = user_ip unless user_ip.nil?
2100
+ execute_or_queue_command(command, &block)
2101
+ end
2102
+
2103
+ # Sends a verification email to the specified send-as alias address. The
2104
+ # verification status must be pending.
2105
+ # @param [String] user_id
2106
+ # User's email address. The special value "me" can be used to indicate the
2107
+ # authenticated user.
2108
+ # @param [String] send_as_email
2109
+ # The send-as alias to be verified.
2110
+ # @param [String] fields
2111
+ # Selector specifying which fields to include in a partial response.
2112
+ # @param [String] quota_user
2113
+ # Available to use for quota purposes for server-side applications. Can be any
2114
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2115
+ # Overrides userIp if both are provided.
2116
+ # @param [String] user_ip
2117
+ # IP address of the site where the request originates. Use this if you want to
2118
+ # enforce per-user limits.
2119
+ # @param [Google::Apis::RequestOptions] options
2120
+ # Request-specific options
2121
+ #
2122
+ # @yield [result, err] Result & error if block supplied
2123
+ # @yieldparam result [NilClass] No result returned for this method
2124
+ # @yieldparam err [StandardError] error object if request failed
2125
+ #
2126
+ # @return [void]
2127
+ #
2128
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2129
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2130
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2131
+ def verify_user_setting_send_as(user_id, send_as_email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2132
+ command = make_simple_command(:post, '{userId}/settings/sendAs/{sendAsEmail}/verify', options)
2133
+ command.params['userId'] = user_id unless user_id.nil?
2134
+ command.params['sendAsEmail'] = send_as_email unless send_as_email.nil?
2135
+ command.query['fields'] = fields unless fields.nil?
2136
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2137
+ command.query['userIp'] = user_ip unless user_ip.nil?
2138
+ execute_or_queue_command(command, &block)
2139
+ end
2140
+
1244
2141
  # Immediately and permanently deletes the specified thread. This operation
1245
2142
  # cannot be undone. Prefer threads.trash instead.
1246
2143
  # @param [String] user_id