Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(155)

Side by Side Diff: discovery/googleapis/gmail__v1.json

Issue 559053002: Generate 0.1.0 version of googleapis/googleapis_beta (Closed) Base URL: git@github.com:dart-lang/googleapis.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 {
2 "auth": {
3 "oauth2": {
4 "scopes": {
5 "https://mail.google.com/": {
6 "description": "View and manage your mail"
7 },
8 "https://www.googleapis.com/auth/gmail.compose": {
9 "description": "Manage drafts and send emails"
10 },
11 "https://www.googleapis.com/auth/gmail.modify": {
12 "description": "View and modify but not delete your email"
13 },
14 "https://www.googleapis.com/auth/gmail.readonly": {
15 "description": "View your emails messages and settings"
16 }
17 }
18 }
19 },
20 "basePath": "/gmail/v1/users/",
21 "baseUrl": "https://www.googleapis.com/gmail/v1/users/",
22 "batchPath": "batch",
23 "description": "The Gmail REST API.",
24 "discoveryVersion": "v1",
25 "documentationLink": "https://developers.google.com/gmail/api/",
26 "etag": "\"uUWyYHXmEn-ab7WLvo8qNz2S8ws/5fnY39OGLjxI_epC657MRv3fFjE\"",
27 "icons": {
28 "x16": "https://www.google.com/images/icons/product/googlemail-16.png",
29 "x32": "https://www.google.com/images/icons/product/googlemail-32.png"
30 },
31 "id": "gmail:v1",
32 "kind": "discovery#restDescription",
33 "name": "gmail",
34 "ownerDomain": "google.com",
35 "ownerName": "Google",
36 "parameters": {
37 "alt": {
38 "default": "json",
39 "description": "Data format for the response.",
40 "enum": [
41 "json"
42 ],
43 "enumDescriptions": [
44 "Responses with Content-Type of application/json"
45 ],
46 "location": "query",
47 "type": "string"
48 },
49 "fields": {
50 "description": "Selector specifying which fields to include in a par tial response.",
51 "location": "query",
52 "type": "string"
53 },
54 "key": {
55 "description": "API key. Your API key identifies your project and pr ovides you with API access, quota, and reports. Required unless you provide an O Auth 2.0 token.",
56 "location": "query",
57 "type": "string"
58 },
59 "oauth_token": {
60 "description": "OAuth 2.0 token for the current user.",
61 "location": "query",
62 "type": "string"
63 },
64 "prettyPrint": {
65 "default": "true",
66 "description": "Returns response with indentations and line breaks." ,
67 "location": "query",
68 "type": "boolean"
69 },
70 "quotaUser": {
71 "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exc eed 40 characters. Overrides userIp if both are provided.",
72 "location": "query",
73 "type": "string"
74 },
75 "userIp": {
76 "description": "IP address of the site where the request originates. Use this if you want to enforce per-user limits.",
77 "location": "query",
78 "type": "string"
79 }
80 },
81 "protocol": "rest",
82 "resources": {
83 "users": {
84 "resources": {
85 "drafts": {
86 "methods": {
87 "create": {
88 "description": "Creates a new draft with the DRAFT l abel.",
89 "httpMethod": "POST",
90 "id": "gmail.users.drafts.create",
91 "mediaUpload": {
92 "accept": [
93 "message/rfc822"
94 ],
95 "maxSize": "35MB",
96 "protocols": {
97 "resumable": {
98 "multipart": true,
99 "path": "/resumable/upload/gmail/v1/user s/{userId}/drafts"
100 },
101 "simple": {
102 "multipart": true,
103 "path": "/upload/gmail/v1/users/{userId} /drafts"
104 }
105 }
106 },
107 "parameterOrder": [
108 "userId"
109 ],
110 "parameters": {
111 "userId": {
112 "default": "me",
113 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
114 "location": "path",
115 "required": true,
116 "type": "string"
117 }
118 },
119 "path": "{userId}/drafts",
120 "request": {
121 "$ref": "Draft"
122 },
123 "response": {
124 "$ref": "Draft"
125 },
126 "scopes": [
127 "https://mail.google.com/",
128 "https://www.googleapis.com/auth/gmail.compose",
129 "https://www.googleapis.com/auth/gmail.modify"
130 ],
131 "supportsMediaUpload": true
132 },
133 "delete": {
134 "description": "Immediately and permanently deletes the specified draft. Does not simply trash it.",
135 "httpMethod": "DELETE",
136 "id": "gmail.users.drafts.delete",
137 "parameterOrder": [
138 "userId",
139 "id"
140 ],
141 "parameters": {
142 "id": {
143 "description": "The ID of the draft to delet e.",
144 "location": "path",
145 "required": true,
146 "type": "string"
147 },
148 "userId": {
149 "default": "me",
150 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
151 "location": "path",
152 "required": true,
153 "type": "string"
154 }
155 },
156 "path": "{userId}/drafts/{id}",
157 "scopes": [
158 "https://mail.google.com/",
159 "https://www.googleapis.com/auth/gmail.compose",
160 "https://www.googleapis.com/auth/gmail.modify"
161 ]
162 },
163 "get": {
164 "description": "Gets the specified draft.",
165 "httpMethod": "GET",
166 "id": "gmail.users.drafts.get",
167 "parameterOrder": [
168 "userId",
169 "id"
170 ],
171 "parameters": {
172 "format": {
173 "default": "full",
174 "description": "The format to return the dra ft in.",
175 "enum": [
176 "full",
177 "metadata",
178 "minimal",
179 "raw"
180 ],
181 "enumDescriptions": [
182 "",
183 "",
184 "",
185 ""
186 ],
187 "location": "query",
188 "type": "string"
189 },
190 "id": {
191 "description": "The ID of the draft to retri eve.",
192 "location": "path",
193 "required": true,
194 "type": "string"
195 },
196 "userId": {
197 "default": "me",
198 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
199 "location": "path",
200 "required": true,
201 "type": "string"
202 }
203 },
204 "path": "{userId}/drafts/{id}",
205 "response": {
206 "$ref": "Draft"
207 },
208 "scopes": [
209 "https://mail.google.com/",
210 "https://www.googleapis.com/auth/gmail.compose",
211 "https://www.googleapis.com/auth/gmail.modify",
212 "https://www.googleapis.com/auth/gmail.readonly"
213 ]
214 },
215 "list": {
216 "description": "Lists the drafts in the user's mailb ox.",
217 "httpMethod": "GET",
218 "id": "gmail.users.drafts.list",
219 "parameterOrder": [
220 "userId"
221 ],
222 "parameters": {
223 "maxResults": {
224 "default": "100",
225 "description": "Maximum number of drafts to return.",
226 "format": "uint32",
227 "location": "query",
228 "type": "integer"
229 },
230 "pageToken": {
231 "description": "Page token to retrieve a spe cific page of results in the list.",
232 "location": "query",
233 "type": "string"
234 },
235 "userId": {
236 "default": "me",
237 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
238 "location": "path",
239 "required": true,
240 "type": "string"
241 }
242 },
243 "path": "{userId}/drafts",
244 "response": {
245 "$ref": "ListDraftsResponse"
246 },
247 "scopes": [
248 "https://mail.google.com/",
249 "https://www.googleapis.com/auth/gmail.compose",
250 "https://www.googleapis.com/auth/gmail.modify",
251 "https://www.googleapis.com/auth/gmail.readonly"
252 ]
253 },
254 "send": {
255 "description": "Sends the specified, existing draft to the recipients in the To, Cc, and Bcc headers.",
256 "httpMethod": "POST",
257 "id": "gmail.users.drafts.send",
258 "mediaUpload": {
259 "accept": [
260 "message/rfc822"
261 ],
262 "maxSize": "35MB",
263 "protocols": {
264 "resumable": {
265 "multipart": true,
266 "path": "/resumable/upload/gmail/v1/user s/{userId}/drafts/send"
267 },
268 "simple": {
269 "multipart": true,
270 "path": "/upload/gmail/v1/users/{userId} /drafts/send"
271 }
272 }
273 },
274 "parameterOrder": [
275 "userId"
276 ],
277 "parameters": {
278 "userId": {
279 "default": "me",
280 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
281 "location": "path",
282 "required": true,
283 "type": "string"
284 }
285 },
286 "path": "{userId}/drafts/send",
287 "request": {
288 "$ref": "Draft"
289 },
290 "response": {
291 "$ref": "Message"
292 },
293 "scopes": [
294 "https://mail.google.com/",
295 "https://www.googleapis.com/auth/gmail.compose",
296 "https://www.googleapis.com/auth/gmail.modify"
297 ],
298 "supportsMediaUpload": true
299 },
300 "update": {
301 "description": "Replaces a draft's content.",
302 "httpMethod": "PUT",
303 "id": "gmail.users.drafts.update",
304 "mediaUpload": {
305 "accept": [
306 "message/rfc822"
307 ],
308 "maxSize": "35MB",
309 "protocols": {
310 "resumable": {
311 "multipart": true,
312 "path": "/resumable/upload/gmail/v1/user s/{userId}/drafts/{id}"
313 },
314 "simple": {
315 "multipart": true,
316 "path": "/upload/gmail/v1/users/{userId} /drafts/{id}"
317 }
318 }
319 },
320 "parameterOrder": [
321 "userId",
322 "id"
323 ],
324 "parameters": {
325 "id": {
326 "description": "The ID of the draft to updat e.",
327 "location": "path",
328 "required": true,
329 "type": "string"
330 },
331 "userId": {
332 "default": "me",
333 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
334 "location": "path",
335 "required": true,
336 "type": "string"
337 }
338 },
339 "path": "{userId}/drafts/{id}",
340 "request": {
341 "$ref": "Draft"
342 },
343 "response": {
344 "$ref": "Draft"
345 },
346 "scopes": [
347 "https://mail.google.com/",
348 "https://www.googleapis.com/auth/gmail.compose",
349 "https://www.googleapis.com/auth/gmail.modify"
350 ],
351 "supportsMediaUpload": true
352 }
353 }
354 },
355 "history": {
356 "methods": {
357 "list": {
358 "description": "Lists the history of all changes to the given mailbox. History results are returned in chronological order (increasi ng historyId).",
359 "httpMethod": "GET",
360 "id": "gmail.users.history.list",
361 "parameterOrder": [
362 "userId"
363 ],
364 "parameters": {
365 "labelId": {
366 "description": "Only return messages with a label matching the ID.",
367 "location": "query",
368 "type": "string"
369 },
370 "maxResults": {
371 "default": "100",
372 "description": "The maximum number of histor y records to return.",
373 "format": "uint32",
374 "location": "query",
375 "type": "integer"
376 },
377 "pageToken": {
378 "description": "Page token to retrieve a spe cific page of results in the list.",
379 "location": "query",
380 "type": "string"
381 },
382 "startHistoryId": {
383 "description": "Required. Returns history re cords after the specified startHistoryId. The supplied startHistoryId should be obtained from the historyId of a message, thread, or previous list response. His tory IDs increase chronologically but are not contiguous with random gaps in bet ween valid IDs. Supplying an invalid or out of date startHistoryId typically ret urns an HTTP 404 error code. A historyId is typically valid for at least a week, but in some circumstances may be valid for only a few hours. If you receive an HTTP 404 error response, your application should perform a full sync. If you rec eive no nextPageToken in the response, there are no updates to retrieve and you can store the returned historyId for a future request.",
384 "format": "uint64",
385 "location": "query",
386 "type": "string"
387 },
388 "userId": {
389 "default": "me",
390 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
391 "location": "path",
392 "required": true,
393 "type": "string"
394 }
395 },
396 "path": "{userId}/history",
397 "response": {
398 "$ref": "ListHistoryResponse"
399 },
400 "scopes": [
401 "https://mail.google.com/",
402 "https://www.googleapis.com/auth/gmail.modify",
403 "https://www.googleapis.com/auth/gmail.readonly"
404 ]
405 }
406 }
407 },
408 "labels": {
409 "methods": {
410 "create": {
411 "description": "Creates a new label.",
412 "httpMethod": "POST",
413 "id": "gmail.users.labels.create",
414 "parameterOrder": [
415 "userId"
416 ],
417 "parameters": {
418 "userId": {
419 "default": "me",
420 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
421 "location": "path",
422 "required": true,
423 "type": "string"
424 }
425 },
426 "path": "{userId}/labels",
427 "request": {
428 "$ref": "Label"
429 },
430 "response": {
431 "$ref": "Label"
432 },
433 "scopes": [
434 "https://mail.google.com/",
435 "https://www.googleapis.com/auth/gmail.modify"
436 ]
437 },
438 "delete": {
439 "description": "Immediately and permanently deletes the specified label and removes it from any messages and threads that it is appl ied to.",
440 "httpMethod": "DELETE",
441 "id": "gmail.users.labels.delete",
442 "parameterOrder": [
443 "userId",
444 "id"
445 ],
446 "parameters": {
447 "id": {
448 "description": "The ID of the label to delet e.",
449 "location": "path",
450 "required": true,
451 "type": "string"
452 },
453 "userId": {
454 "default": "me",
455 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
456 "location": "path",
457 "required": true,
458 "type": "string"
459 }
460 },
461 "path": "{userId}/labels/{id}",
462 "scopes": [
463 "https://mail.google.com/",
464 "https://www.googleapis.com/auth/gmail.modify"
465 ]
466 },
467 "get": {
468 "description": "Gets the specified label.",
469 "httpMethod": "GET",
470 "id": "gmail.users.labels.get",
471 "parameterOrder": [
472 "userId",
473 "id"
474 ],
475 "parameters": {
476 "id": {
477 "description": "The ID of the label to retri eve.",
478 "location": "path",
479 "required": true,
480 "type": "string"
481 },
482 "userId": {
483 "default": "me",
484 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
485 "location": "path",
486 "required": true,
487 "type": "string"
488 }
489 },
490 "path": "{userId}/labels/{id}",
491 "response": {
492 "$ref": "Label"
493 },
494 "scopes": [
495 "https://mail.google.com/",
496 "https://www.googleapis.com/auth/gmail.modify",
497 "https://www.googleapis.com/auth/gmail.readonly"
498 ]
499 },
500 "list": {
501 "description": "Lists all labels in the user's mailb ox.",
502 "httpMethod": "GET",
503 "id": "gmail.users.labels.list",
504 "parameterOrder": [
505 "userId"
506 ],
507 "parameters": {
508 "userId": {
509 "default": "me",
510 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
511 "location": "path",
512 "required": true,
513 "type": "string"
514 }
515 },
516 "path": "{userId}/labels",
517 "response": {
518 "$ref": "ListLabelsResponse"
519 },
520 "scopes": [
521 "https://mail.google.com/",
522 "https://www.googleapis.com/auth/gmail.modify",
523 "https://www.googleapis.com/auth/gmail.readonly"
524 ]
525 },
526 "patch": {
527 "description": "Updates the specified label. This me thod supports patch semantics.",
528 "httpMethod": "PATCH",
529 "id": "gmail.users.labels.patch",
530 "parameterOrder": [
531 "userId",
532 "id"
533 ],
534 "parameters": {
535 "id": {
536 "description": "The ID of the label to updat e.",
537 "location": "path",
538 "required": true,
539 "type": "string"
540 },
541 "userId": {
542 "default": "me",
543 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
544 "location": "path",
545 "required": true,
546 "type": "string"
547 }
548 },
549 "path": "{userId}/labels/{id}",
550 "request": {
551 "$ref": "Label"
552 },
553 "response": {
554 "$ref": "Label"
555 },
556 "scopes": [
557 "https://mail.google.com/",
558 "https://www.googleapis.com/auth/gmail.modify"
559 ]
560 },
561 "update": {
562 "description": "Updates the specified label.",
563 "httpMethod": "PUT",
564 "id": "gmail.users.labels.update",
565 "parameterOrder": [
566 "userId",
567 "id"
568 ],
569 "parameters": {
570 "id": {
571 "description": "The ID of the label to updat e.",
572 "location": "path",
573 "required": true,
574 "type": "string"
575 },
576 "userId": {
577 "default": "me",
578 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
579 "location": "path",
580 "required": true,
581 "type": "string"
582 }
583 },
584 "path": "{userId}/labels/{id}",
585 "request": {
586 "$ref": "Label"
587 },
588 "response": {
589 "$ref": "Label"
590 },
591 "scopes": [
592 "https://mail.google.com/",
593 "https://www.googleapis.com/auth/gmail.modify"
594 ]
595 }
596 }
597 },
598 "messages": {
599 "methods": {
600 "delete": {
601 "description": "Immediately and permanently deletes the specified message. This operation cannot be undone. Prefer messages.trash in stead.",
602 "httpMethod": "DELETE",
603 "id": "gmail.users.messages.delete",
604 "parameterOrder": [
605 "userId",
606 "id"
607 ],
608 "parameters": {
609 "id": {
610 "description": "The ID of the message to del ete.",
611 "location": "path",
612 "required": true,
613 "type": "string"
614 },
615 "userId": {
616 "default": "me",
617 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
618 "location": "path",
619 "required": true,
620 "type": "string"
621 }
622 },
623 "path": "{userId}/messages/{id}",
624 "scopes": [
625 "https://mail.google.com/"
626 ]
627 },
628 "get": {
629 "description": "Gets the specified message.",
630 "httpMethod": "GET",
631 "id": "gmail.users.messages.get",
632 "parameterOrder": [
633 "userId",
634 "id"
635 ],
636 "parameters": {
637 "format": {
638 "default": "full",
639 "description": "The format to return the mes sage in.",
640 "enum": [
641 "full",
642 "metadata",
643 "minimal",
644 "raw"
645 ],
646 "enumDescriptions": [
647 "",
648 "",
649 "",
650 ""
651 ],
652 "location": "query",
653 "type": "string"
654 },
655 "id": {
656 "description": "The ID of the message to ret rieve.",
657 "location": "path",
658 "required": true,
659 "type": "string"
660 },
661 "metadataHeaders": {
662 "description": "When given and format is MET ADATA, only include headers specified.",
663 "location": "query",
664 "repeated": true,
665 "type": "string"
666 },
667 "userId": {
668 "default": "me",
669 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
670 "location": "path",
671 "required": true,
672 "type": "string"
673 }
674 },
675 "path": "{userId}/messages/{id}",
676 "response": {
677 "$ref": "Message"
678 },
679 "scopes": [
680 "https://mail.google.com/",
681 "https://www.googleapis.com/auth/gmail.modify",
682 "https://www.googleapis.com/auth/gmail.readonly"
683 ]
684 },
685 "import": {
686 "description": "Imports a message into only this use r's mailbox, with standard email delivery scanning and classification similar to receiving via SMTP. Does not send a message.",
687 "httpMethod": "POST",
688 "id": "gmail.users.messages.import",
689 "mediaUpload": {
690 "accept": [
691 "message/rfc822"
692 ],
693 "maxSize": "35MB",
694 "protocols": {
695 "resumable": {
696 "multipart": true,
697 "path": "/resumable/upload/gmail/v1/user s/{userId}/messages/import"
698 },
699 "simple": {
700 "multipart": true,
701 "path": "/upload/gmail/v1/users/{userId} /messages/import"
702 }
703 }
704 },
705 "parameterOrder": [
706 "userId"
707 ],
708 "parameters": {
709 "internalDateSource": {
710 "description": "Source for Gmail's internal date of the message.",
711 "enum": [
712 "dateHeader",
713 "receivedTime"
714 ],
715 "enumDescriptions": [
716 "",
717 ""
718 ],
719 "location": "query",
720 "type": "string"
721 },
722 "userId": {
723 "default": "me",
724 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
725 "location": "path",
726 "required": true,
727 "type": "string"
728 }
729 },
730 "path": "{userId}/messages/import",
731 "request": {
732 "$ref": "Message"
733 },
734 "response": {
735 "$ref": "Message"
736 },
737 "scopes": [
738 "https://mail.google.com/",
739 "https://www.googleapis.com/auth/gmail.modify"
740 ],
741 "supportsMediaUpload": true
742 },
743 "insert": {
744 "description": "Directly inserts a message into only this user's mailbox similar to IMAP APPEND, bypassing most scanning and classif ication. Does not send a message.",
745 "httpMethod": "POST",
746 "id": "gmail.users.messages.insert",
747 "mediaUpload": {
748 "accept": [
749 "message/rfc822"
750 ],
751 "maxSize": "35MB",
752 "protocols": {
753 "resumable": {
754 "multipart": true,
755 "path": "/resumable/upload/gmail/v1/user s/{userId}/messages"
756 },
757 "simple": {
758 "multipart": true,
759 "path": "/upload/gmail/v1/users/{userId} /messages"
760 }
761 }
762 },
763 "parameterOrder": [
764 "userId"
765 ],
766 "parameters": {
767 "internalDateSource": {
768 "description": "Source for Gmail's internal date of the message.",
769 "enum": [
770 "dateHeader",
771 "receivedTime"
772 ],
773 "enumDescriptions": [
774 "",
775 ""
776 ],
777 "location": "query",
778 "type": "string"
779 },
780 "userId": {
781 "default": "me",
782 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
783 "location": "path",
784 "required": true,
785 "type": "string"
786 }
787 },
788 "path": "{userId}/messages",
789 "request": {
790 "$ref": "Message"
791 },
792 "response": {
793 "$ref": "Message"
794 },
795 "scopes": [
796 "https://mail.google.com/",
797 "https://www.googleapis.com/auth/gmail.modify"
798 ],
799 "supportsMediaUpload": true
800 },
801 "list": {
802 "description": "Lists the messages in the user's mai lbox.",
803 "httpMethod": "GET",
804 "id": "gmail.users.messages.list",
805 "parameterOrder": [
806 "userId"
807 ],
808 "parameters": {
809 "includeSpamTrash": {
810 "default": "false",
811 "description": "Include messages from SPAM a nd TRASH in the results.",
812 "location": "query",
813 "type": "boolean"
814 },
815 "labelIds": {
816 "description": "Only return messages with la bels that match all of the specified label IDs.",
817 "location": "query",
818 "repeated": true,
819 "type": "string"
820 },
821 "maxResults": {
822 "default": "100",
823 "description": "Maximum number of messages t o return.",
824 "format": "uint32",
825 "location": "query",
826 "type": "integer"
827 },
828 "pageToken": {
829 "description": "Page token to retrieve a spe cific page of results in the list.",
830 "location": "query",
831 "type": "string"
832 },
833 "q": {
834 "description": "Only return messages matchin g the specified query. Supports the same query format as the Gmail search box. F or example, \"from:someuser@example.com rfc822msgid: is:unread\".",
835 "location": "query",
836 "type": "string"
837 },
838 "userId": {
839 "default": "me",
840 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
841 "location": "path",
842 "required": true,
843 "type": "string"
844 }
845 },
846 "path": "{userId}/messages",
847 "response": {
848 "$ref": "ListMessagesResponse"
849 },
850 "scopes": [
851 "https://mail.google.com/",
852 "https://www.googleapis.com/auth/gmail.modify",
853 "https://www.googleapis.com/auth/gmail.readonly"
854 ]
855 },
856 "modify": {
857 "description": "Modifies the labels on the specified message.",
858 "httpMethod": "POST",
859 "id": "gmail.users.messages.modify",
860 "parameterOrder": [
861 "userId",
862 "id"
863 ],
864 "parameters": {
865 "id": {
866 "description": "The ID of the message to mod ify.",
867 "location": "path",
868 "required": true,
869 "type": "string"
870 },
871 "userId": {
872 "default": "me",
873 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
874 "location": "path",
875 "required": true,
876 "type": "string"
877 }
878 },
879 "path": "{userId}/messages/{id}/modify",
880 "request": {
881 "$ref": "ModifyMessageRequest"
882 },
883 "response": {
884 "$ref": "Message"
885 },
886 "scopes": [
887 "https://mail.google.com/",
888 "https://www.googleapis.com/auth/gmail.modify"
889 ]
890 },
891 "send": {
892 "description": "Sends the specified message to the r ecipients in the To, Cc, and Bcc headers.",
893 "httpMethod": "POST",
894 "id": "gmail.users.messages.send",
895 "mediaUpload": {
896 "accept": [
897 "message/rfc822"
898 ],
899 "maxSize": "35MB",
900 "protocols": {
901 "resumable": {
902 "multipart": true,
903 "path": "/resumable/upload/gmail/v1/user s/{userId}/messages/send"
904 },
905 "simple": {
906 "multipart": true,
907 "path": "/upload/gmail/v1/users/{userId} /messages/send"
908 }
909 }
910 },
911 "parameterOrder": [
912 "userId"
913 ],
914 "parameters": {
915 "userId": {
916 "default": "me",
917 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
918 "location": "path",
919 "required": true,
920 "type": "string"
921 }
922 },
923 "path": "{userId}/messages/send",
924 "request": {
925 "$ref": "Message"
926 },
927 "response": {
928 "$ref": "Message"
929 },
930 "scopes": [
931 "https://mail.google.com/",
932 "https://www.googleapis.com/auth/gmail.compose",
933 "https://www.googleapis.com/auth/gmail.modify"
934 ],
935 "supportsMediaUpload": true
936 },
937 "trash": {
938 "description": "Moves the specified message to the t rash.",
939 "httpMethod": "POST",
940 "id": "gmail.users.messages.trash",
941 "parameterOrder": [
942 "userId",
943 "id"
944 ],
945 "parameters": {
946 "id": {
947 "description": "The ID of the message to Tra sh.",
948 "location": "path",
949 "required": true,
950 "type": "string"
951 },
952 "userId": {
953 "default": "me",
954 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
955 "location": "path",
956 "required": true,
957 "type": "string"
958 }
959 },
960 "path": "{userId}/messages/{id}/trash",
961 "response": {
962 "$ref": "Message"
963 },
964 "scopes": [
965 "https://mail.google.com/",
966 "https://www.googleapis.com/auth/gmail.modify"
967 ]
968 },
969 "untrash": {
970 "description": "Removes the specified message from t he trash.",
971 "httpMethod": "POST",
972 "id": "gmail.users.messages.untrash",
973 "parameterOrder": [
974 "userId",
975 "id"
976 ],
977 "parameters": {
978 "id": {
979 "description": "The ID of the message to rem ove from Trash.",
980 "location": "path",
981 "required": true,
982 "type": "string"
983 },
984 "userId": {
985 "default": "me",
986 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
987 "location": "path",
988 "required": true,
989 "type": "string"
990 }
991 },
992 "path": "{userId}/messages/{id}/untrash",
993 "response": {
994 "$ref": "Message"
995 },
996 "scopes": [
997 "https://mail.google.com/",
998 "https://www.googleapis.com/auth/gmail.modify"
999 ]
1000 }
1001 },
1002 "resources": {
1003 "attachments": {
1004 "methods": {
1005 "get": {
1006 "description": "Gets the specified message a ttachment.",
1007 "httpMethod": "GET",
1008 "id": "gmail.users.messages.attachments.get" ,
1009 "parameterOrder": [
1010 "userId",
1011 "messageId",
1012 "id"
1013 ],
1014 "parameters": {
1015 "id": {
1016 "description": "The ID of the attach ment.",
1017 "location": "path",
1018 "required": true,
1019 "type": "string"
1020 },
1021 "messageId": {
1022 "description": "The ID of the messag e containing the attachment.",
1023 "location": "path",
1024 "required": true,
1025 "type": "string"
1026 },
1027 "userId": {
1028 "default": "me",
1029 "description": "The user's email add ress. The special value me can be used to indicate the authenticated user.",
1030 "location": "path",
1031 "required": true,
1032 "type": "string"
1033 }
1034 },
1035 "path": "{userId}/messages/{messageId}/attac hments/{id}",
1036 "response": {
1037 "$ref": "MessagePartBody"
1038 },
1039 "scopes": [
1040 "https://mail.google.com/",
1041 "https://www.googleapis.com/auth/gmail.m odify",
1042 "https://www.googleapis.com/auth/gmail.r eadonly"
1043 ]
1044 }
1045 }
1046 }
1047 }
1048 },
1049 "threads": {
1050 "methods": {
1051 "delete": {
1052 "description": "Immediately and permanently deletes the specified thread. This operation cannot be undone. Prefer threads.trash inst ead.",
1053 "httpMethod": "DELETE",
1054 "id": "gmail.users.threads.delete",
1055 "parameterOrder": [
1056 "userId",
1057 "id"
1058 ],
1059 "parameters": {
1060 "id": {
1061 "description": "ID of the Thread to delete." ,
1062 "location": "path",
1063 "required": true,
1064 "type": "string"
1065 },
1066 "userId": {
1067 "default": "me",
1068 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1069 "location": "path",
1070 "required": true,
1071 "type": "string"
1072 }
1073 },
1074 "path": "{userId}/threads/{id}",
1075 "scopes": [
1076 "https://mail.google.com/"
1077 ]
1078 },
1079 "get": {
1080 "description": "Gets the specified thread.",
1081 "httpMethod": "GET",
1082 "id": "gmail.users.threads.get",
1083 "parameterOrder": [
1084 "userId",
1085 "id"
1086 ],
1087 "parameters": {
1088 "id": {
1089 "description": "The ID of the thread to retr ieve.",
1090 "location": "path",
1091 "required": true,
1092 "type": "string"
1093 },
1094 "userId": {
1095 "default": "me",
1096 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1097 "location": "path",
1098 "required": true,
1099 "type": "string"
1100 }
1101 },
1102 "path": "{userId}/threads/{id}",
1103 "response": {
1104 "$ref": "Thread"
1105 },
1106 "scopes": [
1107 "https://mail.google.com/",
1108 "https://www.googleapis.com/auth/gmail.modify",
1109 "https://www.googleapis.com/auth/gmail.readonly"
1110 ]
1111 },
1112 "list": {
1113 "description": "Lists the threads in the user's mail box.",
1114 "httpMethod": "GET",
1115 "id": "gmail.users.threads.list",
1116 "parameterOrder": [
1117 "userId"
1118 ],
1119 "parameters": {
1120 "includeSpamTrash": {
1121 "default": "false",
1122 "description": "Include threads from SPAM an d TRASH in the results.",
1123 "location": "query",
1124 "type": "boolean"
1125 },
1126 "labelIds": {
1127 "description": "Only return threads with lab els that match all of the specified label IDs.",
1128 "location": "query",
1129 "repeated": true,
1130 "type": "string"
1131 },
1132 "maxResults": {
1133 "default": "100",
1134 "description": "Maximum number of threads to return.",
1135 "format": "uint32",
1136 "location": "query",
1137 "type": "integer"
1138 },
1139 "pageToken": {
1140 "description": "Page token to retrieve a spe cific page of results in the list.",
1141 "location": "query",
1142 "type": "string"
1143 },
1144 "q": {
1145 "description": "Only return threads matching the specified query. Supports the same query format as the Gmail search box. Fo r example, \"from:someuser@example.com rfc822msgid: is:unread\".",
1146 "location": "query",
1147 "type": "string"
1148 },
1149 "userId": {
1150 "default": "me",
1151 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1152 "location": "path",
1153 "required": true,
1154 "type": "string"
1155 }
1156 },
1157 "path": "{userId}/threads",
1158 "response": {
1159 "$ref": "ListThreadsResponse"
1160 },
1161 "scopes": [
1162 "https://mail.google.com/",
1163 "https://www.googleapis.com/auth/gmail.modify",
1164 "https://www.googleapis.com/auth/gmail.readonly"
1165 ]
1166 },
1167 "modify": {
1168 "description": "Modifies the labels applied to the t hread. This applies to all messages in the thread.",
1169 "httpMethod": "POST",
1170 "id": "gmail.users.threads.modify",
1171 "parameterOrder": [
1172 "userId",
1173 "id"
1174 ],
1175 "parameters": {
1176 "id": {
1177 "description": "The ID of the thread to modi fy.",
1178 "location": "path",
1179 "required": true,
1180 "type": "string"
1181 },
1182 "userId": {
1183 "default": "me",
1184 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1185 "location": "path",
1186 "required": true,
1187 "type": "string"
1188 }
1189 },
1190 "path": "{userId}/threads/{id}/modify",
1191 "request": {
1192 "$ref": "ModifyThreadRequest"
1193 },
1194 "response": {
1195 "$ref": "Thread"
1196 },
1197 "scopes": [
1198 "https://mail.google.com/",
1199 "https://www.googleapis.com/auth/gmail.modify"
1200 ]
1201 },
1202 "trash": {
1203 "description": "Moves the specified thread to the tr ash.",
1204 "httpMethod": "POST",
1205 "id": "gmail.users.threads.trash",
1206 "parameterOrder": [
1207 "userId",
1208 "id"
1209 ],
1210 "parameters": {
1211 "id": {
1212 "description": "The ID of the thread to Tras h.",
1213 "location": "path",
1214 "required": true,
1215 "type": "string"
1216 },
1217 "userId": {
1218 "default": "me",
1219 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1220 "location": "path",
1221 "required": true,
1222 "type": "string"
1223 }
1224 },
1225 "path": "{userId}/threads/{id}/trash",
1226 "response": {
1227 "$ref": "Thread"
1228 },
1229 "scopes": [
1230 "https://mail.google.com/",
1231 "https://www.googleapis.com/auth/gmail.modify"
1232 ]
1233 },
1234 "untrash": {
1235 "description": "Removes the specified thread from th e trash.",
1236 "httpMethod": "POST",
1237 "id": "gmail.users.threads.untrash",
1238 "parameterOrder": [
1239 "userId",
1240 "id"
1241 ],
1242 "parameters": {
1243 "id": {
1244 "description": "The ID of the thread to remo ve from Trash.",
1245 "location": "path",
1246 "required": true,
1247 "type": "string"
1248 },
1249 "userId": {
1250 "default": "me",
1251 "description": "The user's email address. Th e special value me can be used to indicate the authenticated user.",
1252 "location": "path",
1253 "required": true,
1254 "type": "string"
1255 }
1256 },
1257 "path": "{userId}/threads/{id}/untrash",
1258 "response": {
1259 "$ref": "Thread"
1260 },
1261 "scopes": [
1262 "https://mail.google.com/",
1263 "https://www.googleapis.com/auth/gmail.modify"
1264 ]
1265 }
1266 }
1267 }
1268 }
1269 }
1270 },
1271 "revision": "20140902",
1272 "rootUrl": "https://www.googleapis.com/",
1273 "schemas": {
1274 "Draft": {
1275 "description": "A draft email in the user's mailbox.",
1276 "id": "Draft",
1277 "properties": {
1278 "id": {
1279 "annotations": {
1280 "required": [
1281 "gmail.users.drafts.send"
1282 ]
1283 },
1284 "description": "The immutable ID of the draft.",
1285 "type": "string"
1286 },
1287 "message": {
1288 "$ref": "Message",
1289 "description": "The message content of the draft."
1290 }
1291 },
1292 "type": "object"
1293 },
1294 "History": {
1295 "description": "A record of a change to the user's mailbox. Each his tory contains a list of the messages that were affected by this change.",
1296 "id": "History",
1297 "properties": {
1298 "id": {
1299 "description": "The mailbox sequence ID.",
1300 "format": "uint64",
1301 "type": "string"
1302 },
1303 "messages": {
1304 "description": "The messages that changed in this history re cord.",
1305 "items": {
1306 "$ref": "Message"
1307 },
1308 "type": "array"
1309 }
1310 },
1311 "type": "object"
1312 },
1313 "Label": {
1314 "description": "Labels are used to categorize messages and threads w ithin the user's mailbox.",
1315 "id": "Label",
1316 "properties": {
1317 "id": {
1318 "annotations": {
1319 "required": [
1320 "gmail.users.labels.update"
1321 ]
1322 },
1323 "description": "The immutable ID of the label.",
1324 "type": "string"
1325 },
1326 "labelListVisibility": {
1327 "annotations": {
1328 "required": [
1329 "gmail.users.labels.create",
1330 "gmail.users.labels.update"
1331 ]
1332 },
1333 "description": "The visibility of the label in the label lis t in the Gmail web interface.",
1334 "enum": [
1335 "labelHide",
1336 "labelShow",
1337 "labelShowIfUnread"
1338 ],
1339 "enumDescriptions": [
1340 "",
1341 "",
1342 ""
1343 ],
1344 "type": "string"
1345 },
1346 "messageListVisibility": {
1347 "annotations": {
1348 "required": [
1349 "gmail.users.labels.create",
1350 "gmail.users.labels.update"
1351 ]
1352 },
1353 "description": "The visibility of the label in the message l ist in the Gmail web interface.",
1354 "enum": [
1355 "hide",
1356 "show"
1357 ],
1358 "enumDescriptions": [
1359 "",
1360 ""
1361 ],
1362 "type": "string"
1363 },
1364 "name": {
1365 "annotations": {
1366 "required": [
1367 "gmail.users.labels.create",
1368 "gmail.users.labels.update"
1369 ]
1370 },
1371 "description": "The display name of the label.",
1372 "type": "string"
1373 },
1374 "type": {
1375 "description": "The owner type for the label. User labels ar e created by the user and can be modified and deleted by the user and can be app lied to any message or thread. System labels are internally created and cannot b e added, modified, or deleted. System labels may be able to be applied to or rem oved from messages and threads under some circumstances but this is not guarante ed. For example, users can apply and remove the INBOX and UNREAD labels from mes sages and threads, but cannot apply or remove the DRAFTS or SENT labels from mes sages or threads.",
1376 "enum": [
1377 "system",
1378 "user"
1379 ],
1380 "enumDescriptions": [
1381 "",
1382 ""
1383 ],
1384 "type": "string"
1385 }
1386 },
1387 "type": "object"
1388 },
1389 "ListDraftsResponse": {
1390 "id": "ListDraftsResponse",
1391 "properties": {
1392 "drafts": {
1393 "description": "List of drafts.",
1394 "items": {
1395 "$ref": "Draft"
1396 },
1397 "type": "array"
1398 },
1399 "nextPageToken": {
1400 "description": "Token to retrieve the next page of results i n the list.",
1401 "type": "string"
1402 },
1403 "resultSizeEstimate": {
1404 "description": "Estimated total number of results.",
1405 "format": "uint32",
1406 "type": "integer"
1407 }
1408 },
1409 "type": "object"
1410 },
1411 "ListHistoryResponse": {
1412 "id": "ListHistoryResponse",
1413 "properties": {
1414 "history": {
1415 "description": "List of history records.",
1416 "items": {
1417 "$ref": "History"
1418 },
1419 "type": "array"
1420 },
1421 "historyId": {
1422 "description": "The ID of the mailbox's current history reco rd.",
1423 "format": "uint64",
1424 "type": "string"
1425 },
1426 "nextPageToken": {
1427 "description": "Page token to retrieve the next page of resu lts in the list.",
1428 "type": "string"
1429 }
1430 },
1431 "type": "object"
1432 },
1433 "ListLabelsResponse": {
1434 "id": "ListLabelsResponse",
1435 "properties": {
1436 "labels": {
1437 "description": "List of labels.",
1438 "items": {
1439 "$ref": "Label"
1440 },
1441 "type": "array"
1442 }
1443 },
1444 "type": "object"
1445 },
1446 "ListMessagesResponse": {
1447 "id": "ListMessagesResponse",
1448 "properties": {
1449 "messages": {
1450 "description": "List of messages.",
1451 "items": {
1452 "$ref": "Message"
1453 },
1454 "type": "array"
1455 },
1456 "nextPageToken": {
1457 "description": "Token to retrieve the next page of results i n the list.",
1458 "type": "string"
1459 },
1460 "resultSizeEstimate": {
1461 "description": "Estimated total number of results.",
1462 "format": "uint32",
1463 "type": "integer"
1464 }
1465 },
1466 "type": "object"
1467 },
1468 "ListThreadsResponse": {
1469 "id": "ListThreadsResponse",
1470 "properties": {
1471 "nextPageToken": {
1472 "description": "Page token to retrieve the next page of resu lts in the list.",
1473 "type": "string"
1474 },
1475 "resultSizeEstimate": {
1476 "description": "Estimated total number of results.",
1477 "format": "uint32",
1478 "type": "integer"
1479 },
1480 "threads": {
1481 "description": "List of threads.",
1482 "items": {
1483 "$ref": "Thread"
1484 },
1485 "type": "array"
1486 }
1487 },
1488 "type": "object"
1489 },
1490 "Message": {
1491 "description": "An email message.",
1492 "id": "Message",
1493 "properties": {
1494 "historyId": {
1495 "description": "The ID of the last history record that modif ied this message.",
1496 "format": "uint64",
1497 "type": "string"
1498 },
1499 "id": {
1500 "description": "The immutable ID of the message.",
1501 "type": "string"
1502 },
1503 "labelIds": {
1504 "description": "List of IDs of labels applied to this messag e.",
1505 "items": {
1506 "type": "string"
1507 },
1508 "type": "array"
1509 },
1510 "payload": {
1511 "$ref": "MessagePart",
1512 "description": "The parsed email structure in the message pa rts."
1513 },
1514 "raw": {
1515 "annotations": {
1516 "required": [
1517 "gmail.users.drafts.create",
1518 "gmail.users.drafts.update",
1519 "gmail.users.messages.insert",
1520 "gmail.users.messages.send"
1521 ]
1522 },
1523 "description": "The entire email message in an RFC 2822 form atted and URL-safe base64 encoded string. Returned in messages.get and drafts.ge t responses when the format=RAW parameter is supplied.",
1524 "format": "byte",
1525 "type": "string"
1526 },
1527 "sizeEstimate": {
1528 "description": "Estimated size in bytes of the message.",
1529 "format": "int32",
1530 "type": "integer"
1531 },
1532 "snippet": {
1533 "description": "A short part of the message text.",
1534 "type": "string"
1535 },
1536 "threadId": {
1537 "description": "The ID of the thread the message belongs to. To add a message or draft to a thread, the following criteria must be met: \n- The requested threadId must be specified on the Message or Draft.Message you sup ply with your request. \n- The References and In-Reply-To headers must be set in compliance with the <a href=\"https://tools.ietf.org/html/rfc2822\"RFC 2822 sta ndard. \n- The Subject headers must match.",
1538 "type": "string"
1539 }
1540 },
1541 "type": "object"
1542 },
1543 "MessagePart": {
1544 "description": "A single MIME message part.",
1545 "id": "MessagePart",
1546 "properties": {
1547 "body": {
1548 "$ref": "MessagePartBody",
1549 "description": "The message part body for this part, which m ay be empty for container MIME message parts."
1550 },
1551 "filename": {
1552 "description": "The filename of the attachment. Only present if this message part represents an attachment.",
1553 "type": "string"
1554 },
1555 "headers": {
1556 "description": "List of headers on this message part. For th e top-level message part, representing the entire message payload, it will conta in the standard RFC 2822 email headers such as To, From, and Subject.",
1557 "items": {
1558 "$ref": "MessagePartHeader"
1559 },
1560 "type": "array"
1561 },
1562 "mimeType": {
1563 "description": "The MIME type of the message part.",
1564 "type": "string"
1565 },
1566 "partId": {
1567 "description": "The immutable ID of the message part.",
1568 "type": "string"
1569 },
1570 "parts": {
1571 "description": "The child MIME message parts of this part. T his only applies to container MIME message parts, for example multipart/*. For n on- container MIME message part types, such as text/plain, this field is empty. For more information, see RFC 1521.",
1572 "items": {
1573 "$ref": "MessagePart"
1574 },
1575 "type": "array"
1576 }
1577 },
1578 "type": "object"
1579 },
1580 "MessagePartBody": {
1581 "description": "The body of a single MIME message part.",
1582 "id": "MessagePartBody",
1583 "properties": {
1584 "attachmentId": {
1585 "description": "When present, contains the ID of an external attachment that can be retrieved in a separate messages.attachments.get request . When not present, the entire content of the message part body is contained in the data field.",
1586 "type": "string"
1587 },
1588 "data": {
1589 "description": "The body data of a MIME message part. May be empty for MIME container types that have no message body or when the body data is sent as a separate attachment. An attachment ID is present if the body data i s contained in a separate attachment.",
1590 "format": "byte",
1591 "type": "string"
1592 },
1593 "size": {
1594 "description": "Total number of bytes in the body of the mes sage part.",
1595 "format": "int32",
1596 "type": "integer"
1597 }
1598 },
1599 "type": "object"
1600 },
1601 "MessagePartHeader": {
1602 "id": "MessagePartHeader",
1603 "properties": {
1604 "name": {
1605 "description": "The name of the header before the : separato r. For example, To.",
1606 "type": "string"
1607 },
1608 "value": {
1609 "description": "The value of the header after the : separato r. For example, someuser@example.com.",
1610 "type": "string"
1611 }
1612 },
1613 "type": "object"
1614 },
1615 "ModifyMessageRequest": {
1616 "id": "ModifyMessageRequest",
1617 "properties": {
1618 "addLabelIds": {
1619 "description": "A list of IDs of labels to add to this messa ge.",
1620 "items": {
1621 "type": "string"
1622 },
1623 "type": "array"
1624 },
1625 "removeLabelIds": {
1626 "description": "A list IDs of labels to remove from this mes sage.",
1627 "items": {
1628 "type": "string"
1629 },
1630 "type": "array"
1631 }
1632 },
1633 "type": "object"
1634 },
1635 "ModifyThreadRequest": {
1636 "id": "ModifyThreadRequest",
1637 "properties": {
1638 "addLabelIds": {
1639 "description": "A list of IDs of labels to add to this threa d.",
1640 "items": {
1641 "type": "string"
1642 },
1643 "type": "array"
1644 },
1645 "removeLabelIds": {
1646 "description": "A list of IDs of labels to remove from this thread.",
1647 "items": {
1648 "type": "string"
1649 },
1650 "type": "array"
1651 }
1652 },
1653 "type": "object"
1654 },
1655 "Thread": {
1656 "description": "A collection of messages representing a conversation .",
1657 "id": "Thread",
1658 "properties": {
1659 "historyId": {
1660 "description": "The ID of the last history record that modif ied this thread.",
1661 "format": "uint64",
1662 "type": "string"
1663 },
1664 "id": {
1665 "description": "The unique ID of the thread.",
1666 "type": "string"
1667 },
1668 "messages": {
1669 "description": "The list of messages in the thread.",
1670 "items": {
1671 "$ref": "Message"
1672 },
1673 "type": "array"
1674 },
1675 "snippet": {
1676 "description": "A short part of the message text.",
1677 "type": "string"
1678 }
1679 },
1680 "type": "object"
1681 }
1682 },
1683 "servicePath": "gmail/v1/users/",
1684 "title": "Gmail API",
1685 "version": "v1"
1686 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698