add-resource
Installation
SKILL.md
Adding a new resource to posthog-definitions
This skill is the playbook for extending posthog-definitions with a new PostHog resource type. It covers the what to change and why, not the line-by-line code — copy the existing dashboard/insight pair as a reference and adapt.
When to use
The user wants to manage a new PostHog resource as code, e.g.:
- "Let's add feature flags."
- "I want to define cohorts in TypeScript."
- "Add survey support to apply."
If the user only wants a one-off API call or a script, this is the wrong tool — this skill is for resources that should join the load → validate → diff → execute pipeline.
Before you touch anything
Re-read these three files. The whole architecture is in them: