# Create Message **POST /api/v1/orgs/{slug}/chats/{chatID}/messages** Adds a new message to an existing chat session. Can be called via Public API (API Key). ## Servers - http://api.example.com: http://api.example.com () ## Authentication methods - Api key auth ## Parameters ### Path parameters - **slug** (string) Organization Slug - **chatID** (integer) Chat ID ### Body: application/json (object) Message Details (role, content, metadata) - **content** (string) - **metadata** (object) Use structured type - **role** (string) ## Responses ### 201 message: Message created successfully, message_id: uint64 #### Body: application/json (object) object ### 400 Invalid chat ID or request data (role, content, metadata validation) #### Body: application/json (object) - ***** (string) ### 401 Unauthorized (API Key invalid/missing or Org ID not found) #### Body: application/json (object) - ***** (string) ### 403 Forbidden (API Key doesn't match slug or chat doesn't belong to org) #### Body: application/json (object) - ***** (string) ### 404 Chat not found #### Body: application/json (object) - ***** (string) ### 500 Failed to get chat or create message #### Body: application/json (object) - ***** (string) [Powered by Bump.sh](https://bump.sh)