Validate song analysis inputs before sending requests
recoup songs analyze previously sent inputs that the API rejects: both selectors together or no audio. Validate exactly one of --preset/--prompt plus required --audio before sending a request, with clear corrective errors and no HTTP call on failure. Add Node 22 development types so TypeScript checking also works.
Validation: production bundle, 77 tests and tsc --noEmit pass. Tests mock the HTTP client; no provider or billable request is made.
This is a small fix against current main, independent of the broader open CLI #23 expansion; that PR will need to preserve these validations when rebased. Coordinated documentation identifies source versus installed package behavior.
Refs recoupable/mono#355 and recoupable/mono#318.
Summary by cubic
Validates recoup songs analyze inputs before hitting the API: it now requires exactly one of --preset or --prompt plus --audio, failing fast with clear errors and no HTTP call instead of sending requests the API rejects. Adds Node 22 development types and runs tsc --noEmit in the CI workflows so type checking passes locally and in publish.
- Tests mock the HTTP client; no provider or billable request is made.
- Refs
recoupable/mono#355andrecoupable/mono#318; the broader CLI #23 expansion will need to preserve these validations when rebased.