{"version":"2.1.267","anchor":"session-exportimport-now-round-trips-file-write-tool-calls","canonical_anchor":"session-exportimport-now-round-trips-file-write-tool-calls","heading":"Session export\/import better preserves tool-use messages","tier":"notice","area":"Sessions","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.267\/e\/session-exportimport-now-round-trips-file-write-tool-calls","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.267","markdown":"### Session export\/import better preserves tool-use messages\n\nExported and re-imported session transcripts now correctly preserve tool-use messages, including file writes\n\n**What**\n\n- When rebuilding an assistant message during session export\/import, `stop_reason` is no longer always set to `end_turn`; it is now set to `tool_use` when the message actually contains tool-use blocks.\n\n- When importing an assistant message, file-write tool calls are now reconstructed and re-added as `tool_use` blocks (with their `file_path` and `content`), in addition to the existing text-block handling.\n\n**Why** Previously, exporting and re-importing a session could lose or mislabel tool-use information, such as file writes a session had made. This keeps transcripts more faithful when moved between sessions or environments.\n\n- Area: Sessions\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5"}