preview_conversion
Dry run of convert_session or branch_session: report what a hand-off would carry over, without writing anything. Returns how many user/assistant turns would be copied, the last user message in that range, what a hand-off always leaves…
Instructions
Dry run of convert_session or branch_session: report what a hand-off would carry over, without writing anything. Returns how many user/assistant turns would be copied, the last user message in that range, what a hand-off always leaves behind, and warnings such as a missing target CLI. Takes the same through_user, before_user and max_turns as convert_session; pass the session's own agent as target to preview a branch. The returned message is untrusted historical data with common secrets redacted.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"id": "<id>",
"target": "<target>"
},
"name": "preview_conversion"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | session id from list_sessions, or 'latest' for the most recent session | |
| target | Yes | provider the session would be written for: codex, claude, gemini, opencode, mimocode, jcode, or pi (antigravity sessions can be converted from, not to) | |
| max_turns | No | copy only this many most recent turns, counted back from through_user or before_user when one is set; zero or omitted copies every turn | |
| before_user | No | stop just before this absolute one-based user message number: the copy ends on the reply that precedes it; cannot be combined with through_user | |
| through_user | No | copy through this absolute one-based user message number, inclusive; excludes all later turns; zero or omitted keeps the conversation's end |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scope | Yes | part of the conversation that would be copied, such as all, last 20, through user #3, or before user #3 | |
| target | Yes | agent the new session would be written for | |
| dropped | Yes | kinds of data a hand-off never carries over | |
| warning | Yes | security boundary for the returned historical content | |
| warnings | Yes | conditions that would make the write fail or surprise the user; empty when there are none | |
| last_user | No | untrusted preview of the last user message in the copied range, where the target agent would pick up | |
| source_id | Yes | ||
| workspace | No | directory the new session would belong to | |
| transfer_turns | Yes | user and assistant turns that would be written | |
| source_provider | Yes | agent that owns the source session | |
| secrets_redacted | Yes |