@segment/action-destinations 3.227.2-staging.9 → 3.227.3-staging.0

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.
Files changed (51) hide show
  1. package/dist/destinations/braze/trackEvent/index.js +1 -1
  2. package/dist/destinations/braze/trackEvent/index.js.map +1 -1
  3. package/dist/destinations/braze/trackPurchase/generated-types.d.ts +1 -0
  4. package/dist/destinations/braze/trackPurchase/index.js +9 -0
  5. package/dist/destinations/braze/trackPurchase/index.js.map +1 -1
  6. package/dist/destinations/braze/updateUserProfile/__snapshots__/snapshot.test.d.ts +1 -0
  7. package/dist/destinations/braze/updateUserProfile/__snapshots__/snapshot.test.js +184 -0
  8. package/dist/destinations/braze/updateUserProfile/__snapshots__/snapshot.test.js.map +1 -0
  9. package/dist/destinations/braze/updateUserProfile/generated-types.d.ts +1 -0
  10. package/dist/destinations/braze/updateUserProfile/index.js +11 -88
  11. package/dist/destinations/braze/updateUserProfile/index.js.map +1 -1
  12. package/dist/destinations/braze/utils.d.ts +4 -0
  13. package/dist/destinations/braze/utils.js +171 -1
  14. package/dist/destinations/braze/utils.js.map +1 -1
  15. package/dist/destinations/dynamic-yield-audiences/syncAudience/generated-types.d.ts +1 -0
  16. package/dist/destinations/dynamic-yield-audiences/syncAudience/index.js +12 -0
  17. package/dist/destinations/dynamic-yield-audiences/syncAudience/index.js.map +1 -1
  18. package/dist/destinations/engage/utils/track.d.ts +10 -10
  19. package/dist/destinations/google-enhanced-conversions/functions.d.ts +1 -1
  20. package/dist/destinations/google-enhanced-conversions/functions.js +1 -1
  21. package/dist/destinations/google-enhanced-conversions/functions.js.map +1 -1
  22. package/dist/destinations/google-enhanced-conversions/postConversion/index.js +1 -0
  23. package/dist/destinations/google-enhanced-conversions/postConversion/index.js.map +1 -1
  24. package/dist/destinations/linkedin-conversions/api/index.d.ts +5 -1
  25. package/dist/destinations/linkedin-conversions/api/index.js +87 -0
  26. package/dist/destinations/linkedin-conversions/api/index.js.map +1 -1
  27. package/dist/destinations/linkedin-conversions/constants.d.ts +1 -0
  28. package/dist/destinations/linkedin-conversions/constants.js +7 -1
  29. package/dist/destinations/linkedin-conversions/constants.js.map +1 -1
  30. package/dist/destinations/linkedin-conversions/streamConversion/generated-types.d.ts +17 -0
  31. package/dist/destinations/linkedin-conversions/streamConversion/index.js +125 -6
  32. package/dist/destinations/linkedin-conversions/streamConversion/index.js.map +1 -1
  33. package/dist/destinations/linkedin-conversions/types.d.ts +37 -0
  34. package/dist/destinations/marketo-static-lists/index.js +3 -14
  35. package/dist/destinations/marketo-static-lists/index.js.map +1 -1
  36. package/package.json +1 -1
  37. package/dist/destinations/klaviyo/addProfileToList/generated-types.d.ts +0 -5
  38. package/dist/destinations/klaviyo/addProfileToList/generated-types.js +0 -3
  39. package/dist/destinations/klaviyo/addProfileToList/generated-types.js.map +0 -1
  40. package/dist/destinations/klaviyo/addProfileToList/index.d.ts +0 -5
  41. package/dist/destinations/klaviyo/addProfileToList/index.js +0 -61
  42. package/dist/destinations/klaviyo/addProfileToList/index.js.map +0 -1
  43. package/dist/destinations/klaviyo/properties.d.ts +0 -4
  44. package/dist/destinations/klaviyo/properties.js +0 -21
  45. package/dist/destinations/klaviyo/properties.js.map +0 -1
  46. package/dist/destinations/klaviyo/removeProfileToList/generated-types.d.ts +0 -5
  47. package/dist/destinations/klaviyo/removeProfileToList/generated-types.js +0 -3
  48. package/dist/destinations/klaviyo/removeProfileToList/generated-types.js.map +0 -1
  49. package/dist/destinations/klaviyo/removeProfileToList/index.d.ts +0 -5
  50. package/dist/destinations/klaviyo/removeProfileToList/index.js +0 -62
  51. package/dist/destinations/klaviyo/removeProfileToList/index.js.map +0 -1
@@ -1,5 +0,0 @@
1
- import { ActionDefinition } from '@segment/actions-core';
2
- import type { Settings } from '../generated-types';
3
- import { Payload } from './generated-types';
4
- declare const action: ActionDefinition<Settings, Payload>;
5
- export default action;
@@ -1,61 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const actions_core_1 = require("@segment/actions-core");
4
- const functions_1 = require("../functions");
5
- const properties_1 = require("../properties");
6
- const action = {
7
- title: 'Add To List',
8
- description: 'Add to list',
9
- fields: {
10
- profile_id: { ...properties_1.profile_id },
11
- list_id: { ...properties_1.list_id },
12
- enable_batching: { ...properties_1.enable_batching }
13
- },
14
- dynamicFields: {
15
- list_id: async (request, { settings }) => {
16
- return functions_1.getListIdDynamicData(request, settings);
17
- }
18
- },
19
- perform: async (request, { payload }) => {
20
- const { profile_id, list_id } = payload;
21
- if (!list_id) {
22
- throw new actions_core_1.IntegrationError("Insert the ID of the default list that you'd like to subscribe users", 'Missing required fields', 400);
23
- }
24
- try {
25
- const listData = {
26
- data: [
27
- {
28
- type: 'profile',
29
- id: profile_id
30
- }
31
- ]
32
- };
33
- const list = await functions_1.executeProfileList(request, 'POST', listData, list_id);
34
- return list;
35
- }
36
- catch (error) {
37
- throw new Error('An error occurred while processing the request');
38
- }
39
- },
40
- performBatch: async (request, { payload }) => {
41
- try {
42
- if (!payload[0].list_id) {
43
- throw new actions_core_1.IntegrationError("Insert the ID of the default list that you'd like to subscribe users", 'Missing required fields', 400);
44
- }
45
- const batch_data = { data: [] };
46
- payload.forEach((data) => {
47
- if (!data.list_id) {
48
- return;
49
- }
50
- batch_data.data.push({ type: 'profile', id: data.profile_id });
51
- });
52
- const list = await functions_1.executeProfileList(request, 'POST', batch_data, payload[0].list_id);
53
- return list;
54
- }
55
- catch (error) {
56
- throw new Error('An error occurred while processing the request');
57
- }
58
- }
59
- };
60
- exports.default = action;
61
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/klaviyo/addProfileToList/index.ts"],"names":[],"mappings":";;AAAA,wDAAgG;AAIhG,4CAAuE;AACvE,8CAAoE;AAEpE,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,aAAa;IACpB,WAAW,EAAE,aAAa;IAC1B,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,IAAI,EAAE,EAAE;gBACvB,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;oBACjB,OAAM;iBACP;gBACD,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,EAAE,EAAE,IAAI,CAAC,UAAU,EAAE,CAAC,CAAA;YAChE,CAAC,CAAC,CAAA;YACF,MAAM,IAAI,GAAG,MAAM,8BAAkB,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAA;YACtF,OAAO,IAAI,CAAA;SACZ;QAAC,OAAO,KAAK,EAAE;YACd,MAAM,IAAI,KAAK,CAAC,gDAAgD,CAAC,CAAA;SAClE;IACH,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
@@ -1,4 +0,0 @@
1
- import { InputField } from '@segment/actions-core/destination-kit/types';
2
- export declare const enable_batching: InputField;
3
- export declare const list_id: InputField;
4
- export declare const profile_id: InputField;
@@ -1,21 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.profile_id = exports.list_id = exports.enable_batching = void 0;
4
- exports.enable_batching = {
5
- label: 'Enable Batching',
6
- description: 'Enable batching of requests to the Klaviyo.',
7
- type: 'boolean',
8
- default: true
9
- };
10
- exports.list_id = {
11
- label: 'List Id',
12
- description: `'Insert the ID of the default list that you'd like to subscribe users to when you call .identify().'`,
13
- type: 'string',
14
- dynamic: true
15
- };
16
- exports.profile_id = {
17
- label: 'Profile Id',
18
- description: 'Profile Id of User',
19
- type: 'string'
20
- };
21
- //# sourceMappingURL=properties.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"properties.js","sourceRoot":"","sources":["../../../src/destinations/klaviyo/properties.ts"],"names":[],"mappings":";;;AAEa,QAAA,eAAe,GAAe;IACzC,KAAK,EAAE,iBAAiB;IACxB,WAAW,EAAE,6CAA6C;IAC1D,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,IAAI;CACd,CAAA;AAEY,QAAA,OAAO,GAAe;IACjC,KAAK,EAAE,SAAS;IAChB,WAAW,EAAE,sGAAsG;IACnH,IAAI,EAAE,QAAQ;IACd,OAAO,EAAE,IAAI;CACd,CAAA;AAEY,QAAA,UAAU,GAAe;IACpC,KAAK,EAAE,YAAY;IACnB,WAAW,EAAE,oBAAoB;IACjC,IAAI,EAAE,QAAQ;CACf,CAAA"}
@@ -1,5 +0,0 @@
1
- export interface Payload {
2
- profile_id?: string;
3
- list_id?: string;
4
- enable_batching?: boolean;
5
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=generated-types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"generated-types.js","sourceRoot":"","sources":["../../../../src/destinations/klaviyo/removeProfileToList/generated-types.ts"],"names":[],"mappings":""}
@@ -1,5 +0,0 @@
1
- import { ActionDefinition } from '@segment/actions-core';
2
- import type { Settings } from '../generated-types';
3
- import { Payload } from './generated-types';
4
- declare const action: ActionDefinition<Settings, Payload>;
5
- export default action;
@@ -1,62 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const actions_core_1 = require("@segment/actions-core");
4
- const functions_1 = require("../functions");
5
- const properties_1 = require("../properties");
6
- const action = {
7
- title: 'Remove profile from list',
8
- description: 'Remove profile from list',
9
- fields: {
10
- profile_id: { ...properties_1.profile_id },
11
- list_id: { ...properties_1.list_id },
12
- enable_batching: { ...properties_1.enable_batching }
13
- },
14
- dynamicFields: {
15
- list_id: async (request, { settings }) => {
16
- return functions_1.getListIdDynamicData(request, settings);
17
- }
18
- },
19
- perform: async (request, { payload }) => {
20
- const { profile_id, list_id } = payload;
21
- if (!list_id) {
22
- throw new actions_core_1.IntegrationError("Insert the ID of the default list that you'd like to subscribe users", 'Missing required fields', 400);
23
- }
24
- try {
25
- const listData = {
26
- data: [
27
- {
28
- type: 'profile',
29
- id: profile_id
30
- }
31
- ]
32
- };
33
- const list = await functions_1.executeProfileList(request, 'DELETE', listData, list_id);
34
- return list;
35
- }
36
- catch (error) {
37
- console.log(error);
38
- throw new Error('An error occurred while processing the request');
39
- }
40
- },
41
- performBatch: async (request, { payload }) => {
42
- try {
43
- if (!payload[0].list_id) {
44
- throw new actions_core_1.IntegrationError("Insert the ID of the default list that you'd like to subscribe users", 'Missing required fields', 400);
45
- }
46
- const batch_data = { data: [] };
47
- payload.forEach((data) => {
48
- if (!data.list_id) {
49
- return;
50
- }
51
- batch_data.data.push({ type: 'profile', id: data.profile_id });
52
- });
53
- const list = await functions_1.executeProfileList(request, 'DELETE', batch_data, payload[0].list_id);
54
- return list;
55
- }
56
- catch (error) {
57
- throw new Error('An error occurred while processing the request');
58
- }
59
- }
60
- };
61
- exports.default = action;
62
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/klaviyo/removeProfileToList/index.ts"],"names":[],"mappings":";;AAAA,wDAAgG;AAKhG,4CAAuE;AACvE,8CAAoE;AAEpE,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,0BAA0B;IACjC,WAAW,EAAE,0BAA0B;IACvC,MAAM,EAAE;QACN,UAAU,EAAE,EAAE,GAAG,uBAAU,EAAE;QAC7B,OAAO,EAAE,EAAE,GAAG,oBAAO,EAAE;QACvB,eAAe,EAAE,EAAE,GAAG,4BAAe,EAAE;KACxC;IACD,aAAa,EAAE;QACb,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,QAAQ,EAAE,EAAiC,EAAE;YACtE,OAAO,gCAAoB,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAA;QAChD,CAAC;KACF;IACD,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACtC,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,OAAO,CAAA;QAEvC,IAAI,CAAC,O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