Global options
Explore Fern CLI global options.
Quick Reference
When troubleshooting:
- Use
--log-level debug
to see detailed output when encountering issues - When using
--api
, ensure the API name matches exactly with the directory name in yourfern/apis/
folder
The following sections describe each global option in detail.
help
Use the --help
option with any Fern CLI command to see an explanation and available options.
log-level
Use the --log-level
option to set the verbosity of Fern’s logging output. The default level is info
.
Available levels (from most to least verbose):
debug
: Debug messages, informational messages, warnings, and errorsinfo
: Informational messages, warnings, and errorswarn
: Warnings and errors onlyerror
: Error messages only
api
Use the --api
option to target a specific API. This is particularly useful when your project contains multiple API definitions. The API name should match the directory name in your fern/apis/
folder.
group
Use the --group
option to target a specific generator group.
version
Use the --version
option to specify the SDK version number, typically following semantic versioning (semver) format (MAJOR.MINOR.PATCH
). This is particularly useful in CI/CD pipelines when publishing SDK releases.