blob: f9ba6f35bd6ae2566510ff67573efc398a9878a1 [file] [log] [blame]
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="gmail_v1.html">Gmail API</a> . <a href="gmail_v1.users.html">users</a> . <a href="gmail_v1.users.settings.html">settings</a> . <a href="gmail_v1.users.settings.sendAs.html">sendAs</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040078 <code><a href="gmail_v1.users.settings.sendAs.smimeInfo.html">smimeInfo()</a></code>
79</p>
80<p class="firstline">Returns the smimeInfo Resource.</p>
81
82<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070083 <code><a href="#create">create(userId, body=None, x__xgafv=None)</a></code></p>
84<p class="firstline">Creates a custom "from" send-as alias. If an SMTP MSA is specified, Gmail</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070085<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070086 <code><a href="#delete">delete(userId, sendAsEmail, x__xgafv=None)</a></code></p>
87<p class="firstline">Deletes the specified send-as alias. Revokes any verification that may</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070088<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070089 <code><a href="#get">get(userId, sendAsEmail, x__xgafv=None)</a></code></p>
90<p class="firstline">Gets the specified send-as alias. Fails with an HTTP 404 error if the</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070091<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070092 <code><a href="#list">list(userId, x__xgafv=None)</a></code></p>
93<p class="firstline">Lists the send-as aliases for the specified account. The result includes</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070094<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070095 <code><a href="#patch">patch(userId, sendAsEmail, body=None, x__xgafv=None)</a></code></p>
96<p class="firstline">Patch the specified send-as alias.</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070097<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070098 <code><a href="#update">update(userId, sendAsEmail, body=None, x__xgafv=None)</a></code></p>
99<p class="firstline">Updates a send-as alias. If a signature is provided, Gmail will sanitize</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700100<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700101 <code><a href="#verify">verify(userId, sendAsEmail, x__xgafv=None)</a></code></p>
102<p class="firstline">Sends a verification email to the specified send-as alias address.</p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700103<h3>Method Details</h3>
104<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700105 <code class="details" id="create">create(userId, body=None, x__xgafv=None)</code>
106 <pre>Creates a custom &quot;from&quot; send-as alias. If an SMTP MSA is specified, Gmail
107will attempt to connect to the SMTP service to validate the configuration
108before creating the alias. If ownership verification is required for the
109alias, a message will be sent to the email address and the resource&#x27;s
110verification status will be set to `pending`; otherwise, the
111resource will be created with verification status set to
112`accepted`. If a signature is provided, Gmail will sanitize the
113HTML before saving it with the alias.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700114
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700115This method is only available to service account clients that have been
116delegated domain-wide authority.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400117
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700118Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700119 userId: string, User&#x27;s email address. The special value &quot;me&quot;
120can be used to indicate the authenticated user. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700121 body: object, The request body.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700122 The object takes the form of:
123
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700124{ # Settings associated with a send-as alias, which can be either the primary
125 # login address associated with the account or a custom &quot;from&quot; address.
126 # Send-as aliases correspond to the
127 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
128 # feature in the web interface.
129 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
130 # this alias. This is read-only for all operations except create.
131 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
132 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
133 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
134 # Every Gmail account has exactly one primary address, and it cannot be
135 # deleted from the collection of send-as aliases. This field is read-only.
136 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
137 # alias in the Gmail web UI.
138 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
139 # situations such as composing a new message or sending a vacation
140 # auto-reply. Every Gmail account has exactly one default send-as address,
141 # so the only legal value that clients may write to this field is
142 # `true`. Changing this from `false` to
143 # `true` for an address will result in this field becoming
144 # `false` for the other previous default address.
145 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
146 # sent using this alias. If this is empty, Gmail will not generate a
147 # &quot;Reply-To:&quot; header.
148 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
149 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
150 # &quot;From:&quot; header with the name that is used for the primary address
151 # associated with the account.
152 # If the admin has disabled the ability for users to update their name
153 # format, requests to update this field for the primary login will silently
154 # fail.
155 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
156 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
157 # This setting only applies to custom &quot;from&quot; aliases.
158 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
159 # sent using this alias. If this is empty, outbound mail will be sent
160 # directly from Gmail&#x27;s servers to the destination SMTP service. This
161 # setting only applies to custom &quot;from&quot; aliases.
162 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
163 # This is a write-only field that can be specified in requests to create or
164 # update SendAs settings; it is never populated in responses.
165 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
166 # service. Required.
167 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
168 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
169 # This is a write-only field that can be specified in requests to create or
170 # update SendAs settings; it is never populated in responses.
171 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700172 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700173 }
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700174
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700175 x__xgafv: string, V1 error format.
176 Allowed values
177 1 - v1 error format
178 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700179
180Returns:
181 An object of the form:
182
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700183 { # Settings associated with a send-as alias, which can be either the primary
184 # login address associated with the account or a custom &quot;from&quot; address.
185 # Send-as aliases correspond to the
186 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
187 # feature in the web interface.
188 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
189 # this alias. This is read-only for all operations except create.
190 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
191 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
192 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
193 # Every Gmail account has exactly one primary address, and it cannot be
194 # deleted from the collection of send-as aliases. This field is read-only.
195 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
196 # alias in the Gmail web UI.
197 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
198 # situations such as composing a new message or sending a vacation
199 # auto-reply. Every Gmail account has exactly one default send-as address,
200 # so the only legal value that clients may write to this field is
201 # `true`. Changing this from `false` to
202 # `true` for an address will result in this field becoming
203 # `false` for the other previous default address.
204 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
205 # sent using this alias. If this is empty, Gmail will not generate a
206 # &quot;Reply-To:&quot; header.
207 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
208 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
209 # &quot;From:&quot; header with the name that is used for the primary address
210 # associated with the account.
211 # If the admin has disabled the ability for users to update their name
212 # format, requests to update this field for the primary login will silently
213 # fail.
214 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
215 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
216 # This setting only applies to custom &quot;from&quot; aliases.
217 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
218 # sent using this alias. If this is empty, outbound mail will be sent
219 # directly from Gmail&#x27;s servers to the destination SMTP service. This
220 # setting only applies to custom &quot;from&quot; aliases.
221 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
222 # This is a write-only field that can be specified in requests to create or
223 # update SendAs settings; it is never populated in responses.
224 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
225 # service. Required.
226 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
227 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
228 # This is a write-only field that can be specified in requests to create or
229 # update SendAs settings; it is never populated in responses.
230 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700231 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700232 }</pre>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700233</div>
234
235<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700236 <code class="details" id="delete">delete(userId, sendAsEmail, x__xgafv=None)</code>
237 <pre>Deletes the specified send-as alias. Revokes any verification that may
238have been required for using it.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700239
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700240This method is only available to service account clients that have been
241delegated domain-wide authority.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400242
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700243Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700244 userId: string, User&#x27;s email address. The special value &quot;me&quot;
245can be used to indicate the authenticated user. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700246 sendAsEmail: string, The send-as alias to be deleted. (required)
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700247 x__xgafv: string, V1 error format.
248 Allowed values
249 1 - v1 error format
250 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700251</pre>
252</div>
253
254<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700255 <code class="details" id="get">get(userId, sendAsEmail, x__xgafv=None)</code>
256 <pre>Gets the specified send-as alias. Fails with an HTTP 404 error if the
257specified address is not a member of the collection.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700258
259Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700260 userId: string, User&#x27;s email address. The special value &quot;me&quot;
261can be used to indicate the authenticated user. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700262 sendAsEmail: string, The send-as alias to be retrieved. (required)
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700263 x__xgafv: string, V1 error format.
264 Allowed values
265 1 - v1 error format
266 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700267
268Returns:
269 An object of the form:
270
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700271 { # Settings associated with a send-as alias, which can be either the primary
272 # login address associated with the account or a custom &quot;from&quot; address.
273 # Send-as aliases correspond to the
274 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
275 # feature in the web interface.
276 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
277 # this alias. This is read-only for all operations except create.
278 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
279 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
280 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
281 # Every Gmail account has exactly one primary address, and it cannot be
282 # deleted from the collection of send-as aliases. This field is read-only.
283 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
284 # alias in the Gmail web UI.
285 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
286 # situations such as composing a new message or sending a vacation
287 # auto-reply. Every Gmail account has exactly one default send-as address,
288 # so the only legal value that clients may write to this field is
289 # `true`. Changing this from `false` to
290 # `true` for an address will result in this field becoming
291 # `false` for the other previous default address.
292 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
293 # sent using this alias. If this is empty, Gmail will not generate a
294 # &quot;Reply-To:&quot; header.
295 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
296 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
297 # &quot;From:&quot; header with the name that is used for the primary address
298 # associated with the account.
299 # If the admin has disabled the ability for users to update their name
300 # format, requests to update this field for the primary login will silently
301 # fail.
302 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
303 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
304 # This setting only applies to custom &quot;from&quot; aliases.
305 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
306 # sent using this alias. If this is empty, outbound mail will be sent
307 # directly from Gmail&#x27;s servers to the destination SMTP service. This
308 # setting only applies to custom &quot;from&quot; aliases.
309 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
310 # This is a write-only field that can be specified in requests to create or
311 # update SendAs settings; it is never populated in responses.
312 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
313 # service. Required.
314 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
315 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
316 # This is a write-only field that can be specified in requests to create or
317 # update SendAs settings; it is never populated in responses.
318 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700319 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700320 }</pre>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700321</div>
322
323<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700324 <code class="details" id="list">list(userId, x__xgafv=None)</code>
325 <pre>Lists the send-as aliases for the specified account. The result includes
326the primary send-as address associated with the account as well as any
327custom &quot;from&quot; aliases.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700328
329Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700330 userId: string, User&#x27;s email address. The special value &quot;me&quot;
331can be used to indicate the authenticated user. (required)
332 x__xgafv: string, V1 error format.
333 Allowed values
334 1 - v1 error format
335 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700336
337Returns:
338 An object of the form:
339
340 { # Response for the ListSendAs method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700341 &quot;sendAs&quot;: [ # List of send-as aliases.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700342 { # Settings associated with a send-as alias, which can be either the primary
343 # login address associated with the account or a custom &quot;from&quot; address.
344 # Send-as aliases correspond to the
345 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
346 # feature in the web interface.
347 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
348 # this alias. This is read-only for all operations except create.
349 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
350 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
351 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
352 # Every Gmail account has exactly one primary address, and it cannot be
353 # deleted from the collection of send-as aliases. This field is read-only.
354 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
355 # alias in the Gmail web UI.
356 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
357 # situations such as composing a new message or sending a vacation
358 # auto-reply. Every Gmail account has exactly one default send-as address,
359 # so the only legal value that clients may write to this field is
360 # `true`. Changing this from `false` to
361 # `true` for an address will result in this field becoming
362 # `false` for the other previous default address.
363 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
364 # sent using this alias. If this is empty, Gmail will not generate a
365 # &quot;Reply-To:&quot; header.
366 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
367 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
368 # &quot;From:&quot; header with the name that is used for the primary address
369 # associated with the account.
370 # If the admin has disabled the ability for users to update their name
371 # format, requests to update this field for the primary login will silently
372 # fail.
373 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
374 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
375 # This setting only applies to custom &quot;from&quot; aliases.
376 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
377 # sent using this alias. If this is empty, outbound mail will be sent
378 # directly from Gmail&#x27;s servers to the destination SMTP service. This
379 # setting only applies to custom &quot;from&quot; aliases.
380 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
381 # This is a write-only field that can be specified in requests to create or
382 # update SendAs settings; it is never populated in responses.
383 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
384 # service. Required.
385 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
386 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
387 # This is a write-only field that can be specified in requests to create or
388 # update SendAs settings; it is never populated in responses.
389 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700390 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700391 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700392 ],
393 }</pre>
394</div>
395
396<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700397 <code class="details" id="patch">patch(userId, sendAsEmail, body=None, x__xgafv=None)</code>
398 <pre>Patch the specified send-as alias.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700399
400Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700401 userId: string, User&#x27;s email address. The special value &quot;me&quot;
402can be used to indicate the authenticated user. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700403 sendAsEmail: string, The send-as alias to be updated. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700404 body: object, The request body.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700405 The object takes the form of:
406
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700407{ # Settings associated with a send-as alias, which can be either the primary
408 # login address associated with the account or a custom &quot;from&quot; address.
409 # Send-as aliases correspond to the
410 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
411 # feature in the web interface.
412 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
413 # this alias. This is read-only for all operations except create.
414 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
415 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
416 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
417 # Every Gmail account has exactly one primary address, and it cannot be
418 # deleted from the collection of send-as aliases. This field is read-only.
419 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
420 # alias in the Gmail web UI.
421 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
422 # situations such as composing a new message or sending a vacation
423 # auto-reply. Every Gmail account has exactly one default send-as address,
424 # so the only legal value that clients may write to this field is
425 # `true`. Changing this from `false` to
426 # `true` for an address will result in this field becoming
427 # `false` for the other previous default address.
428 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
429 # sent using this alias. If this is empty, Gmail will not generate a
430 # &quot;Reply-To:&quot; header.
431 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
432 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
433 # &quot;From:&quot; header with the name that is used for the primary address
434 # associated with the account.
435 # If the admin has disabled the ability for users to update their name
436 # format, requests to update this field for the primary login will silently
437 # fail.
438 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
439 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
440 # This setting only applies to custom &quot;from&quot; aliases.
441 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
442 # sent using this alias. If this is empty, outbound mail will be sent
443 # directly from Gmail&#x27;s servers to the destination SMTP service. This
444 # setting only applies to custom &quot;from&quot; aliases.
445 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
446 # This is a write-only field that can be specified in requests to create or
447 # update SendAs settings; it is never populated in responses.
448 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
449 # service. Required.
450 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
451 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
452 # This is a write-only field that can be specified in requests to create or
453 # update SendAs settings; it is never populated in responses.
454 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700455 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700456 }
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700457
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700458 x__xgafv: string, V1 error format.
459 Allowed values
460 1 - v1 error format
461 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700462
463Returns:
464 An object of the form:
465
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700466 { # Settings associated with a send-as alias, which can be either the primary
467 # login address associated with the account or a custom &quot;from&quot; address.
468 # Send-as aliases correspond to the
469 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
470 # feature in the web interface.
471 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
472 # this alias. This is read-only for all operations except create.
473 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
474 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
475 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
476 # Every Gmail account has exactly one primary address, and it cannot be
477 # deleted from the collection of send-as aliases. This field is read-only.
478 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
479 # alias in the Gmail web UI.
480 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
481 # situations such as composing a new message or sending a vacation
482 # auto-reply. Every Gmail account has exactly one default send-as address,
483 # so the only legal value that clients may write to this field is
484 # `true`. Changing this from `false` to
485 # `true` for an address will result in this field becoming
486 # `false` for the other previous default address.
487 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
488 # sent using this alias. If this is empty, Gmail will not generate a
489 # &quot;Reply-To:&quot; header.
490 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
491 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
492 # &quot;From:&quot; header with the name that is used for the primary address
493 # associated with the account.
494 # If the admin has disabled the ability for users to update their name
495 # format, requests to update this field for the primary login will silently
496 # fail.
497 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
498 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
499 # This setting only applies to custom &quot;from&quot; aliases.
500 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
501 # sent using this alias. If this is empty, outbound mail will be sent
502 # directly from Gmail&#x27;s servers to the destination SMTP service. This
503 # setting only applies to custom &quot;from&quot; aliases.
504 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
505 # This is a write-only field that can be specified in requests to create or
506 # update SendAs settings; it is never populated in responses.
507 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
508 # service. Required.
509 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
510 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
511 # This is a write-only field that can be specified in requests to create or
512 # update SendAs settings; it is never populated in responses.
513 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700514 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700515 }</pre>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700516</div>
517
518<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700519 <code class="details" id="update">update(userId, sendAsEmail, body=None, x__xgafv=None)</code>
520 <pre>Updates a send-as alias. If a signature is provided, Gmail will sanitize
521the HTML before saving it with the alias.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700522
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700523Addresses other than the primary address for the account can only be
524updated by service account clients that have been delegated domain-wide
525authority.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400526
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700527Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700528 userId: string, User&#x27;s email address. The special value &quot;me&quot;
529can be used to indicate the authenticated user. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700530 sendAsEmail: string, The send-as alias to be updated. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700531 body: object, The request body.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700532 The object takes the form of:
533
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700534{ # Settings associated with a send-as alias, which can be either the primary
535 # login address associated with the account or a custom &quot;from&quot; address.
536 # Send-as aliases correspond to the
537 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
538 # feature in the web interface.
539 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
540 # this alias. This is read-only for all operations except create.
541 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
542 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
543 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
544 # Every Gmail account has exactly one primary address, and it cannot be
545 # deleted from the collection of send-as aliases. This field is read-only.
546 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
547 # alias in the Gmail web UI.
548 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
549 # situations such as composing a new message or sending a vacation
550 # auto-reply. Every Gmail account has exactly one default send-as address,
551 # so the only legal value that clients may write to this field is
552 # `true`. Changing this from `false` to
553 # `true` for an address will result in this field becoming
554 # `false` for the other previous default address.
555 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
556 # sent using this alias. If this is empty, Gmail will not generate a
557 # &quot;Reply-To:&quot; header.
558 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
559 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
560 # &quot;From:&quot; header with the name that is used for the primary address
561 # associated with the account.
562 # If the admin has disabled the ability for users to update their name
563 # format, requests to update this field for the primary login will silently
564 # fail.
565 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
566 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
567 # This setting only applies to custom &quot;from&quot; aliases.
568 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
569 # sent using this alias. If this is empty, outbound mail will be sent
570 # directly from Gmail&#x27;s servers to the destination SMTP service. This
571 # setting only applies to custom &quot;from&quot; aliases.
572 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
573 # This is a write-only field that can be specified in requests to create or
574 # update SendAs settings; it is never populated in responses.
575 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
576 # service. Required.
577 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
578 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
579 # This is a write-only field that can be specified in requests to create or
580 # update SendAs settings; it is never populated in responses.
581 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700582 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700583 }
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700584
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700585 x__xgafv: string, V1 error format.
586 Allowed values
587 1 - v1 error format
588 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700589
590Returns:
591 An object of the form:
592
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700593 { # Settings associated with a send-as alias, which can be either the primary
594 # login address associated with the account or a custom &quot;from&quot; address.
595 # Send-as aliases correspond to the
596 # &lt;a href=&quot;https://support.google.com/mail/answer/22370&quot;&gt;&quot;Send Mail As&quot;&lt;/a&gt;
597 # feature in the web interface.
598 &quot;sendAsEmail&quot;: &quot;A String&quot;, # The email address that appears in the &quot;From:&quot; header for mail sent using
599 # this alias. This is read-only for all operations except create.
600 &quot;verificationStatus&quot;: &quot;A String&quot;, # Indicates whether this address has been verified for use as a send-as
601 # alias. Read-only. This setting only applies to custom &quot;from&quot; aliases.
602 &quot;isPrimary&quot;: True or False, # Whether this address is the primary address used to login to the account.
603 # Every Gmail account has exactly one primary address, and it cannot be
604 # deleted from the collection of send-as aliases. This field is read-only.
605 &quot;signature&quot;: &quot;A String&quot;, # An optional HTML signature that is included in messages composed with this
606 # alias in the Gmail web UI.
607 &quot;isDefault&quot;: True or False, # Whether this address is selected as the default &quot;From:&quot; address in
608 # situations such as composing a new message or sending a vacation
609 # auto-reply. Every Gmail account has exactly one default send-as address,
610 # so the only legal value that clients may write to this field is
611 # `true`. Changing this from `false` to
612 # `true` for an address will result in this field becoming
613 # `false` for the other previous default address.
614 &quot;replyToAddress&quot;: &quot;A String&quot;, # An optional email address that is included in a &quot;Reply-To:&quot; header for mail
615 # sent using this alias. If this is empty, Gmail will not generate a
616 # &quot;Reply-To:&quot; header.
617 &quot;displayName&quot;: &quot;A String&quot;, # A name that appears in the &quot;From:&quot; header for mail sent using this alias.
618 # For custom &quot;from&quot; addresses, when this is empty, Gmail will populate the
619 # &quot;From:&quot; header with the name that is used for the primary address
620 # associated with the account.
621 # If the admin has disabled the ability for users to update their name
622 # format, requests to update this field for the primary login will silently
623 # fail.
624 &quot;treatAsAlias&quot;: True or False, # Whether Gmail should &lt;a href=&quot;https://support.google.com/a/answer/1710338&quot;&gt;
625 # treat this address as an alias&lt;/a&gt; for the user&#x27;s primary email address.
626 # This setting only applies to custom &quot;from&quot; aliases.
627 &quot;smtpMsa&quot;: { # Configuration for communication with an SMTP service. # An optional SMTP service that will be used as an outbound relay for mail
628 # sent using this alias. If this is empty, outbound mail will be sent
629 # directly from Gmail&#x27;s servers to the destination SMTP service. This
630 # setting only applies to custom &quot;from&quot; aliases.
631 &quot;password&quot;: &quot;A String&quot;, # The password that will be used for authentication with the SMTP service.
632 # This is a write-only field that can be specified in requests to create or
633 # update SendAs settings; it is never populated in responses.
634 &quot;securityMode&quot;: &quot;A String&quot;, # The protocol that will be used to secure communication with the SMTP
635 # service. Required.
636 &quot;host&quot;: &quot;A String&quot;, # The hostname of the SMTP service. Required.
637 &quot;username&quot;: &quot;A String&quot;, # The username that will be used for authentication with the SMTP service.
638 # This is a write-only field that can be specified in requests to create or
639 # update SendAs settings; it is never populated in responses.
640 &quot;port&quot;: 42, # The port of the SMTP service. Required.
Bu Sun Kim65020912020-05-20 12:08:20 -0700641 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700642 }</pre>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700643</div>
644
645<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700646 <code class="details" id="verify">verify(userId, sendAsEmail, x__xgafv=None)</code>
647 <pre>Sends a verification email to the specified send-as alias address.
648The verification status must be `pending`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700649
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700650This method is only available to service account clients that have been
651delegated domain-wide authority.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400652
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700653Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700654 userId: string, User&#x27;s email address. The special value &quot;me&quot;
655can be used to indicate the authenticated user. (required)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700656 sendAsEmail: string, The send-as alias to be verified. (required)
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700657 x__xgafv: string, V1 error format.
658 Allowed values
659 1 - v1 error format
660 2 - v2 error format
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700661</pre>
662</div>
663
664</body></html>