Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTP Request node doesn't include developer-token from Googla Ads OAuth2 API credential #14020

Open
hcirbian opened this issue Mar 18, 2025 · 1 comment
Labels
in linear Issue or PR has been created in Linear for internal review

Comments

@hcirbian
Copy link

Describe the problem/error/question

We are trying to do a specific request to Google Ads not covered by the Google Ads node. For this, we are using the HTTP Request node with the Google Ads OAuth2 API credential. But when executing the workflow, the HTTP Request node is not including the "developer token" from the credential, so the request fails with a DEVELOPER_TOKEN_PARAMETER_MISSING error.

See Google Ads example documentation, which states that the developer-token should be added to the request as a header:
https://developers.google.com/google-ads/api/rest/examples#streaming

Can you please fix this bug so the HTTP Request node includes the developer-token in its request when using the Google Ads OAuth2 credential? While this bug is solved, is there any workaround we can use?

Thanks a lot!

PD: By the way, the Google Ads node shared below works fine using the same credentials.

What is the error message (if any)?

400 - "[{\n "error": {\n "code": 400,\n "message": "Request contains an invalid argument.",\n "status": "INVALID_ARGUMENT",\n "details": [\n {\n "@type": "type.googleapis.com/google.ads.googleads.v19.errors.GoogleAdsFailure",\n "errors": [\n {\n "errorCode": {\n "requestError": "DEVELOPER_TOKEN_PARAMETER_MISSING"\n },\n "message": "developer-token parameter is missing."\n }\n ],\n "requestId": "cDQJlTJFo2QJ96e3rjj0yw"\n }\n ]\n }\n}\n]"

Please share your workflow/screenshots/recording

{
"nodes": [
{
"parameters": {},
"type": "n8n-nodes-base.manualTrigger",
"typeVersion": 1,
"position": [
-1360,
-340
],
"id": "3711242b-6a17-45d7-a3ad-7ce1bdc2b8ff",
"name": "When clicking ‘Test workflow’"
},
{
"parameters": {
"operation": "get",
"managerCustomerId": "xxx-xxx-xxxx",
"clientCustomerId": "xxx-xxx-xxxx",
"campaignId": "xxxxxxxxxxxx",
"requestOptions": {}
},
"type": "n8n-nodes-base.googleAds",
"typeVersion": 1,
"position": [
-940,
-540
],
"id": "358c646c-282d-4647-aae9-9788f3c9c002",
"name": "Google Ads",
"notesInFlow": false,
"credentials": {
"googleAdsOAuth2Api": {
"id": "mscVZtf49FzAPZp0",
"name": "Google Ads account"
}
}
},
{
"parameters": {
"method": "POST",
"url": "https://googleads.googleapis.com/v19/customers/xxxxxxxxxx/googleAds:searchStream",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "googleAdsOAuth2Api",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "application/json"
},
{
"name": "login-customer-id",
"value": "xxxxxxxxxx"
}
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={ "query":"SELECT campaign.name FROM campaign WHERE campaign.id = 'xxxxxxxxxxx'" }",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
-940,
-340
],
"id": "d090dd3e-5a0d-4e73-99bf-b5c956563b1f",
"name": "HTTP Request",
"credentials": {
"googleAdsOAuth2Api": {
"id": "mscVZtf49FzAPZp0",
"name": "Google Ads account"
}
}
}
],
"connections": {
"When clicking ‘Test workflow’": {
"main": [
[
{
"node": "Google Ads",
"type": "main",
"index": 0
},
{
"node": "HTTP Request",
"type": "main",
"index": 0
}
]
]
},
"Google Ads": {
"main": [
[]
]
}
},
"pinData": {},
"meta": {
"templateCredsSetupCompleted": true,
"instanceId": "602a3fb38e15c2ee821af2a0b04b5c1d86c98fb0e20da59128b397ea15e8307c"
}
}

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)
⚠️ WARNING ⚠️ If you have sensitive data in your workflow (like API keys), please remove it before sharing.

Share the output returned by the last node

{
"errorMessage": "Bad request - please check your parameters",
"errorDescription": "Request contains an invalid argument.",
"errorDetails": {
"rawErrorMessage": [
"400 - "[{\n \"error\": {\n \"code\": 400,\n \"message\": \"Request contains an invalid argument.\",\n \"status\": \"INVALID_ARGUMENT\",\n \"details\": [\n {\n \"@type\": \"type.googleapis.com/google.ads.googleads.v19.errors.GoogleAdsFailure\",\n \"errors\": [\n {\n \"errorCode\": {\n \"requestError\": \"DEVELOPER_TOKEN_PARAMETER_MISSING\"\n },\n \"message\": \"developer-token parameter is missing.\"\n }\n ],\n \"requestId\": \"7el-uAzaty08kCqSdpk29w\"\n }\n ]\n }\n}\n]""
],
"httpCode": "400"
},
"n8nDetails": {
"nodeName": "HTTP Request",
"nodeType": "n8n-nodes-base.httpRequest",
"nodeVersion": 4.2,
"itemIndex": 0,
"time": "3/18/2025, 2:07:09 PM",
"n8nVersion": "1.83.2 (Cloud)",
"binaryDataMode": "filesystem",
"stackTrace": [
"NodeApiError: Bad request - please check your parameters",
" at ExecuteContext.requestWithAuthentication (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/node-execution-context/utils/request-helper-functions.js:991:19)",
" at processTicksAndRejections (node:internal/process/task_queues:95:5)",
" at ExecuteContext.requestWithAuthentication (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/node-execution-context/utils/request-helper-functions.js:1147:20)"
]
}
}

Debug info

core

  • n8nVersion: 1.83.2
  • platform: docker (cloud)
  • nodeJsVersion: 20.18.3
  • database: sqlite
  • executionMode: regular
  • concurrency: 5
  • license: community

storage

  • success: all
  • error: all
  • progress: false
  • manual: true
  • binaryMode: filesystem

pruning

  • enabled: true
  • maxAge: 168 hours
  • maxCount: 2500 executions

client

  • userAgent: mozilla/5.0 (x11; linux x86_64) applewebkit/537.36 (khtml, like gecko) chrome/134.0.0.0 safari/537.36
  • isTouchDevice: false

Generated at: 2025-03-18T12:40:19.740Z}

@Joffcom
Copy link
Member

Joffcom commented Mar 18, 2025

Hey @hcirbian,

We have created an internal ticket to look into this which we will be tracking as "GHC-1261"

@Joffcom Joffcom added the in linear Issue or PR has been created in Linear for internal review label Mar 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in linear Issue or PR has been created in Linear for internal review
Projects
None yet
Development

No branches or pull requests

2 participants