Session resume · for Claude Code and Codex

# Close the laptop. *Carry on from another one.*

**The gateway keeps a copy of each conversation that passes through it, and one command turns that copy into a native Claude Code or Codex session on any machine.** The client's own resume command then opens it, so you can stop on one laptop and carry on from another, or switch clients mid-task.

1 command to move a session

2 clients, Claude Code and Codex

200 latest messages kept per session

15 min before the command expires

[Connect your agent →](https://context-mode.com/docs/quick-start) [Read the docs](https://context-mode.com/docs/session-resume)

## Key facts

What it is

A Context Mode Gateway feature that rebuilds a conversation as a native session file.

Who it is for

Developers who move between machines, or between Claude Code and Codex.

Clients

Claude Code and Codex.

Measured result

Not a cost feature, and not measured on its own. For the gateway as a whole, see [Benchmarks](https://context-mode.com/docs/benchmarks#pooled).

Limits

It brings back message text, tool names and a summary before the latest 200 messages. The command expires after 15 minutes.

Built-in resume

### What the clients do today

Each client keeps sessions in a local file.

## Their resume reads your disk, *and ours reads the gateway.*

Claude Code saves sessions under `~/.claude/projects`, Codex under `~/.codex/sessions`. On a new laptop or a remote dev box, or after the file is deleted, there is nothing to resume.

claude --resume sessions saved on this computer, opens in Claude Code

codex resume sessions saved on this computer, opens in Codex

Claude Code in the cloud a session that runs in the cloud is on every device from the start, and `--teleport` pulls it into a terminal; [Claude Code only](https://code.claude.com/docs/en/claude-code-on-the-web)

Context Mode sessions saved at the gateway, opens in either client, on any machine with Node.js and curl, for sessions that ran on your own machines

How it works

### Console to terminal

You never copy a file or paste an API key.

## Pick the workspace, *paste one line.*

01 save Each request through the gateway adds its new messages to the copy.

02 pick In the console, open Sessions and click Open in Claude Code or Open in Codex.

03 paste Run the command in the project folder. It writes the client's own session file.

04 continue The client opens it with its own resume command.

Switch clients

### One copy per workspace

A workspace is one project and one worktree.

## Start in Claude Code *and finish in Codex.*

A conversation held in one client opens in the other. The command carries a token that expires after 15 minutes and reads only your own account's workspaces.

What comes back

Message text for the latest 200 messages of each session, and a summary of older ones. Tool calls show by name, without their output. [Full list →](https://context-mode.com/docs/session-resume#saved)

## FAQ

### Can I start in Claude Code and finish in Codex?

Yes. The copy belongs to the workspace, whichever client wrote it.

### Does resume bring back every tool output?

No. It brings back message text, tool names and a summary before the latest 200 messages.

### Is the command safe to paste in a shared channel?

No. Until it expires after 15 minutes, anyone who has it can read that conversation.

## Your conversation, *on the next machine.*

*npx @context-mode/cli* points Claude Code and Codex at the gateway. Saving starts with the next request.

[Connect your agent →](https://context-mode.com/docs/quick-start) [How resume works →](https://context-mode.com/docs/session-resume)
