| name | dbt-parser-refresh |
| description | Regenerates TypeScript types from dbt artifact JSON schemas. Use when the user asks to update parsers, sync with upstream, refresh types, or regenerate parser types from existing schemas. |
| compatibility | Requires pnpm, Node.js |
dbt Parser Refresh
Trigger scenarios
Activate this skill when the user says or implies:
- Refresh parsers, update parsers, sync parsers
- Update from dbt-core, sync with upstream dbt-core
- Regenerate TypeScript types, regenerate parser types, run codegen
- Download dbt schemas, pull schemas from dbt-core (note: this repo has no download script; schemas live in
resources/)
Scripts and paths
- Run commands from the repository root.
- Generate (only): Regenerate TypeScript types from existing JSON schemas under
packages/dbt-artifacts-parser/resources/json-schema/ (and legacy resources/<category>/ when used).
- From repo root:
pnpm --filter dbt-artifacts-parser gen:types or bash packages/dbt-artifacts-parser/scripts/generate.sh
- From package:
cd packages/dbt-artifacts-parser && pnpm gen:types
- Schema location:
packages/dbt-artifacts-parser/resources/json-schema/{catalog,manifest,run-results,sources,semantic_manifest}/ (JSON Schemas for codegen; kept separate from resources/manifest/ etc. so fixture discovery does not treat schemas as artifacts). Each *_vN.json file is turned into src/<category>/vN.ts. Legacy resources/<category>/ is still accepted for catalog/sources when present.
- Artifact categories:
catalog, manifest, run-results, sources, semantic_manifest.
- The generate script does not accept artifact_type or version arguments; it processes all
*_vN.json files in each category directory.
- Removing a schema: delete the matching
src/<category>/vN.ts yourself (partial regen does not delete absent versions). When adding a new major version, update hand-maintained src/<category>/index.ts (exports, Parsed* unions, parse helpers).
- Root
src/index.ts: still regenerated by generate.sh (catalog re-export); category index.ts files are not overwritten.
Adding new schemas
This repo has no download script. To add new schema versions, copy JSON schema files (e.g. from dbt-labs/dbt-core under schemas/dbt/ on GitHub raw, or https://schemas.getdbt.com/) into the appropriate packages/dbt-artifacts-parser/resources/json-schema/<category>/ directory (use *_vN.json filenames), then run the generate command above.
Example
Full regenerate (all categories and versions):
pnpm --filter dbt-artifacts-parser gen:types
Or from repo root using the script directly:
bash packages/dbt-artifacts-parser/scripts/generate.sh