Emit Claude Code plugin hint at module load time - #2805
Merged
Conversation
johno-stripe
requested review from
jar-stripe
and
a lite review from Copilot
and removed request for
a team
August 6, 2026 21:04
johno-stripe
enabled auto-merge (squash)
August 6, 2026 21:07
This was referenced Aug 6, 2026
xavdid
approved these changes
Aug 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why?
Claude Code supports a plugin hint feature, where if we detect the
CLAUDECODEorCLAUDE_CODE_CHILD_SESSIONenvironment variables, emitting the following string will prompt the user to install our official plugin:<claude-code-hint v="1" type="plugin" value="stripe@claude-plugins-official" />Our plugin's source code can be found here.
What?
Note that while this will fire frequently, Claude Code will automatically hide these log lines and keep the user from being re-prompted:
My first approach was to emit this using a post-install script, but npm unfortunately hides the output from the installing process, so those error logs didn't successfully reach Claude.
See Also
Key source here is the documentation on how plugin hints work:
Changelog
CLAUDECODEorCLAUDE_CODE_CHILD_SESSIONenvironment variables are detected.