Create Channel
https://api.deadsimplechat.com/consumer/api/v1/chatroom/:roodId/channel
Create Channel
info
The auth
query parameter is your private key. You can find it in your Dashboard under Developer -> Private Key.
Create a Channel Inside of a Chat Room
Parameters | Description | |
---|---|---|
Path | ||
roomId | string | roomId of the chat room where you want to create the channel |
Query | ||
auth | string | Go to Dashboard -> Developer -> Private Key is your auth room |
Body | ||
enabled | boolean | set the channel enabled or disabled |
notifyAllUsers | boolean | Whenever a message is sent to this channel do you want to notify all users in the chant room. If this is set to true all users in the chatroom will be notified even if they have never opened the channel, if this is set to false then only the users who have open the channel will be notified of the new messages. |
channelName | string | name of the channel |
metadata | string | metadata of the channel (maximum length: 1000) |
Responses
200
JSON
{
"_id": "65ea3ac1861e60c09f805871",
"channelName": "myChannel",
"enabled": true,
"metadata": "abcpqe",
"notifyAllUsers": false,
"roomId": "MG99xw-79"
}
404
JSON
{
"message": "Invalid auth token"
}