List user's chat messages
GET
/chat/users/{userId}/messages
Chat Messages
In the query parameter, you must provide either of the following:
to_contact
: The email address of the contact with whom the user conversed by sending/receiving messages.to_channel
: The channel ID of the channel to/from which the user has sent and/or received messages.Specify a date in the
date
query parameter to view messages from that date. If a date is not provided, the default value for the query will be the current date.Scopes:
chat_message:read
, chat_message:read:admin
Medium
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'http://api.zoom.us/v2/chat/users//messages'
响应示例响应示例
200 - response
{
"date": "2019-09-17",
"messages": [
{
"date_time": "2019-09-17T20:25:21Z",
"id": "F3CbafdljsfjkdfgBA7",
"message": "And you?",
"sender": "myemail@someemailaddr.com",
"timestamp": 1568751921626
},
{
"date_time": "2019-09-17T20:25:17Z",
"id": "B0DbfdgdfhAAfgf237000",
"message": "I am good",
"sender": "myemail@someemailaddr.com",
"timestamp": 1568751917976
},
{
"date_time": "2019-09-17T20:24:13Z",
"id": "C9Bbdfgd4sad301",
"message": "How are you",
"sender": "myfriendsemail@someemailaddr.us",
"timestamp": 1568751853297
},
{
"date_time": "2019-09-17T20:22:26Z",
"id": "769fgdgdfgfd4566F7B96665",
"message": "hello",
"sender": "myfriendsemail@someemailaddr.us",
"timestamp": 1568751746769
}
],
"next_page_token": "",
"page_size": 10
}
请求参数
Path 参数
userId
string
必需
Query 参数
to_contact
string
可选
contact
or channel
as a query parameter to retrieve messages either from an individual or a chat channel.to_channel
string
可选
contact
or channel
as a query parameter to retrieve messages either from an individual or a chat channel.date
string <date>
可选
page_size
integer
可选
<= 50
默认值:
10
next_page_token
string
可选
include_deleted_and_edited_message
string
可选
Set the value of this field to
true
to include edited and deleted messages in the response.