managing-endpoint-versions
Fungsinya
Skill ini menjelaskan cara kerja versi endpoint dan cara mengembalikan atau melihat pratinjau perubahan tanpa merusak penggunaan yang aktif. Ditujukan untuk orang yang mengedit endpoint dan ingin menghindari kejutan.
Kapan dipakai
- βSaat Anda ingin mengembalikan endpoint ke versi yang lebih lama.
- βSaat Anda ingin menguji perubahan kueri di playground sebelum diaktifkan.
- βSaat Anda ingin memperbarui deskripsi atau pengaturan kesegaran pada satu versi tanpa membuat versi baru.
Link skill
https://github.com/PostHog/posthog/blob/master/products/endpoints/skills/managing-endpoint-versions/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βBagaimana cara mengembalikan endpoint saya ke versi 3?β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Mengubah kueri membuat versi baru, sedangkan mengubah pengaturan memperbarui versi yang dipilih di tempat. Skill menggunakan ini untuk menunjukkan cara yang aman untuk menguji dan mengembalikan perubahan.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Managing endpoint versions
This skill is the practical guide to endpoint versioning. It covers the today-workflow, which has some sharp edges worth being explicit about.
When to use this skill
- "How do I roll back to v3?"
- "I want to test changes before they go live"
- "How do I update the description /
data_freshness_secondson a specific version?" - "Can I disable v4 without affecting v5?"
- The user is uncertain whether a query change will cut a new version
Versioning model β what to know
| Behaviour | Reality |
|---|---|
| Query change | Auto-cuts a new version. Saving any edit to the query creates a new version and bumps the current version number |
Settings change (description, data_freshness_seconds, materialisation) |
Does not cut a new version. Updates the targeted version in place |
| The "current" version | Always the highest version number β it's not a pointer you can move backwards |
Calling without ?version=N |
Runs the latest version. So unpinned callers always hit the newest |
| Disabling the whole endpoint | endpoint-update with is_active: false (no version) takes every version offline at once |
| Disabling a single version | endpoint-update with version + is_active: false retires one version without affecting the others |
The model is forward-only. There is no "make v3 the default again" operation today. Practically
this means "rollback" requires either creating a new top version that re-uses the old query, or
pinning callers to ?version=N.
Available tools
| Tool | Purpose |
|---|---|
endpoint-versions |
List all versions for an endpoint, latest first |
endpoint-get |
Full config; supports ?version=N to fetch a specific version |
endpoint-update |
The workhorse β supports version body param to target a specific version |
endpoint-run |
Execute a version directly via ?version=N (without affecting which version other callers hit) |
Workflows
Previewing a draft before publishing
There is no "draft" concept in the model. Editing the query commits it as a new version immediately. To preview safely:
- Test the new query first with the
execute-sqltool (or the SQL editor) β not on the live endpoint - When ready, update the endpoint β this creates the new version automatically
- Use
endpoint-runwith?version=Nto confirm the new version returns what you expect - Old callers still hit the latest version (which is now your new version) β there is no "soft launch"
If the user needs a true staging endpoint, the only workaround today is a sibling endpoint
with a _v2 or _staging suffix. Document this honestly β there is no in-product staging path.
Rolling back to an older version
The forward-only model means "rollback" requires forking:
endpoint-versionsto find the version with the good query (say v3)endpoint-getwith?version=3to retrieve that version's query JSONendpoint-updatewith the v3 query as the new query β this creates a new version (e.g. v6) with the same query as v3- All callers without
?version=Nnow hit v6 (== v3's query)
The old version (v5, the broken one) still exists and is still callable via ?version=5 until
explicitly deactivated.
Faster mitigation if you can change every caller: have them pin to ?version=3 until a real
fix is ready. Lower-impact than cutting a
Pertanyaan umum
Apakah mengubah pengaturan membuat versi baru?
Tidak. Pengaturan seperti deskripsi atau kesegaran memperbarui versi yang dituju secara langsung.
Apakah mengubah kueri membuat versi baru?
Ya. Menyimpan perubahan kueri secara otomatis membuat versi baru dan menaikkan nomor versi saat ini.
Bisakah saya menonaktifkan versi lama tanpa memengaruhi versi baru?
Bisa. Skill mencakup penonaktifan versi tertentu, yang membiarkan versi lainnya tidak berubah.
Detail
Deskripsi asli dari pembuat
Work safely with endpoint versions β preview a draft in the playground, roll back to an older version, update settings on one version without bumping query history, deactivate a specific version. Use when the user asks "how do I roll back my endpoint", "preview my changes before publishing", "I want to fix v5 without bumping the version", or anything involving the version history. Calls out today's limitations honestly: there is no pointer flip; "rollback" means forking the old query into a new top version.
repo: PostHog/posthog
Popularitas
- Bintang GitHub
- 41k
- Peringkat
- #6863
- Lisensi
- β
- Diperbarui
- 2/11/2026
Komentar
- β¦
Skill lain dari repositori ini
depot-ci
41kMembantu agent Anda menyiapkan dan menjalankan alur kerja Depot CI, alternatif GitHub Actions, termasuk memigrasikan alur kerja yang ada dan membaca log eksekusi.
depot-container-builds
41kMembantu agent Anda membangun image Docker di builder jarak jauh Depot, termasuk image multi-platform, pengiriman ke registry, dan perbaikan kegagalan build.
depot-github-runners
41kMembantu agent Anda memindahkan job GitHub Actions ke runner yang dikelola Depot, memilih ukuran dan label runner, serta memecahkan masalah pengaturan runner.
editing-agents-md
41kMembantu agent Anda memutuskan apakah sebuah aturan layak masuk ke berkas AGENTS.md atau CLAUDE.md, dan menulisnya agar tetap dipatuhi tanpa membuat berkas membengkak.
Skill serupa
discrawl
394kMemungkinkan agent Anda mencari dan merangkum arsip pesan Discord lokal yang tersimpan, memeriksa seberapa baru arsipnya, dan membaca pesan langsung.
clickhouse-io
280kMembantu agent Anda mengoptimalkan query dan skema di database ClickHouse dengan praktik terbaik analitik berperforma tinggi. Gunakan saat query analitik terlalu lambat.
scientific-db-pubmed-database
280kMembantu agent Anda mencari artikel ilmiah di bidang biomedis. Berguna untuk riset yang membutuhkan informasi medis spesifik.