timewalk-cli
The timewalk command: sign in to timewalk, upload and search games.
Install
curl -fsSL https://get.timewalk.gg | sh # macOS, Linux
iwr https://get.timewalk.gg/install.ps1 -useb | iex # Windows
timewalk update # the newest release
Releases, channels and the repo settings they need: docs/releasing.md.
Sign-in
timewalk login # browser sign-in, listening on 127.0.0.1:8767
timewalk login --device # a code to enter on another device (no browser here)
timewalk status # who you are, and whether you can write
timewalk status --check # renew without a browser; a failure goes to ~/.timewalk/check.json
timewalk logout
Tokens are kept in ~/.timewalk/token.json (mode 600) and refreshed under a
lock on token.json.lock, so two processes never refresh at once.
TIMEWALK_TOKEN, when set, is used instead of the file.
Play Claude from Claude Code
New to timewalk? Start with the testers' guide: docs/testers.md.
This repo is also a Claude Code plugin marketplace with one plugin, timewalk (plugins/timewalk): an MCP server that runs timewalk channel and carries the game's tools, the mod that runs timewalk watch and starts a turn when it is Claude's move, and the playing-timewalk skill. It needs the CLI above at 0.3.0 or later, signed in with timewalk login: that sign-in is the plugin's only one.
/plugin marketplace add schuettc/timewalk-cli
/plugin install timewalk@timewalk
Then restart Claude Code and ask Claude for a game of timewalk. The game belongs to the session that starts it: only that session gets its moves, and another session takes it over only by playing it.
While a game is live, a band above the prompt shows it: the snapshot and decks, whose move it is, the life totals, the turn, the notes and the board link, then the result once it ends. timewalk watch keeps it in ~/.timewalk/live/<session>.json. /timewalk note <text> leaves a note on the game (see Notes on a game). The plugin's one hooks module is hooks/band.js, which loads the generated hooks/register.js unchanged; its words are in hooks/band-view.js, tested by test/band-view.test.mjs.
Play Claude from pi
Paste this prompt into pi:
Set me up to play timewalk from pi. Do each step in order and tell me what you did:
1. If `command -v timewalk` finds nothing, install it: `curl -fsSL https://get.timewalk.gg | sh`. Otherwise run `timewalk update`. Then `timewalk version` must be 0.3.0 or later; if it isn't, stop and tell me the release isn't out yet.
2. Run `timewalk status`. If it says I'm not signed in, run `timewalk login` and wait for me to finish in the browser.
3. In ~/.pi/agent/channels.json, add under "channelServers" the entry "timewalk": {"command": "timewalk", "args": ["channel"]}, keeping every existing entry (create the file as {"channelServers": {...}} if it is missing). Show me the diff before you write it.
4. If ~/.config/mcp/mcp.json has a "timewalk" entry under "mcpServers" (the old connector), remove it, keeping every other entry, and show me the diff before you write. The channel carries the game's tools now.
5. Install the playing skill: fetch https://raw.githubusercontent.com/schuettc/timewalk-cli/main/plugins/timewalk/skills/playing-timewalk/SKILL.md (with `gh api repos/schuettc/timewalk-cli/contents/plugins/timewalk/skills/playing-timewalk/SKILL.md -H 'Accept: application/vnd.github.raw'` if the plain fetch is refused) into ~/.pi/agent/skills/playing-timewalk/SKILL.md, replacing an older copy.
6. Tell me to run /reload (or restart pi).
Then ask pi for a game of timewalk. Every pi session runs the channel, and the game belongs to the session that starts it: only that session gets its moves.
Contribute snapshots and playbooks
Anyone on the timewalk writers list (the list that lets you play) can write a deck's playbook or capture a new snapshot and send it to the maintainer, who reviews it and opens the pull request. You don't need the timewalk repo: the plugin's skills read its snapshots, atlas and archived sources through the timewalk tools.
- Install the plugin as for playing (Claude Code or pi; in pi, fetch
plugins/timewalk/skills/contribute-playbook/SKILL.md and contribute-snapshot/SKILL.md the same way as the playing skill, into ~/.pi/agent/skills/<name>/SKILL.md).
- Ask Claude to draft a playbook for
<deck> (contribute-playbook), or to capture a snapshot of <format> from <dates> (contribute-snapshot). It asks your handle once: claims from your own play are cited as yours, [[player-<handle>]].
- Pages it reads that the archive doesn't hold yet are saved in
~/timewalk-contrib/<id>/sources/ and uploaded with the files. When you've read the draft, it submits it.