Today I am facing same issue for Ads running on my site https://bdjobsfeed.com/
Bing Ads API: Error Fetching http headers
We use bingads PHP lib. Sometimes, when we try to make a call using GetCampaignCriterionsByIds or AddCampaignCriterions methods we get "Error Fetching http headers" but when repeat call we get success. Why does it happen? What does this error mean exactly?
3 answers
Sort by: Most helpful
-
-
Eric Urban - MSFT 626 Reputation points Microsoft Employee
2021-04-11T12:49:22.667+00:00 The error seems not specific to the Bing Ads API.
There are some suggestions in this stackoverflow thread.
In case it helps we will be updating the PHP SDK for passing custom options to SoapClient. In the meantime you can modify your local copy as needed here.
-
Eric Nagel 1 Reputation point
2021-04-15T22:34:45.67+00:00 So this isn't a solution to the problem, but it's a work around that's working for me:
$failed = false; do { try { $poll_response = $this->ServiceClient->GetService()->PollGenerateReport($request); $failed = false; } catch(\Exception $e) { $failed = true; } } while ($failed);