v1
latestOpenAPI 3.0.02026-07-1761823.7 KBGenerate object
Generate a structured object for a specific workflow
post/api/v1/generate/object
Request body
Example request
{
"input": "Tell me about renewable energy",
"workflowSlug": "my_great_workflow",
"groupId": "my-group-id",
"schema": {
"title": "My great response",
"description": "The response to the input",
"type": "object"
}
}Response
Successfully generated object (we also return the run ID in the header X-Run-ID)
Example response
{
"metadata": {
"runId": "run_1234567890",
"cost": "0.001",
"model": {
"name": "gpt-4o",
"tag": "openai:gpt-4o"
},
"durationInMs": 1000,
"inputTokens": 1000,
"outputTokens": 1000
}
}