npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@intentsolutionsio/posthog-pack

v1.0.2

Published

Claude Code skill pack for PostHog - 24 skills covering product analytics and feature flags

Readme

PostHog Skill Pack

Claude Code skill pack for PostHog product analytics — event capture, feature flags, experiments, session recordings, and HogQL queries (24 skills)

What This Covers

PostHog is an open-source product analytics platform. This pack provides production-ready patterns for posthog-js (browser), posthog-node (server), and the PostHog REST/HogQL API. Every skill uses real PostHog endpoints, actual SDK methods, and working code — not placeholders.

Key PostHog concepts covered: event capture (posthog.capture), user identification (posthog.identify), group analytics (posthog.group), feature flags (getFeatureFlag, isFeatureEnabled, getAllFlags), A/B experiments, cohorts, session recordings, autocapture configuration, HogQL queries, CDP webhook destinations, and the /capture/, /batch/, /decide/ API endpoints.

Installation

/plugin install posthog-pack@claude-code-plugins-plus

Skills

Getting Started (S01-S04)

| Skill | What It Does | |-------|-------------| | posthog-install-auth | Install posthog-js/posthog-node, configure phc_ and phx_ API keys | | posthog-hello-world | First event capture, identify, and feature flag check (Node + browser + Python + curl) | | posthog-local-dev-loop | Debug mode, mocked PostHog for vitest, integration tests against dev project | | posthog-sdk-patterns | Singleton client, typed events, React hooks, Next.js App Router provider, reverse proxy |

Core Workflows (S05-S08)

| Skill | What It Does | |-------|-------------| | posthog-core-workflow-a | Event taxonomy design, posthog.capture, identify, group, server-side capture, annotations API | | posthog-core-workflow-b | Feature flags (boolean + multivariate), getAllFlags, experiments, cohorts API | | posthog-common-errors | Fix events not appearing, flags returning undefined, 401/429 errors, identity fragmentation | | posthog-debug-bundle | Diagnostic script: SDK versions, API connectivity, event capture test, flag evaluation test |

Operations (S09-S12)

| Skill | What It Does | |-------|-------------| | posthog-rate-limits | PostHog rate limit tiers (240/min analytics, unlimited capture), backoff, request queue | | posthog-security-basics | phc_ vs phx_ key security, scoped API keys, rotation procedure, git leak prevention | | posthog-prod-checklist | Production SDK config, graceful degradation wrappers, health check endpoint, serverless pattern | | posthog-upgrade-migration | posthog-node v5 breaking changes (sendFeatureFlags), before_send, upgrade procedure |

Pro Skills (P13-P18)

| Skill | What It Does | |-------|-------------| | posthog-ci-integration | GitHub Actions with mocked unit tests, integration tests, deployment annotations | | posthog-deploy-integration | Next.js + Vercel reverse proxy, edge function capture, self-hosted Docker, Cloud Run | | posthog-webhooks-events | CDP webhook destinations, event handler routing, Events API, HogQL queries | | posthog-performance-tuning | Local flag evaluation (<1ms), batching config, event sampling, efficient HogQL | | posthog-cost-tuning | Autocapture tuning, before_send sampling, bot filtering, session recording sampling, billing monitoring | | posthog-reference-architecture | File structure, event taxonomy, flag constants, analytics module, data pipeline integration |

Flagship Skills (F19-F24)

| Skill | What It Does | |-------|-------------| | posthog-multi-env-setup | Separate projects per env, environment-aware SDK config, flag rollout per env | | posthog-observability | Flag evaluation latency instrumentation, event volume monitoring, Prometheus alerts, HogQL dashboards | | posthog-incident-runbook | Triage decision tree, immediate actions for 401/429/500, graceful degradation, evidence collection | | posthog-data-handling | GDPR sanitize_properties, consent opt-in/opt-out, data deletion API, PII-safe exports | | posthog-enterprise-rbac | Org/project hierarchy, member roles, scoped API keys, SSO/SAML, activity audit log | | posthog-migration-deep-dive | Migrate from GA/Mixpanel/Amplitude, dual-write adapter, historical import, flag-controlled cutover |

Quick Reference

| Operation | SDK Method | |-----------|-----------| | Capture event | posthog.capture({ distinctId, event, properties }) | | Identify user | posthog.identify({ distinctId, properties }) | | Group analytics | posthog.group('company', 'id', { name: '...' }) | | Check boolean flag | posthog.isFeatureEnabled('flag-key', userId) | | Get multivariate flag | posthog.getFeatureFlag('flag-key', userId) | | Get all flags | posthog.getAllFlags(userId) | | Flush events | await posthog.flush() or await posthog.shutdown() |

API Key Types

| Key | Prefix | Purpose | Client-safe? | |-----|--------|---------|-------------| | Project API Key | phc_ | Event capture, flag evaluation | Yes | | Personal API Key | phx_ | Admin API, local flag eval, HogQL | Never |

License

MIT