CRBNai API
  1. Documents
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
      • Post Chat Message
    • 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
        POST
      • Prepare Document Upload
        POST
    • 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. Documents

Add Document to Knowledge Bot

Testing
POST
/api/knowledge-bots/{id}/documents
kbdocument
Add a Document to Knowledge Bot.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://app.crbnai.com/api/knowledge-bots//documents' \
--header 'Content-Type: application/json' \
--data-raw '{
    "path": "/etc/namedb/hatchback_repurpose_bicycle.yml",
    "filename": "payment.crl",
    "user_metadata": "reprehenderit ad Ut esse sit"
}'
Response Response Example
{
  "knowledge_base_id": "1ab61a25-f4b7-42f7-8845-0bfce7a41943",
  "name": "fugit",
  "path": "quasi",
  "created_at": "2096-03-24T04:25:55.607Z",
  "updated_at": "2032-05-10T13:22:01.954Z",
  "last_parsed_page": 49509,
  "status": "animi",
  "id": "5fe1fd39-b1ae-4976-b4fe-34943b693b0d"
}

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
path
string 
required
The path returned from the prepare-upload API.
filename
string 
required
The name of the file you want to add to the Knowledge Bot.
user_metadata
string  | integer  | boolean  | array  | object  | number  | null 
optional
Examples

Responses

🟢200OK
text/plain
Body
null 
optional
Previous
Update Document
Next
Prepare Document Upload
Built with