CRBNai API
  1. Messages
CRBNai API
  • README
  • Authentication
  • Guides
    • Creating a Knowledge Bot
  • API Keys
    • Get all API Keys
      GET
    • Create API Key
      POST
    • Delete API Key
      DELETE
  • Chats
    • Messages
      • Get Chat Messages
        GET
      • Post Chat Message
        POST
    • Recipes
      • Get All Chat Recipes
    • Get All Chats
      GET
    • Create Chat
      POST
  • Documents
    • Delete Document
      DELETE
    • Download Document
      GET
    • Update Document
      PUT
  • Knowledge Bots
    • Documents
      • Add Document to Knowledge Bot
      • Prepare Document Upload
    • Chats
      • Chat Messages
        • Get Messages of a Knowledge Bot chat
        • Post a message to a Knowlege Bot chat
      • Get all Knowledge Bot chats
      • Create Knowledge Bot chat
    • Chats - deprecated
      • Chat with a Knowledge Bot
    • Create Knowledge Bot
      POST
    • Get All Knowledge Bots
      GET
    • Get Knowledge Bot by ID
      GET
    • Delete Knowledge Bot by ID
      DELETE
    • Update Knowledge Bot by ID
      PUT
  1. Messages

Post Chat Message

POST
/api/chats/{id}/messages
chatmessages
Post a new chat message to a chat which then responds with a stream of JSONs containing deltas which build the response message.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://app.crbnai.com/api/chats//messages' \
--header 'Content-Type: application/json' \
--data-raw '{
    "content": "string"
}'
Response Response Example
200 - Success
{"type":"delta","delta":"Sure"}
{"type":"delta","delta":"!"}
{"type":"delta","delta":" Here"}
{"type":"delta","delta":"'s"}
{"type":"delta","delta":" a"}
{"type":"delta","delta":" sample"}
{"type":"delta","delta":" question"}
{"type":"delta","delta":":\n\n"}
{"type":"delta","delta":"\"What"}
{"type":"delta","delta":" are"}
{"type":"delta","delta":" the"}
{"type":"delta","delta":" key"}
{"type":"delta","delta":" steps"}
{"type":"delta","delta":" to"}
{"type":"delta","delta":" starting"}
{"type":"delta","delta":" a"}
{"type":"delta","delta":" small"}
{"type":"delta","delta":" business"}
{"type":"delta","delta":"?\""}

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Path Params
id
string 
required
Body Params application/json
content
string 
required
Content of the chat message.
Examples

Responses

🟢200OK
text/plain
Body
object {0}
🟠404Record Not Found
Previous
Get Chat Messages
Next
Get All Chat Recipes
Built with