Method: users.settings.sendAs.list
列出指定账号的“用以下地址发送邮件”别名。结果包括与账号关联的主要“发件人”地址以及任何自定义的“发件人”地址别名。
HTTP 请求
GET https://gmail.googleapis.com/gmail/v1/users/{userId}/settings/sendAs
网址采用 gRPC 转码语法。
路径参数
参数 |
userId |
string
用户的电子邮件地址。特殊值“me”可用于指示通过身份验证的用户。
|
响应正文
对 sendAs.list 方法的响应。
如果成功,响应正文将包含结构如下的数据:
JSON 表示法 |
{
"sendAs": [
{
object (SendAs )
}
]
} |
字段 |
sendAs[] |
object (SendAs )
“用以下地址发送邮件”别名列表。
|
授权范围
需要以下 OAuth 范围之一:
https://www.googleapis.com/auth/gmail.settings.basic
https://mail.google.com/
https://www.googleapis.com/auth/gmail.modify
https://www.googleapis.com/auth/gmail.readonly
有关详情,请参阅授权指南。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-09-05。
[null,null,["最后更新时间 (UTC):2024-09-05。"],[[["Lists send-as aliases, including the primary address and custom \"from\" aliases, for a specified Gmail account."],["Uses an HTTP GET request with the user's email address as a path parameter."],["Returns a JSON response containing an array of send-as aliases with details."],["Requires specific OAuth scopes for authorization, like `gmail.settings.basic` or `gmail.readonly`."]]],["This describes how to retrieve send-as aliases for a Gmail account. Using a `GET` request to `https://gmail.googleapis.com/gmail/v1/users/{userId}/settings/sendAs`, specifying the user's email (or \"me\") in the `userId` path parameter. The request body must be empty. The successful response includes a JSON object with a `sendAs` array, detailing the account's primary send-as address and custom \"from\" aliases. This action requires specific OAuth scopes like `gmail.settings.basic` or `mail.google.com`.\n"]]