api-contract-review

Review REST API contracts for HTTP mapping, DTO validation, and exception handling.

Updated Feb 24, 2026
One-click install
npx skills add https://github.com/Exar-lab/Bank-project --skill api-contract-review-exar-lab
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-contract-review
Source: https://github.com/Exar-lab/Bank-project/tree/main/.agents/skills/api-contract-review
Command: npx skills add https://github.com/Exar-lab/Bank-project --skill api-contract-review-exar-lab

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill unit provides a standardized way to ensure that REST API contracts meet industry best practices, including correct HTTP verb/status code mapping, validation, error handling, and security checks.

Core Features & Use Cases

  • HTTP Verb/Status Code Mapping: Ensures proper use of HTTP verbs and status codes for REST endpoints.
  • Validation: Ensures that request DTOs are validated using @Valid annotations.
  • Error Handling: Ensures proper global exception handling and structured error responses.
  • Security: Ensures use of @PreAuthorize for securing endpoints and handling security-related exceptions.

Quick Start

Run the 'api-contract-review' skill before designing or reviewing a REST API endpoint to validate its contract compliance.

Frequently Asked Questions about api-contract-review

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

FAQPage Schema
How do I ensure my REST API contract follows correct HTTP verb and status code mapping?

To ensure REST API contract compliance, you must map HTTP verbs to correct status codes for each endpoint. This validation process checks that your HTTP methods and response codes align with industry best practices before API deployment.

How do I validate request DTOs in a Spring Framework REST API?

Validating request DTOs in a Spring Framework REST API requires applying the @Valid annotation to incoming request objects. This ensures data integrity by triggering validation constraints before the API processes the request payload.

What is the best way to implement global exception handling for REST APIs?

The best way to implement global exception handling for REST APIs is to establish a standardized mechanism for structured error responses. This ensures consistent security and error management across all endpoints during the API review process.

Does this REST API contract review process work with Spring Framework security annotations?

Yes, the REST API contract review process works with Spring Framework security by verifying the use of @PreAuthorize annotations. It checks that endpoints are properly secured and that security-related exceptions are handled correctly.

When do I need to run an API contract compliance check during development?

You need to run an API contract compliance check before designing or reviewing any REST API endpoint. It is applicable across all stages of API development to validate HTTP verb mapping, DTO validation, and exception handling continuously.