input-boundary-guardrails

Normalize external API inputs with centralized validation utilities and type contracts.

2|1|Updated Dec 15, 2025
One-click install
npx skills add https://github.com/sgpropertyanalytics/sg-property-analytics --skill input-boundary-guardrails
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: input-boundary-guardrails
Source: https://github.com/sgpropertyanalytics/sg-property-analytics/tree/main/.claude/skills/input-boundary-guardrails
Command: npx skills add https://github.com/sgpropertyanalytics/sg-property-analytics --skill input-boundary-guardrails

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Backend input validation and type safety guardrails that MUST be activated before writing or modifying ANY API route handlers that accept external input. They enforce boundary normalization, canonical types, fail-fast validation, and single-source parsing to prevent runtime errors from untrusted data.

Core Features & Use Cases

  • Boundary normalization and centralized helpers (to_int, to_date, to_bool)
  • Fail-fast validation with explicit error messages across route handlers
  • Clear internal contracts and canonical types guiding service logic
  • Use Case: ensure external inputs (query params, JSON bodies, headers) are safe before business logic runs.

Quick Start

Apply the input boundary guardrails to your API routes and normalize all external inputs at the boundary before any processing.

Frequently Asked Questions about input-boundary-guardrails

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is input boundary normalization for backend route handlers?

Yes, you can enforce fail-fast validation on environment-derived values across services. The guardrails apply strict type contracts and boundary normalization to environment variables just as they do for query parameters and JSON bodies, returning explicit 400-level validation errors when values are unsafe.

How do I prevent type mismatches and runtime errors from untrusted API inputs?

Prevent type mismatches and runtime errors from untrusted API inputs by applying boundary guardrails that parse and normalize external data at the API entry point. This single-source parsing approach enforces canonical types and stops invalid data before it reaches service logic.

Do I need to normalize external inputs before writing API route handlers?

Yes, you must normalize external inputs before writing or modifying any API route handlers that accept external data. Activating these boundary guardrails first ensures that query params, JSON bodies, and headers are safe and correctly typed before business logic executes.

What is the best way to return clear validation errors for invalid API input types?

The best way to return clear validation errors for invalid API input types is to use centralized boundary normalization that provides explicit 400-level error messages with input-type context. This fail-fast approach immediately rejects untrusted data that fails type contract checks.