for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace NotificationChannels\Unisender\Exceptions;
use GuzzleHttp\Exception\RequestException;
use Psr\Http\Message\ResponseInterface;
class ApiRequestFailedException extends \RuntimeException
{
/**
* @var ResponseInterface
*/
protected $response;
* ApiRequestFailedException constructor.
*
* @param RequestException $exception
* @param ResponseInterface $response
public function __construct(RequestException $exception, ResponseInterface $response)
parent::__construct('API Request Failed', $response->getStatusCode(), $exception);
$this->response = $response;
}
* @return ResponseInterface
public function getResponse()
return $this->response;