Set Group as Encrypted
- Print
- DarkLight
- PDF
Set Group as Encrypted
- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
Post
/api/v1/groups.setEncrypted
Set group encryption.
Changelog
Version | Description |
---|---|
3.13.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
{
"encrypted": false,
"roomId": "JZ8Y2dLfYhsg323Rf"
}
object
encrypted
boolean Required
Whether or not to encrypt the room.
roomId
string
The group ID. Alternatively, use the roomName
parameter and enter the group name.
Responses
200
OK
Success
{
"group": {
"_id": "JZ8Y2dLfYhsg323Rf",
"fname": "test",
"description": "",
"broadcast": false,
"encrypted": false,
"teamMain": true,
"name": "test",
"t": "p",
"msgs": 0,
"usersCount": 1,
"u": {
"_id": "d26x6zSkaPSe5gCyy",
"username": "rodriq"
},
"ts": "2021-10-22T11:59:17.029Z",
"ro": false,
"teamId": "6172a795c563fc000acc4629",
"_updatedAt": "2021-10-22T12:00:11.496Z"
},
"success": true
}
object
group
object
_id
string
fname
string
description
string
broadcast
boolean
encrypted
boolean
teamMain
boolean
name
string
t
string
msgs
integer
usersCount
integer
u
object
_id
string
username
string
ts
string
ro
boolean
teamId
string
_updatedAt
string
success
boolean
400
Bad Request
Invalid RoomId or RoomName
{
"success": false,
"error": "The required \"roomId\" or \"roomName\" param provided does not match any group [error-room-not-found]",
"errorType": "error-room-not-found"
}
No RoomId or Roomname
{
"success": false,
"error": "The parameter \"roomId\" or \"roomName\" is required [error-room-param-not-provided]",
"errorType": "error-room-param-not-provided"
}
object
success
boolean
error
string
errorType
string
401
Unauthorized
Authorization Error
{
"status": "error",
"message": "You must be logged in to do this."
}
object
status
string
message
string
Was this article helpful?