Rename chat room
PUT
/chat-rooms/:idRename a group chat. Only joined members can rename it. Direct messages (whose display name is derived from the participants) and event/community chats (which use their own name) cannot be renamed. Sending an empty string clears the name.
| Auth | Login required |
|---|
Path parameters
idstringrequiredChat room ID.
Request body
namestringNew room name (up to 60 characters). Send an empty string or null to clear it.
Request
curl https://api.4s.link/chat-rooms/ID \-X PUT \-H "Authorization: Bearer 4s_at_..." \-H "Content-Type: application/json" \-d '{"name": "Project Team"}'
Example response
{"id": "r1a2b3c4-...","type": "GROUP","name": "Project Team","members": [{"id": "rm1a2b3-...","status": "JOINED","user": { "id": "a1b2c3d4-...", "slug": "taro", "firstName": "太郎", "lastName": "山田", "avatarUrl": "https://.../avatar.png" }}]}