From 0f8b8a2b403735cb13c34a363cf3f7140f8281be Mon Sep 17 00:00:00 2001 From: Sankeerth Date: Fri, 18 Oct 2024 15:03:39 +0530 Subject: [PATCH] chore: cleanup pinterest tag old tests (#3815) Co-authored-by: Sai Sankeerth --- test/__tests__/data/pinterest_tag_input.json | 2491 ----------------- test/__tests__/data/pinterest_tag_output.json | 1027 ------- .../pinterest_tag_router_batch_output.json | 943 ------- .../pinterest_tag_router_error_input.json | 124 - .../pinterest_tag_router_error_output.json | 59 - .../data/pinterest_tag_router_input.json | 1212 -------- .../data/pinterest_tag_router_output.json | 735 ----- .../data/pinterest_tag_step_input.json | 2476 ---------------- .../data/pinterest_tag_step_output.json | 911 ------ .../__tests__/pinterestConversion-cdk.test.ts | 135 - 10 files changed, 10113 deletions(-) delete mode 100644 test/__tests__/data/pinterest_tag_input.json delete mode 100644 test/__tests__/data/pinterest_tag_output.json delete mode 100644 test/__tests__/data/pinterest_tag_router_batch_output.json delete mode 100644 test/__tests__/data/pinterest_tag_router_error_input.json delete mode 100644 test/__tests__/data/pinterest_tag_router_error_output.json delete mode 100644 test/__tests__/data/pinterest_tag_router_input.json delete mode 100644 test/__tests__/data/pinterest_tag_router_output.json delete mode 100644 test/__tests__/data/pinterest_tag_step_input.json delete mode 100644 test/__tests__/data/pinterest_tag_step_output.json delete mode 100644 test/__tests__/pinterestConversion-cdk.test.ts diff --git a/test/__tests__/data/pinterest_tag_input.json b/test/__tests__/data/pinterest_tag_input.json deleted file mode 100644 index 15e378caf6..0000000000 --- a/test/__tests__/data/pinterest_tag_input.json +++ /dev/null @@ -1,2491 +0,0 @@ -[ - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "gender": "non-binary", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsTestEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Order completed", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "product added", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "product_id": "123", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Product List Filtered", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Product List Filtered", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "group", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "enhancedMatch": true, - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "channel": "abc", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123", - "adTrackingEnabled": true - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "ip": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "adTrackingEnabled": false - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "requestIP": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "Hashed phone", - "gender": "Hashed Gender", - "dob": "Hashed DB", - "lastname": "Hashed Lastname", - "firstName": "Hashed FirstName", - "address": { - "city": "Hashed City", - "state": "Hashed State", - "zip": "Hashed Zip", - "country": "Hashed country" - } - }, - "device": { - "adTrackingEnabled": false, - "advertisingId": "Hashed maids" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": false, - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "requestIP": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": ["Hashed phone", "Hashed phone1"], - "gender": ["Hashed Gender", "Hashed Gender1"], - "dob": ["Hashed DB", "Hashed DB1"], - "lastname": ["Hashed Lastname", "Hashed Lastname1"], - "firstName": ["Hashed FirstName", "Hashed FirstName1"], - "address": { - "city": ["Hashed City", "Hashed City1"], - "state": ["Hashed State", "Hashed State1"], - "zip": ["Hashed Zip", "Hashed Zip1"], - "country": ["Hashed country", "Hashed country1"] - } - }, - "device": { - "adTrackingEnabled": false, - "advertisingId": "Hashed maids" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": false, - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "name": "Test Tool", - "type": "page", - "sentAt": "2023-02-01T00:00:00.379Z", - "userId": "", - "channel": "web", - "context": { - "os": { - "name": "", - "version": "" - }, - "app": { - "name": "RudderLabs JavaScript SDK", - "version": "2.22.3", - "namespace": "com.rudderlabs.javascript" - }, - "page": { - "url": "https://www.abc.com/s598907", - "path": "/test-path/s598907", - "title": "Test Tool + Reviews | Rudderstack", - "search": "", - "tab_url": "https://www.abc.com/s598907", - "referrer": "$direct", - "initial_referrer": "$direct", - "referring_domain": "", - "initial_referring_domain": "" - }, - "locale": "en-US", - "screen": { - "width": 1024, - "height": 1024, - "density": 1, - "innerWidth": 1024, - "innerHeight": 1024 - }, - "traits": {}, - "library": { - "name": "RudderLabs JavaScript SDK", - "version": "2.22.3" - }, - "campaign": {}, - "doNotSell": false, - "sessionId": 1675209600203, - "userAgent": "Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; Googlebot/2.1; +http://www.google.com/bot.html) Chrome/109.0.5414.101 Safari/537.36", - "gaClientId": { - "integrations": { - "Google Ads": { - "gclid": "" - }, - "Google Analytics": { - "clientId": "1518934611.1234569600" - } - } - }, - "sessionStart": true - }, - "rudderId": "7291a10f-e7dd-49f9-94ce-0154f53897y6", - "messageId": "1c77a616-13a7-4a2e-a8e7-e1a0971897y6", - "timestamp": "2023-02-01T12:47:30.030Z", - "properties": { - "sku": "45790-32", - "url": "https://www.abc.com/23rty", - "name": "Test Tool", - "path": "/test-path/tool", - "email": "", - "title": "Test Tool + Reviews | Rudderstack", - "review": { - "reviewCount": 2, - "averageReview": 5, - "reviewContentID": ["238300132"] - }, - "search": "", - "tab_url": "https://www.abc/com", - "pageInfo": { - "pageId": "s592897", - "category": { - "pageType": "product", - "subCategory": "Dining & Kitchen Furniture", - "pageTemplate": "product detail grouper", - "primaryCategory": "Furniture" - }, - "brandType": "new brand" - }, - "referrer": "", - "subCategory": "Dining & Kitchen Furniture", - "primaryCategory": "Furniture", - "initial_referrer": "$direct", - "referring_domain": "", - "initial_referring_domain": "" - }, - "receivedAt": "2023-02-01T12:47:30.038Z", - "request_ip": "66.249.72.218", - "anonymousId": "a61c77a6-1613-474a-aee8-e7e1a0971047", - "integrations": { - "All": true - }, - "originalTimestamp": "2023-02-01T00:00:00.371Z" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123478671210", - "sendingUnHashedData": false, - "enableDeduplication": false, - "eventsMapping": [ - { - "from": "Product Added", - "to": "AddToCart" - }, - { - "from": "Order Completed", - "to": "Checkout" - }, - { - "from": "Product Viewed", - "to": "PageVisit" - }, - { - "from": "Lead", - "to": "Lead" - }, - { - "from": "Signup", - "to": "Signup" - } - ], - "enhancedMatch": true - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "test", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "sku": "1234", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "sku": "1234", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - } - ] - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Track call with v5 Api version and send external_id toggle enabled", - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendExternalId": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Custom event with v5 Api version", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Custom event with v5 Api version, with unhashed User Data and the values are an array of strings", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": ["abc@gmail.com", "def@gmail.com"], - "phone": ["+1234589947", "+1234589948"], - "ge": ["male", "male"], - "db": ["19950715", "19970615"], - "lastname": ["Rudderlabs", "Xu"], - "firstName": ["Test", "Alex"], - "address": { - "city": ["Kolkata", "Mumbai"], - "state": ["WB", "MH"], - "zip": ["700114", "700115"], - "country": ["IN", "IN"] - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Ad Account Id check in V5", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Conversion Token check in V5", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": false, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } -] diff --git a/test/__tests__/data/pinterest_tag_output.json b/test/__tests__/data/pinterest_tag_output.json deleted file mode 100644 index dccdb248c9..0000000000 --- a/test/__tests__/data/pinterest_tag_output.json +++ /dev/null @@ -1,1027 +0,0 @@ -[ - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": { - "test": true - }, - "body": { - "JSON": { - "action_source": "web", - "event_name": "watch_video", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome", - "ge": ["1b16b1df538ba12dc3f97edbb85caa7050d46c148134290feba80f8236c83db9"] - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "checkout", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "add_to_cart", - "action_source": "web", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 2, - "content_ids": ["123"], - "contents": [ - { - "quantity": 2, - "item_price": "25" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Advertiser Id not found. Aborting" - }, - { - "statusCode": 400, - "error": "It is required at least one of em, hashed_maids or pair of client_ip_address and client_user_agent" - }, - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "watch_video", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "num_items": 2, - "order_id": "50314b8e9bcf000000000000", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Advertiser Id not found. Aborting" - }, - { - "statusCode": 400, - "error": "message type group is not supported" - }, - { - "statusCode": 400, - "error": "Action source must be one of app_android, app_ios, web, offline" - }, - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "action_source": "web", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "num_items": 2, - "order_id": "50314b8e9bcf000000000000", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "page_visit", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "opt_out": false, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "opt_out": true, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "client_ip_address": "127.0.0.0", - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "action_source": "web", - "opt_out": true, - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "user_data": { - "ph": ["Hashed phone"], - "db": ["Hashed DB"], - "ln": ["Hashed Lastname"], - "fn": ["Hashed FirstName"], - "ct": ["Hashed City"], - "st": ["Hashed State"], - "zp": ["Hashed Zip"], - "country": ["Hashed country"], - "hashed_maids": ["Hashed maids"], - "ge": ["Hashed Gender"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "action_source": "web", - "opt_out": true, - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "user_data": { - "ph": ["Hashed phone", "Hashed phone1"], - "db": ["Hashed DB", "Hashed DB1"], - "ln": ["Hashed Lastname", "Hashed Lastname1"], - "fn": ["Hashed FirstName", "Hashed FirstName1"], - "ct": ["Hashed City", "Hashed City1"], - "st": ["Hashed State", "Hashed State1"], - "zp": ["Hashed Zip", "Hashed Zip1"], - "country": ["Hashed country", "Hashed country1"], - "hashed_maids": ["Hashed maids"], - "ge": ["Hashed Gender", "Hashed Gender1"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "body": { - "JSON": { - "event_time": 1675255650, - "event_source_url": "https://www.abc.com/s598907", - "action_source": "web", - "app_name": "RudderLabs JavaScript SDK", - "app_version": "2.22.3", - "language": "en-US", - "event_id": "1c77a616-13a7-4a2e-a8e7-e1a0971897y6", - "advertiser_id": "123478671210", - "user_data": { - "client_ip_address": "66.249.72.218", - "client_user_agent": "Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; Googlebot/2.1; +http://www.google.com/bot.html) Chrome/109.0.5414.101 Safari/537.36" - }, - "event_name": "page_visit" - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 0, - "content_ids": ["1234"], - "contents": [ - { - "quantity": 1, - "item_price": "undefined" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 1, - "content_ids": ["507f1f77bcf86cd799439011"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "body": { - "FORM": {}, - "JSON": { - "action_source": "web", - "advertiser_id": "123456", - "app_id": "429047995", - "custom_data": { - "contents": [ - { - "item_price": "undefined", - "quantity": 1 - } - ], - "currency": "USD", - "num_items": 0, - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "custom event", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - }, - "JSON_ARRAY": {}, - "XML": {} - }, - "endpoint": "https://ct.pinterest.com/events/v3", - "files": {}, - "headers": { - "Content-Type": "application/json" - }, - "method": "POST", - "params": {}, - "type": "REST", - "version": "1" - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "watch_video", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome", - "external_id": ["3217d71a74c219d6e31e28267b313a7ceb6a2c032db1a091c9416b25b2ae2bc8"] - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": [ - "48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08", - "c392e50ebeca7bea4405e9c545023451ac56620031f81263f681269bde14218b" - ], - "ph": [ - "d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b", - "22bdde2594851294f2a6f4c34af704e68b398b03129ea9ceb58f0ffe33f6db52" - ], - "ln": [ - "dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251", - "9c2f138690fca4890c3c4a6691610fbbbdf32091cc001f7355cfdf574baa52b9" - ], - "fn": [ - "9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08", - "4135aa9dc1b842a653dea846903ddb95bfb8c5a10c504a7fa16e10bc31d1fdf0" - ], - "ct": [ - "6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85", - "d209bcc17778fd19fd2bc0c99a3868bf011da5162d3a75037a605768ebc276e2" - ], - "st": [ - "3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd", - "1b0316ed1cfed044035c55363e02ccafab26d66b1c2746b94d17285f043324aa" - ], - "zp": [ - "1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c", - "4d6755aa1e85517191f06cc91448696c173e1195ae51f94a1670116ac7b5c47b" - ], - "country": [ - "582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf", - "582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf" - ], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Ad Account ID not found. Aborting" - }, - { - "statusCode": 400, - "error": "Conversion Token not found. Aborting" - }, - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom event", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 0, - "contents": [ - { - "quantity": 1, - "item_price": "undefined" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ] -] diff --git a/test/__tests__/data/pinterest_tag_router_batch_output.json b/test/__tests__/data/pinterest_tag_router_batch_output.json deleted file mode 100644 index 0eb8f0532a..0000000000 --- a/test/__tests__/data/pinterest_tag_router_batch_output.json +++ /dev/null @@ -1,943 +0,0 @@ -[ - [ - { - "batchedRequest": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "data": [ - { - "event_name": "watch_video", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "signup", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "checkout", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": [ - { - "jobId": 1, - "userId": "u1" - }, - { - "jobId": 2, - "userId": "u1" - } - ], - "batched": true, - "statusCode": 200, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "batchedRequest": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "data": [ - { - "event_name": "add_to_cart", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 2, - "content_ids": ["123"], - "contents": [ - { - "quantity": 2, - "item_price": "25" - } - ] - } - }, - { - "event_name": "search", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "signup", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": [ - { - "jobId": 3, - "userId": "u1" - }, - { - "jobId": 4, - "userId": "u1" - }, - { - "jobId": 6, - "userId": "u1" - } - ], - "batched": true, - "statusCode": 200, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "batchedRequest": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "data": [ - { - "action_source": "web", - "event_name": "WatchVideo", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["bdfdee6414a89d72bfbf5ee90b1f85924467bae1e3980d83c2cd348dc31d5819"], - "fn": ["ee5db3fe0253b651aca3676692e0c59b25909304f5c51d223a02a215d104144b"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": [ - { - "jobId": 7, - "userId": "u1" - } - ], - "batched": true, - "statusCode": 200, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "metadata": [ - { - "jobId": 5, - "userId": "u1" - } - ], - "batched": false, - "statusCode": 400, - "error": "message type identify is not supported", - "statTags": { - "errorCategory": "dataValidation", - "errorType": "instrumentation" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } - ], - [ - { - "batched": true, - "batchedRequest": { - "body": { - "FORM": {}, - "JSON": { - "data": [ - { - "action_source": "web", - "app_id": "429047995", - "custom_data": { - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ], - "currency": "USD", - "num_items": 3, - "opt_out_type": "LDP", - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "watch_video", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - }, - { - "action_source": "web", - "app_id": "429047995", - "custom_data": { - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ], - "currency": "USD", - "num_items": 3, - "opt_out_type": "LDP", - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "signup", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - }, - { - "action_source": "web", - "app_id": "429047995", - "custom_data": { - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "item_brand": "testBrand", - "id": "505bd76785ebb509fc183733", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ], - "currency": "USD", - "num_items": 3, - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "checkout", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {} - }, - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "files": {}, - "headers": { - "Authorization": "Bearer conversionToken123", - "Content-Type": "application/json" - }, - "method": "POST", - "params": {}, - "type": "REST", - "version": "1" - }, - "destination": { - "Config": { - "sendAsTestEvent": false, - "adAccountId": "accountId123", - "apiVersion": "newApi", - "appId": "429047995", - "conversionToken": "conversionToken123", - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "deduplicationKey": "messageId", - "enableDeduplication": true, - "enhancedMatch": true, - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ], - "sendingUnHashedData": true, - "tagId": "123456789" - }, - "Enabled": true, - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Transformations": [] - }, - "metadata": [ - { - "jobId": 8, - "userId": "u1" - }, - { - "jobId": 9, - "userId": "u1" - } - ], - "statusCode": 200 - }, - { - "batched": true, - "batchedRequest": { - "body": { - "FORM": {}, - "JSON": { - "data": [ - { - "action_source": "web", - "app_id": "429047995", - "custom_data": { - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ], - "currency": "USD", - "num_items": 3, - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "custom", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {} - }, - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "files": {}, - "headers": { - "Authorization": "Bearer conversionToken123", - "Content-Type": "application/json" - }, - "method": "POST", - "params": {}, - "type": "REST", - "version": "1" - }, - "destination": { - "Config": { - "sendAsTestEvent": false, - "adAccountId": "accountId123", - "apiVersion": "newApi", - "appId": "429047995", - "conversionToken": "conversionToken123", - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "deduplicationKey": "messageId", - "enableDeduplication": true, - "enhancedMatch": true, - "sendAsCustomEvent": true, - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ], - "sendingUnHashedData": true, - "tagId": "123456789" - }, - "Enabled": true, - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Transformations": [] - }, - "metadata": [ - { - "jobId": 10, - "userId": "u1" - } - ], - "statusCode": 200 - } - ] -] diff --git a/test/__tests__/data/pinterest_tag_router_error_input.json b/test/__tests__/data/pinterest_tag_router_error_input.json deleted file mode 100644 index ce188c7335..0000000000 --- a/test/__tests__/data/pinterest_tag_router_error_input.json +++ /dev/null @@ -1,124 +0,0 @@ -[ - { - "message": { - "type": "Identify", - "event": "User Signup", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 5, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "Watch Video" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } -] diff --git a/test/__tests__/data/pinterest_tag_router_error_output.json b/test/__tests__/data/pinterest_tag_router_error_output.json deleted file mode 100644 index 4cd4e6966c..0000000000 --- a/test/__tests__/data/pinterest_tag_router_error_output.json +++ /dev/null @@ -1,59 +0,0 @@ -[ - { - "metadata": [ - { - "jobId": 5, - "userId": "u1" - } - ], - "batched": false, - "statusCode": 400, - "error": "message type identify is not supported", - "statTags": { - "errorCategory": "dataValidation", - "errorType": "instrumentation" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "Watch Video" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } -] diff --git a/test/__tests__/data/pinterest_tag_router_input.json b/test/__tests__/data/pinterest_tag_router_input.json deleted file mode 100644 index c1639382d7..0000000000 --- a/test/__tests__/data/pinterest_tag_router_input.json +++ /dev/null @@ -1,1212 +0,0 @@ -[ - [ - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 1, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Order completed", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 2, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "product added", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "product_id": "123", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 3, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Product List Filtered", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 4, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "Identify", - "event": "User Signup", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 5, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "User Created", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 6, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "version": "1", - "statusCode": 200, - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "WatchVideo", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["bdfdee6414a89d72bfbf5ee90b1f85924467bae1e3980d83c2cd348dc31d5819"], - "fn": ["ee5db3fe0253b651aca3676692e0c59b25909304f5c51d223a02a215d104144b"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": { - "jobId": 7, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } - ], - [ - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 8, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Order completed", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 9, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Test", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "brand": "testBrand", - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "brand": "testBrand", - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "metadata": { - "jobId": 10, - "userId": "u1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } - ] -] diff --git a/test/__tests__/data/pinterest_tag_router_output.json b/test/__tests__/data/pinterest_tag_router_output.json deleted file mode 100644 index a54d328978..0000000000 --- a/test/__tests__/data/pinterest_tag_router_output.json +++ /dev/null @@ -1,735 +0,0 @@ -[ - [ - { - "batchedRequest": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "data": [ - { - "event_name": "watch_video", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "signup", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "checkout", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "add_to_cart", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 2, - "content_ids": ["123"], - "contents": [ - { - "quantity": 2, - "item_price": "25" - } - ] - } - }, - { - "event_name": "search", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "signup", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "action_source": "web", - "event_name": "WatchVideo", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["bdfdee6414a89d72bfbf5ee90b1f85924467bae1e3980d83c2cd348dc31d5819"], - "fn": ["ee5db3fe0253b651aca3676692e0c59b25909304f5c51d223a02a215d104144b"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": [ - { - "jobId": 1, - "userId": "u1" - }, - { - "jobId": 2, - "userId": "u1" - }, - { - "jobId": 3, - "userId": "u1" - }, - { - "jobId": 4, - "userId": "u1" - }, - { - "jobId": 6, - "userId": "u1" - }, - { - "jobId": 7, - "userId": "u1" - } - ], - "batched": true, - "statusCode": 200, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "metadata": [ - { - "jobId": 5, - "userId": "u1" - } - ], - "statTags": { - "errorCategory": "dataValidation", - "errorType": "instrumentation" - }, - "batched": false, - "statusCode": 400, - "error": "message type identify is not supported", - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } - ], - [ - { - "batchedRequest": { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "data": [ - { - "event_name": "watch_video", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "signup", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "opt_out_type": "LDP", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "checkout", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - }, - { - "event_name": "custom", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": [ - "6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090" - ], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "id": "507f1f77bcf86cd799439011", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Monopoly: 3rd Edition", - "quantity": 1, - "item_price": "19" - }, - { - "id": "505bd76785ebb509fc183733", - "item_brand": "testBrand", - "item_category": "Games", - "item_name": "Uno Card Game", - "quantity": 2, - "item_price": "3" - } - ] - } - } - ] - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - }, - "metadata": [ - { - "jobId": 8, - "userId": "u1" - }, - { - "jobId": 9, - "userId": "u1" - }, - { - "jobId": 10, - "userId": "u1" - } - ], - "batched": true, - "statusCode": 200, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - }, - { - "from": "ABC Searched", - "to": "Signup" - }, - { - "from": "User Signup", - "to": "Signup" - }, - { - "from": "User Created", - "to": "Signup" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } - ] -] diff --git a/test/__tests__/data/pinterest_tag_step_input.json b/test/__tests__/data/pinterest_tag_step_input.json deleted file mode 100644 index 7b4e507120..0000000000 --- a/test/__tests__/data/pinterest_tag_step_input.json +++ /dev/null @@ -1,2476 +0,0 @@ -[ - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "gender": "non-binary", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Order completed", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "product added", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "product_id": "123", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Product List Filtered", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "Product List Filtered", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "429047995", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "group", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "enhancedMatch": true, - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "ABC Searched", - "channel": "abc", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "numOfItems": 2, - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123", - "adTrackingEnabled": true - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "ip": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "adTrackingEnabled": false - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "requestIP": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": "Hashed phone", - "gender": "Hashed Gender", - "dob": "Hashed DB", - "lastname": "Hashed Lastname", - "firstName": "Hashed FirstName", - "address": { - "city": "Hashed City", - "state": "Hashed State", - "zip": "Hashed Zip", - "country": "Hashed country" - } - }, - "device": { - "adTrackingEnabled": false, - "advertisingId": "Hashed maids" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": false, - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "page", - "name": "ApplicationLoaded", - "category": "test category", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "requestIP": "127.0.0.0", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "phone": ["Hashed phone", "Hashed phone1"], - "gender": ["Hashed Gender", "Hashed Gender1"], - "dob": ["Hashed DB", "Hashed DB1"], - "lastname": ["Hashed Lastname", "Hashed Lastname1"], - "firstName": ["Hashed FirstName", "Hashed FirstName1"], - "address": { - "city": ["Hashed City", "Hashed City1"], - "state": ["Hashed State", "Hashed State1"], - "zip": ["Hashed Zip", "Hashed Zip1"], - "country": ["Hashed country", "Hashed country1"] - } - }, - "device": { - "adTrackingEnabled": false, - "advertisingId": "Hashed maids" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "path": "", - "referrer": "", - "search": "", - "title": "", - "url": "" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": false, - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "name": "Test Tool", - "type": "page", - "sentAt": "2023-02-01T00:00:00.379Z", - "userId": "", - "channel": "web", - "context": { - "os": { - "name": "", - "version": "" - }, - "app": { - "name": "RudderLabs JavaScript SDK", - "version": "2.22.3", - "namespace": "com.rudderlabs.javascript" - }, - "page": { - "url": "https://www.abc.com/s598907", - "path": "/test-path/s598907", - "title": "Test Tool + Reviews | Rudderstack", - "search": "", - "tab_url": "https://www.abc.com/s598907", - "referrer": "$direct", - "initial_referrer": "$direct", - "referring_domain": "", - "initial_referring_domain": "" - }, - "locale": "en-US", - "screen": { - "width": 1024, - "height": 1024, - "density": 1, - "innerWidth": 1024, - "innerHeight": 1024 - }, - "traits": {}, - "library": { - "name": "RudderLabs JavaScript SDK", - "version": "2.22.3" - }, - "campaign": {}, - "doNotSell": false, - "sessionId": 1675209600203, - "userAgent": "Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; Googlebot/2.1; +http://www.google.com/bot.html) Chrome/109.0.5414.101 Safari/537.36", - "gaClientId": { - "integrations": { - "Google Ads": { - "gclid": "" - }, - "Google Analytics": { - "clientId": "1518934611.1234569600" - } - } - }, - "sessionStart": true - }, - "rudderId": "7291a10f-e7dd-49f9-94ce-0154f53897y6", - "messageId": "1c77a616-13a7-4a2e-a8e7-e1a0971897y6", - "timestamp": "2023-02-01T12:47:30.030Z", - "properties": { - "sku": "45790-32", - "url": "https://www.abc.com/23rty", - "name": "Test Tool", - "path": "/test-path/tool", - "email": "", - "title": "Test Tool + Reviews | Rudderstack", - "review": { - "reviewCount": 2, - "averageReview": 5, - "reviewContentID": ["238300132"] - }, - "search": "", - "tab_url": "https://www.abc/com", - "pageInfo": { - "pageId": "s592897", - "category": { - "pageType": "product", - "subCategory": "Dining & Kitchen Furniture", - "pageTemplate": "product detail grouper", - "primaryCategory": "Furniture" - }, - "brandType": "new brand" - }, - "referrer": "", - "subCategory": "Dining & Kitchen Furniture", - "primaryCategory": "Furniture", - "initial_referrer": "$direct", - "referring_domain": "", - "initial_referring_domain": "" - }, - "receivedAt": "2023-02-01T12:47:30.038Z", - "request_ip": "66.249.72.218", - "anonymousId": "a61c77a6-1613-474a-aee8-e7e1a0971047", - "integrations": { - "All": true - }, - "originalTimestamp": "2023-02-01T00:00:00.371Z" - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123478671210", - "sendingUnHashedData": false, - "enableDeduplication": false, - "eventsMapping": [ - { - "from": "Product Added", - "to": "AddToCart" - }, - { - "from": "Order Completed", - "to": "Checkout" - }, - { - "from": "Product Viewed", - "to": "PageVisit" - }, - { - "from": "Lead", - "to": "Lead" - }, - { - "from": "Signup", - "to": "Signup" - } - ], - "enhancedMatch": true - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "test", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "sku": "1234", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "sku": "1234", - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - } - ] - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "advertiserId": "123456", - "appId": "429047995", - "sendingUnHashedData": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "enhancedMatch": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Track call with v5 Api version and send external_id toggle enabled", - "message": { - "type": "track", - "event": "ABC Searched", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendExternalId": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Custom event with v5 Api version", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Custom event with v5 Api version, with unhashed User Data and the values are an array of strings", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": ["abc@gmail.com", "def@gmail.com"], - "phone": ["+1234589947", "+1234589948"], - "ge": ["male", "male"], - "db": ["19950715", "19970615"], - "lastname": ["Rudderlabs", "Xu"], - "firstName": ["Test", "Alex"], - "address": { - "city": ["Kolkata", "Mumbai"], - "state": ["WB", "MH"], - "zip": ["700114", "700115"], - "country": ["IN", "IN"] - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "price": 25, - "quantity": 2, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "optOutType": "LDP", - "products": [ - { - "sku": "45790-32", - "url": "https://www.example.com/product/path", - "name": "Monopoly: 3rd Edition", - "price": 19, - "category": "Games", - "quantity": 1, - "image_url": "https:///www.example.com/product/path.jpg", - "product_id": "507f1f77bcf86cd799439011" - }, - { - "sku": "46493-32", - "name": "Uno Card Game", - "price": 3, - "category": "Games", - "quantity": 2, - "product_id": "505bd76785ebb509fc183733" - } - ], - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Ad Account Id check in V5", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "description": "Conversion Token check in V5", - "message": { - "type": "track", - "event": "random", - "sentAt": "2020-08-14T05:30:30.118Z", - "channel": "web", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": true, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - }, - { - "message": { - "type": "track", - "event": "custom event", - "channel": "web", - "sentAt": "2020-08-14T05:30:30.118Z", - "context": { - "source": "test", - "userAgent": "chrome", - "traits": { - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "email": "abc@gmail.com", - "phone": "+1234589947", - "ge": "male", - "db": "19950715", - "lastname": "Rudderlabs", - "firstName": "Test", - "address": { - "city": "Kolkata", - "state": "WB", - "zip": "700114", - "country": "IN" - } - }, - "device": { - "advertisingId": "abc123" - }, - "library": { - "name": "rudder-sdk-ruby-sync", - "version": "1.0.6" - } - }, - "messageId": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "timestamp": "2020-08-14T05:30:30.118Z", - "properties": { - "tax": 2, - "total": 27.5, - "coupon": "hasbros", - "revenue": 48, - "currency": "USD", - "discount": 2.5, - "order_id": "50314b8e9bcf000000000000", - "requestIP": "123.0.0.0", - "shipping": 3, - "subtotal": 22.5, - "affiliation": "Google Store", - "checkout_id": "fksdjfsdjfisjf9sdfjsd9f" - }, - "anonymousId": "50be5c78-6c3f-4b60-be84-97805a316fb1", - "integrations": { - "All": true - } - }, - "destination": { - "ID": "1pYpzzvcn7AQ2W9GGIAZSsN6Mfq", - "Name": "PINTEREST_TAG", - "Config": { - "sendAsTestEvent": false, - "tagId": "123456789", - "apiVersion": "newApi", - "adAccountId": "accountId123", - "conversionToken": "conversionToken123", - "appId": "429047995", - "enhancedMatch": true, - "enableDeduplication": true, - "deduplicationKey": "messageId", - "sendingUnHashedData": true, - "sendAsCustomEvent": false, - "customProperties": [ - { - "properties": "presentclass" - }, - { - "properties": "presentgrade" - } - ], - "eventsMapping": [ - { - "from": "ABC Searched", - "to": "WatchVideo" - } - ] - }, - "Enabled": true, - "Transformations": [] - } - } -] diff --git a/test/__tests__/data/pinterest_tag_step_output.json b/test/__tests__/data/pinterest_tag_step_output.json deleted file mode 100644 index d364bf82dc..0000000000 --- a/test/__tests__/data/pinterest_tag_step_output.json +++ /dev/null @@ -1,911 +0,0 @@ -[ - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "watch_video", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome", - "ge": ["1b16b1df538ba12dc3f97edbb85caa7050d46c148134290feba80f8236c83db9"] - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "checkout", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "add_to_cart", - "action_source": "web", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 2, - "content_ids": ["123"], - "contents": [ - { - "quantity": 2, - "item_price": "25" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Advertiser Id not found. Aborting" - }, - { - "statusCode": 400, - "error": "It is required at least one of em, hashed_maids or pair of client_ip_address and client_user_agent" - }, - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "watch_video", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "num_items": 2, - "order_id": "50314b8e9bcf000000000000", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Advertiser Id not found. Aborting" - }, - { - "statusCode": 400, - "error": "message type group is not supported" - }, - { - "statusCode": 400, - "error": "Action source must be one of app_android, app_ios, web, offline" - }, - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "action_source": "web", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "num_items": 2, - "order_id": "50314b8e9bcf000000000000", - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "page_visit", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "opt_out": false, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "opt_out": true, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "action_source": "web", - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "client_ip_address": "127.0.0.0", - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "action_source": "web", - "opt_out": true, - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "user_data": { - "ph": ["Hashed phone"], - "db": ["Hashed DB"], - "ln": ["Hashed Lastname"], - "fn": ["Hashed FirstName"], - "ct": ["Hashed City"], - "st": ["Hashed State"], - "zp": ["Hashed Zip"], - "country": ["Hashed country"], - "hashed_maids": ["Hashed maids"], - "ge": ["Hashed Gender"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_time": 1597383030, - "action_source": "web", - "opt_out": true, - "event_name": "view_category", - "app_id": "429047995", - "advertiser_id": "123456", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "user_data": { - "ph": ["Hashed phone", "Hashed phone1"], - "db": ["Hashed DB", "Hashed DB1"], - "ln": ["Hashed Lastname", "Hashed Lastname1"], - "fn": ["Hashed FirstName", "Hashed FirstName1"], - "ct": ["Hashed City", "Hashed City1"], - "st": ["Hashed State", "Hashed State1"], - "zp": ["Hashed Zip", "Hashed Zip1"], - "country": ["Hashed country", "Hashed country1"], - "hashed_maids": ["Hashed maids"], - "ge": ["Hashed Gender", "Hashed Gender1"], - "client_user_agent": "chrome" - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "body": { - "JSON": { - "event_time": 1675255650, - "event_source_url": "https://www.abc.com/s598907", - "action_source": "web", - "app_name": "RudderLabs JavaScript SDK", - "app_version": "2.22.3", - "language": "en-US", - "event_id": "1c77a616-13a7-4a2e-a8e7-e1a0971897y6", - "advertiser_id": "123478671210", - "user_data": { - "client_ip_address": "66.249.72.218", - "client_user_agent": "Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; Googlebot/2.1; +http://www.google.com/bot.html) Chrome/109.0.5414.101 Safari/537.36" - }, - "event_name": "page_visit" - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 0, - "content_ids": ["1234"], - "contents": [ - { - "quantity": 1, - "item_price": "undefined" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://ct.pinterest.com/events/v3", - "headers": { - "Content-Type": "application/json" - }, - "params": {}, - "body": { - "JSON": { - "event_name": "custom", - "event_time": 1597383030, - "action_source": "web", - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "advertiser_id": "123456", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "num_items": 1, - "content_ids": ["507f1f77bcf86cd799439011"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "body": { - "FORM": {}, - "JSON": { - "action_source": "web", - "advertiser_id": "123456", - "app_id": "429047995", - "custom_data": { - "contents": [{ "item_price": "undefined", "quantity": 1 }], - "currency": "USD", - "num_items": 0, - "order_id": "50314b8e9bcf000000000000", - "value": "27.5" - }, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "event_name": "custom event", - "event_time": 1597383030, - "user_data": { - "client_user_agent": "chrome", - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"] - } - }, - "JSON_ARRAY": {}, - "XML": {} - }, - "endpoint": "https://ct.pinterest.com/events/v3", - "files": {}, - "headers": { "Content-Type": "application/json" }, - "method": "POST", - "params": {}, - "type": "REST", - "version": "1" - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "watch_video", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome", - "external_id": ["3217d71a74c219d6e31e28267b313a7ceb6a2c032db1a091c9416b25b2ae2bc8"] - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": ["48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08"], - "ph": ["d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b"], - "ln": ["dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251"], - "fn": ["9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08"], - "ct": ["6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85"], - "st": ["3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd"], - "zp": ["1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c"], - "country": ["582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf"], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - [ - { - "version": "1", - "type": "REST", - "method": "POST", - "endpoint": "https://api.pinterest.com/v5/ad_accounts/accountId123/events", - "headers": { - "Content-Type": "application/json", - "Authorization": "Bearer conversionToken123" - }, - "params": {}, - "body": { - "JSON": { - "action_source": "web", - "event_name": "custom", - "event_time": 1597383030, - "event_id": "7208bbb6-2c4e-45bb-bf5b-ad426f3593e9", - "app_id": "429047995", - "user_data": { - "em": [ - "48ddb93f0b30c475423fe177832912c5bcdce3cc72872f8051627967ef278e08", - "c392e50ebeca7bea4405e9c545023451ac56620031f81263f681269bde14218b" - ], - "ph": [ - "d164bbe036663cb5c96835e9ccc6501e9a521127ea62f6359744928ba932413b", - "22bdde2594851294f2a6f4c34af704e68b398b03129ea9ceb58f0ffe33f6db52" - ], - "ln": [ - "dcf000c2386fb76d22cefc0d118a8511bb75999019cd373df52044bccd1bd251", - "9c2f138690fca4890c3c4a6691610fbbbdf32091cc001f7355cfdf574baa52b9" - ], - "fn": [ - "9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08", - "4135aa9dc1b842a653dea846903ddb95bfb8c5a10c504a7fa16e10bc31d1fdf0" - ], - "ct": [ - "6689106ca7922c30b2fd2c175c85bc7fc2d52cc4941bdd7bb622c6cdc6284a85", - "d209bcc17778fd19fd2bc0c99a3868bf011da5162d3a75037a605768ebc276e2" - ], - "st": [ - "3b45022ab36728cdae12e709e945bba267c50ee8a91e6e4388539a8e03a3fdcd", - "1b0316ed1cfed044035c55363e02ccafab26d66b1c2746b94d17285f043324aa" - ], - "zp": [ - "1a4292e00780e18d00e76fde9850aee5344e939ba593333cd5e4b4aa2cd33b0c", - "4d6755aa1e85517191f06cc91448696c173e1195ae51f94a1670116ac7b5c47b" - ], - "country": [ - "582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf", - "582967534d0f909d196b97f9e6921342777aea87b46fa52df165389db1fb8ccf" - ], - "hashed_maids": ["6ca13d52ca70c883e0f0bb101e425a89e8624de51db2d2392593af6a84118090"], - "client_user_agent": "chrome" - }, - "custom_data": { - "currency": "USD", - "value": "27.5", - "order_id": "50314b8e9bcf000000000000", - "opt_out_type": "LDP", - "num_items": 3, - "content_ids": ["507f1f77bcf86cd799439011", "505bd76785ebb509fc183733"], - "contents": [ - { - "quantity": 1, - "item_price": "19" - }, - { - "quantity": 2, - "item_price": "3" - } - ] - } - }, - "JSON_ARRAY": {}, - "XML": {}, - "FORM": {} - }, - "files": {} - } - ], - { - "statusCode": 400, - "error": "Ad Account ID not found. Aborting" - }, - { - "statusCode": 400, - "error": "Conversion Token not found. Aborting" - }, - { - "statusCode": 400, - "error": "custom event is not mapped in UI. Make sure to map the event in UI or enable the 'send as custom event' setting" - } -] diff --git a/test/__tests__/pinterestConversion-cdk.test.ts b/test/__tests__/pinterestConversion-cdk.test.ts deleted file mode 100644 index 2afde331d5..0000000000 --- a/test/__tests__/pinterestConversion-cdk.test.ts +++ /dev/null @@ -1,135 +0,0 @@ -import fs from 'fs'; -import path from 'path'; -import { executeWorkflow, getWorkflowEngine, processCdkV2Workflow } from '../../src/cdk/v2/handler'; -import tags from '../../src/v0/util/tags'; -import logger from '../../src/logger'; - -const integration = 'pinterest_tag'; -const name = 'Pinterest Conversion API'; - -describe(`${name} Tests`, () => { - describe('Processor Tests', () => { - const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_input.json`), - { encoding: 'utf8' }, - ); - const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_output.json`), - { encoding: 'utf8' }, - ); - const inputData = JSON.parse(inputDataFile); - const expectedData = JSON.parse(outputDataFile); - inputData.forEach((input, index) => { - it(`${name} - payload: ${index}`, async () => { - const expected = expectedData[index]; - try { - const output = await processCdkV2Workflow( - integration, - input, - tags.FEATURES.PROCESSOR, - logger, - ); - expect(output).toEqual(expected); - } catch (error: any) { - expect(error.message).toEqual(expected.error); - } - }); - }); - }); - - describe('Processor Step Tests', () => { - const inputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_input.json`), - { encoding: 'utf8' }, - ); - const outputDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_output.json`), - { encoding: 'utf8' }, - ); - const inputData = JSON.parse(inputDataFile); - const expectedData = JSON.parse(outputDataFile); - inputData.forEach((input, index) => { - it(`${name} - payload: ${index}`, async () => { - const expected = expectedData[index]; - try { - const output = await processCdkV2Workflow( - integration, - input, - tags.FEATURES.PROCESSOR, - logger, - ); - expect(output).toEqual(expected); - } catch (error: any) { - expect(error.message).toEqual(expected.error); - } - }); - }); - }); - - describe('Router Tests', () => { - // Router Test Data - const inputRouterDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_router_input.json`), - { encoding: 'utf8' }, - ); - - const inputRouterErrorDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_router_error_input.json`), - { encoding: 'utf8' }, - ); - - const outputRouterBatchDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_router_batch_output.json`), - { encoding: 'utf8' }, - ); - const outputRouterDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_router_output.json`), - { encoding: 'utf8' }, - ); - const outputRouterErrorDataFile = fs.readFileSync( - path.resolve(__dirname, `./data/${integration}_router_error_output.json`), - { encoding: 'utf8' }, - ); - const inputRouterData = JSON.parse(inputRouterDataFile); - const inputRouterErrorData = JSON.parse(inputRouterErrorDataFile); - - const expectedRouterBatchData = JSON.parse(outputRouterBatchDataFile); - const expectedRouterData = JSON.parse(outputRouterDataFile); - const expectedRouterErrorData = JSON.parse(outputRouterErrorDataFile); - - it('Payload with error input', async () => { - const output = await processCdkV2Workflow( - integration, - inputRouterErrorData, - tags.FEATURES.ROUTER, - logger, - ); - expect(output).toEqual(expectedRouterErrorData); - }); - - describe('Default Batch size', () => { - inputRouterData.forEach((input, index) => { - it(`Payload: ${index}`, async () => { - const output = await processCdkV2Workflow( - integration, - input, - tags.FEATURES.ROUTER, - logger, - ); - expect(output).toEqual(expectedRouterData[index]); - }); - }); - }); - describe('Batch size 3', () => { - inputRouterData.forEach((input, index) => { - it(`Payload: ${index}`, async () => { - const workflowEngine = await getWorkflowEngine(integration, tags.FEATURES.ROUTER, { - MAX_BATCH_SIZE: 3, - }); - const output = await executeWorkflow(workflowEngine, input); - expect(output).toEqual(expectedRouterBatchData[index]); - }); - }); - }); - }); -});