- Returning.AI
- Auth
- Server
- Role
- Channel
- Badge
- Integration
create new channel
Developing
POST
/channels
Request
Header Params
x-api-key
string
required
Body Params application/json
topic
string
required
channelType
string
required
Example
{
"topic": "IC Markets",
"channelType": "open"
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://rai-api.returning.ai/api/v1/channels' \
--header 'x-api-key;' \
--header 'Content-Type: application/json' \
--data-raw '{
"topic": "IC Markets",
"channelType": "open"
}'
Responses
🟢200Success
application/json
Body
meta
object
required
success
boolean
required
message
string
required
devMessage
string
required
body
object
required
title
string
required
permissions
array[string]
required
userId
string
required
serverId
string
required
channelType
string
required
_id
string
required
createdAt
string
required
updatedAt
string
required
__v
integer
required
Example
{
"meta": {
"success": true,
"message": "Channel has been created successfully",
"devMessage": "Channel has been created successfully"
},
"body": {
"topic": "Chit Chat",
"permissions": [],
"userId": "1",
"serverId": "{_id}",
"channelType": "open",
"_id": "{_id}",
"createdAt": "2024-07-25T16:50:17.610Z",
"updatedAt": "2024-07-25T16:50:17.610Z",
"__v": 0
}
}