Skip to content

Runtime Contract

Advanced integrations can send a JSON-RPC 2.0 style payload directly to an agent:

{
"jsonrpc": "2.0",
"id": "request-1",
"method": "agent.request",
"params": {
"sessionId": "session-1",
"userId": "user-1",
"content": {
"text": "Hello"
}
}
}

For normal Node-RED flows, use agent-in to build this shape for you.

MethodPurposeRequired content
agent.requestStart or continue an agent turn.{ text, images? }
agent.statusRead current session status.No content required.
tool.responseReturn a skill result to the agent.Tool result data and correlation fields.

images may contain URL images or base64 image data when the selected model supports vision input.

Studio and downstream flows may show these event types:

  • agent.request
  • agent.clarify
  • agent.response
  • agent.status
  • agent.warning
  • agent.error
  • agent.usage
  • tool.request
  • tool.response
  • memory.read
  • memory.write

Debug events may be available when debug mode is enabled, but they can contain sensitive request and response details. Enable debug mode only in trusted environments.

ModeBehavior
fullIncludes the full stored conversation history.
summaryIncludes a stored summary plus the latest window of messages.
lastnIncludes only the latest configured number of messages.
noneSends no stored history.

Smartunit stores two kinds of operational data:

DataPurpose
FactsSaved memory such as preferences, profile details, summaries, and usage totals.
EventsActivity history used to inspect sessions, responses, tool calls, warnings, and errors.

Facts can be scoped to a session or user. Event history can contain user input, model output, and tool results, so handle exports and screenshots carefully.

Budgets can limit tokens or provider-reported spend. Supported periods are:

  • session
  • daily
  • weekly
  • monthly
  • lifetime

Warnings emit agent.warning; hard limits emit agent.error and stop the turn.