import type { RawAxiosRequestHeaders } from 'axios'; import type { CollectionProp, GetSpaceEnvironmentParams, QueryParams } from '../../common-types'; import type { AgentGeneratePayload, AgentProps } from '../../entities/agent'; import type { AgentGenerateResponse } from '../../entities/agent-run'; import type { OptionalDefaults } from '../wrappers/wrap'; export type AgentPlainClientAPI = { /** * Fetches the AI Agent. * @param params Entity IDs to identify the AI Agent. * @returns The AI Agent. * @throws if the request fails or the AI Agent is not found. */ get(params: OptionalDefaults): Promise; /** * Fetches all AI Agents for the given space and environment. * @param params Entity IDs and query options. * @returns A collection containing an array of AI Agents. * @throws if the request fails or the entities are not found. */ getMany(params: OptionalDefaults): Promise>; /** * Generates a response from an AI Agent. * @param params Entity IDs to identify the AI Agent. * @param payload The generation payload. * @param headers Optional headers for the request. * @returns A promise resolving with a simplified response containing `sys.id`, `sys.type`, and `sys.status`. * Use `agentRun.get()` with the returned `sys.id` to poll for full results. * @throws if the request fails or the payload is malformed. */ generate(params: OptionalDefaults, payload: AgentGeneratePayload, headers?: Partial): Promise; };