@segment/action-destinations 3.119.0 → 3.119.1-cli-test.63
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/destinations/actable-predictive/sendCustomEvent/index.js +1 -1
- package/dist/destinations/actable-predictive/sendCustomEvent/index.js.map +1 -1
- package/dist/destinations/actable-predictive/sendEmailEvent/index.js +1 -1
- package/dist/destinations/actable-predictive/sendEmailEvent/index.js.map +1 -1
- package/dist/destinations/actable-predictive/sendTransactionEvent/index.js +1 -1
- package/dist/destinations/actable-predictive/sendTransactionEvent/index.js.map +1 -1
- package/dist/destinations/actable-predictive/sendWebEvent/index.js +1 -1
- package/dist/destinations/actable-predictive/sendWebEvent/index.js.map +1 -1
- package/dist/destinations/adobe-target/adobeTarget_operations.d.ts +2 -1
- package/dist/destinations/adobe-target/adobeTarget_operations.js +8 -4
- package/dist/destinations/adobe-target/adobeTarget_operations.js.map +1 -1
- package/dist/destinations/adobe-target/updateProfile/index.js +3 -11
- package/dist/destinations/adobe-target/updateProfile/index.js.map +1 -1
- package/dist/destinations/braze-cohorts/api/index.d.ts +15 -0
- package/dist/destinations/braze-cohorts/api/index.js +36 -0
- package/dist/destinations/braze-cohorts/api/index.js.map +1 -0
- package/dist/destinations/braze-cohorts/braze-cohorts-types.d.ts +10 -0
- package/dist/destinations/braze-cohorts/braze-cohorts-types.js +3 -0
- package/dist/destinations/braze-cohorts/braze-cohorts-types.js.map +1 -0
- package/dist/destinations/braze-cohorts/generated-types.d.ts +4 -0
- package/dist/destinations/braze-cohorts/generated-types.js +3 -0
- package/dist/destinations/braze-cohorts/generated-types.js.map +1 -0
- package/dist/destinations/braze-cohorts/index.d.ts +4 -0
- package/dist/destinations/braze-cohorts/index.js +53 -0
- package/dist/destinations/braze-cohorts/index.js.map +1 -0
- package/dist/destinations/braze-cohorts/syncAudiences/generated-types.d.ts +16 -0
- package/dist/destinations/braze-cohorts/syncAudiences/generated-types.js +3 -0
- package/dist/destinations/braze-cohorts/syncAudiences/generated-types.js.map +1 -0
- package/dist/destinations/braze-cohorts/syncAudiences/index.d.ts +5 -0
- package/dist/destinations/braze-cohorts/syncAudiences/index.js +158 -0
- package/dist/destinations/braze-cohorts/syncAudiences/index.js.map +1 -0
- package/dist/destinations/customerio/createUpdateObject/generated-types.d.ts +11 -0
- package/dist/destinations/customerio/createUpdateObject/generated-types.js +3 -0
- package/dist/destinations/customerio/createUpdateObject/generated-types.js.map +1 -0
- package/dist/destinations/customerio/createUpdateObject/index.d.ts +5 -0
- package/dist/destinations/customerio/createUpdateObject/index.js +102 -0
- package/dist/destinations/customerio/createUpdateObject/index.js.map +1 -0
- package/dist/destinations/customerio/createUpdatePerson/generated-types.d.ts +2 -0
- package/dist/destinations/customerio/createUpdatePerson/index.js +24 -0
- package/dist/destinations/customerio/createUpdatePerson/index.js.map +1 -1
- package/dist/destinations/customerio/index.js +9 -1
- package/dist/destinations/customerio/index.js.map +1 -1
- package/dist/destinations/engage-messaging-sendgrid/sendEmail/generated-types.d.ts +1 -0
- package/dist/destinations/engage-messaging-sendgrid/sendEmail/index.js +12 -0
- package/dist/destinations/engage-messaging-sendgrid/sendEmail/index.js.map +1 -1
- package/dist/destinations/engage-messaging-twilio/sendSms/generated-types.d.ts +1 -0
- package/dist/destinations/engage-messaging-twilio/sendSms/index.js +12 -0
- package/dist/destinations/engage-messaging-twilio/sendSms/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/addToCart/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/addToCart/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/custom/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/custom/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/generated-types.d.ts +1 -0
- package/dist/destinations/facebook-conversions-api/index.js +7 -1
- package/dist/destinations/facebook-conversions-api/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/initiateCheckout/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/initiateCheckout/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/pageView/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/pageView/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/purchase/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/purchase/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/search/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/search/index.js.map +1 -1
- package/dist/destinations/facebook-conversions-api/viewContent/index.js +2 -1
- package/dist/destinations/facebook-conversions-api/viewContent/index.js.map +1 -1
- package/dist/destinations/google-analytics-4/selectPromotion/index.js +0 -3
- package/dist/destinations/google-analytics-4/selectPromotion/index.js.map +1 -1
- package/dist/destinations/google-analytics-4/viewItem/index.js +1 -13
- package/dist/destinations/google-analytics-4/viewItem/index.js.map +1 -1
- package/dist/destinations/google-enhanced-conversions/index.js +2 -2
- package/dist/destinations/google-enhanced-conversions/index.js.map +1 -1
- package/dist/destinations/google-enhanced-conversions/postConversion/index.js +2 -2
- package/dist/destinations/google-enhanced-conversions/postConversion/index.js.map +1 -1
- package/dist/destinations/google-enhanced-conversions/uploadClickConversion/index.js +1 -1
- package/dist/destinations/google-enhanced-conversions/uploadClickConversion/index.js.map +1 -1
- package/dist/destinations/google-sheets-dev/generated-types.d.ts +2 -0
- package/dist/destinations/google-sheets-dev/generated-types.js +3 -0
- package/dist/destinations/google-sheets-dev/generated-types.js.map +1 -0
- package/dist/destinations/google-sheets-dev/index.d.ts +4 -0
- package/dist/destinations/google-sheets-dev/index.js +41 -0
- package/dist/destinations/google-sheets-dev/index.js.map +1 -0
- package/dist/destinations/google-sheets-dev/postSheet.types.d.ts +11 -0
- package/dist/destinations/google-sheets-dev/postSheet.types.js +3 -0
- package/dist/destinations/google-sheets-dev/postSheet.types.js.map +1 -0
- package/dist/destinations/heap/constants.d.ts +1 -1
- package/dist/destinations/heap/constants.js +2 -2
- package/dist/destinations/heap/constants.js.map +1 -1
- package/dist/destinations/heap/index.js +1 -1
- package/dist/destinations/heap/index.js.map +1 -1
- package/dist/destinations/heap/trackEvent/generated-types.d.ts +4 -2
- package/dist/destinations/heap/trackEvent/index.js +44 -15
- package/dist/destinations/heap/trackEvent/index.js.map +1 -1
- package/dist/destinations/hubspot/helperFunctions.d.ts +7 -0
- package/dist/destinations/hubspot/helperFunctions.js +27 -0
- package/dist/destinations/hubspot/helperFunctions.js.map +1 -0
- package/dist/destinations/hubspot/sendCustomBehavioralEvent/index.js +2 -1
- package/dist/destinations/hubspot/sendCustomBehavioralEvent/index.js.map +1 -1
- package/dist/destinations/hubspot/upsertCompany/index.js +4 -7
- package/dist/destinations/hubspot/upsertCompany/index.js.map +1 -1
- package/dist/destinations/hubspot/upsertContact/index.js +4 -7
- package/dist/destinations/hubspot/upsertContact/index.js.map +1 -1
- package/dist/destinations/hubspot/upsertCustomObjectRecord/index.js +2 -1
- package/dist/destinations/hubspot/upsertCustomObjectRecord/index.js.map +1 -1
- package/dist/destinations/index.js +7 -0
- package/dist/destinations/index.js.map +1 -1
- package/dist/destinations/ironclad/RecordAction/generated-types.d.ts +12 -0
- package/dist/destinations/ironclad/RecordAction/generated-types.js +3 -0
- package/dist/destinations/ironclad/RecordAction/generated-types.js.map +1 -0
- package/dist/destinations/ironclad/RecordAction/index.d.ts +5 -0
- package/dist/destinations/ironclad/RecordAction/index.js +117 -0
- package/dist/destinations/ironclad/RecordAction/index.js.map +1 -0
- package/dist/destinations/ironclad/generated-types.d.ts +5 -0
- package/dist/destinations/ironclad/generated-types.js +3 -0
- package/dist/destinations/ironclad/generated-types.js.map +1 -0
- package/dist/destinations/ironclad/index.d.ts +4 -0
- package/dist/destinations/ironclad/index.js +42 -0
- package/dist/destinations/ironclad/index.js.map +1 -0
- package/dist/destinations/pipedrive/createUpdateActivity/index.js +44 -17
- package/dist/destinations/pipedrive/createUpdateActivity/index.js.map +1 -1
- package/dist/destinations/pipedrive/createUpdateDeal/index.js +35 -11
- package/dist/destinations/pipedrive/createUpdateDeal/index.js.map +1 -1
- package/dist/destinations/pipedrive/createUpdateLead/generated-types.d.ts +3 -8
- package/dist/destinations/pipedrive/createUpdateLead/index.js +54 -27
- package/dist/destinations/pipedrive/createUpdateLead/index.js.map +1 -1
- package/dist/destinations/pipedrive/createUpdateNote/generated-types.d.ts +1 -1
- package/dist/destinations/pipedrive/createUpdateNote/index.js +22 -13
- package/dist/destinations/pipedrive/createUpdateNote/index.js.map +1 -1
- package/dist/destinations/pipedrive/createUpdateOrganization/index.js +8 -2
- package/dist/destinations/pipedrive/createUpdateOrganization/index.js.map +1 -1
- package/dist/destinations/pipedrive/createUpdatePerson/index.js +15 -3
- package/dist/destinations/pipedrive/createUpdatePerson/index.js.map +1 -1
- package/dist/destinations/pipedrive/index.d.ts +1 -1
- package/dist/destinations/pipedrive/index.js +22 -1
- package/dist/destinations/pipedrive/index.js.map +1 -1
- package/dist/destinations/pipedrive/pipedriveApi/leads.d.ts +5 -1
- package/dist/destinations/pipedrive/pipedriveApi/leads.js.map +1 -1
- package/dist/destinations/pipedrive/pipedriveApi/notes.d.ts +1 -1
- package/dist/destinations/pipedrive/pipedriveApi/pipedrive-client.d.ts +2 -1
- package/dist/destinations/pipedrive/pipedriveApi/pipedrive-client.js +14 -2
- package/dist/destinations/pipedrive/pipedriveApi/pipedrive-client.js.map +1 -1
- package/dist/destinations/ripe/generated-types.d.ts +4 -0
- package/dist/destinations/ripe/generated-types.js +3 -0
- package/dist/destinations/ripe/generated-types.js.map +1 -0
- package/dist/destinations/ripe/group/generated-types.d.ts +10 -0
- package/dist/destinations/ripe/group/generated-types.js +3 -0
- package/dist/destinations/ripe/group/generated-types.js.map +1 -0
- package/dist/destinations/ripe/group/index.d.ts +5 -0
- package/dist/destinations/ripe/group/index.js +68 -0
- package/dist/destinations/ripe/group/index.js.map +1 -0
- package/dist/destinations/ripe/identify/generated-types.d.ts +10 -0
- package/dist/destinations/ripe/identify/generated-types.js +3 -0
- package/dist/destinations/ripe/identify/generated-types.js.map +1 -0
- package/dist/destinations/ripe/identify/index.d.ts +5 -0
- package/dist/destinations/ripe/identify/index.js +70 -0
- package/dist/destinations/ripe/identify/index.js.map +1 -0
- package/dist/destinations/ripe/index.d.ts +4 -0
- package/dist/destinations/ripe/index.js +83 -0
- package/dist/destinations/ripe/index.js.map +1 -0
- package/dist/destinations/ripe/page/generated-types.d.ts +16 -0
- package/dist/destinations/ripe/page/generated-types.js +3 -0
- package/dist/destinations/ripe/page/generated-types.js.map +1 -0
- package/dist/destinations/ripe/page/index.d.ts +5 -0
- package/dist/destinations/ripe/page/index.js +153 -0
- package/dist/destinations/ripe/page/index.js.map +1 -0
- package/dist/destinations/ripe/track/generated-types.d.ts +11 -0
- package/dist/destinations/ripe/track/generated-types.js +3 -0
- package/dist/destinations/ripe/track/generated-types.js.map +1 -0
- package/dist/destinations/ripe/track/index.d.ts +5 -0
- package/dist/destinations/ripe/track/index.js +79 -0
- package/dist/destinations/ripe/track/index.js.map +1 -0
- package/dist/destinations/salesforce/account/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/account/index.js +1 -0
- package/dist/destinations/salesforce/account/index.js.map +1 -1
- package/dist/destinations/salesforce/cases/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/cases/index.js +1 -0
- package/dist/destinations/salesforce/cases/index.js.map +1 -1
- package/dist/destinations/salesforce/contact/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/contact/index.js +1 -0
- package/dist/destinations/salesforce/contact/index.js.map +1 -1
- package/dist/destinations/salesforce/customObject/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/customObject/index.js +1 -0
- package/dist/destinations/salesforce/customObject/index.js.map +1 -1
- package/dist/destinations/salesforce/lead/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/lead/index.js +7 -6
- package/dist/destinations/salesforce/lead/index.js.map +1 -1
- package/dist/destinations/salesforce/opportunity/generated-types.d.ts +1 -0
- package/dist/destinations/salesforce/opportunity/index.js +1 -0
- package/dist/destinations/salesforce/opportunity/index.js.map +1 -1
- package/dist/destinations/salesforce/sf-operations.js +17 -6
- package/dist/destinations/salesforce/sf-operations.js.map +1 -1
- package/dist/destinations/salesforce/sf-properties.d.ts +1 -0
- package/dist/destinations/salesforce/sf-properties.js +11 -1
- package/dist/destinations/salesforce/sf-properties.js.map +1 -1
- package/dist/destinations/salesforce/sf-utils.js +9 -4
- package/dist/destinations/salesforce/sf-utils.js.map +1 -1
- package/dist/destinations/saleswings/api.d.ts +35 -0
- package/dist/destinations/saleswings/api.js +19 -0
- package/dist/destinations/saleswings/api.js.map +1 -0
- package/dist/destinations/saleswings/common.d.ts +5 -0
- package/dist/destinations/saleswings/common.js +37 -0
- package/dist/destinations/saleswings/common.js.map +1 -0
- package/dist/destinations/saleswings/converter.d.ts +12 -0
- package/dist/destinations/saleswings/converter.js +34 -0
- package/dist/destinations/saleswings/converter.js.map +1 -0
- package/dist/destinations/saleswings/fields.d.ts +12 -0
- package/dist/destinations/saleswings/fields.js +102 -0
- package/dist/destinations/saleswings/fields.js.map +1 -0
- package/dist/destinations/saleswings/generated-types.d.ts +3 -0
- package/dist/destinations/saleswings/generated-types.js +3 -0
- package/dist/destinations/saleswings/generated-types.js.map +1 -0
- package/dist/destinations/saleswings/index.d.ts +4 -0
- package/dist/destinations/saleswings/index.js +67 -0
- package/dist/destinations/saleswings/index.js.map +1 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/generated-types.d.ts +14 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/generated-types.js +3 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/generated-types.js.map +1 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/index.d.ts +5 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/index.js +39 -0
- package/dist/destinations/saleswings/submitIdentifyEvent/index.js.map +1 -0
- package/dist/destinations/saleswings/submitPageEvent/generated-types.d.ts +8 -0
- package/dist/destinations/saleswings/submitPageEvent/generated-types.js +3 -0
- package/dist/destinations/saleswings/submitPageEvent/generated-types.js.map +1 -0
- package/dist/destinations/saleswings/submitPageEvent/index.d.ts +5 -0
- package/dist/destinations/saleswings/submitPageEvent/index.js +35 -0
- package/dist/destinations/saleswings/submitPageEvent/index.js.map +1 -0
- package/dist/destinations/saleswings/submitScreenEvent/generated-types.d.ts +14 -0
- package/dist/destinations/saleswings/submitScreenEvent/generated-types.js +3 -0
- package/dist/destinations/saleswings/submitScreenEvent/generated-types.js.map +1 -0
- package/dist/destinations/saleswings/submitScreenEvent/index.d.ts +5 -0
- package/dist/destinations/saleswings/submitScreenEvent/index.js +42 -0
- package/dist/destinations/saleswings/submitScreenEvent/index.js.map +1 -0
- package/dist/destinations/saleswings/submitTrackEvent/generated-types.d.ts +14 -0
- package/dist/destinations/saleswings/submitTrackEvent/generated-types.js +3 -0
- package/dist/destinations/saleswings/submitTrackEvent/generated-types.js.map +1 -0
- package/dist/destinations/saleswings/submitTrackEvent/index.d.ts +5 -0
- package/dist/destinations/saleswings/submitTrackEvent/index.js +42 -0
- package/dist/destinations/saleswings/submitTrackEvent/index.js.map +1 -0
- package/dist/destinations/saleswings/testing.d.ts +10 -0
- package/dist/destinations/saleswings/testing.js +55 -0
- package/dist/destinations/saleswings/testing.js.map +1 -0
- package/dist/destinations/segment-profiles/errors.d.ts +14 -0
- package/dist/destinations/segment-profiles/errors.js +10 -0
- package/dist/destinations/segment-profiles/errors.js.map +1 -0
- package/dist/destinations/segment-profiles/generated-types.d.ts +4 -0
- package/dist/destinations/segment-profiles/generated-types.js +3 -0
- package/dist/destinations/segment-profiles/generated-types.js.map +1 -0
- package/dist/destinations/segment-profiles/helperFunctions.d.ts +8 -0
- package/dist/destinations/segment-profiles/helperFunctions.js +52 -0
- package/dist/destinations/segment-profiles/helperFunctions.js.map +1 -0
- package/dist/destinations/segment-profiles/index.d.ts +4 -0
- package/dist/destinations/segment-profiles/index.js +50 -0
- package/dist/destinations/segment-profiles/index.js.map +1 -0
- package/dist/destinations/segment-profiles/properties.d.ts +12 -0
- package/dist/destinations/segment-profiles/properties.js +20 -0
- package/dist/destinations/segment-profiles/properties.js.map +1 -0
- package/dist/destinations/segment-profiles/segment-properties.d.ts +6 -0
- package/dist/destinations/segment-profiles/segment-properties.js +33 -0
- package/dist/destinations/segment-profiles/segment-properties.js.map +1 -0
- package/dist/destinations/segment-profiles/sendGroup/generated-types.d.ts +9 -0
- package/dist/destinations/segment-profiles/sendGroup/generated-types.js +3 -0
- package/dist/destinations/segment-profiles/sendGroup/generated-types.js.map +1 -0
- package/dist/destinations/segment-profiles/sendGroup/index.d.ts +5 -0
- package/dist/destinations/segment-profiles/sendGroup/index.js +52 -0
- package/dist/destinations/segment-profiles/sendGroup/index.js.map +1 -0
- package/dist/destinations/segment-profiles/sendIdentify/generated-types.d.ts +9 -0
- package/dist/destinations/segment-profiles/sendIdentify/generated-types.js +3 -0
- package/dist/destinations/segment-profiles/sendIdentify/generated-types.js.map +1 -0
- package/dist/destinations/segment-profiles/sendIdentify/index.d.ts +5 -0
- package/dist/destinations/segment-profiles/sendIdentify/index.js +52 -0
- package/dist/destinations/segment-profiles/sendIdentify/index.js.map +1 -0
- package/dist/destinations/snap-conversions-api/_tests_/index.test.js +1 -1
- package/dist/destinations/snap-conversions-api/_tests_/index.test.js.map +1 -1
- package/dist/destinations/snap-conversions-api/snap-capi-properties.js +1 -1
- package/dist/destinations/snap-conversions-api/snap-capi-properties.js.map +1 -1
- package/dist/destinations/vwo/generated-types.d.ts +3 -0
- package/dist/destinations/vwo/generated-types.js +3 -0
- package/dist/destinations/vwo/generated-types.js.map +1 -0
- package/dist/destinations/vwo/identifyUser/generated-types.d.ts +12 -0
- package/dist/destinations/vwo/identifyUser/generated-types.js +3 -0
- package/dist/destinations/vwo/identifyUser/generated-types.js.map +1 -0
- package/dist/destinations/vwo/identifyUser/index.d.ts +5 -0
- package/dist/destinations/vwo/identifyUser/index.js +80 -0
- package/dist/destinations/vwo/identifyUser/index.js.map +1 -0
- package/dist/destinations/vwo/index.d.ts +4 -0
- package/dist/destinations/vwo/index.js +60 -0
- package/dist/destinations/vwo/index.js.map +1 -0
- package/dist/destinations/vwo/pageVisit/generated-types.d.ts +10 -0
- package/dist/destinations/vwo/pageVisit/generated-types.js +3 -0
- package/dist/destinations/vwo/pageVisit/generated-types.js.map +1 -0
- package/dist/destinations/vwo/pageVisit/index.d.ts +5 -0
- package/dist/destinations/vwo/pageVisit/index.js +77 -0
- package/dist/destinations/vwo/pageVisit/index.js.map +1 -0
- package/dist/destinations/vwo/trackEvent/generated-types.d.ts +13 -0
- package/dist/destinations/vwo/trackEvent/generated-types.js +3 -0
- package/dist/destinations/vwo/trackEvent/generated-types.js.map +1 -0
- package/dist/destinations/vwo/trackEvent/index.d.ts +5 -0
- package/dist/destinations/vwo/trackEvent/index.js +86 -0
- package/dist/destinations/vwo/trackEvent/index.js.map +1 -0
- package/dist/destinations/vwo/types.d.ts +42 -0
- package/dist/destinations/vwo/types.js +3 -0
- package/dist/destinations/vwo/types.js.map +1 -0
- package/dist/destinations/vwo/utility.d.ts +13 -0
- package/dist/destinations/vwo/utility.js +59 -0
- package/dist/destinations/vwo/utility.js.map +1 -0
- package/package.json +4 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-analytics-4/selectPromotion/index.ts"],"names":[],"mappings":";;AAAA,wDAA0E;AAC1E,oDAAkG;AAClG,sDAc0B;AAK1B,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,kBAAkB;IACzB,WAAW,EAAE,4CAA4C;IACzD,mBAAmB,EAAE,gDAAgD;IACrE,MAAM,EAAE;QACN,SAAS,EAAE,EAAE,GAAG,0BAAS,EAAE;QAC3B,OAAO,EAAE,EAAE,GAAG,wBAAO,EAAE;QACvB,gBAAgB,EAAE,EAAE,GAAG,iCAAgB,EAAE;QACzC,aAAa,EAAE,EAAE,GAAG,8BAAa,EAAE;QACnC,aAAa,EAAE,EAAE,GAAG,8BAAa,EAAE,OAAO,EAAE,EAAE,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c,CAAC,gBAAgB,GAAG,gCAAgB,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAA;SAC7E;QAED,OAAO,OAAO,CAAC,6CAA6C,EAAE;YAC5D,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,cAAc;SACrB,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -34,19 +34,7 @@ const action = {
|
|
|
34
34
|
if (product.currency) {
|
|
35
35
|
ga4_functions_1.verifyCurrency(product.currency);
|
|
36
36
|
}
|
|
37
|
-
return
|
|
38
|
-
item_id: product.item_id,
|
|
39
|
-
item_name: product.item_name,
|
|
40
|
-
quantity: product.quantity,
|
|
41
|
-
affiliation: product.affiliation,
|
|
42
|
-
coupon: product.coupon,
|
|
43
|
-
discount: product.discount,
|
|
44
|
-
item_brand: product.item_brand,
|
|
45
|
-
item_category: product.item_category,
|
|
46
|
-
item_variant: product.item_variant,
|
|
47
|
-
price: product.price,
|
|
48
|
-
currency: product.currency
|
|
49
|
-
};
|
|
37
|
+
return product;
|
|
50
38
|
});
|
|
51
39
|
}
|
|
52
40
|
if (features && features['actions-google-analytics-4-verify-params-feature']) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-analytics-4/viewItem/index.ts"],"names":[],"mappings":";;AAAA,wDAA0E;AAC1E,oDAAkG;AAClG,sDAW0B;AAK1B,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,WAAW;IAClB,WAAW,EAAE,sCAAsC;IACnD,mBAAmB,EAAE,8CAA8C;IACnE,MAAM,EAAE;QACN,SAAS,EAAE,EAAE,GAAG,0BAAS,EAAE;QAC3B,OAAO,EAAE,EAAE,GAAG,wBAAO,EAAE;QACvB,gBAAgB,EAAE,EAAE,GAAG,iCAAgB,EAAE;QACzC,QAAQ,EAAE,EAAE,GAAG,yBAAQ,EAAE;QACzB,KAAK,EAAE,EAAE,GAAG,sBAAK,EAAE;QACnB,KAAK,EAAE;YACL,GAAG,sCAAqB;YACxB,QAAQ,EAAE,IAAI;SACf;QACD,eAAe,EAAE,gCAAe;QAChC,oBAAoB,EAAE,qCAAoB;QAC1C,MAAM,EAAE,uBAAM;KACf;IACD,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE;QAC1C,IAAI,OAAO,CAAC,QAAQ,EAAE;YACpB,8BAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAA;SACjC;QAED,IAAI,WAAW,GAAkB,EAAE,CAAA;QAEnC,IAAI,OAAO,CAAC,KAAK,EAAE;YACjB,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE;gBAC1C,IAAI,OAAO,CAAC,SAAS,KAAK,SAAS,IAAI,OAAO,CAAC,OAAO,KAAK,SAAS,EAAE;oBACpE,MAAM,IAAI,+BAAgB,CACxB,+EAA+E,EAC/E,8BAA8B,EAC9B,GAAG,CACJ,CAAA;iBACF;gBAED,IAAI,OAAO,CAAC,QAAQ,EAAE;oBACpB,8BAAc,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAA;iBACjC;gBAED,OAAO
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-analytics-4/viewItem/index.ts"],"names":[],"mappings":";;AAAA,wDAA0E;AAC1E,oDAAkG;AAClG,sDAW0B;AAK1B,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,WAAW;IAClB,WAAW,EAAE,sCAAsC;IACnD,mBAAmB,EAAE,8CAA8C;IACnE,MAAM,EAAE;QACN,SAAS,EAAE,EAAE,GAAG,0BAAS,EAAE;QAC3B,OAAO,EAAE,EAAE,GAAG,wBAAO,EAAE;QACvB,gBAAgB,EAAE,EAAE,GAAG,iCAAgB,EAAE;QACzC,QAAQ,EAAE,EAAE,GAAG,yBAAQ,EAAE;QACzB,KAAK,EAAE,EAA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K,EAAE,OAAO,CAAC,KAAK;wBACpB,oBAAoB,EAAE,OAAO,CAAC,oBAAoB;wBAClD,GAAG,OAAO,CAAC,MAAM;qBAClB;iBACF;aACF;YACD,GAAG,qCAAoB,CAAC,OAAO,CAAC,eAAe,CAAC;SACjD,CAAA;QAED,IAAI,QAAQ,IAAI,QAAQ,CAAC,0CAA0C,CAAC,EAAE;YACpE,cAAc,CAAC,gBAAgB,GAAG,gCAAgB,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAA;SAC7E;QAED,OAAO,OAAO,CAAC,6CAA6C,EAAE;YAC5D,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,cAAc;SACrB,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -8,7 +8,7 @@ const uploadCallConversion_1 = __importDefault(require("./uploadCallConversion")
|
|
|
8
8
|
const uploadClickConversion_1 = __importDefault(require("./uploadClickConversion"));
|
|
9
9
|
const uploadConversionAdjustment_1 = __importDefault(require("./uploadConversionAdjustment"));
|
|
10
10
|
const destination = {
|
|
11
|
-
name: 'Google
|
|
11
|
+
name: 'Google Ads Conversions',
|
|
12
12
|
slug: 'actions-google-enhanced-conversions',
|
|
13
13
|
mode: 'cloud',
|
|
14
14
|
authentication: {
|
|
@@ -16,7 +16,7 @@ const destination = {
|
|
|
16
16
|
fields: {
|
|
17
17
|
conversionTrackingId: {
|
|
18
18
|
label: 'Conversion ID',
|
|
19
|
-
description: 'You will find this information in the event snippet for your conversion action, for example `send_to: AW-CONVERSION_ID/AW-CONVERSION_LABEL`. In the sample snippet, AW-CONVERSION_ID stands for the conversion ID unique to your account. Enter the conversion
|
|
19
|
+
description: 'You will find this information in the event snippet for your conversion action, for example `send_to: AW-CONVERSION_ID/AW-CONVERSION_LABEL`. In the sample snippet, AW-CONVERSION_ID stands for the conversion ID unique to your account. Enter the conversion ID, without the AW- prefix. **Required if you are using a mapping that sends data to the legacy Google Enhanced Conversions API (i.e. Upload Enhanced Conversion (Legacy) Action).**',
|
|
20
20
|
type: 'string'
|
|
21
21
|
},
|
|
22
22
|
customerId: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/google-enhanced-conversions/index.ts"],"names":[],"mappings":";;;;;AAEA,sEAA6C;AAC7C,kFAAyD;AACzD,oFAA2D;AAC3D,8FAAqE;AAerE,MAAM,WAAW,GAAoC;IAGnD,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/google-enhanced-conversions/index.ts"],"names":[],"mappings":";;;;;AAEA,sEAA6C;AAC7C,kFAAyD;AACzD,oFAA2D;AAC3D,8FAAqE;AAerE,MAAM,WAAW,GAAoC;IAGnD,IAAI,EAAE,wBAAwB;IAC9B,IAAI,EAAE,qCAAqC;IAC3C,IAAI,EAAE,OAAO;IACb,cAAc,EAAE;QACd,MAAM,EAAE,QAAQ;QAChB,MAAM,EAAE;YACN,oBAAoB,EAAE;gBACpB,KAAK,EAAE,eAAe;gBACtB,WAAW,EACT,qbAAqb;gBACvb,IAAI,EAAE,QAAQ;aACf;YACD,UAAU,EAAE;gBACV,KAAK,EAAE,aAAa;gBACpB,WAAW,EACT,oKAAoK;gBACtK,IAAI,EAAE,QAAQ;aACf;SACF;QACD,kBAAkB,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE;YAQrC,OAAO,IAAI,CAAA;QACb,CAAC;QACD,kBAAkB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE;YAC9C,MAAM,GAAG,GAAG,MAAM,OAAO,CAAuB,4CAA4C,EAAE;gBAC5F,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,IAAI,eAAe,CAAC;oBACxB,aAAa,EAAE,IAAI,CAAC,YAAY;oBAChC,SAAS,EAAE,IAAI,CAAC,QAAQ;oBACxB,aAAa,EAAE,IAAI,CAAC,YAAY;oBAChC,UAAU,EAAE,eAAe;iBAC5B,CAAC;aACH,CAAC,CAAA;YAEF,OAAO,EAAE,WAAW,EAAE,GAAG,CAAC,IAAI,CAAC,YAAY,EAAE,CAAA;QAC/C,CAAC;KACF;IACD,aAAa,CAAC,EAAE,IAAI,EAAE;QACpB,OAAO;YACL,OAAO,EAAE;gBACP,aAAa,EAAE,UAAU,IAAI,EAAE,WAAW,EAAE;aAC7C;SACF,CAAA;IACH,CAAC;IACD,OAAO,EAAE;QACP,cAAc,EAAd,wBAAc;QACd,qBAAqB,EAArB,+BAAqB;QACrB,oBAAoB,EAApB,8BAAoB;QACpB,0BAA0B,EAA1B,oCAA0B;KAC3B;CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
|
|
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const actions_core_1 = require("@segment/actions-core");
|
|
4
4
|
const formatter_1 = require("./formatter");
|
|
5
5
|
const action = {
|
|
6
|
-
title: '
|
|
7
|
-
description: '
|
|
6
|
+
title: 'Upload Enhanced Conversion (Legacy)',
|
|
7
|
+
description: 'Upload a conversion enhancement to the legacy Google Enhanced Conversions API.',
|
|
8
8
|
fields: {
|
|
9
9
|
conversion_label: {
|
|
10
10
|
label: 'Conversion Label',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-enhanced-conversions/postConversion/index.ts"],"names":[],"mappings":";;AAAA,wDAAqF;AAIrF,2CASoB;AAYpB,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-enhanced-conversions/postConversion/index.ts"],"names":[],"mappings":";;AAAA,wDAAqF;AAIrF,2CASoB;AAYpB,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,qCAAqC;IAC5C,WAAW,EAAE,gFAAgF;IAC7F,MAAM,EAAE;QAEN,gBAAgB,EAAE;YAChB,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G;iBACF;aACF;YAED,MAAM,GAAG,CAAA;SACV;IACH,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -92,7 +92,7 @@ const action = {
|
|
|
92
92
|
},
|
|
93
93
|
conversion_environment: {
|
|
94
94
|
label: 'Conversion Environment',
|
|
95
|
-
description: 'The environment this conversion was recorded on, e.g. APP or WEB.',
|
|
95
|
+
description: 'The environment this conversion was recorded on, e.g. APP or WEB. Sending the environment field requires an allowlist in your Google Ads account. Leave this field blank if your account has not been allowlisted.',
|
|
96
96
|
type: 'string',
|
|
97
97
|
choices: [
|
|
98
98
|
{ label: 'APP', value: 'APP' },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-enhanced-conversions/uploadClickConversion/index.ts"],"names":[],"mappings":";;AAAA,wDAA0E;AAG1E,oCAAuE;AACvE,4CAAoH;AAGpH,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,yBAAyB;IAChC,WAAW,EAAE,2DAA2D;IACxE,MAAM,EAAE;QACN,iBAAiB,EAAE;YACjB,KAAK,EAAE,sBAAsB;YAC7B,WAAW,EACT,sUAAsU;YACxU,IAAI,EAAE,QAAQ;YACd,QAAQ,EAAE,IAAI;SACf;QACD,KAAK,EAAE;YACL,KAAK,EAAE,OAAO;YACd,WAAW,EAAE,8DAA8D;YAC3E,IAAI,EAAE,QAAQ;SACf;QACD,MAAM,EAAE;YACN,KAAK,EAAE,QAAQ;YACf,WAAW,EACT,uHAAuH;YACzH,IAAI,EAAE,QAAQ;SACf;QACD,MAAM,EAAE;YACN,KAAK,EAAE,QAAQ;YACf,WAAW,EACT,uHAAuH;YACzH,IAAI,EAAE,QAAQ;SACf;QACD,oBAAoB,EAAE;YACpB,KAAK,EAAE,sBAAsB;YAC7B,WAAW,EACT,8LAA8L;YAChM,IAAI,EAAE,QAAQ;YACd,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE;gBACP,OAA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jC;SACF;QACD,sBAAsB,EAAE;YACtB,KAAK,EAAE,wBAAwB;YAC/B,WAAW,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/google-enhanced-conversions/uploadClickConversion/index.ts"],"names":[],"mappings":";;AAAA,wDAA0E;AAG1E,oCAAuE;AACvE,4CAAoH;AAGpH,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,yBAAyB;IAChC,WAAW,EAAE,2DAA2D;IACxE,MAAM,EAAE;QACN,iBAAiB,EAAE;YACjB,KAAK,EAAE,sBAAsB;YAC7B,WAAW,EACT,sUAAsU;YACxU,IAAI,EAAE,QAAQ;YACd,QAAQ,EAAE,IAAI;SACf;QACD,KAAK,EAAE;YACL,KAAK,EAAE,OAAO;YACd,WAAW,EAAE,8DAA8D;YAC3E,IAAI,EAAE,QAAQ;SACf;QACD,MAAM,EAAE;YACN,KAAK,EAAE,QAAQ;YACf,WAAW,EACT,uHAAuH;YACzH,IAAI,EAAE,QAAQ;SACf;QACD,MAAM,EAAE;YACN,KAAK,EAAE,QAAQ;YACf,WAAW,EACT,uHAAuH;YACzH,IAAI,EAAE,QAAQ;SACf;QACD,oBAAoB,EAAE;YACpB,KAAK,EAAE,sBAAsB;YAC7B,WAAW,EACT,8LAA8L;YAChM,IAAI,EAAE,QAAQ;YACd,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE;gBACP,OAAO,EAAE,aAAa;aACvB;SACF;QACD,aAAa,EAAE;YACb,KAAK,EAAE,eAAe;YACtB,WAAW,EACT,4HAA4H;YAC9H,IAAI,EAAE,QAAQ;YACd,MAAM,EAAE,OAAO;YACf,OAAO,EAAE;gBACP,KAAK,EAAE;oBACL,MAAM,EAAE,EAAE,OAAO,EAAE,oBAAoB,EAAE;oBACzC,IAAI,EAAE,EAAE,OAAO,EAAE,oBAAoB,EAAE;oBACvC,IAAI,EAAE,EAAE,OAAO,EAAE,wBAAwB,EAAE;iBAC5C;aACF;SACF;QACD,YAAY,E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KAAK,EAAE,SAAS;aACjB;YACD,eAAe,EAAE,EAAE;SACpB,CAAA;QAGD,IAAI,OAAO,CAAC,gBAAgB,EAAE;YAC5B,MAAM,iBAAiB,GAAG,MAAM,8BAAkB,CAAC,QAAQ,CAAC,UAAU,EAAE,IAAI,EAAE,OAAO,CAAC,CAAA;YACtF,cAAc,CAAC,eAAe,GAAG,iCAAqB,CACpD,OAAO,CAAC,gBAAgB,EACxB,iBAAiB,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAClC,CAAA;SACF;QAED,IAAI,OAAO,CAAC,aAAa,EAAE;YACzB,cAAc,CAAC,eAAe,CAAC,IAAI,CAAC,EAAE,WAAW,EAAE,gBAAI,CAAC,OAAO,CAAC,aAAa,CAAC,EAAE,CAAC,CAAA;SAClF;QAED,IAAI,OAAO,CAAC,YAAY,EAAE;YACxB,cAAc,CAAC,eAAe,CAAC,IAAI,CAAC,EAAE,iBAAiB,EAAE,gBAAI,CAAC,OAAO,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;SACvF;QAED,MAAM,QAAQ,GAA2C,MAAM,OAAO,CACpE,GAAG,oBAAY,IAAI,QAAQ,CAAC,UAAU,yBAAyB,EAC/D;YACE,MAAM,EAAE,MAAM;YACd,OAAO,EAAE;gBACP,iBAAiB,EAAE,GAAG,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE;aAC5D;YACD,IAAI,EAAE;gBACJ,WAAW,EAAE,CAAC,cAAc,CAAC;gBAC7B,cAAc,EAAE,IAAI;aACrB;SACF,CACF,CAAA;QAED,8BAAkB,CAAC,QAAQ,CAAC,CAAA;QAC5B,OAAO,QAAQ,CAAA;IACjB,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generated-types.js","sourceRoot":"","sources":["../../../src/destinations/google-sheets-dev/generated-types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const postSheet_1 = __importDefault(require("../google-sheets/postSheet"));
|
|
7
|
+
const destination = {
|
|
8
|
+
name: 'Google Sheets (dev only)',
|
|
9
|
+
slug: 'actions-google-sheets-dev',
|
|
10
|
+
mode: 'cloud',
|
|
11
|
+
authentication: {
|
|
12
|
+
scheme: 'oauth-managed',
|
|
13
|
+
fields: {},
|
|
14
|
+
refreshAccessToken: async (request, { auth }) => {
|
|
15
|
+
if (!auth.refreshTokenUrl)
|
|
16
|
+
throw new Error('destination misconfigured: missing refresh token URL');
|
|
17
|
+
const res = await request(auth.refreshTokenUrl, {
|
|
18
|
+
method: 'POST',
|
|
19
|
+
body: new URLSearchParams({
|
|
20
|
+
refresh_token: auth.refreshToken,
|
|
21
|
+
client_id: auth.clientId,
|
|
22
|
+
client_secret: auth.clientSecret,
|
|
23
|
+
grant_type: 'refresh_token'
|
|
24
|
+
})
|
|
25
|
+
});
|
|
26
|
+
return { accessToken: res.data.access_token };
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
extendRequest({ auth }) {
|
|
30
|
+
return {
|
|
31
|
+
headers: {
|
|
32
|
+
authorization: `Bearer ${auth?.accessToken}`
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
},
|
|
36
|
+
actions: {
|
|
37
|
+
postSheet: postSheet_1.default
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
exports.default = destination;
|
|
41
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/google-sheets-dev/index.ts"],"names":[],"mappings":";;;;;AAGA,2EAAkD;AAQlD,MAAM,WAAW,GAAoC;IACnD,IAAI,EAAE,0BAA0B;IAChC,IAAI,EAAE,2BAA2B;IACjC,IAAI,EAAE,OAAO;IAEb,cAAc,EAAE;QACd,MAAM,EAAE,eAAe;QACvB,MAAM,EAAE,EAAE;QAMV,kBAAkB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE;YAC9C,IAAI,CAAC,IAAI,CAAC,eAAe;gBAAE,MAAM,IAAI,KAAK,CAAC,sDAAsD,CAAC,CAAA;YAClG,MAAM,GAAG,GAAG,MAAM,OAAO,CAAuB,IAAI,CAAC,eAAe,EAAE;gBACpE,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,IAAI,eAAe,CAAC;oBACxB,aAAa,EAAE,IAAI,CAAC,YAAY;oBAChC,SAAS,EAAE,IAAI,CAAC,QAAQ;oBACxB,aAAa,EAAE,IAAI,CAAC,YAAY;oBAChC,UAAU,EAAE,eAAe;iBAC5B,CAAC;aACH,CAAC,CAAA;YAEF,OAAO,EAAE,WAAW,EAAE,GAAG,CAAC,IAAI,CAAC,YAAY,EAAE,CAAA;QAC/C,CAAC;KACF;IACD,aAAa,CAAC,EAAE,IAAI,EAAE;QACpB,OAAO;YACL,OAAO,EAAE;gBACP,aAAa,EAAE,UAAU,IAAI,EAAE,WAAW,EAAE;aAC7C;SACF,CAAA;IACH,CAAC;IAQD,OAAO,EAAE;QACP,SAAS,EAAT,mBAAS;KACV;CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"postSheet.types.js","sourceRoot":"","sources":["../../../src/destinations/google-sheets-dev/postSheet.types.ts"],"names":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const HEAP_SEGMENT_CLOUD_LIBRARY_NAME = "cloud-mode-destination";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
3
|
+
exports.HEAP_SEGMENT_CLOUD_LIBRARY_NAME = void 0;
|
|
4
|
+
exports.HEAP_SEGMENT_CLOUD_LIBRARY_NAME = 'cloud-mode-destination';
|
|
5
5
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/destinations/heap/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/destinations/heap/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,+BAA+B,GAAG,wBAAwB,CAAA"}
|
|
@@ -9,7 +9,7 @@ const identifyUser_1 = __importDefault(require("./identifyUser"));
|
|
|
9
9
|
const presets = [
|
|
10
10
|
{
|
|
11
11
|
name: 'Track Calls',
|
|
12
|
-
subscribe: 'type = "track"',
|
|
12
|
+
subscribe: 'type = "track" or type = "page" or type = "screen"',
|
|
13
13
|
partnerAction: 'trackEvent',
|
|
14
14
|
mapping: actions_core_1.defaultValues(trackEvent_1.default.fields)
|
|
15
15
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/heap/index.ts"],"names":[],"mappings":";;;;;AAEA,8DAAqC;AACrC,wDAAqD;AACrD,kEAAyC;AAGzC,MAAM,OAAO,GAAqC;IAChD;QACE,IAAI,EAAE,aAAa;QACnB,SAAS,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/heap/index.ts"],"names":[],"mappings":";;;;;AAEA,8DAAqC;AACrC,wDAAqD;AACrD,kEAAyC;AAGzC,MAAM,OAAO,GAAqC;IAChD;QACE,IAAI,EAAE,aAAa;QACnB,SAAS,EAAE,oDAAoD;QAC/D,aAAa,EAAE,YAAY;QAC3B,OAAO,EAAE,4BAAa,CAAC,oBAAU,CAAC,MAAM,CAAC;KAC1C;IACD;QACE,IAAI,EAAE,gBAAgB;QACtB,SAAS,EAAE,mBAAmB;QAC9B,aAAa,EAAE,cAAc;QAC7B,OAAO,EAAE,4BAAa,CAAC,sBAAY,CAAC,MAAM,CAAC;KAC5C;CACF,CAAA;AAED,MAAM,WAAW,GAAoC;IACnD,IAAI,EAAE,sBAAsB;IAC5B,IAAI,EAAE,oBAAoB;IAC1B,IAAI,EAAE,OAAO;IACb,cAAc,EAAE;QACd,MAAM,EAAE,QAAQ;QAChB,MAAM,EAAE;YACN,KAAK,EAAE;gBACL,KAAK,EAAE,QAAQ;gBACf,WAAW,EAAE,mDAAmD;gBAChE,IAAI,EAAE,QAAQ;gBACd,QAAQ,EAAE,IAAI;aACf;SACF;KACF;IAED,OAAO;IACP,OAAO,EAAE;QACP,UAAU,EAAV,oBAAU;QACV,YAAY,EAAZ,sBAAY;KACb;CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
|
|
@@ -2,10 +2,12 @@ export interface Payload {
|
|
|
2
2
|
message_id: string;
|
|
3
3
|
identity?: string | null;
|
|
4
4
|
anonymous_id?: string | null;
|
|
5
|
-
event
|
|
5
|
+
event?: string;
|
|
6
6
|
properties?: {
|
|
7
7
|
[k: string]: unknown;
|
|
8
8
|
};
|
|
9
9
|
timestamp?: string | number;
|
|
10
|
-
|
|
10
|
+
session_id?: string;
|
|
11
|
+
type?: string;
|
|
12
|
+
name?: string;
|
|
11
13
|
}
|
|
@@ -11,7 +11,7 @@ const actions_core_1 = require("@segment/actions-core");
|
|
|
11
11
|
const action = {
|
|
12
12
|
title: 'Track Event',
|
|
13
13
|
description: 'Send an event to Heap.',
|
|
14
|
-
defaultSubscription: 'type = "track"',
|
|
14
|
+
defaultSubscription: 'type = "track" or type = "page" or type = "screen"',
|
|
15
15
|
fields: {
|
|
16
16
|
message_id: {
|
|
17
17
|
label: 'Message ID',
|
|
@@ -41,10 +41,9 @@ const action = {
|
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
43
|
event: {
|
|
44
|
-
label: 'Event Type',
|
|
44
|
+
label: 'Track Event Type',
|
|
45
45
|
type: 'string',
|
|
46
|
-
description: '
|
|
47
|
-
required: true,
|
|
46
|
+
description: 'Name of the user action. This only exists on track events. Limited to 1024 characters.',
|
|
48
47
|
default: {
|
|
49
48
|
'@path': '$.event'
|
|
50
49
|
}
|
|
@@ -65,12 +64,28 @@ const action = {
|
|
|
65
64
|
'@path': '$.timestamp'
|
|
66
65
|
}
|
|
67
66
|
},
|
|
68
|
-
|
|
69
|
-
label: '
|
|
67
|
+
session_id: {
|
|
68
|
+
label: 'Session ID',
|
|
69
|
+
type: 'string',
|
|
70
|
+
description: 'A Heap session ID. The session ID can be retrived by calling getSessionId() on the heap api. If a session ID is not provided one will be created.',
|
|
71
|
+
default: {
|
|
72
|
+
'@path': '$.session_id'
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
type: {
|
|
76
|
+
label: 'Type',
|
|
77
|
+
type: 'string',
|
|
78
|
+
description: 'The type of call. Can be track, page, or screen.',
|
|
79
|
+
default: {
|
|
80
|
+
'@path': '$.type'
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
name: {
|
|
84
|
+
label: 'Page or Screen Name',
|
|
70
85
|
type: 'string',
|
|
71
|
-
description: 'The name of the
|
|
86
|
+
description: 'The name of the page or screen being viewed. This only exists for page and screen events.',
|
|
72
87
|
default: {
|
|
73
|
-
'@path': '$.
|
|
88
|
+
'@path': '$.name'
|
|
74
89
|
}
|
|
75
90
|
}
|
|
76
91
|
},
|
|
@@ -81,29 +96,43 @@ const action = {
|
|
|
81
96
|
if (!payload.anonymous_id && !payload.identity) {
|
|
82
97
|
throw new actions_core_1.IntegrationError('Either anonymous user id or identity should be specified.');
|
|
83
98
|
}
|
|
84
|
-
const defaultEventProperties = { segment_library:
|
|
99
|
+
const defaultEventProperties = { segment_library: constants_1.HEAP_SEGMENT_CLOUD_LIBRARY_NAME };
|
|
85
100
|
const flatten = flat_1.flat(payload.properties || {});
|
|
86
101
|
const eventProperties = Object.assign(defaultEventProperties, flatten);
|
|
87
|
-
const
|
|
102
|
+
const heapPayload = {
|
|
88
103
|
app_id: settings.appId,
|
|
89
|
-
event: payload
|
|
104
|
+
event: getEventName(payload),
|
|
90
105
|
properties: eventProperties,
|
|
91
106
|
idempotency_key: payload.message_id
|
|
92
107
|
};
|
|
93
108
|
if (payload.anonymous_id && !payload.identity) {
|
|
94
|
-
|
|
109
|
+
heapPayload.user_id = userIdHash_1.getHeapUserId(payload.anonymous_id);
|
|
95
110
|
}
|
|
96
111
|
if (payload.identity) {
|
|
97
|
-
|
|
112
|
+
heapPayload.identity = payload.identity;
|
|
98
113
|
}
|
|
99
114
|
if (payload.timestamp && dayjs_1.default.utc(payload.timestamp).isValid()) {
|
|
100
|
-
|
|
115
|
+
heapPayload.timestamp = dayjs_1.default.utc(payload.timestamp).toISOString();
|
|
116
|
+
}
|
|
117
|
+
if (payload.session_id) {
|
|
118
|
+
heapPayload.session_id = payload.session_id;
|
|
101
119
|
}
|
|
102
120
|
return request('https://heapanalytics.com/api/track', {
|
|
103
121
|
method: 'post',
|
|
104
|
-
json:
|
|
122
|
+
json: heapPayload
|
|
105
123
|
});
|
|
106
124
|
}
|
|
107
125
|
};
|
|
126
|
+
const getEventName = (payload) => {
|
|
127
|
+
switch (payload.type) {
|
|
128
|
+
case 'track':
|
|
129
|
+
return payload.event;
|
|
130
|
+
case 'page':
|
|
131
|
+
case 'screen':
|
|
132
|
+
return payload.name;
|
|
133
|
+
default:
|
|
134
|
+
return undefined;
|
|
135
|
+
}
|
|
136
|
+
};
|
|
108
137
|
exports.default = action;
|
|
109
138
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/heap/trackEvent/index.ts"],"names":[],"mappings":";;;;;AAGA,+DAAsC;AACtC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations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CAAC,CAAA;SAC1D;QAED,IAAI,OAAO,CAAC,QAAQ,EAAE;YACpB,WAAW,CAAC,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAA;SACxC;QAED,IAAI,OAAO,CAAC,SAAS,IAAI,eAAK,CAAC,GAAG,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE,EAAE;YAC/D,WAAW,CAAC,SAAS,GAAG,eAAK,CAAC,GAAG,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,WAAW,EAAE,CAAA;SACnE;QAED,IAAI,OAAO,CAAC,UAAU,EAAE;YACtB,WAAW,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAA;SAC5C;QAED,OAAO,OAAO,CAAC,qCAAqC,EAAE;YACpD,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,WAAW;SAClB,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,MAAM,YAAY,GAAG,CAAC,OAAgB,EAAE,EAAE;IACxC,QAAQ,OAAO,CAAC,IAAI,EAAE;QACpB,KAAK,OAAO;YACV,OAAO,OAAO,CAAC,KAAK,CAAA;QACtB,KAAK,MAAM,CAAC;QACZ,KAAK,QAAQ;YACX,OAAO,OAAO,CAAC,IAAI,CAAA;QACrB;YACE,OAAO,SAAS,CAAA;KACnB;AACH,CAAC,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.flattenObject = void 0;
|
|
4
|
+
function flattenObject(obj) {
|
|
5
|
+
if (typeof obj === 'undefined' || obj === null)
|
|
6
|
+
return obj;
|
|
7
|
+
const flattened = {};
|
|
8
|
+
Object.keys(obj).forEach((key) => {
|
|
9
|
+
if (typeof obj[key] === 'undefined' || obj[key] == null || !Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
10
|
+
return;
|
|
11
|
+
}
|
|
12
|
+
if (obj[key] instanceof Array) {
|
|
13
|
+
flattened[key] = obj[key]
|
|
14
|
+
.map((item) => (typeof item === 'object' ? JSON.stringify(item) : item))
|
|
15
|
+
.join(';');
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
18
|
+
if (typeof obj[key] === 'object') {
|
|
19
|
+
flattened[key] = JSON.stringify(obj[key]);
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
flattened[key] = obj[key];
|
|
23
|
+
});
|
|
24
|
+
return flattened;
|
|
25
|
+
}
|
|
26
|
+
exports.flattenObject = flattenObject;
|
|
27
|
+
//# sourceMappingURL=helperFunctions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helperFunctions.js","sourceRoot":"","sources":["../../../src/destinations/hubspot/helperFunctions.ts"],"names":[],"mappings":";;;AAKA,SAAgB,aAAa,CAAC,GAAe;IAC3C,IAAI,OAAO,GAAG,KAAK,WAAW,IAAI,GAAG,KAAK,IAAI;QAAE,OAAO,GAAG,CAAA;IAE1D,MAAM,SAAS,GAAe,EAAE,CAAA;IAEhC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC,GAAW,EAAE,EAAE;QAGvC,IAAI,OAAO,GAAG,CAAC,GAAG,CAAC,KAAK,WAAW,IAAI,GAAG,CAAC,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,EAAE;YAC1G,OAAM;SACP;QAGD,IAAI,GAAG,CAAC,GAAG,CAAC,YAAY,KAAK,EAAE;YAC7B,SAAS,CAAC,GAAG,CAAC,GAAI,GAAG,CAAC,GAAG,CAAoB;iBAC1C,GAAG,CAAC,CAAC,IAAa,EAAE,EAAE,CAAC,CAAC,OAAO,IAAI,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;iBAChF,IAAI,CAAC,GAAG,CAAC,CAAA;YACZ,OAAM;SACP;QAGD,IAAI,OAAO,GAAG,CAAC,GAAG,CAAC,KAAK,QAAQ,EAAE;YAChC,SAAS,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,CAAA;YACzC,OAAM;SACP;QAED,SAAS,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAA;IAC3B,CAAC,CAAC,CAAA;IAEF,OAAO,SAAS,CAAA;AAClB,CAAC;AA9BD,sCA8BC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const properties_1 = require("../properties");
|
|
4
|
+
const helperFunctions_1 = require("../helperFunctions");
|
|
4
5
|
const action = {
|
|
5
6
|
title: 'Send Custom Behavioral Event',
|
|
6
7
|
description: 'Send a custom behavioral event to HubSpot.',
|
|
@@ -57,7 +58,7 @@ const action = {
|
|
|
57
58
|
utk: payload.utk,
|
|
58
59
|
email: payload.email,
|
|
59
60
|
objectId: payload.objectId,
|
|
60
|
-
properties: payload.properties
|
|
61
|
+
properties: helperFunctions_1.flattenObject(payload.properties)
|
|
61
62
|
};
|
|
62
63
|
return request(`${properties_1.HUBSPOT_BASE_URL}/events/v3/send`, {
|
|
63
64
|
method: 'post',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/hubspot/sendCustomBehavioralEvent/index.ts"],"names":[],"mappings":";;AAEA,8CAAgD;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/hubspot/sendCustomBehavioralEvent/index.ts"],"names":[],"mappings":";;AAEA,8CAAgD;AAEhD,wDAAkD;AAWlD,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,8BAA8B;IACrC,WAAW,EAAE,4CAA4C;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,UAAU,EAAE,+BAAa,CAAC,OAAO,CAAC,UAAU,CAAC;SAC9C,CAAA;QACD,OAAO,OAAO,CAAC,GAAG,6BAAgB,iBAAiB,EAAE;YACnD,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,KAAK;SACZ,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const properties_1 = require("../properties");
|
|
4
4
|
const errors_1 = require("../errors");
|
|
5
|
+
const helperFunctions_1 = require("../helperFunctions");
|
|
5
6
|
var CompanySearchFilterOperator;
|
|
6
7
|
(function (CompanySearchFilterOperator) {
|
|
7
8
|
CompanySearchFilterOperator["EQ"] = "EQ";
|
|
@@ -173,7 +174,7 @@ const action = {
|
|
|
173
174
|
industry: payload.industry,
|
|
174
175
|
lifecyclestage: payload.lifecyclestage?.toLocaleLowerCase(),
|
|
175
176
|
[properties_1.SEGMENT_UNIQUE_IDENTIFIER]: payload.groupid,
|
|
176
|
-
...payload.properties
|
|
177
|
+
...helperFunctions_1.flattenObject(payload.properties)
|
|
177
178
|
};
|
|
178
179
|
let companyId = '';
|
|
179
180
|
try {
|
|
@@ -259,9 +260,7 @@ function createCompany(request, properties) {
|
|
|
259
260
|
return request(`${properties_1.HUBSPOT_BASE_URL}/crm/v3/objects/companies`, {
|
|
260
261
|
method: 'POST',
|
|
261
262
|
json: {
|
|
262
|
-
properties:
|
|
263
|
-
...properties
|
|
264
|
-
}
|
|
263
|
+
properties: properties
|
|
265
264
|
}
|
|
266
265
|
});
|
|
267
266
|
}
|
|
@@ -270,9 +269,7 @@ function updateCompany(request, uniqueIdentifier, properties, idProperty) {
|
|
|
270
269
|
return request(updateCompanyURL, {
|
|
271
270
|
method: 'PATCH',
|
|
272
271
|
json: {
|
|
273
|
-
properties:
|
|
274
|
-
...properties
|
|
275
|
-
}
|
|
272
|
+
properties: properties
|
|
276
273
|
}
|
|
277
274
|
});
|
|
278
275
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/hubspot/upsertCompany/index.ts"],"names":[],"mappings":";;AAGA,8CAA6F;AAC7F,sCAQkB;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/hubspot/upsertCompany/index.ts"],"names":[],"mappings":";;AAGA,8CAA6F;AAC7F,sCAQkB;AAClB,wDAAkD;AAElD,IAAK,2BAcJ;AAdD,WAAK,2BAA2B;IAC9B,wCAAS,CAAA;IACT,0CAAW,CAAA;IACX,wCAAS,CAAA;IACT,0CAAW,CAAA;IACX,wCAAS,CAAA;IACT,0CAAW,CAAA;IACX,kDAAmB,CAAA;IACnB,wCAAS,CAAA;IACT,gDAAiB,CAAA;IACjB,4DAA6B,CAAA;IAC7B,oEAAqC,CAAA;IACrC,gEAAiC,CAAA;IACjC,wEAAyC,CAAA;AAC3C,CAAC,EAdI,2BAA2B,KAA3B,2BAA2B,QAc/B;AAwFD,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,gBAAgB;IACvB,WAAW,EAAE,wCAAwC;IACrD,mBAAmB,EAAE,gBAAgB;IACrC,MAAM,EAAE;QACN,OAAO,EAAE;YACP,KAAK,EAAE,2BAA2B;YAClC,WAAW,EACT,uQAAuQ;YACzQ,IAAI,EAAE,QAAQ;YACd,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE;gBACP,KAAK,EAAE;oBACL,MAAM,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE;oBAChC,IAAI,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE;oBAC9B,IAAI,EAAE,EAAE,OAAO,EAAE,mBAAmB,EAAE;iBACvC;aACF;SACF;QACD,gBAAgB,EAAE;YAChB,KAAK,EAAE,6BAA6B;YACpC,WAAW,EACT,yQAAyQ;YAC3Q,IAAI,EAAE,SAAS;YACf,QAAQ,EAAE,IA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,IAAI;gBAEF,MAAM,qCAAqC,CAAC,OAAO,CAAC,CAAA;aACrD;YAAC,OAAO,CAAC,EAAE;gBAGV,IAAK,CAAe,EAAE,QAAQ,EAAE,MAAM,KAAK,GAAG,EAAE;oBAC9C,MAAM,CAAC,CAAA;iBACR;aACF;YAGD,MAAM,qBAAqB,GAAG,MAAM,qBAAqB,EAAE,CAAA;YAC3D,OAAO,qBAAqB,CAAC,IAAI,CAAC,EAAE,CAAA;SACrC;aAAM;YACL,MAAM,CAAC,CAAA;SACR;KACF;AACH,CAAC;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const properties_1 = require("../properties");
|
|
4
|
+
const helperFunctions_1 = require("../helperFunctions");
|
|
4
5
|
const action = {
|
|
5
6
|
title: 'Upsert Contact',
|
|
6
7
|
description: 'Create or update a contact in HubSpot.',
|
|
@@ -134,7 +135,7 @@ const action = {
|
|
|
134
135
|
email: payload.email,
|
|
135
136
|
website: payload.website,
|
|
136
137
|
lifecyclestage: payload.lifecyclestage?.toLowerCase(),
|
|
137
|
-
...payload.properties
|
|
138
|
+
...helperFunctions_1.flattenObject(payload.properties)
|
|
138
139
|
};
|
|
139
140
|
try {
|
|
140
141
|
const response = await updateContact(request, payload.email, contactProperties);
|
|
@@ -163,9 +164,7 @@ async function createContact(request, contactProperties) {
|
|
|
163
164
|
return request(`${properties_1.HUBSPOT_BASE_URL}/crm/v3/objects/contacts`, {
|
|
164
165
|
method: 'POST',
|
|
165
166
|
json: {
|
|
166
|
-
properties:
|
|
167
|
-
...contactProperties
|
|
168
|
-
}
|
|
167
|
+
properties: contactProperties
|
|
169
168
|
}
|
|
170
169
|
});
|
|
171
170
|
}
|
|
@@ -173,9 +172,7 @@ async function updateContact(request, email, properties) {
|
|
|
173
172
|
return request(`${properties_1.HUBSPOT_BASE_URL}/crm/v3/objects/contacts/${email}?idProperty=email`, {
|
|
174
173
|
method: 'PATCH',
|
|
175
174
|
json: {
|
|
176
|
-
properties:
|
|
177
|
-
...properties
|
|
178
|
-
}
|
|
175
|
+
properties: properties
|
|
179
176
|
}
|
|
180
177
|
});
|
|
181
178
|
}
|