chore(codegen): daily schema refresh (2026-06-20)#42
Open
timgl wants to merge 1 commit into
Open
Conversation
Regenerate src/generated/api.d.ts from the live PostHog OpenAPI schema (filtered by openapi-filter.yaml) and patch two resource clients for upstream schema-component renames. - dashboard/client.ts: PatchedDashboard -> PatchedPatchedDashboardOpenApi - experiment/client.ts: PaginatedExperimentList -> PaginatedExperimentBasicList No filter changes: all new operationIds under managed families are non-CRUD sub-actions or full-PUT variants the resources don't use. Generated-By: PostHog Code Task-Id: 2e95497b-db18-4591-9a76-b417f7c88b21
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Daily OpenAPI schema refresh — 2026-06-20
Automated refresh of
src/generated/api.d.tsfrom the live PostHog OpenAPIspec (
https://us.posthog.com/api/schema/?format=json, filtered byopenapi-filter.yaml). Regenerated only viapnpm codegen— no hand edits togenerated types.
Spec diff size
src/generated/api.d.ts: +1958 / −156 lines (17,571 → 19,373)New operationIds added to the filter
None. All operationIds newly appearing under managed resource families
(insights, dashboards, feature_flags, experiments, cohorts, actions,
event_definitions, event_schemas, schema_property_groups, experiment_holdouts,
experiment_saved_metrics) are non-CRUD sub-actions — activity logs, sharing,
bulk_update_tags, tile/widget manipulation, suggestions, stats — or full-PUT*_updatevariants where the resource already uses PATCH (*_partial_update).None are needed for the infrastructure-as-code CRUD wrappers, so the allowlist
was left untouched. Everything else in the drift report (agent_applications,
error_tracking, llm_analytics, vision_scanners, conversations, tasks,
warehouse, …) is product/runtime surface, out of scope for a definitions tool.
No brand-new resource family warranted onboarding this cycle.
Resources touched
Two upstream schema-component renames broke
pnpm typecheck; patched the typealiases minimally (no logic/refactor):
src/resources/dashboard/client.ts—PatchedDashboard→PatchedPatchedDashboardOpenApi(the dashboards PATCH request body; retainsrestriction_levelandtiles)src/resources/experiment/client.ts—PaginatedExperimentList→PaginatedExperimentBasicList(the experiments list response)Verification
pnpm typecheck✅pnpm test✅ (35 files, 291 tests)Lint/format were not run repo-wide —
mainis not currentlyprettier-clean (68 pre-existing files) and the constraint is to avoid touching
unrelated files. The two edited lines are not flagged by prettier.
Unresolved drift
live spec — nothing to flag for human deletion.
PaginatedExperimentList,PatchedDashboard,AggregationPropertyType1(replaced by
AggregationPropertyType). Handled by the two client patchesabove; no manual deletion needed.
Generated by the daily schema-refresh agent.
TaskRun:
2e95497b-db18-4591-9a76-b417f7c88b21