Skip to content

[Plugin] adding install id to the active-session marker - #157

Draft
alexfarnhambrown wants to merge 1 commit into
mainfrom
alex/adding-install-id-to-session-marker
Draft

[Plugin] adding install id to the active-session marker#157
alexfarnhambrown wants to merge 1 commit into
mainfrom
alex/adding-install-id-to-session-marker

Conversation

@alexfarnhambrown

@alexfarnhambrown alexfarnhambrown commented Aug 25, 2026

Copy link
Copy Markdown

Summary

Adds the installation UUID to active-session.json so Vercel CLI telemetry can attribute a command to the plugin installation that ran it.

#136 added plugin:install_id to the plugin's own phone-home but deliberately kept it out of the marker. The CLI only reads the marker, so today it can tell that a command ran inside a plugin session but not which installation that session belonged to. Consumer PR: vercel/vercel#17542. Tracked in PIPE-6602.

Changes

  • hooks/src/telemetry.mtsinstallId?: string on ActiveSessionMarker, populated from the existing getOrCreateInstallationId()
  • README.md — the telemetry section stated the ID is never written to the marker, which this changes
  • Version 0.48.1 → 0.49.0, hook bundle rebuilt
  • Test coverage for the new field

Stays on schema 1

The field is additive and optional, so older readers ignore it. A bump would actively break things: the shipped CLI reader does a hard marker.schema !== 1 → return null, so schema 2 would blank out vercel_plugin_active_session and vercel_plugin_version for everyone until they upgrade their CLI.

Optional rather than required because getOrCreateInstallationId() returns null when the file can't be written or read back.

Tests

bun test          # 975 passing
bun run validate  # clean

Rollout note

anthropics/claude-plugins-official pins this repo to commit 19606ac (0.45.1), 10 commits behind main. #136 is inside that gap, so the official-marketplace population isn't emitting plugin:install_id yet and won't pick this up either until that pin moves.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

@jeffsee55 jeffsee55 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was earlier discussion about whether this UUID should stay plugin-only or also go on active-session.json #136 kept it plugin-only so as long as we're ok to do that 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants