Get
/api/v1/engagement-dashboard/messages/top-five-popular-channels
Retrieves the top 5 popular channels in your workspace by the number of messages sent. It highlights the number of messages sent in private channels, private chats, and public channels.
Permission required: view-engagement-dashboard
Changelog
Version | Description |
---|---|
3.1.0 | Added |
Header parameters
X-Auth-Token
stringRequired
The token of the authenticated user.
ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired
The user ID of the authenticated user.
ExamplerbAXPnMktTFbNpwtJ
Query parameters
start
stringRequired
The start date.
Example2023-10-29T14:48:00.000Z
end
stringRequired
The end date.
Example2023-11-05T14:48:00.000Z
Responses
200
t
denotes the type of room where the messages are sent. The types of rooms can be any of the following:
d
represents Private Chatsc
represents Public Channelsp
represents Private Channels"
Success Example
{
"channels": [
{
"messages": 727,
"t": "d",
"usernames": [
"google-calendar.bot",
"pavi.kim"
]
},
{
"messages": 26,
"t": "d",
"usernames": [
"fun.baek",
"google-calendar.bot"
]
},
{
"messages": 2,
"t": "d",
"usernames": [
"test.test",
"rocket.cat"
]
},
{
"messages": 1,
"t": "d",
"usernames": [
"ria.mit",
"rocket.cat"
]
},
{
"messages": 1,
"t": "d",
"usernames": [
"janna.coelho",
"rocket.cat"
]
}
],
"success": true
}
object
channels
Array of object
object
messages
integer
t
string
name
string
usernames
Array of object
object
success
boolean
400
Bad Request
Missing key
{
"success": false,
"error": "Match error: Missing key 'start'"
}
Example 2
{
"success": false,
"error": "Match error: Failed Match.Where validation in field start"
}
object
success
boolean
error
string
401
Unauthorized
Authorization Error
{
"status": "error",
"message": "You must be logged in to do this."
}
object
status
string
message
string
403
Forbidden
Permission Error
{
"success": false,
"error": "User does not have the permissions required for this action [error-unauthorized]"
}
object
success
boolean
error
string