Gmail API 概览
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
Gmail API 是一个 RESTful API,可用于访问 Gmail 邮箱和发送邮件。对于大多数 Web 应用,Gmail API 是授权访问用户的 Gmail 数据的最佳选择,并且适用于各种应用,例如:
- 只读邮件提取、索引和备份
- 自动或程序化消息发送
- 电子邮件帐号迁移
- 电子邮件整理(包括邮件过滤和排序)
- 整个组织中的电子邮件签名标准化
以下是 Gmail API 中使用的常用术语列表:
- 消息
- 包含发件人、收件人、主题和正文的电子邮件。消息创建后,便无法更改。消息由消息资源表示。
- 线程
- 形成会话的相关消息集合。在电子邮件客户端应用中,当一个或多个收件人使用他们自己的消息回复邮件时,就会形成一个会话。
- 标签
一种整理消息和话题的机制。例如,系统可能会创建“税费”标签,并将其应用于与用户税费相关的所有消息和会话。标签有两种:
- 系统标签
- 内部创建的标签,例如
INBOX
、TRASH
或 SPAM
。这些标签无法删除或修改。不过,某些系统标签(如 INBOX
)可以应用于消息和线程,或从中移除。 - 用户标签
- 用户创建的标签。这些标签可以由用户或应用删除或修改。用户标签由标签资源表示。
- 草稿
一条未发送的邮件。您可以替换草稿中包含的邮件。
发送草稿会自动删除草稿,并创建带有 SENT
系统标签的消息。草稿由草稿资源表示。
后续步骤
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2023-01-29 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"没有我需要的信息"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"太复杂/步骤太多"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"内容需要更新"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻译问题"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"示例/代码问题"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"易于理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"解决了我的问题"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]