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

feat: google ads v14 upgrade #2577

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { getMappingConfig } = require('../../util');

const API_VERSION = 'v13';
const API_VERSION = 'v14';

const BASE_ENDPOINT = `https://googleads.googleapis.com/${API_VERSION}/customers/:customerId`;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ describe('getExisitingUserIdentifier util tests', () => {
describe('getClickConversionPayloadAndEndpoint util tests', () => {
it('getClickConversionPayloadAndEndpoint flow check when default field identifier is present', () => {
let expectedOutput = {
endpoint: 'https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions',
endpoint: 'https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions',
payload: {
conversions: [
{
Expand All @@ -187,7 +187,7 @@ describe('getClickConversionPayloadAndEndpoint util tests', () => {
delete fittingPayload.traits.email;
delete fittingPayload.properties.email;
let expectedOutput = {
endpoint: 'https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions',
endpoint: 'https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions',
payload: {
conversions: [
{
Expand Down Expand Up @@ -215,7 +215,7 @@ describe('getClickConversionPayloadAndEndpoint util tests', () => {
delete fittingPayload.traits.phone;
delete fittingPayload.properties.email;
let expectedOutput = {
endpoint: 'https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions',
endpoint: 'https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions',
payload: {
conversions: [
{
Expand Down Expand Up @@ -251,7 +251,7 @@ describe('getClickConversionPayloadAndEndpoint util tests', () => {
},
];
let expectedOutput = {
endpoint: 'https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions',
endpoint: 'https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions',
payload: {
conversions: [
{
Expand Down
38 changes: 19 additions & 19 deletions test/__tests__/data/google_adwords_offline_conversions.json
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -418,7 +418,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -677,7 +677,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -936,7 +936,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -1796,7 +1796,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -1896,7 +1896,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -2090,7 +2090,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -2257,7 +2257,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -2461,7 +2461,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -2651,7 +2651,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -3077,7 +3077,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -3383,7 +3383,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -3544,7 +3544,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -3827,7 +3827,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -3993,7 +3993,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -4163,7 +4163,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -4294,7 +4294,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -4421,7 +4421,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -4546,7 +4546,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/11122233331/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/11122233331/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -75,7 +75,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1112223333/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/1112223333/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -145,7 +145,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/customerid/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/customerid/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -215,7 +215,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1234567890:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/1234567890:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -320,7 +320,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1234567891:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/1234567891:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -425,7 +425,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/1234567891:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/1234567891:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"code": 400,
"details": [
{
"@type": "type.googleapis.com/google.ads.googleads.v13.errors.GoogleAdsFailure",
"@type": "type.googleapis.com/google.ads.googleads.v14.errors.GoogleAdsFailure",
"errors": [
{
"errorCode": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/7693729833/offlineUserDataJobs",
"endpoint": "https://googleads.googleapis.com/v14/customers/7693729833/offlineUserDataJobs",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -130,7 +130,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadClickConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadClickConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -259,7 +259,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/9625812972:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/9625812972:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down Expand Up @@ -367,7 +367,7 @@
"version": "1",
"type": "REST",
"method": "POST",
"endpoint": "https://googleads.googleapis.com/v13/customers/7693729833:uploadCallConversions",
"endpoint": "https://googleads.googleapis.com/v14/customers/7693729833:uploadCallConversions",
"headers": {
"Authorization": "Bearer abcd1234",
"Content-Type": "application/json",
Expand Down