> ## 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. # Set Default Channel > Set whether the channel is a default channel or not. All new users will automatically join this channel. Permission required: `edit-room` ### Changelog | Version | Description | | ------- | ----------- | |0.66.0 | Added | ## OpenAPI ````json POST /api/v1/channels.setDefault { "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/channels.setDefault": { "post": { "tags": [ "Channels" ], "summary": "Set Default Channel", "description": "Set whether the channel is a default channel or not. All new users will automatically join this channel. Permission required: `edit-room`\n\n### Changelog\n| Version | Description |\n| ------- | ----------- |\n|0.66.0 | Added |", "operationId": "post-api-v1-channels.setDefault", "parameters": [ { "$ref": "#/components/parameters/Auth-Token" }, { "$ref": "#/components/parameters/UserId" } ], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "roomId": { "type": "string", "description": "The channel ID." }, "default": { "type": "boolean", "description": "Boolean of whether the room is default or not." } }, "required": [ "roomId", "default" ] }, "examples": { "Example": { "value": { "roomId": "ByehQjC44FwMeiLbX", "default": true } } } } } }, "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "type": "object", "properties": { "channel": { "type": "object", "properties": { "_id": { "type": "string" }, "name": { "type": "string" }, "t": { "type": "string" }, "msgs": { "type": "integer" }, "u": { "type": "object", "properties": { "_id": { "type": "string" }, "username": { "type": "string" } } }, "ts": { "type": "string" }, "ro": { "type": "boolean" }, "sysMes": { "type": "boolean" }, "_updatedAt": { "type": "string" }, "usernames": { "type": "array", "items": { "type": "string" } }, "joinCodeRequired": { "type": "boolean" }, "muted": { "type": "array", "items": { "type": "object" } }, "default": { "type": "boolean" } } }, "success": { "type": "boolean" } } }, "examples": { "Example": { "value": { "channel": { "_id": "ByehQjC44FwMeiLbX", "name": "testing0", "t": "c", "msgs": 0, "u": { "_id": "aiPqNoGkjpNDiRx6d", "username": "goose160" }, "ts": "2017-01-05T18:02:50.754Z", "ro": true, "sysMes": true, "_updatedAt": "2017-01-05T19:02:24.429Z", "usernames": [ "goose160", "graywolf336" ], "joinCodeRequired": true, "muted": [], "default": true }, "success": true } } } } } }, "401": { "$ref": "#/components/responses/authorizationError" } } } } }, "components": { "parameters": { "Auth-Token": { "name": "X-Auth-Token", "in": "header", "description": "The `authToken` of the authenticated user.", "required": true, "schema": { "type": "string" }, "example": "RScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f" }, "UserId": { "name": "X-User-Id", "in": "header", "description": "The `userId` of the authenticated user.", "required": true, "schema": { "type": "string" }, "example": "rbAXPnMktTFbNpwtJ" } }, "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." } } } } } } } } } ````