public function httpAuth()
    {
        $client_id     = $this->settings['client_id'];
        $client_secret = $this->settings['client_secret'];
        
        $headerToken = base64_encode("$client_id:$client_secret");

        $headers = array('Accept' => 'application/json', 'Authorization' => "Basic $headerToken");

        $request_path = "api/oauth/token";
        $domain       = $this->ddnDomain();
        $full_url     = $domain . $request_path;
        
        \Unirest\Request::curlOpts(array(
            CURLOPT_SSL_VERIFYHOST => 0,
            CURLOPT_SSLVERSION => 6,
            CURLOPT_SSL_VERIFYPEER => false,
            CURLOPT_TIMEOUT => $this->settings['timeout'] !== 30 ? $this->settings['timeout'] : 30
        ));

        $data = array('grant_type' => 'client_credentials');
        $body = \Unirest\Request\Body::form($data);
        $response = \Unirest\Request::post($full_url, $headers, $body);

        return $response;
    }