curl request via PHP to method 'api/integrations/chat/system' return "error: EOF" #3333
-
Hello! When I send request to method 'api/integrations/chat/system' with PHP curl, it's return $contents = curl_exec($c); if ($contents) return $contents; What could be the problem? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
My problem was invalid CURLOPT_POST and CURLOPT_HTTPHEADER params. For POST request need to be set CURLOPT_POST parameter to 1 and CURLOPT_HTTPHEADER as 'Content-Type: application/json'. |
Beta Was this translation helpful? Give feedback.
My problem was invalid CURLOPT_POST and CURLOPT_HTTPHEADER params. For POST request need to be set CURLOPT_POST parameter to 1 and CURLOPT_HTTPHEADER as 'Content-Type: application/json'.