KUBB_INPUT_NOT_FOUND: Input not found
Code: KUBB_INPUT_NOT_FOUND
Level: error
The file set as input (or passed as kubb generate PATH) could not be read. The OpenAPI adapter checks the path before parsing, so the run stops here instead of failing later with a vague read error.
What happened
Kubb resolves a file input relative to the config file, then confirms the file exists before reading it. This diagnostic fires when nothing is there. URLs skip this check, so a remote spec surfaces its own fetch error instead.
Common causes
- A typo in
input, or a path relative to the wrong directory. - The spec was moved or renamed but the config still points at the old location.
kubb generate ./spec.yamlran from a directory where that relative path does not resolve.
How to fix it
- Check the path exists and is readable, then set it as
inputor pass it askubb generate PATH. - Use a path relative to your
kubb.config.ts, or an absolute path. - For a remote spec, set
inputto the full URL.
Example output
text
[KUBB_INPUT_NOT_FOUND] @kubb/adapter-oas: Cannot read the file set as `input` (or via `kubb generate PATH`): ./petStore.yaml
fix: Check that the path exists and is readable, then set it as `input` or pass it as `kubb generate PATH`.
see: https://kubb.dev/docs/5.x/reference/diagnostics/kubb-input-not-found