Skip to main content
POST
/
api
/
agents
/
plan
Plan a workflow from a goal
curl --request POST \
  --url http://localhost:3001/api/agents/plan \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "goal": "<string>",
  "context": {},
  "constraints": [
    "<string>"
  ],
  "autoExecute": true
}
'
{
  "success": true,
  "goal": "<string>",
  "flowspec": {},
  "reasoning": "<string>",
  "complexity": "<string>",
  "workflowId": "<string>",
  "execution": {},
  "executionError": "<string>",
  "message": "<string>"
}

Documentation Index

Fetch the complete documentation index at: https://docs.lucid.foundation/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Lucid API key (lk_live_... or lk_test_...)

Body

application/json
goal
string
required
context
object
constraints
string[]
autoExecute
boolean

Response

OK

success
boolean
required
goal
string
required
flowspec
object
required
reasoning
string
required
complexity
string
workflowId
string
execution
object
executionError
string
message
string