getMessage()) { case "Failed": throw ApiError::failed("Refresh failed"); case "NotFound": throw ApiError::unauthorized("Not authorized"); default: throw $err; } } } }