Skip to main content
GET
列出会话
按时间倒序列出单个收件箱内的会话。返回 countlimitnext_page_tokenthreads,用 next_page_token 翻页。每条含 thread_idlabelstimestampsendersrecipientssubjectpreviewmessage_countlast_message_idsize 及附件元数据。会话是邮件的归组;要单封邮件用 get_agentmail_inbox_messages。要检索而非翻页用 get_agentmail_inbox_threads_search

示例

授权

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

请求头

Authorization
string
必填

Bearer 身份验证

路径参数

inbox_id
string
必填

收件箱的 ID。

查询参数

limit
integer

返回项目数量的上限。

page_token
string

用于分页的页面 token。

labels
string[]

用于筛选的标签。

before
string<date-time>

用于筛选的截止时间戳。

after
string<date-time>

用于筛选此时间戳之后数据的时间戳。

ascending
boolean

按时间升序排序。

include_spam
boolean

在结果中包含垃圾邮件。

include_blocked
boolean

在结果中包含被屏蔽项。

include_unauthenticated
boolean

在结果中包含未经身份验证的内容。

include_trash
boolean

在结果中包含垃圾内容。

响应

状态码为 200 的响应

count
integer
必填

返回的项目数量。

threads
ThreadItem · object[]
必填

timestamp 降序排列。

limit
integer

返回项目数量的上限。

next_page_token
string

用于分页的页面 token。