orval

Generate type-safe TypeScript API clients from OpenAPI specifications with Orval.

193|17|Updated Jan 16, 2026
One-click install
npx skills add https://github.com/pproenca/dot-skills --skill orval
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: orval
Source: https://github.com/pproenca/dot-skills/tree/main/skills/.experimental/orval
Command: npx skills add https://github.com/pproenca/dot-skills --skill orval

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve?

This Skill streamlines the process of generating type-safe TypeScript clients from OpenAPI specifications, reducing boilerplate code and preventing runtime errors.

Core Features & Use Cases

  • Type-Safe Client Generation: Automatically generates API client code (hooks, types, mocks) from OpenAPI specs.
  • Best Practices Enforcement: Provides 42 rules across 8 categories to ensure optimal configuration and output.
  • Use Case: When setting up a new project that consumes a REST API, use this Skill to generate a robust and type-safe client using Orval, integrating seamlessly with tools like React Query.

Quick Start

Configure Orval to generate a React Query client from your OpenAPI specification located at './openapi.yaml'.

Frequently Asked Questions about orval

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

FAQPage Schema
How do I generate a type-safe TypeScript API client from an OpenAPI specification?

Orval generates type-safe TypeScript API clients from OpenAPI specifications by creating hooks, types, and mocks automatically. This reduces boilerplate code and prevents runtime errors by enforcing strict type safety across API integration workflows.

Can I integrate generated API clients with React Query for data fetching?

Yes, Orval generates API clients that seamlessly integrate with React Query. It produces type-safe hooks for data fetching and mutations, ensuring type safety across your React Query workflows without manual boilerplate.

What are the best practices for configuring Orval for code generation?

Configuring Orval for code generation involves applying 42 best-practice rules across 8 categories. These rules ensure optimal configuration, code organization, custom mutators, and query library integration for robust TypeScript client generation.

Does Orval support generating mocks from OpenAPI specifications?

Yes, Orval supports generating mocks from OpenAPI specifications. Alongside type-safe client code and hooks, it automatically generates mocks to streamline testing and development workflows for API integration.

How do I set up custom mutators for a generated TypeScript API client?

To set up custom mutators for a generated TypeScript API client, configure Orval with custom mutator functions. This allows you to tailor API request and response handling while maintaining strict type safety and following best-practice code organization.