Agent skill · Databases

data-validation

Provides comprehensive guidance for input validation, data serialization, and ID management in backend APIs. This skill should be used when designing validation schemas, transforming request/response data, mapping database IDs to external identifiers, and ensuring type safety across API boundaries.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill data-validation-allenlin90-eridu-services-2 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 7 KB
Bundled scripts: none
Path: skills/api/data-validation-allenlin90-eridu-services-2/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Data Validation Skill Provides comprehensive guidance for input validation, response serialization, and ID management. ## Core Concepts **API Contract vs Internal Implementation**: ``` ┌─────────────────────────────────────────┐ │ Client (External) │ │ snake_case IDs, user-friendly │ └──────────────┬──────────────────────────┘ │ HTTP API Boundary │ ┌──────────────▼──────────────────────────┐ │ Your Application (Internal) │ │ camelCase IDs, database structure │ └─────────────────────────────────────────┘ ``` **Responsibilities at each layer**: | Layer | Responsibility | | ---------- | -------------------------------------------------- | | Controller | Validate input (schema), serialize output (schema) | | Service | Business logic with internal format | | Repository | Database access with internal format | | Database | Storage with primary keys | ## ID Management Pattern ### External API Contract ``` URL: GET /admin/users/:id // id = uid (user_abc123) Response: { "id": "user_abc123", // UID mapped as id "email": "user@example.com", "name": "John Doe", // NO "uid" field // NO database "id" field (bigint primary key) } ``` ### Internal Implementation ``` Database: { id: 12345, // big

What's inside
Steps it walks through
  1. Core Concepts
  2. ID Management Pattern
  3. External API Contract
  4. Internal Implementation
  5. UID Format
  6. Input Validation Pattern
  7. Response Serialization Pattern
  8. Nested Validation
  9. Type Mapping
  10. Pagination Validation
  11. Error Messages
  12. Best Practices Checklist
  13. Related Skills
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the data-validation skill do?

Provides comprehensive guidance for input validation, data serialization, and ID management in backend APIs. This skill should be used when designing validation schemas, transforming request/response data, mapping database IDs to external identifiers, and ensuring type safety across API boundaries.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill data-validation-allenlin90-eridu-services-2 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going