client-api-wire-shape-verification
CommunityPrevent API wire shape drift before shipping code.
System Documentation
What problem does it solve?
This Skill fixes the common issue where TypeScript compiles cleanly for a typed API client wrapper, but the first real API call returns a 400 error or causes a silent runtime crash due to mismatched field names, types, or nullability between the client's assumed shape and the actual backend implementation. It eliminates bugs caused by relying on stale plan documents, incorrect schema guesses, or outdated Prisma model assumptions instead of the actual backend source code.
Core Features & Use Cases
- Backend Source-of-Truth Verification: Guides you to validate client wrapper shapes against actual backend route handlers, body validators, and Prisma query returns rather than plan docs or schema guesses.
- Step-by-Step Verification Recipe: Provides a mandatory pre-commit checklist for all new or modified typed request<T>() calls to catch field-name drift, type drift, and nullability drift.
- 400 Error Diagnosis: Includes targeted steps to debug "tsc passes but endpoint 400s" issues by diffing actual backend response JSON against client TypeScript types.
- Use Case: Use this Skill when writing or modifying typed API client wrappers, Prisma model to TypeScript type mappings, or Zod schema to backend DTO alignments in full-stack applications where frontend and backend are developed by separate agents or teams.
Quick Start
Use the client-api-wire-shape-verification skill to cross-check your typed API client wrapper's field names, types, and nullability against the actual backend route handler before committing the code.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: client-api-wire-shape-verification Download link: https://github.com/freedomw1987/tree_monstor/archive/main.zip#client-api-wire-shape-verification Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 536,000+ vetted skills library on demand.