wire / terminal-osc / 51
OSC 51 is iTerm2's shell integration protocol for marking prompts and commands (similar to OSC 133 but iTerm2-specific).
aka: OSC 51 · OSC 51 — Shell integration (iTerm2)
OSC introducer: \x1b] ESC ] (0x1B 0x5D)
terminator (ST|BEL): ST \x1b\ · BEL \x07
| id | name | bytes (ST) | meaning |
|---|---|---|---|
| mark | Mark prompt | \x1b]51;A\x1b\ | OSC 51 ; A ST marks the start of a prompt (iTerm2 variant). |
agent: curl -H 'accept: application/json' wire.phall.io/terminal-osc/51
or /terminal-osc/51.json