Skip to content
Developer Preview

session/fork

Branches a session into a new id whose log copies the source through a cut point, with durable provenance.

Type: SessionForkParams

session/fork params.

Field Type Stability Presence Description
approvalRules ClientApprovalRule[] Experimental optional Client-supplied shell prefix allow-rules override: omitted inherits the source session’s rules, present replaces with that set (an explicit empty array clears). Explicit null is invalid params. Until the served-handler slice, a host refuses any spelled approvalRules on session/start/fork/resume with -32602; clients omit it. Experimental (session/fork.approvalRules).
commandId string required The idempotency handle (UUIDv7).
cutPoint ForkCutPoint optional Copy history through a completed turn, inclusive. Omitted means “all completed turns”.
excludeItems boolean optional Skip inline history in the result and page it later — same as session/resume.
sessionId string required The source session.
Source

schema/msp/experimental/msp.schema.json#/methods/session~2Ffork

{
"description": "Branches a session into a new id whose log copies the source through a cut point, with durable provenance.",
"params": {
"$ref": "#/$defs/SessionForkParams"
},
"result": {
"$ref": "#/$defs/SessionForkResult"
}
}