Class: AiAgentContextReference
Methods
append
▸ append(data
, file?
): Promise
<void
>
Appends data to an existing context entry on the agent. This will result in an error if an entry is not found.
Parameters
Name | Type | Description |
---|---|---|
data | AiChatBotContextData | An object containing options for appending the entry. |
file? | File | The file to append. |
Returns
Promise
<void
>
delete
▸ delete(): Promise
<void
>
Deletes an existing context entry for the agent. Throws an error if an entry with the specified context ID does not exist.
Returns
Promise
<void
>
A promise that resolves when the context entry is successfully deleted.
insert
▸ insert(data
, file?
): Promise
<void
>
Adds a new context entry to the agent. Throws an error if an entry with the same ID already exists.
Parameters
Name | Type | Description |
---|---|---|
data | AiChatBotContextData | An object containing options for creating the entry. |
file? | BlobAndFilename | File | The file to upload (optional). |
Returns
Promise
<void
>
A promise that resolves when the context entry is successfully created.
update
▸ update(data
): Promise
<void
>
Updates an existing context entry for the agent. Throws an error if an entry with the specified context ID does not exist.
Parameters
Name | Type | Description |
---|---|---|
data | Partial <AiChatBotContextData > | An object containing options for updating the entry. |
Returns
Promise
<void
>
A promise that resolves when the context entry is successfully updated.