title: How to fix error:1408F10B:SSL routines:ssl3_get_record:wrong version number in guzzle 6 and laravel 5.7
body: <p>I want to get some data from the external API. I am using Guzzle 6 and Laravel 5.7 for doing this. But when I test it in postman, I got an error like this</p>
  
  <blockquote>
    <p>GuzzleHttp\Exception\ConnectException: cURL error 35: error:1408F10B:SSL routines:ssl3_get_record:wrong version number</p>
  </blockquote>
  
  <p>This is my code :</p>
  
  <pre><code>  public function testapi(Request $request){
          $xmlrequest = '&lt;soapenv:Envelope 
          xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"  
          xmlns:web="http://systemsunion.com/connect/webservices/"&gt; 
                    &lt;soapenv:Body&gt; 
                        &lt;web:SecurityProviderAuthenticateRequest&gt; 
                           &lt;web:name&gt;username&lt;/web:name&gt; 
                           &lt;web:password&gt;password&lt;/web:password&gt; 
                        &lt;/web:SecurityProviderAuthenticateRequest&gt; 
                     &lt;/soapenv:Body&gt; 
                  &lt;/soapenv:Envelope&gt;';
  
              $action = 'SecurityProviderAuthenticateRequest';     
              $url = 'https://xx.xx.xx.xx:xxxx/services/Provider?wsdl';
              $client = new Client();     
              $response = $client-&gt;post($url, [         
                              'headers' =&gt; [           
                                  'SOAPAction' =&gt; $action, // Add the action              
                                  'Content-Type' =&gt; 'text/xml'          
                              ],          
                              'body' =&gt; $xmlrequest 
                          ]); 
  
              if ($response) {
                  $res = $response-&gt;getBody()-&gt;getContents();
                  $doc = new \DOMDocument();
                  $doc-&gt;loadXML($res);
                  print_r($doc);
                  print_r($res);
                  exit();
              }
           }
  </code></pre>
  
  <p>How to fix this error?</p>