it2 artifact add
Add an artifact to a session
Synopsis
it2 artifact add <session-id> <category> [flags]
Description
Attach an artifact to an iTerm2 session.
Categories:
buffer-snapshot Capture current buffer state
buffer-diff Store buffer changes since last snapshot
file Attach a file produced during session
event Log an event received by session
note Add a note or annotation
error Log an error that occurred
custom Custom artifact type
The artifact is stored in ~/.it2/sessions/
with an automatically generated filename based on timestamp.
Examples:
Capture buffer snapshot
$ it2 artifact add sess_abc123 buffer-snapshot
Attach a file
$ it2 artifact add sess_abc123 file --path output.txt --description "Build output"
Add a note
$ it2 artifact add sess_abc123 note --data "Started debugging memory leak"
Log an event
$ it2 artifact add sess_abc123 event --data '{"type":"notification","message":"Task completed"}'
Store buffer diff
$ it2 artifact add sess_abc123 buffer-diff --since 2025-10-10T14:30:00Z
Options
-
-d,--data - Inline data content
-
--description - Description of the artifact
-
--format(default "table") - Output format (table|json|yaml|text)
-
--lines(default 10000) - Number of buffer lines to capture (for buffer-snapshot)
-
--name - Custom name for artifact (default: auto-generated)
-
-p,--path - Path to file to attach
-
--since - Timestamp for diff comparison (for buffer-diff)
-
--timeout(default "5s") - Command timeout
-
--url(default "ws://localhost:1912") - iTerm2 WebSocket URL
See Also
- it2 artifact - Manage session artifacts and attachments