Skip to content

holocron-skill-client

Scaffolds a complete HTTP client package in clients/ of theholocron/holocron, following the current patterns. The standalone theholocron/clients repo is archived.

Invoke as: /holocron-skill-client

Trigger: user asks to add a new HTTP client package to the clients group.

A new clients/<slug>-client/ directory with:

  • package.json — MIT, repository.directory set, version matching the clients/ group, workspace:^ on @theholocron/http-client, catalog:configs / catalog: dev dependencies
  • tsconfig.json, plus one-line tsdown.config.ts and vitest.config.ts re-exporting the shared presets
  • src/utils.ts — create<Vendor>RestClient() using createRestClient from @theholocron/http-client
  • src/<resource>/<resource>.ts — one file per API resource
  • src/index.ts — public API surface
  • src/index.test.ts — tests beside the source, using stubFetch (DI fetch pattern)

The workspace glob (clients/*) and release config already cover the new folder. By hand:

  1. Run pnpm install and commit the updated lockfile.
  2. Add a component under the # clients heading of codecov.yml (generated by holocron setup; add the block in the same format).
  3. Add the docs page docs/src/content/docs/clients/<slug>.mdx, a row in clients/index.mdx and the sidebar entry in the root astro.config.ts.
  4. Run holocron run ci.
  • The clients/ folder is one version group: set version to the group’s current version
  • Use createRestClient from @theholocron/http-client — no raw fetch calls in the client factory
  • Use stubFetch in tests — DI pattern, no vi.stubGlobal; no __tests__ directories
  • Reference implementation: clients/axiom-client