Lists AI agents based on the provided parameters.
This operation is performed by calling function getAiAgents.
See the endpoint docs at API Reference.
await client.aiStudio.getAiAgents();- queryParams
GetAiAgentsQueryParams- Query parameters of getAiAgents method
- headersInput
GetAiAgentsHeadersInput- Headers of getAiAgents method
- cancellationToken
undefined | CancellationToken- Token used for request cancellation.
This function returns a value of type AiMultipleAgentResponse.
A successful response including the agents list.
Creates an AI agent. At least one of the following capabilities must be provided: ask, text_gen, extract.
This operation is performed by calling function createAiAgent.
See the endpoint docs at API Reference.
await client.aiStudio.createAiAgent({
name: agentName,
accessState: 'enabled',
ask: new AiStudioAgentAsk({ accessState: 'enabled', description: 'desc1' }),
} satisfies CreateAiAgentInput);- requestBodyInput
CreateAiAgentInput- Request body of createAiAgent method
- optionalsInput
CreateAiAgentOptionalsInput
This function returns a value of type AiSingleAgentResponseFull.
Definition of created AI agent.
Updates an AI agent.
This operation is performed by calling function updateAiAgentById.
See the endpoint docs at API Reference.
await client.aiStudio.updateAiAgentById(createdAgent.id, {
name: agentName,
accessState: 'enabled',
ask: new AiStudioAgentAsk({ accessState: 'disabled', description: 'desc2' }),
} satisfies CreateAiAgentInput);- agentId
string- The ID of the agent to update. Example: "1234"
- requestBodyInput
CreateAiAgentInput- Request body of updateAiAgentById method
- optionalsInput
UpdateAiAgentByIdOptionalsInput
This function returns a value of type AiSingleAgentResponseFull.
Definition of created AI agent.
Gets an AI Agent using the agent_id parameter.
This operation is performed by calling function getAiAgentById.
See the endpoint docs at API Reference.
await client.aiStudio.getAiAgentById(createdAgent.id, {
queryParams: { fields: ['ask'] } satisfies GetAiAgentByIdQueryParams,
} satisfies GetAiAgentByIdOptionalsInput);- agentId
string- The agent id to get. Example: "1234"
- optionalsInput
GetAiAgentByIdOptionalsInput
This function returns a value of type AiSingleAgentResponseFull.
A successful response including the agent.
Deletes an AI agent using the provided parameters.
This operation is performed by calling function deleteAiAgentById.
See the endpoint docs at API Reference.
await client.aiStudio.deleteAiAgentById(createdAgent.id);- agentId
string- The ID of the agent to delete. Example: "1234"
- optionalsInput
DeleteAiAgentByIdOptionalsInput
This function returns a value of type undefined.
A successful response with no content.