CLI

orval reference

orval provides a set of options that allow you to generate your models or the API calls of your application. This page contains a complete list of all orval options available.

To download and install orval, follow the instructions here.

Basic Usage

The orval command is used to generate client with appropriate type-signatures. By default search for an orval.config.js file.

$ orval

Input

The --input option, shorthand -i, can be used to set the path or link to your OpenApi specification.

$ orval --input ./petstore.yaml

Output

The --output option, shorthand -o, can be used to set the path to where you want to generate your models and HTTP calls.

$ orval --output ./api/endpoints/petstoreFromFileSpec.ts"

Config

The --config option, shorthand -c, can be used to set the path to an orval config.

$ orval --config ./api/orval.config.js

Projet

The --project option, shorthand -p, can be used to focus on one project of your orval config.

$ orval --project petstore
Was this page helpful?

© 2020 Victor Bury. All rights reserved.