Skip to content

feat: add Kotlin Multiplatform (KMP) integration skill#240

Merged
turnipdabeets merged 1 commit into
mainfrom
feat/kmp-support
Jul 15, 2026
Merged

feat: add Kotlin Multiplatform (KMP) integration skill#240
turnipdabeets merged 1 commit into
mainfrom
feat/kmp-support

Conversation

@turnipdabeets

Copy link
Copy Markdown
Contributor

Adds Kotlin Multiplatform (KMP) support to the context mill so the PostHog wizard can fetch KMP integration context at runtime.

Why

The wizard's KMP support (PostHog/wizard#906) is gated on a context-mill release that includes KMP — the wizard pulls its per-framework skills from context-mill releases. This PR adds that KMP skill.

Changes

Mirrors the existing docs-only mobile/language variants (Flutter, Elixir, Go) — no example app, docs + framework guidelines:

  • context/skills/integration/config.yaml — new kmp variant (template: description-kmp-docs-only.md, tags [kmp, kotlin, multiplatform, mobile], docs from /docs/libraries/kmp).
  • context/skills/integration/description-kmp-docs-only.md — KMP-specific docs-only description template (detect a kotlin("multiplatform") project, install com.posthog:posthog-kmp in commonMain, PostHog.setup(...) with per-platform PostHogContext, com.posthog.kmp package).
  • context/commandments.yamlkmp framework guidelines: commonMain install location, the com.posthog.kmp package, per-platform PostHogContext, thin-wrapper-over-native behavior, HOST_US/HOST_EU, and Maven Central versioning (0.x pre-release).

Verification

  • npm run build → generates the integration-kmp skill: SKILL.md with the KMP instructions, the fetched references/kmp.md (from /docs/libraries/kmp.md), and all KMP commandments embedded under "Framework guidelines". Also produced dist/skills/integration-kmp.zip.
  • npm test → 107/107 pass.

Notes

  • Draft, mirroring the draft wizard PR — the SDK is 0.x pre-release (published on Maven Central at 0.0.2).
  • The identifiers line up with the wizard's KMP config (Integration.kmp, packageName: posthog-kmp, docsUrl: /docs/libraries/kmp): the generated skill id is kmp / integration-kmp.
  • No example app included (like Flutter/Go/Elixir); a example-apps/kmp app could be a follow-up once the SDK stabilizes.
  • This needs a context-mill release cut after merge for the wizard to consume it. cc @gewenyu99

🤖 Generated with Claude Code

Adds a docs-only integration variant for the PostHog Kotlin Multiplatform
SDK (posthog-kmp), mirroring the existing docs-only mobile entries (Flutter,
Elixir, Go):

- context/skills/integration/config.yaml: new `kmp` variant (docs-only,
  tags [kmp, kotlin, multiplatform, mobile], docs from /docs/libraries/kmp)
- context/skills/integration/description-kmp-docs-only.md: KMP-specific
  docs-only description template
- context/commandments.yaml: `kmp` framework guidelines (commonMain install,
  com.posthog.kmp package, PostHog.setup with per-platform PostHogContext,
  native-wrapper behavior, Maven Central versioning)

Build generates `integration-kmp` skill (SKILL.md + fetched /docs/libraries/kmp
reference + embedded commandments); `npm run build` and `npm test` (107) pass.

This provides the KMP context the wizard fetches at runtime, unblocking
PostHog/wizard#906.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

🧙 Wizard CI

Run the Wizard CI and test your changes against wizard-workbench example apps by replying with a GitHub comment using one of the following commands:

Test all apps:

  • /wizard-ci all

Test all apps in a directory:

  • /wizard-ci basic-integration
  • /wizard-ci mcp-analytics
  • /wizard-ci revenue

Test an individual app:

  • /wizard-ci basic-integration/android
  • /wizard-ci basic-integration/angular
  • /wizard-ci basic-integration/astro
Show more apps
  • /wizard-ci basic-integration/django
  • /wizard-ci basic-integration/fastapi
  • /wizard-ci basic-integration/flask
  • /wizard-ci basic-integration/javascript-node
  • /wizard-ci basic-integration/javascript-web
  • /wizard-ci basic-integration/laravel
  • /wizard-ci basic-integration/next-js
  • /wizard-ci basic-integration/nuxt
  • /wizard-ci basic-integration/python
  • /wizard-ci basic-integration/rails
  • /wizard-ci basic-integration/react-native
  • /wizard-ci basic-integration/react-router
  • /wizard-ci basic-integration/sveltekit
  • /wizard-ci basic-integration/swift
  • /wizard-ci basic-integration/tanstack-router
  • /wizard-ci basic-integration/tanstack-start
  • /wizard-ci basic-integration/vue
  • /wizard-ci mcp-analytics/custom-dispatcher
  • /wizard-ci mcp-analytics/typescript-sdk
  • /wizard-ci revenue/stripe

Results will be posted here when complete.

@turnipdabeets
turnipdabeets marked this pull request as ready for review July 15, 2026 15:57
@turnipdabeets
turnipdabeets requested a review from a team as a code owner July 15, 2026 15:57
@turnipdabeets
turnipdabeets requested a review from a team July 15, 2026 15:57
@turnipdabeets
turnipdabeets merged commit 22ed9f1 into main Jul 15, 2026
15 checks passed
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