Aleph
Gateway RPCMethods Reference

wizard.*

Setup wizard RPC methods

wizard.* is the JSON-RPC surface for the configuration wizard. The five methods are registered as service_unavailable placeholders inside HandlerRegistry::new() and replaced with the real handlers by install_wizard_handlers once WizardSessionManager is built at server boot (src/bin/aleph-server/commands/start/mod.rs:655-660). The runtime factory ships only the onboarding flow; any other wizard_type returns Unknown wizard type from the start handler.

The wizard state itself is process-local — restarting the daemon drops in-flight sessions. There is no CLI subcommand equivalent any more (aleph wizard was removed); the Panel drives these RPCs.

Methods

wizard.start

Start a new wizard session. Returns the first step.

Request:

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "wizard.start",
  "params": {
    "wizard_type": "onboarding",
    "initial_data": {}
  }
}
ParameterTypeRequiredDescription
wizard_typestringyesonboarding is the only flow currently registered.
initial_dataobjectnoReserved; ignored by the runtime factory.

Response:

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "session_id": "<uuid>",
    "step": { "id": "...", "type": "note|select|multi_select|text|confirm|progress", ... },
    "status": "running"
  }
}

wizard.next

Skip a non-blocking step (notes / intros) without an answer. If answer is supplied, the call is rejected — submit the answer with wizard.answer instead.

ParameterTypeRequiredDescription
session_idstringyesThe session id from wizard.start
answeranynoReserved; supplying a value returns an Invalid answer error.

Response: the next step, or the terminal step (status: done|error|cancelled).

wizard.answer

Answer a step and advance to the next one.

ParameterTypeRequiredDescription
session_idstringyesThe session id from wizard.start
step_idstringyesThe id of the current step being answered
valueanyyesThe answer (string for text, string for select, array of strings for multi_select, bool for confirm)

Response: the next step, or the terminal step.

wizard.cancel

Cancel an in-flight wizard session. Removes the session from the manager; the WizardSession Arc drop closes the session channels.

ParameterTypeRequiredDescription
session_idstringyesThe session id from wizard.start

Response:

{ "result": { "cancelled": true } }

wizard.status

Get the current status of a wizard session.

ParameterTypeRequiredDescription
session_idstringyesThe session id from wizard.start

Response:

{ "result": { "status": "running|done|error|cancelled" } }

A RESOURCE_NOT_FOUND (-32004) is returned when no session with that id is active.

Wiring

wizard.* sits between the phase-1 registry and the boot-time install:

  • HandlerRegistry::new() — every wizard.* method is bound to a placeholder that returns SERVICE_UNAVAILABLE (-32002) with "wizard manager not yet initialised".
  • install_wizard_handlers (called from start_server) — replaces the placeholders with the real handlers from src/gateway/handlers/wizard.rs. The runtime factory closes over OnboardingFlow::new; any other wizard_type produces Unknown wizard type from start.

The 11-step onboarding flow in the current runtime covers: provider, credentials, primary model, secondary model, thinking level, session mode, exec tier, messaging apps, gateway TLS, and the final completion step. It is driven by the WizardSessionManager and WizardFlow trait, both in src/gateway/handlers/wizard.rs and src/wizard/.

See Also

On this page