Skip to content

infra: regen-js-client skill#48

Open
bzajzon-laserfiche wants to merge 2 commits into
mainfrom
claude-infra-and-docs
Open

infra: regen-js-client skill#48
bzajzon-laserfiche wants to merge 2 commits into
mainfrom
claude-infra-and-docs

Conversation

@bzajzon-laserfiche
Copy link
Copy Markdown
Contributor

Summary

First team-shared playbook for AI coding assistants in this repo. No code changes.

.claude/skills/regen-js-client/SKILL.md covers the NSwag regen flow for the V2 client (packages/lf-repository-api-client-v2) and the four traps that have silently broken the test suite in the past:

  1. --swagger-override-filepath is mandatory — without it, Entry.fromJS regenerates as throw-only and every importEntry/getEntry/listEntries call fails at deserialization.
  2. .env baseUrl must NOT have a trailing slash — NSwag prepends / to every path; trailing slash yields //v2/… and 404s.
  3. jsdom multipart-Blob test wrapper — every test that sends a Blob in multipart form must be wrapped with describe.skipIf(SKIP_UNDER_JSDOM) until #658052 closes. The current 12 wrapped files are listed in the skill.
  4. [OpenApiTag] client-split — NSwag's MultipleClientsFromFirstTagAndOperationId mode generates one client class per unique tag; an outlier tag on the server side silently disappears the method from entriesClient.

.claude/skills/README.md explains discovery (Claude Code auto-scans SKILL.md frontmatter; bodies are vendor-neutral) and authoring conventions.

Architecture rationale: site-api-repository/docs/design-ai-assistant-skills.md (in companion PR).

Companion PRs

  • site-api-repository: add-v2-endpoint skill + design doc
  • lf-repository-api-client-dotnet: regen-dotnet-client skill

First team-shared skill for AI coding assistants in this repo. Documents
the NSwag-generated V2 client regen against site-api-repository's
swagger, plus the four traps that have silently broken the JS test
suite in the past: swagger-override-filepath, baseUrl trailing-slash,
jsdom multipart-Blob skip (#658052), and OpenApiTag client-split.

README.md explains discovery (auto-scan of .claude/skills/*/SKILL.md
frontmatter; vendor-neutral bodies so other assistants can read them)
and authoring conventions.

No change to the repo-level README intentionally; the skills system is
scoped to its own directory in client libraries.
Replaces the reference to the (now-deleted) preview-NuGet user-story
memory with a direct link to the regen-dotnet-client skill, which is
the canonical home for the dotnet client publish workflow and the
in-flight #659276 Phase 2 details.
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.

1 participant