private function sendRequest(string $endPoint, string $method, string $content = "", bool $https = true): Response
    {
        $url = ($https ? "https://" : "http://") . self::DOMAIN . "/" .$endPoint;
        $request = \Httpful\Request::init($method, 'application/json');
        $request->basicAuth($this->accountToken, $this->apiToken)
                ->addHeader('User-Agent', 'iP1sms/indev')
                ->expectsJson()
                ->Uri($url)
                ->body($content, 'application/json')
                ->neverSerialize();

        $response = $request->send();

        if ($response->hasErrors()) {
            $this->errorResponses[] = $response;
        }
        return $response;
    }