# Create a new chat session **POST /chat** ## Servers - Local development server: http://localhost:3000/api/v1 (Local development server) - Production server: https://referspecs-backend.onrender.com/api/v1 (Production server) ## Authentication methods - Bearer auth ## Parameters ### Body: application/json (object) - **name** (string) Optional name for the chat session. Defaults to "New Chat". - **type** (string) The type of chat session. ## Responses ### 201 Chat created successfully #### Body: application/json (object) - **success** (boolean) - **statusCode** (integer) - **message** (string) - **data** (object) ### 400 Bad Request (e.g., missing type, invalid type) #### Body: application/json (object) - **success** (boolean) - **statusCode** (integer) - **message** (string) ### 401 Unauthorized (User not authenticated) #### Body: application/json (object) - **success** (boolean) - **statusCode** (integer) - **message** (string) ### 500 Internal Server Error #### Body: application/json (object) - **success** (boolean) - **statusCode** (integer) - **message** (string) [Powered by Bump.sh](https://bump.sh)