Jeden/Docs

CLI command

jeden rpc

Serve Jeden's newline-delimited JSON RPC interface on standard input and output.

Exact invocation#

Shell
jeden rpc

Inputs and options#

  • No command-specific positional input or option is required.
  • Clients send one JSON request per line with an id, method, and optional params object.
  • session/open takes {session,options?} and reopens the existing ledger in place. Its returned sessionPath remains the source path; retained request identities and revisions are preserved. A missing state.json is refused as session not found rather than creating another conversation.
  • session/completion/get takes {sessionId}; session/completion/control takes {sessionId,taskId,action,reason,revision}, with action pause, resume or cancel. Both return {sessionId,completion}. Task IDs may also name an original request.
  • session/completion/continue takes {sessionId,requestId} and uses the ordinary prompt response and event stream without capturing a new user request. Events completion {state} and assistantMessage {text} are nonterminal; result includes text and the completion snapshot.
  • session/completion/add takes {sessionId,prompt} and returns {sessionId,completion} without running a model. Native /todo commands sent through session/prompt also operate on that selected session rather than becoming model instructions.
  • session/import-omp takes {planPath,refresh?} and returns the same report as import-omp without invoking a model or terminating a source process.

Output and state effect#

Keeps an in-process session map, emits one-line JSON responses and interaction events, and creates normal Jeden session state for requests that start or resume work. User-facing session prompts use the same structured task-report contract as CLI/TUI, headless, and the SDKs; accepted task_report events carry version, complete-or-blocked status, the seven-area report, and its rendered human text. The config/contracts/get and config/contracts/set results include the two editable user contract settings plus a localized, versioned, built-in read-only taskContract with instructions and requirement descriptors. config/communication/get and config/communication/set return the resolved effective communication policy. Session events include toolCall, toolResult, and reasoningDelta only when that policy shows them. RPC opens no listener.

Refusals and boundaries#

  • Frames larger than 1 MiB are refused.
  • Malformed JSON, missing methods, unknown methods, invalid parameters, and writes to a closed output stream are returned as RPC errors rather than guessed.