Skip to content

docs(llm-analytics): add Claude Code installation guide#16318

Merged
andrewm4894 merged 2 commits intomasterfrom
claude/posthog-analytics-guide-49UFD
Apr 13, 2026
Merged

docs(llm-analytics): add Claude Code installation guide#16318
andrewm4894 merged 2 commits intomasterfrom
claude/posthog-analytics-guide-49UFD

Conversation

@andrewm4894
Copy link
Copy Markdown
Member

Summary

  • Adds a new LLM analytics installation guide for sending Claude Code sessions to PostHog
  • Covers setup via the PostHog AI plugin (claude plugin install posthog), which uses a SessionEnd hook to automatically capture generations, tool executions, and traces
  • Includes configuration options (env vars, privacy mode, trace grouping), verification steps, and retroactive ingestion of past sessions
  • Adds Claude Code to the sidebar navigation in the LLM analytics installation section

Assumes PostHog/ai-plugin#24 has been merged.

Test plan

  • Verify the new page renders correctly at /docs/llm-analytics/installation/claude-code
  • Verify Claude Code appears in the installation platform grid with the Anthropic icon
  • Verify sidebar navigation shows Claude Code between Pi Coding Agent and Manual capture
  • Verify all internal links in the guide resolve correctly

https://claude.ai/code/session_015Y4J4R4GUpWx595wwgCsfb

Add guide for sending Claude Code sessions to PostHog LLM Analytics
using the PostHog AI plugin's SessionEnd hook integration.

https://claude.ai/code/session_015Y4J4R4GUpWx595wwgCsfb
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 13, 2026

Deploy preview

Status Details Updated (UTC)
🟢 Ready View preview Apr 13, 2026 08:44AM

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 13, 2026

Vale prose linter → found 10 errors, 6 warnings, 0 suggestions in your markdown

Full report → Copy the linter results into an LLM to batch-fix issues.

Linter being weird? Update the rules!

contents/docs/llm-analytics/installation/claude-code.mdx — 10 errors, 6 warnings, 0 suggestions
Line Severity Message Rule
39:279 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
39:322 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
43:37 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
44:21 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
45:20 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
46:17 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
53:61 warning Use 'project token' instead of 'project API key'. The project token (phc_) is not an API key. PostHogBase.ProjectToken
63:70 warning Capitalize 'Logs' for PostHog's product. Use 'logs' for the general industry concept. PostHogBase.ProductNames
67:45 warning Use 'project token' instead of 'project API key'. The project token (phc_) is not an API key. PostHogBase.ProjectToken
122:51 warning Use 'project token' instead of 'project API key'. The project token (phc_) is not an API key. PostHogBase.ProjectToken
137:196 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
151:24 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
152:18 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
152:176 warning Use descriptive link text instead of '[learn more]'. PostHogBase.DescriptiveLinkText
153:19 error Hi, Andy here... use an en dash ( – ) with spaces. On Mac, holding down the Option and hyphen key will give you an en dash. PostHogBase.EnDash
153:123 warning Use descriptive link text instead of '[learn more]'. PostHogBase.DescriptiveLinkText

Use the Claude sparkle/starburst logo instead of the generic Anthropic
lettermark so Claude Code stands out in the installation platform list.

https://claude.ai/code/session_015Y4J4R4GUpWx595wwgCsfb
@andrewm4894 andrewm4894 merged commit a188350 into master Apr 13, 2026
19 checks passed
@andrewm4894 andrewm4894 deleted the claude/posthog-analytics-guide-49UFD branch April 13, 2026 13:33
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