(chatbot)
- postChatbotCreate - Create Chatbot
- getChatbotList - List Chatbots
- postChatbotGet - Get Chatbot
- getChatbotAnalytics - Get Chatbot analytics
- getChatbotGetMessages - Get Chatbot messages
- postChatbotUpdate - Update Chatbot
- postChatbotDelete - Delete Chatbot
- postChatbotReset - Reset Token
Create Chatbot
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.postChatbotCreate({
name: "Chatbot -1",
brainId: "1f1d7a6a-e45b-4974-a0ba-98935650cb9c",
urls: [
"https://byteleap.co",
"https://ayushgoyal.dev",
],
});
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.PostChatbotCreateRequestBody | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.PostChatbotCreateResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
List Chatbots
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.getChatbotList("<value>");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
brainId |
string | ➖ | The ID of the brain to filter chatbots |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.GetChatbotListResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Get Chatbot
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.postChatbotGet("7a2e792d-cf48-49d2-a36d-186be034a9dc");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
chatbotId |
string | ➖ | N/A | [object Object] |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. | |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
|
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.PostChatbotGetResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Get Chatbot analytics
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.getChatbotAnalytics("1a718a80-71c0-414b-915c-5c5991597ac7");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
chatbotId |
string | ➖ | N/A | [object Object] |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. | |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
|
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.GetChatbotAnalyticsResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
note: there is a limit of 10000 messages
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.getChatbotGetMessages("1a718a80-71c0-414b-915c-5c5991597ac7");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
chatbotId |
string | ➖ | N/A | [object Object] |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. | |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
|
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.GetChatbotGetMessagesResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Update Chatbot
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.postChatbotUpdate({
chatbotId: "1a718a80-71c0-414b-915c-5c5991597ac7",
name: "Chatbot -1",
urls: [
"https://byteleap.co",
"https://anshgoyal.com",
],
});
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.PostChatbotUpdateRequestBody | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.PostChatbotUpdateResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Delete Chatbot
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.postChatbotDelete("2de69bc3-3f60-46a2-be30-e95c98ab7a87");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
chatbotId |
string | ➖ | N/A | [object Object] |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. | |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
|
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.PostChatbotDeleteResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Reset Token
import { AthenaCopilot } from "@athena-ai/sdk";
const athenaCopilot = new AthenaCopilot({
security: {
username: "<YOUR_USERNAME_HERE>",
password: "<YOUR_PASSWORD_HERE>",
},
});
async function run() {
const result = await athenaCopilot.chatbot.postChatbotReset("c7af119a-a5c6-47a4-a5fd-fbf96ef08851");
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
chatbotId |
string | ➖ | N/A | [object Object] |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. | |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
|
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.PostChatbotResetResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |