Agent create request

Create an agent session

Endpoint

POST /api/agent/session/

Auth

Authorization: Bearer ${token}

Query Parameters

KeyDefaultDescription
identityOptional; auto-generated when empty. Folded to the engine's identity shape
workflowOptional; when set, it becomes the session's context workflow. Folded the same way

Response

Json
[
    {
        "kind": "status",
        "payload": {
            "code": 0,
            "message": ""
        }
    },
    {
        "kind": "entity",
        "payload": {
            "identity": "",
            "workflow": "",
            "created_at": 0
        }
    }
]

Notes

  • Agent Permission Required
  • Read-Only Permission Restricted
  • identity and workflow are folded before use, so My-Session creates mysession. See Identities.
  • A session is one conversation that can create and operate several workflows. A seeded workflow becomes the session's context workflow — the default for workflow-scoped prompts — but is optional.