Hi,
I getting the following error while accessing the CM360 API via python application.
2022-06-07 12:15:16,403 - ERROR - Failed with exception HttpError: <HttpError 503 when requesting
https://dfareporting.googleapis.com/dfareporting/v3.5/userprofiles/5785039/reports/960643433/files?alt=json returned "The service is currently unavailable.". Details: "[{'message': 'The service is currently unavailable.', 'domain': 'global', 'reason': 'backendError'}]">
Traceback (most recent call last):
File "/python/jobs/dcm_reports/__main__.py", line 82, in <module>
report_run = dfa.poll_report(report, event_date, timeout=timeout, interval=interval)
File "/python/library/dfareporting/dfareporting.py", line 227, in poll_report
report_run = self.get_report_run(report, end_date)
File "/python/library/dfareporting/dfareporting.py", line 175, in get_report_run
.list(profileId=self.profile_id, reportId=report_id)
File "/usr/local/lib/python3.7/site-packages/googleapiclient/_helpers.py", line 131, in positional_wrapper
return wrapped(*args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/googleapiclient/http.py", line 937, in execute
raise HttpError(resp, content, uri=self.uri)
googleapiclient.errors.HttpError: <HttpError 503 when requesting
https://dfareporting.googleapis.com/dfareporting/v3.5/userprofiles/5785039/reports/960643433/files?alt=json returned "The service is currently unavailable.". Details: "[{'message': 'The service is currently unavailable.', 'domain': 'global', 'reason': 'backendError'}]">
Traceback (most recent call last):
This is what I am looking to pull.
from .types import Report
search_dcm_report = Report(
dataset="dcm",
table="search_dcm_report",
report={
"name": "search_dcm_report",
"fileName": "search_dcm_report",
"format": "CSV",
"type": "STANDARD",
"criteria": {
"dateRange": {
"kind": "dfareporting#dateRange",
"relativeDateRange": "LAST_7_DAYS",
},
"dimensions": [
{"kind": "dfareporting#sortedDimension", "name": "advertiser"},
{"kind": "dfareporting#sortedDimension", "name": "advertiserId"},
{"kind": "dfareporting#sortedDimension", "name": "campaign"},
{"kind": "dfareporting#sortedDimension", "name": "campaignId"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchAdGroup"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchAdGroupId"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchEngineAccount"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchKeyword"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchKeywordId"},
{"kind": "dfareporting#sortedDimension", "name": "paidSearchMatchType"},
],
"metricNames": [
"paidSearchClicks",
"paidSearchImpressions",
"paidSearchCost",
],
},
"schedule": {
"active": True,
"repeats": "DAILY",
"every": 1,
"startDate": "2022-05-25",
"expirationDate": "2050-06-23",
},
"delivery": {"emailOwner": False},
},
csv_params={"header": 0, "skipfooter": 1},
)
Could you please tell me why I am getting that error? Thanks.