Documentation Index Fetch the complete documentation index at: https://koreai.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Back to API List
This API allows you to import bot functions from a specified file.
Field Value Method POST Endpoint https://{{host}}/api/public/bot/botId/import/botfunctionsContent Type application/jsonAuthorization auth: {{JWT}} See How to generate the JWT Token .API Scope App Builder: Not Applicable; Admin Console: Bot Definition > Bot Import
Query Parameters
Parameter Required Description hostRequired The environment URL. For example, https://platform.kore.ai botIDRequired The Bot ID or Stream ID of the bot into which you want to import the functions. You can get it under General Settings on the App Builder.
Sample Request
curl -X POST \
'https: //{{host}}/api/public/bot/botId/import/botfunctions' \
--header 'auth: { {YOUR_JWT_ACCESS_TOKEN }}' \
--header 'content-type: application/json' \
--data '[{ "fileName" : "BotFunctions.js" , "fileId" : "6565d8fea4fa7f2827b225f3" }]'
Body Parameters
Parameter Required Description fileIdRequired The unique identifier (ID) of the file to be imported. This ID can be retrieved from the response of the Upload File API after uploading the Bot Functions file. fileNameRequired The name of the file containing the bot functions to import.
Sample Response
Success:
{
"requestType" : "BotImport" ,
"status" : "Success" ,
"createdOn" : "2023-11-28T12:14:59.215Z" ,
"_id" : "6565d9c378438bc41a6cfxxx" ,
"createdBy" : "u-37bc3853-76fd-5a25-b307-1af2e8f1bxxx" ,
"__v" : 0 ,
"fileId" : "6565d8fea4fa7f2827b225f3" ,
"fileName" : "BotFunctions.js"
}
Failure:
{
"errors" : [
{
"msg" : "Invalid file id" ,
"code" : 400
}
]
}