session_clear_all
Clear all gateway session records, optionally filtering by provider, to reset session state and trigger asynchronous worktree cleanup.
Instructions
Delete all gateway session records, optionally scoped to one provider. The tool result confirms record deletion; worktree cleanup observers run asynchronously and may still be in progress. Worktree cleanup runs per session on the processing host for file-backed and PostgreSQL session managers. Both managers stage a caller-hidden cleanup tombstone before cleanup runs and retain a failed removal for retry by the host that owns the worktree, finalizing the record only once Git no longer registers the worktree, read back rather than inferred from the recorded path being absent. File-backed TTL eviction uses the same tombstone retry path. Deletion processed by a different host removes no worktree and leaves the owning host's record intact. The database-side cleanup_expired_sessions function stages the same tombstone instead of deleting a worktree-bearing session; it invokes no gateway observer and so attempts no removal itself. A tombstone is not bounded by retention.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cli | No | Provider filter (claude|codex|gemini|grok|mistral|devin|cursor|grok-api) |