Skip to main content
POST
Execute Batch Agent Completions

Headers

x-api-key
string
required

Body

application/json
Maximum array length: 50
agent_config
AgentSpec · object
required

The configuration of the agent to be completed.

task
string | null

The task to be completed by the agent.

history
History · object

Earlier turns of the conversation. A list of {role, content} messages reaches the model as chat turns before the task when every role is user, assistant or system. A list with any other role (an agent name, developer, tool), a list sent without a task, or a dictionary reaches the model as text ahead of the task.

img
string | null

A base64 encoded image for the agent to process. Encode your image file to base64 and pass it here.

imgs
string[] | null

A list of base64 encoded images for the agent to process. Encode your image files to base64 and pass them here.

tools_enabled
string[] | null

A list of tools that the agent should use to complete its task.

Response

Successful Response

batch_id
string | null

The unique identifier for the agent batch completion.

total_requests
integer | null

The total number of requests in the batch.

results
any | null

The outputs generated by the agent.

execution_time
number | null

The execution time of the agent batch completion.

timestamp
string | null

The timestamp when the agent batch completion was created.