success: false instead of a normal JobResult. The outputs and metadata fields are absent; an error field is present with a human-readable description of what went wrong.
Error response structure
Always
false for error responses.The name of the operation that failed, e.g.
"resize" or "crop". Use this to correlate errors in streaming sessions where multiple jobs may be in flight.Human-readable description of the error.
Example
Common errors
| Error message | Cause |
|---|---|
Input file not found | The path in input or inputs does not exist or is not readable. |
Invalid image format | The file exists but cannot be decoded — unsupported format or corrupted data. |
width is required | A resize or similar operation was submitted without a widths array or scale_percent. |
Must specify either 'rect' or 'gravity' | A crop job did not include either a manual rectangle or a smart crop mode. |
Invalid rotation angle | The angle field for a rotate job is not one of 0, 90, 180, or 270. |
Opacity must be between 0.0 and 1.0 | The opacity value on a watermark job is outside the valid range. |
Output path required | An operation that writes a single file (e.g. crop, rotate, watermark) was sent without an output field. |
At least one width must be specified | The widths array on a resize or srcset job was empty. |
Error handling in Go
The Go client distinguishes between two categories of failure:- Transport / spawn errors — the
errreturn value from a client method is non-nil. The Rust process could not start, timed out, or crashed before writing a response. - Operation errors —
errisnilbutresult.Successisfalse. The engine ran successfully and returned a structured error describing what went wrong with the job.
StreamClient, the pattern is identical:
Timeout configuration
Operations that process large files (video transcode, batch jobs) can take longer than the default 30-second timeout. Adjust it before sending the job:err return value with a context deadline message; result will be nil.