When a kicked-off crew reaches a terminal failure state, the API currently returns a successful HTTP status (2xx) while indicating failure only in the response body. As a result, callers cannot distinguish a genuinely successful request from a failed job without manually inspecting the response payload.
Proposal: Introduce CrewAI::JobFailedError < CrewAI::Error and raise it in Client#parse whenever the response body indicates a terminal job failure.
When a kicked-off crew reaches a terminal failure state, the API currently returns a successful HTTP status (2xx) while indicating failure only in the response body. As a result, callers cannot distinguish a genuinely successful request from a failed job without manually inspecting the response payload.
Proposal: Introduce CrewAI::JobFailedError < CrewAI::Error and raise it in Client#parse whenever the response body indicates a terminal job failure.