Post
/api/v1/groups.rename
Rename a private channel. Permission required: edit-room
Changelog
Version | Description |
---|---|
0.48.0 | Added |
Header parameters
X-Auth-Token
stringRequired
The authToken
of the authenticated user.
ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired
The userId
of the authenticated user.
ExamplerbAXPnMktTFbNpwtJ
Body parameters
Example
{
"roomId": "ByehQjC44FwMeiLbX",
"name": "new-name"
}
object
roomId
string Required
The private group's ID. You can find the IDs by using any of the following endpoints:
- Get List of User Groups: This endpoint returns all private channels in the workspace, if you have the required permissions to view them.
- Get Groups: This endpoint returns the private channels that you are a member of.
name
string Required
The new name of the private group. It can not be the same as another or the existing name.
Responses
200
OK
Success
{
"group": {
"_id": "ByehQjC44FwMeiLbX",
"name": "new-name",
"t": "p",
"usernames": [
"testing1"
],
"msgs": 4,
"u": {
"_id": "aobEdbYhXfu5hkeqG",
"username": "testing1"
},
"ts": "2016-12-09T15:08:58.042Z",
"ro": false,
"sysMes": true,
"_updatedAt": "2016-12-09T15:57:44.686Z"
},
"success": true
}
object
group
object
_id
string
name
string
t
string
usernames
Array of string
string
msgs
integer
u
object
_id
string
username
string
ts
string
ro
boolean
sysMes
boolean
_updatedAt
string
success
boolean