-
Notifications
You must be signed in to change notification settings - Fork 103
Description
- macos
- "google-ads-api": "^17.1.0-rest-beta"
- node version v22.13.0
- OAuth client ID app type is Desktop app.
main code:
const customer = client.Customer({ customer_id: customer_id, refresh_token: refresh_token, }); const campaigns = await customer.report({ entity: "campaign", attributes: [ "campaign.id", "campaign.name", "campaign.bidding_strategy_type", "campaign_budget.amount_micros", ], metrics: [ "metrics.cost_micros", "metrics.clicks", "metrics.impressions", "metrics.all_conversions", ], constraints: { "campaign.status": enums.CampaignStatus.ENABLED, }, limit: 20, });
I got the error:
node_modules/google-ads-api/build/src/customer.js:395
googleAdsFailure = new Error(data?.value?.error?.message ?? defaultErrorMessage, { cause: data?.value?.error ?? data?.value });
^
Error: SSL is required to perform this operation.
at Chain. (/xx/node_modules/google-ads-api/build/src/customer.js:395:36)
at Object.onceWrapper (node:events:639:26)
at Chain.emit (node:events:524:28)
at addChunk (node:internal/streams/readable:561:12)
at readableAddChunkPushObjectMode (node:internal/streams/readable:538:3)
at Readable.push (node:internal/streams/readable:393:5)
at StreamArray. (/xx/node_modules/stream-chain/index.js:136:45)
at StreamArray.emit (node:events:524:28)
at addChunk (node:internal/streams/readable:561:12)
at readableAddChunkPushObjectMode (node:internal/streams/readable:538:3) {
[cause]: {
code: 403,
message: 'SSL is required to perform this operation.',
status: 'PERMISSION_DENIED'
}
}