> ## Documentation Index > Fetch the complete documentation index at: https://developer.rocket.chat/llms.txt > Use this file to discover all available pages before exploring further. # Remove Room from the Team > Removes a room from a team. Permissions required: `remove-team-channel`, `view-all-team-channels` ## OpenAPI ````json POST /api/v1/teams.removeRoom { "openapi": "3.0.0", "info": { "version": "1.0.0", "title": "Rooms" }, "servers": [ { "url": "https://apiexplorer.support.rocket.chat" } ], "tags": [ { "name": "Channels" }, { "name": "Directory" }, { "name": "Groups" }, { "name": "Rooms" }, { "name": "Teams" }, { "name": "Room Invites" }, { "name": "Subscriptions" }, { "name": "ABAC" } ], "paths": { "/api/v1/teams.removeRoom": { "post": { "tags": [ "Teams" ], "summary": "Remove Room from the Team", "description": "Removes a room from a team. \n\nPermissions required: `remove-team-channel`, `view-all-team-channels`", "operationId": "post-api-v1-teams.removeRoom", "parameters": [ { "$ref": "#/components/parameters/UserId" }, { "$ref": "#/components/parameters/Auth-Token" } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "teamName": { "type": "string", "description": "Enter the team name. This parameter is required if `teamId` is not provided.", "example": "team01" }, "teamId": { "type": "string", "description": "Enter the team ID. This parameter is required if `teamName` is not provided.", "example": "d8eiFT9fIwfs" }, "roomId": { "type": "string", "description": "The room ID to be removed from the team.", "example": "8dugqGhuRvCBLdZft" } } }, "examples": { "Example": { "value": { "teamId": "63f3efc4b000b6b6d86704b2", "roomId": "JKa7R9zu2DinBhBN9" } } } } } }, "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "type": "object", "properties": { "room": { "type": "object", "properties": { "_id": { "type": "string" }, "fname": { "type": "string" }, "customFields": { "type": "object" }, "description": { "type": "string" }, "broadcast": { "type": "boolean" }, "encrypted": { "type": "boolean" }, "federated": { "type": "boolean" }, "name": { "type": "string" }, "t": { "type": "string" }, "msgs": { "type": "integer" }, "usersCount": { "type": "integer" }, "u": { "type": "object", "properties": { "_id": { "type": "string" }, "username": { "type": "string" } } }, "ts": { "type": "string" }, "ro": { "type": "boolean" }, "default": { "type": "boolean" }, "sysMes": { "type": "boolean" }, "_updatedAt": { "type": "string" }, "lm": { "type": "string" }, "lastMessage": { "type": "object", "properties": { "_id": { "type": "string" }, "t": { "type": "string" }, "msg": { "type": "string" }, "groupable": { "type": "boolean" }, "blocks": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "blockId": { "type": "string" }, "callId": { "type": "string" }, "appId": { "type": "string" } } } }, "ts": { "type": "string" }, "u": { "type": "object", "properties": { "_id": { "type": "string" }, "username": { "type": "string" }, "name": { "type": "string" } } }, "rid": { "type": "string" }, "_updatedAt": { "type": "string" }, "urls": { "type": "array", "items": { "type": "object" } }, "mentions": { "type": "array", "items": { "type": "object" } }, "channels": { "type": "array", "items": { "type": "object" } } } } } }, "success": { "type": "boolean" } } }, "examples": { "Success": { "value": { "room": { "_id": "JKa7R9zu2DinBhBN9", "fname": "Livestream", "customFields": {}, "description": "", "broadcast": false, "encrypted": false, "federated": false, "name": "Livestream", "t": "c", "msgs": 15, "usersCount": 3, "u": { "_id": "rbAXPnMktTFbNpwtJ", "username": "roxie" }, "ts": "2023-02-22T17:15:26.989Z", "ro": false, "default": false, "sysMes": true, "_updatedAt": "2023-09-29T05:51:47.779Z", "lm": "2023-09-14T12:06:00.594Z", "lastMessage": { "_id": "rtf5JoPLQup3X7Aof", "t": "videoconf", "msg": "", "groupable": false, "blocks": [ { "type": "video_conf", "blockId": "6502f728a2f73c7460df6f71", "callId": "6502f728a2f73c7460df6f71", "appId": "videoconf-core" } ], "ts": "2023-09-14T12:06:00.594Z", "u": { "_id": "rbAXPnMktTFbNpwtJ", "username": "test.test", "name": "test test" }, "rid": "JKa7R9zu2DinBhBN9", "_updatedAt": "2023-09-14T12:06:00.685Z", "urls": [], "mentions": [], "channels": [] } }, "success": true } } } } } }, "401": { "$ref": "#/components/responses/authorizationError" } } } } }, "components": { "parameters": { "UserId": { "name": "X-User-Id", "in": "header", "description": "The `userId` of the authenticated user.", "required": true, "schema": { "type": "string" }, "example": "rbAXPnMktTFbNpwtJ" }, "Auth-Token": { "name": "X-Auth-Token", "in": "header", "description": "The `authToken` of the authenticated user.", "required": true, "schema": { "type": "string" }, "example": "RScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f" } }, "responses": { "authorizationError": { "description": "Unauthorized", "content": { "application/json": { "schema": { "type": "object", "properties": { "status": { "type": "string" }, "message": { "type": "string" } } }, "examples": { "Authorization Error": { "value": { "status": "error", "message": "You must be logged in to do this." } } } } } } } } } ````