The generators.yml file serves two roles: it declares your OpenAPI specification location (in the api.specs section), and configures SDK generation (in the optional groups section).
APIs declared here can be rendered in your documentation via docs.yml. See Generate your API Reference.
Path to the OpenAPI specification file.
URL of the API definition origin for pulling updates. For instructions on how to set up automatic syncing, refer to Sync your OpenAPI specification.
Path to an OpenAPI Overlay file. Overlays follow the OpenAPI Overlay Specification and are the recommended approach for customizing OpenAPI specifications.
Path to an OpenAPI overrides file, or a list of paths to multiple override files applied sequentially. Consider using overlays instead for a standards-based approach.
Namespace for the specification. Useful for configuring a single package with multiple API versions.
OpenAPI-specific generation settings for this individual spec. To apply the same settings across all OpenAPI specs, use global api.settings instead.
Whether to use the titles of schemas within an OpenAPI definition as the names of types within Fern.
Whether to include path parameters within the generated in-lined request.
Whether to inline allOf schemas during code generation. When true, Fern recursively visits allOf schema definitions and inlines them into the child schema. When false, allOf schemas are extended through inheritance.
Enabling this setting allows child schemas to override parent property requirements. For example, a child schema can mark a parent’s required property as optional. Without this setting, Fern ignores the child schema’s optional declaration and preserves the parent schema’s requirement instead.
Whether to prefer undiscriminated unions with literals.
Whether to only include schemas referenced by endpoints in the generated SDK (tree-shaking).
Preserves nullable schemas in API definition settings. When false, nullable schemas are treated as optional.
Enables parsing deep object query parameters.
Controls whether references to nullable schemas are wrapped in optional types. When false, nullable references are treated as required fields that can be null.
Controls whether optional schemas are coerced to nullable types during code generation. When false, optional and nullable are treated as distinct concepts.
Enables exploring readonly schemas in OpenAPI specifications.
Enables respecting forward compatible enums in OpenAPI specifications.
Enables using the bytes type for binary responses. Defaults to file stream.
The default encoding of form parameters. Options: form, json.
Configure what additionalProperties should default to when not explicitly defined on a schema.
If true, convert strings with format date to strings. If false, convert to dates.
If true, preserve oneOf structures with a single schema. If false, unwrap them.
Filter to apply to the OpenAPI specification. Use this to limit which endpoints are included in the generated SDK or API Reference docs based on their paths.
For tag-based filtering instead of path-based filtering, use audiences at the group level.
Endpoints to include in the generated SDK. Specify endpoints in the format METHOD /path (e.g., POST /users, GET /users/{id}). Only the listed endpoints will be included in the generated SDK; all other endpoints will be excluded. If your API uses namespaces, prefix with the namespace and :: (e.g., payments::POST /users).
Controls the maximum depth for which optional properties will have examples generated. A depth of 0 means no optional properties will have examples.
Controls the maximum depth for which optional properties will have examples generated in responses.
Controls whether enums are converted to literal types during code generation. When false (default), enums are preserved as enum types, maintaining the original enum structure from your OpenAPI specification. When true, enums are coerced to literal types, which can be useful for simpler type representations in generated code.
Controls the naming convention for autogenerated request names. When enabled, places the verb before the noun in request names (e.g., UsersListRequest becomes ListUsersRequest), following more idiomatic naming patterns.
Inlines type aliases to simplify your generated SDK. When enabled, reduces unnecessary type definitions by replacing simple aliases with their underlying types directly. Useful for OpenAPI specs with many primitive or simple type aliases.
Set to true to inline all aliases, or use an object with an except array
to preserve specific type aliases:
When enabled, groups servers by host into unified environments, enabling APIs with multiple protocols (REST, WebSocket, etc.) to share environment configuration. Environment URL IDs use the server name, with path or protocol suffixes added only when needed to resolve collisions.