@segment/action-destinations 3.50.0 → 3.50.1-alpha.3
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/dist/destinations/gainsight-px-cloud-action/common-fields.js +5 -267
- package/dist/destinations/gainsight-px-cloud-action/common-fields.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/groupIdentify/generated-types.d.ts +0 -58
- package/dist/destinations/gainsight-px-cloud-action/groupIdentify/index.js +1 -22
- package/dist/destinations/gainsight-px-cloud-action/groupIdentify/index.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/identifyUser/generated-types.d.ts +0 -57
- package/dist/destinations/gainsight-px-cloud-action/identifyUser/index.js +1 -13
- package/dist/destinations/gainsight-px-cloud-action/identifyUser/index.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/index.js +5 -1
- package/dist/destinations/gainsight-px-cloud-action/index.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/regional-endpoints.d.ts +2 -0
- package/dist/destinations/gainsight-px-cloud-action/regional-endpoints.js +4 -2
- package/dist/destinations/gainsight-px-cloud-action/regional-endpoints.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/trackEvent/generated-types.d.ts +0 -58
- package/dist/destinations/gainsight-px-cloud-action/trackEvent/index.js +1 -21
- package/dist/destinations/gainsight-px-cloud-action/trackEvent/index.js.map +1 -1
- package/dist/destinations/gainsight-px-cloud-action/trackPageView/generated-types.d.ts +0 -61
- package/dist/destinations/gainsight-px-cloud-action/trackPageView/index.js +1 -44
- package/dist/destinations/gainsight-px-cloud-action/trackPageView/index.js.map +1 -1
- package/dist/destinations/metronome/index.js +1 -1
- package/dist/destinations/metronome/index.js.map +1 -1
- package/dist/destinations/metronome/sendEvent/index.js +5 -7
- package/dist/destinations/metronome/sendEvent/index.js.map +1 -1
- package/dist/destinations/tiktok-conversions/index.js +75 -19
- package/dist/destinations/tiktok-conversions/index.js.map +1 -1
- package/dist/destinations/tiktok-conversions/reportWebEvent/formatter.d.ts +3 -3
- package/dist/destinations/tiktok-conversions/reportWebEvent/formatter.js +9 -3
- package/dist/destinations/tiktok-conversions/reportWebEvent/formatter.js.map +1 -1
- package/dist/destinations/tiktok-conversions/reportWebEvent/generated-types.d.ts +16 -6
- package/dist/destinations/tiktok-conversions/reportWebEvent/index.js +116 -27
- package/dist/destinations/tiktok-conversions/reportWebEvent/index.js.map +1 -1
- package/package.json +4 -4
|
@@ -2,276 +2,14 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.commonFields = void 0;
|
|
4
4
|
exports.commonFields = {
|
|
5
|
-
|
|
6
|
-
label: '
|
|
7
|
-
type: 'string',
|
|
8
|
-
allowNull: true,
|
|
9
|
-
description: 'The generated anonymous ID for the user',
|
|
10
|
-
default: {
|
|
11
|
-
'@path': '$.anonymousId'
|
|
12
|
-
}
|
|
13
|
-
},
|
|
14
|
-
context: {
|
|
15
|
-
label: 'Event Context',
|
|
5
|
+
segmentEvent: {
|
|
6
|
+
label: 'Segment Event',
|
|
16
7
|
type: 'object',
|
|
17
|
-
description: '
|
|
18
|
-
required: true,
|
|
19
|
-
default: { '@path': '$.context' },
|
|
20
|
-
properties: {
|
|
21
|
-
campaign: {
|
|
22
|
-
label: 'UTM Properties',
|
|
23
|
-
type: 'object',
|
|
24
|
-
description: 'UTM Tracking Properties',
|
|
25
|
-
properties: {
|
|
26
|
-
source: {
|
|
27
|
-
label: 'UTM Source',
|
|
28
|
-
type: 'string',
|
|
29
|
-
default: { '@path': '$.context.campaign.source' }
|
|
30
|
-
},
|
|
31
|
-
medium: {
|
|
32
|
-
label: 'UTM Medium',
|
|
33
|
-
type: 'string',
|
|
34
|
-
default: { '@path': '$.context.campaign.medium' }
|
|
35
|
-
},
|
|
36
|
-
name: {
|
|
37
|
-
label: 'UTM Campaign',
|
|
38
|
-
type: 'string',
|
|
39
|
-
default: { '@path': '$.context.campaign.name' }
|
|
40
|
-
},
|
|
41
|
-
term: {
|
|
42
|
-
label: 'UTM Term',
|
|
43
|
-
type: 'string',
|
|
44
|
-
default: { '@path': '$.context.campaign.term' }
|
|
45
|
-
},
|
|
46
|
-
content: {
|
|
47
|
-
label: 'UTM Content',
|
|
48
|
-
type: 'string',
|
|
49
|
-
default: { '@path': '$.context.campaign.content' }
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
|
-
location: {
|
|
54
|
-
label: 'Location',
|
|
55
|
-
type: 'object',
|
|
56
|
-
description: 'information about the user’s current location',
|
|
57
|
-
properties: {
|
|
58
|
-
city: {
|
|
59
|
-
label: 'City',
|
|
60
|
-
type: 'string',
|
|
61
|
-
default: { '@path': '$.context.location.city' }
|
|
62
|
-
},
|
|
63
|
-
country: {
|
|
64
|
-
label: 'Country',
|
|
65
|
-
type: 'string',
|
|
66
|
-
default: { '@path': '$.context.location.country' }
|
|
67
|
-
},
|
|
68
|
-
latitude: {
|
|
69
|
-
label: 'Latitude',
|
|
70
|
-
type: 'number',
|
|
71
|
-
default: { '@path': '$.context.location.latitude' }
|
|
72
|
-
},
|
|
73
|
-
longitude: {
|
|
74
|
-
label: 'Longitude',
|
|
75
|
-
type: 'number',
|
|
76
|
-
default: { '@path': '$.context.location.longitude' }
|
|
77
|
-
},
|
|
78
|
-
region: {
|
|
79
|
-
label: 'Region',
|
|
80
|
-
type: 'string',
|
|
81
|
-
default: { '@path': '$.context.location.region' }
|
|
82
|
-
},
|
|
83
|
-
speed: {
|
|
84
|
-
label: 'Speed',
|
|
85
|
-
type: 'number',
|
|
86
|
-
default: { '@path': '$.context.location.speed' }
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
},
|
|
90
|
-
page: {
|
|
91
|
-
label: 'Page Properties',
|
|
92
|
-
type: 'object',
|
|
93
|
-
description: 'Current page properties',
|
|
94
|
-
properties: {
|
|
95
|
-
path: {
|
|
96
|
-
label: 'Page path',
|
|
97
|
-
type: 'string',
|
|
98
|
-
default: { '@path': '$.context.page.path' }
|
|
99
|
-
},
|
|
100
|
-
referrer: {
|
|
101
|
-
label: 'Referrer',
|
|
102
|
-
type: 'string',
|
|
103
|
-
default: { '@path': '$.context.page.referrer' }
|
|
104
|
-
},
|
|
105
|
-
search: {
|
|
106
|
-
label: 'Search',
|
|
107
|
-
type: 'string',
|
|
108
|
-
default: { '@path': '$.context.page.search' }
|
|
109
|
-
},
|
|
110
|
-
title: {
|
|
111
|
-
label: 'Title',
|
|
112
|
-
type: 'string',
|
|
113
|
-
default: { '@path': '$.context.page.title' }
|
|
114
|
-
},
|
|
115
|
-
url: {
|
|
116
|
-
label: 'Url',
|
|
117
|
-
type: 'string',
|
|
118
|
-
default: { '@path': '$.context.page.url' }
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
},
|
|
122
|
-
screen: {
|
|
123
|
-
label: 'Screen Properties',
|
|
124
|
-
type: 'object',
|
|
125
|
-
description: 'Screen Properties',
|
|
126
|
-
properties: {
|
|
127
|
-
width: {
|
|
128
|
-
label: 'Screen Width',
|
|
129
|
-
type: 'number',
|
|
130
|
-
default: { '@path': '$.context.screen.width' }
|
|
131
|
-
},
|
|
132
|
-
height: {
|
|
133
|
-
label: 'Screen Height',
|
|
134
|
-
type: 'number',
|
|
135
|
-
default: { '@path': '$.context.screen.height' }
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
},
|
|
139
|
-
app: {
|
|
140
|
-
label: 'Application Properties',
|
|
141
|
-
type: 'object',
|
|
142
|
-
description: 'Application Properties',
|
|
143
|
-
properties: {
|
|
144
|
-
name: {
|
|
145
|
-
label: 'Name',
|
|
146
|
-
type: 'string',
|
|
147
|
-
default: { '@path': '$.context.app.name' },
|
|
148
|
-
},
|
|
149
|
-
version: {
|
|
150
|
-
label: 'Version',
|
|
151
|
-
type: 'string',
|
|
152
|
-
default: { '@path': '$.context.app.version' }
|
|
153
|
-
},
|
|
154
|
-
build: {
|
|
155
|
-
label: 'Build',
|
|
156
|
-
type: 'string',
|
|
157
|
-
default: { '@path': '$.context.app.build' }
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
},
|
|
161
|
-
device: {
|
|
162
|
-
label: 'Device Properties',
|
|
163
|
-
type: 'object',
|
|
164
|
-
description: 'Device Properties',
|
|
165
|
-
default: { '@path': '$.context.device' }
|
|
166
|
-
},
|
|
167
|
-
network: {
|
|
168
|
-
label: 'Network Properties',
|
|
169
|
-
type: 'object',
|
|
170
|
-
description: 'Network Properties',
|
|
171
|
-
default: { '@path': '$.context.network' }
|
|
172
|
-
},
|
|
173
|
-
library: {
|
|
174
|
-
label: 'Library Properties',
|
|
175
|
-
type: 'object',
|
|
176
|
-
description: 'Device Properties',
|
|
177
|
-
properties: {
|
|
178
|
-
name: {
|
|
179
|
-
label: 'Name',
|
|
180
|
-
type: 'string',
|
|
181
|
-
default: { '@path': '$.context.library.name' },
|
|
182
|
-
},
|
|
183
|
-
version: {
|
|
184
|
-
label: 'Version',
|
|
185
|
-
type: 'string',
|
|
186
|
-
default: { '@path': '$.context.library.version' }
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
},
|
|
190
|
-
ip: {
|
|
191
|
-
label: 'Users IP address',
|
|
192
|
-
type: 'string',
|
|
193
|
-
description: 'Users IP address',
|
|
194
|
-
default: { '@path': '$.context.ip' }
|
|
195
|
-
},
|
|
196
|
-
locale: {
|
|
197
|
-
label: 'Users Locale string',
|
|
198
|
-
type: 'string',
|
|
199
|
-
description: 'Users Locale string',
|
|
200
|
-
default: { '@path': '$.context.locale' }
|
|
201
|
-
},
|
|
202
|
-
userAgent: {
|
|
203
|
-
label: 'User Agent string',
|
|
204
|
-
type: 'string',
|
|
205
|
-
description: 'User Agent string',
|
|
206
|
-
default: { '@path': '$.context.userAgent' }
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
},
|
|
210
|
-
messageId: {
|
|
211
|
-
type: 'string',
|
|
212
|
-
label: 'Message ID',
|
|
213
|
-
description: 'The message ID uniquely identifies an event to ensure each event is only processed once.',
|
|
214
|
-
required: true,
|
|
215
|
-
default: {
|
|
216
|
-
'@path': '$.messageId'
|
|
217
|
-
}
|
|
218
|
-
},
|
|
219
|
-
receivedAt: {
|
|
220
|
-
type: 'datetime',
|
|
221
|
-
label: 'receivedAt',
|
|
222
|
-
description: 'The timestamp at which this event was received.',
|
|
223
|
-
required: true,
|
|
224
|
-
default: {
|
|
225
|
-
'@path': '$.receivedAt'
|
|
226
|
-
}
|
|
227
|
-
},
|
|
228
|
-
sentAt: {
|
|
229
|
-
type: 'datetime',
|
|
230
|
-
label: 'sentAt',
|
|
231
|
-
description: 'The timestamp at which this was sent.',
|
|
232
|
-
required: true,
|
|
233
|
-
default: {
|
|
234
|
-
'@path': '$.sentAt'
|
|
235
|
-
}
|
|
236
|
-
},
|
|
237
|
-
timestamp: {
|
|
238
|
-
type: 'datetime',
|
|
239
|
-
label: 'timestamp',
|
|
240
|
-
description: 'The timestamp at which this event occurred.',
|
|
241
|
-
required: true,
|
|
242
|
-
default: {
|
|
243
|
-
'@path': '$.timestamp'
|
|
244
|
-
}
|
|
245
|
-
},
|
|
246
|
-
userId: {
|
|
247
|
-
label: 'User ID',
|
|
248
|
-
type: 'string',
|
|
249
|
-
allowNull: true,
|
|
250
|
-
required: true,
|
|
251
|
-
description: 'The unique user identifier',
|
|
252
|
-
default: {
|
|
253
|
-
'@path': '$.userId'
|
|
254
|
-
}
|
|
255
|
-
},
|
|
256
|
-
type: {
|
|
257
|
-
label: 'Type',
|
|
258
|
-
type: 'string',
|
|
259
|
-
allowNull: false,
|
|
260
|
-
required: true,
|
|
261
|
-
description: 'Segment event type',
|
|
262
|
-
default: {
|
|
263
|
-
'@path': '$.type'
|
|
264
|
-
}
|
|
265
|
-
},
|
|
266
|
-
version: {
|
|
267
|
-
label: 'Version',
|
|
268
|
-
type: 'number',
|
|
269
|
-
allowNull: true,
|
|
8
|
+
description: 'The raw Segment event',
|
|
270
9
|
required: false,
|
|
271
|
-
description: 'Version of the Segment Tracking API that received the message',
|
|
272
10
|
default: {
|
|
273
|
-
'@path': '$.
|
|
11
|
+
'@path': '$.'
|
|
274
12
|
}
|
|
275
|
-
}
|
|
13
|
+
}
|
|
276
14
|
};
|
|
277
15
|
//# sourceMappingURL=common-fields.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common-fields.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/common-fields.ts"],"names":[],"mappings":";;;AAEa,QAAA,YAAY,GAA+B;IACtD,
|
|
1
|
+
{"version":3,"file":"common-fields.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/common-fields.ts"],"names":[],"mappings":";;;AAEa,QAAA,YAAY,GAA+B;IACtD,YAAY,EAAE;QACZ,KAAK,EAAE,eAAe;QACtB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE,uBAAuB;QACpC,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE;YACP,OAAO,EAAE,IAAI;SACd;KACF;CACF,CAAA"}
|
|
@@ -1,60 +1,2 @@
|
|
|
1
1
|
export interface Payload {
|
|
2
|
-
groupId: string;
|
|
3
|
-
traits: {
|
|
4
|
-
[k: string]: unknown;
|
|
5
|
-
};
|
|
6
|
-
anonymousId?: string | null;
|
|
7
|
-
context: {
|
|
8
|
-
campaign?: {
|
|
9
|
-
source?: string;
|
|
10
|
-
medium?: string;
|
|
11
|
-
name?: string;
|
|
12
|
-
term?: string;
|
|
13
|
-
content?: string;
|
|
14
|
-
};
|
|
15
|
-
location?: {
|
|
16
|
-
city?: string;
|
|
17
|
-
country?: string;
|
|
18
|
-
latitude?: number;
|
|
19
|
-
longitude?: number;
|
|
20
|
-
region?: string;
|
|
21
|
-
speed?: number;
|
|
22
|
-
};
|
|
23
|
-
page?: {
|
|
24
|
-
path?: string;
|
|
25
|
-
referrer?: string;
|
|
26
|
-
search?: string;
|
|
27
|
-
title?: string;
|
|
28
|
-
url?: string;
|
|
29
|
-
};
|
|
30
|
-
screen?: {
|
|
31
|
-
width?: number;
|
|
32
|
-
height?: number;
|
|
33
|
-
};
|
|
34
|
-
app?: {
|
|
35
|
-
name?: string;
|
|
36
|
-
version?: string;
|
|
37
|
-
build?: string;
|
|
38
|
-
};
|
|
39
|
-
device?: {
|
|
40
|
-
[k: string]: unknown;
|
|
41
|
-
};
|
|
42
|
-
network?: {
|
|
43
|
-
[k: string]: unknown;
|
|
44
|
-
};
|
|
45
|
-
library?: {
|
|
46
|
-
name?: string;
|
|
47
|
-
version?: string;
|
|
48
|
-
};
|
|
49
|
-
ip?: string;
|
|
50
|
-
locale?: string;
|
|
51
|
-
userAgent?: string;
|
|
52
|
-
};
|
|
53
|
-
messageId: string;
|
|
54
|
-
receivedAt: string | number;
|
|
55
|
-
sentAt: string | number;
|
|
56
|
-
timestamp: string | number;
|
|
57
|
-
userId: string | null;
|
|
58
|
-
type: string;
|
|
59
|
-
version?: number | null;
|
|
60
2
|
}
|
|
@@ -1,32 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const regional_endpoints_1 = require("../regional-endpoints");
|
|
4
|
-
const common_fields_1 = require("../common-fields");
|
|
5
4
|
const action = {
|
|
6
5
|
title: 'Group Identify User',
|
|
7
6
|
description: 'Updates or adds properties to an account. The account is created if it does not exist.',
|
|
8
7
|
defaultSubscription: 'type = "group"',
|
|
9
|
-
fields: {
|
|
10
|
-
groupId: {
|
|
11
|
-
label: 'Account ID',
|
|
12
|
-
type: 'string',
|
|
13
|
-
description: 'The unique identifier of the account.',
|
|
14
|
-
required: true,
|
|
15
|
-
default: {
|
|
16
|
-
'@path': '$.groupId'
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
traits: {
|
|
20
|
-
label: 'User Properties',
|
|
21
|
-
type: 'object',
|
|
22
|
-
description: 'Properties to set on the user profile',
|
|
23
|
-
required: true,
|
|
24
|
-
default: {
|
|
25
|
-
'@path': '$.traits'
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
...common_fields_1.commonFields
|
|
29
|
-
},
|
|
8
|
+
fields: {},
|
|
30
9
|
perform: (request, { payload, settings }) => {
|
|
31
10
|
return request(regional_endpoints_1.getEndpointByRegion('track', settings.dataCenter), {
|
|
32
11
|
method: 'post',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/groupIdentify/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/groupIdentify/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;AAE3D,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,qBAAqB;IAC5B,WAAW,EAAE,wFAAwF;IACrG,mBAAmB,EAAE,gBAAgB;IACrC,MAAM,EAAE,EAAE;IACV,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE;QAE1C,OAAO,OAAO,CAAC,wCAAmB,CAAC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,EAAE;YAChE,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,OAAO;SACd,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -1,59 +1,2 @@
|
|
|
1
1
|
export interface Payload {
|
|
2
|
-
traits: {
|
|
3
|
-
[k: string]: unknown;
|
|
4
|
-
};
|
|
5
|
-
anonymousId?: string | null;
|
|
6
|
-
context: {
|
|
7
|
-
campaign?: {
|
|
8
|
-
source?: string;
|
|
9
|
-
medium?: string;
|
|
10
|
-
name?: string;
|
|
11
|
-
term?: string;
|
|
12
|
-
content?: string;
|
|
13
|
-
};
|
|
14
|
-
location?: {
|
|
15
|
-
city?: string;
|
|
16
|
-
country?: string;
|
|
17
|
-
latitude?: number;
|
|
18
|
-
longitude?: number;
|
|
19
|
-
region?: string;
|
|
20
|
-
speed?: number;
|
|
21
|
-
};
|
|
22
|
-
page?: {
|
|
23
|
-
path?: string;
|
|
24
|
-
referrer?: string;
|
|
25
|
-
search?: string;
|
|
26
|
-
title?: string;
|
|
27
|
-
url?: string;
|
|
28
|
-
};
|
|
29
|
-
screen?: {
|
|
30
|
-
width?: number;
|
|
31
|
-
height?: number;
|
|
32
|
-
};
|
|
33
|
-
app?: {
|
|
34
|
-
name?: string;
|
|
35
|
-
version?: string;
|
|
36
|
-
build?: string;
|
|
37
|
-
};
|
|
38
|
-
device?: {
|
|
39
|
-
[k: string]: unknown;
|
|
40
|
-
};
|
|
41
|
-
network?: {
|
|
42
|
-
[k: string]: unknown;
|
|
43
|
-
};
|
|
44
|
-
library?: {
|
|
45
|
-
name?: string;
|
|
46
|
-
version?: string;
|
|
47
|
-
};
|
|
48
|
-
ip?: string;
|
|
49
|
-
locale?: string;
|
|
50
|
-
userAgent?: string;
|
|
51
|
-
};
|
|
52
|
-
messageId: string;
|
|
53
|
-
receivedAt: string | number;
|
|
54
|
-
sentAt: string | number;
|
|
55
|
-
timestamp: string | number;
|
|
56
|
-
userId: string | null;
|
|
57
|
-
type: string;
|
|
58
|
-
version?: number | null;
|
|
59
2
|
}
|
|
@@ -1,23 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const regional_endpoints_1 = require("../regional-endpoints");
|
|
4
|
-
const common_fields_1 = require("../common-fields");
|
|
5
4
|
const action = {
|
|
6
5
|
title: 'Identify User',
|
|
7
6
|
description: 'Set the user ID for a particular device ID or update user properties',
|
|
8
7
|
defaultSubscription: 'type = "identify"',
|
|
9
|
-
fields: {
|
|
10
|
-
traits: {
|
|
11
|
-
label: 'User Properties',
|
|
12
|
-
type: 'object',
|
|
13
|
-
description: 'Properties to set on the user profile',
|
|
14
|
-
required: true,
|
|
15
|
-
default: {
|
|
16
|
-
'@path': '$.traits'
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
...common_fields_1.commonFields
|
|
20
|
-
},
|
|
8
|
+
fields: {},
|
|
21
9
|
perform: (request, { payload, settings }) => {
|
|
22
10
|
return request(regional_endpoints_1.getEndpointByRegion('track', settings.dataCenter), {
|
|
23
11
|
method: 'post',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/identifyUser/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/identifyUser/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;AAE3D,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,eAAe;IACtB,WAAW,EAAE,sEAAsE;IACnF,mBAAmB,EAAE,mBAAmB;IACxC,MAAM,EAAE,EAAE;IACV,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE;QAE1C,OAAO,OAAO,CAAC,wCAAmB,CAAC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,EAAE;YAChE,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,OAAO;SACd,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -37,7 +37,7 @@ const presets = [
|
|
|
37
37
|
}
|
|
38
38
|
];
|
|
39
39
|
const destination = {
|
|
40
|
-
name: 'Gainsight
|
|
40
|
+
name: 'Gainsight PX Cloud (Actions)',
|
|
41
41
|
slug: 'actions-gainsight-px-cloud',
|
|
42
42
|
mode: 'cloud',
|
|
43
43
|
authentication: {
|
|
@@ -63,6 +63,10 @@ const destination = {
|
|
|
63
63
|
{
|
|
64
64
|
label: 'Europe',
|
|
65
65
|
value: 'europe'
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
label: 'US2',
|
|
69
|
+
value: 'us2'
|
|
66
70
|
}
|
|
67
71
|
]
|
|
68
72
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/index.ts"],"names":[],"mappings":";;;;;AACA,wDAAwD;AAExD,wDAAqD;AAErD,6DAA0D;AAC1D,kEAAyC;AACzC,oEAA2C;AAC3C,8DAAqC;AACrC,oEAA2C;AAG3C,MAAM,OAAO,GAAqC;IAChD;QACE,IAAI,EAAE,eAAe;QACrB,SAAS,EAAE,mBAAmB;QAC9B,aAAa,EAAE,cAAc;QAC7B,OAAO,EAAE,4BAAa,CAAC,sBAAY,CAAC,MAAM,CAAC;KAC5C;IACD;QACE,IAAI,EAAE,YAAY;QAClB,SAAS,EAAE,gBAAgB;QAC3B,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,4BAAa,CAAC,uBAAa,CAAC,MAAM,CAAC;KAC7C;IACD;QACE,IAAI,EAAE,aAAa;QACnB,SAAS,EAAE,gBAAgB;QAC3B,aAAa,EAAE,YAAY;QAC3B,OAAO,EAAE,4BAAa,CAAC,oBAAU,CAAC,MAAM,CAAC;KAC1C;IACD;QACE,IAAI,EAAE,iBAAiB;QACvB,SAAS,EAAE,eAAe;QAC1B,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,4BAAa,CAAC,uBAAa,CAAC,MAAM,CAAC;KAC7C;CACF,CAAA;AAED,MAAM,WAAW,GAAoC;IACnD,IAAI,EAAE,8BAA8B;IACpC,IAAI,EAAE,4BAA4B;IAClC,IAAI,EAAE,OAAO;IAEb,cAAc,EAAE;QACd,MAAM,EAAE,OAAO;QACf,MAAM,EAAE;YACN,MAAM,EAAE;gBACN,KAAK,EAAE,SAAS;gBAChB,WAAW,EAAE,sFAAsF;gBACnG,IAAI,EAAE,QAAQ;gBACd,QAAQ,EAAE,IAAI;aACf;YACD,UAAU,EAAE;gBACV,KAAK,EAAE,aAAa;gBACpB,WAAW,EAAE,0DAA0D;gBACvE,IAAI,EAAE,QAAQ;gBACd,MAAM,EAAE,MAAM;gBACd,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE;oBACP;wBACE,KAAK,EAAE,eAAe;wBACtB,KAAK,EAAE,eAAe;qBACvB;oBACD;wBACE,KAAK,EAAE,QAAQ;wBACf,KAAK,EAAE,QAAQ;qBAChB;iBACF;aACF;SACF;QACD,kBAAkB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;YAClD,MAAM,QAAQ,GAAG,wCAAmB,CAAC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,CAAA;YAClE,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,QAAQ,EAAE;gBACvC,MAAM,EAAE,MAAM;gBACd,QAAQ,EAAE,QAAQ,CAAC,MAAM;gBACzB,QAAQ,EAAE,EAAE;gBACZ,IAAI,EAAE,EAAE;gBACR,eAAe,EAAE,KAAK;aACvB,CAAC,CAAA;YAGF,IAAI,QAAQ,CAAC,MAAM,KAAK,GAAG,EAAE;gBAC3B,OAAO,IAAI,CAAA;aACZ;YACD,MAAM,IAAI,+BAAgB,CAAC,iBAAiB,EAAE,iBAAiB,EAAE,GAAG,CAAC,CAAA;QACvE,CAAC;KACF;IACD,aAAa,CAAC,EAAE,QAAQ,EAAE;QACxB,OAAO;YACL,QAAQ,EAAE,QAAQ,CAAC,MAAM;YACzB,QAAQ,EAAE,EAAE;SACb,CAAA;IACH,CAAC;IACD,OAAO;IACP,OAAO,EAAE;QACP,YAAY,EAAZ,sBAAY;QACZ,aAAa,EAAb,uBAAa;QACb,UAAU,EAAV,oBAAU;QACV,aAAa,EAAb,uBAAa;KACd;CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/index.ts"],"names":[],"mappings":";;;;;AACA,wDAAwD;AAExD,wDAAqD;AAErD,6DAA0D;AAC1D,kEAAyC;AACzC,oEAA2C;AAC3C,8DAAqC;AACrC,oEAA2C;AAG3C,MAAM,OAAO,GAAqC;IAChD;QACE,IAAI,EAAE,eAAe;QACrB,SAAS,EAAE,mBAAmB;QAC9B,aAAa,EAAE,cAAc;QAC7B,OAAO,EAAE,4BAAa,CAAC,sBAAY,CAAC,MAAM,CAAC;KAC5C;IACD;QACE,IAAI,EAAE,YAAY;QAClB,SAAS,EAAE,gBAAgB;QAC3B,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,4BAAa,CAAC,uBAAa,CAAC,MAAM,CAAC;KAC7C;IACD;QACE,IAAI,EAAE,aAAa;QACnB,SAAS,EAAE,gBAAgB;QAC3B,aAAa,EAAE,YAAY;QAC3B,OAAO,EAAE,4BAAa,CAAC,oBAAU,CAAC,MAAM,CAAC;KAC1C;IACD;QACE,IAAI,EAAE,iBAAiB;QACvB,SAAS,EAAE,eAAe;QAC1B,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,4BAAa,CAAC,uBAAa,CAAC,MAAM,CAAC;KAC7C;CACF,CAAA;AAED,MAAM,WAAW,GAAoC;IACnD,IAAI,EAAE,8BAA8B;IACpC,IAAI,EAAE,4BAA4B;IAClC,IAAI,EAAE,OAAO;IAEb,cAAc,EAAE;QACd,MAAM,EAAE,OAAO;QACf,MAAM,EAAE;YACN,MAAM,EAAE;gBACN,KAAK,EAAE,SAAS;gBAChB,WAAW,EAAE,sFAAsF;gBACnG,IAAI,EAAE,QAAQ;gBACd,QAAQ,EAAE,IAAI;aACf;YACD,UAAU,EAAE;gBACV,KAAK,EAAE,aAAa;gBACpB,WAAW,EAAE,0DAA0D;gBACvE,IAAI,EAAE,QAAQ;gBACd,MAAM,EAAE,MAAM;gBACd,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE;oBACP;wBACE,KAAK,EAAE,eAAe;wBACtB,KAAK,EAAE,eAAe;qBACvB;oBACD;wBACE,KAAK,EAAE,QAAQ;wBACf,KAAK,EAAE,QAAQ;qBAChB;oBACD;wBACE,KAAK,EAAE,KAAK;wBACZ,KAAK,EAAE,KAAK;qBACb;iBACF;aACF;SACF;QACD,kBAAkB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;YAClD,MAAM,QAAQ,GAAG,wCAAmB,CAAC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,CAAA;YAClE,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,QAAQ,EAAE;gBACvC,MAAM,EAAE,MAAM;gBACd,QAAQ,EAAE,QAAQ,CAAC,MAAM;gBACzB,QAAQ,EAAE,EAAE;gBACZ,IAAI,EAAE,EAAE;gBACR,eAAe,EAAE,KAAK;aACvB,CAAC,CAAA;YAGF,IAAI,QAAQ,CAAC,MAAM,KAAK,GAAG,EAAE;gBAC3B,OAAO,IAAI,CAAA;aACZ;YACD,MAAM,IAAI,+BAAgB,CAAC,iBAAiB,EAAE,iBAAiB,EAAE,GAAG,CAAC,CAAA;QACvE,CAAC;KACF;IACD,aAAa,CAAC,EAAE,QAAQ,EAAE;QACxB,OAAO;YACL,QAAQ,EAAE,QAAQ,CAAC,MAAM;YACzB,QAAQ,EAAE,EAAE;SACb,CAAA;IACH,CAAC;IACD,OAAO;IACP,OAAO,EAAE;QACP,YAAY,EAAZ,sBAAY;QACZ,aAAa,EAAb,uBAAa;QACb,UAAU,EAAV,oBAAU;QACV,aAAa,EAAb,uBAAa;KACd;CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
|
|
@@ -2,10 +2,12 @@ export declare const endpoints: {
|
|
|
2
2
|
track: {
|
|
3
3
|
north_america: string;
|
|
4
4
|
europe: string;
|
|
5
|
+
us2: string;
|
|
5
6
|
};
|
|
6
7
|
batch: {
|
|
7
8
|
north_america: string;
|
|
8
9
|
europe: string;
|
|
10
|
+
us2: string;
|
|
9
11
|
};
|
|
10
12
|
};
|
|
11
13
|
export declare function getEndpointByRegion(endpoint: keyof typeof endpoints, region?: string): string;
|
|
@@ -4,11 +4,13 @@ exports.getEndpointByRegion = exports.endpoints = void 0;
|
|
|
4
4
|
exports.endpoints = {
|
|
5
5
|
track: {
|
|
6
6
|
north_america: 'https://segment-esp.aptrinsic.com/rte/segmentio/v1/push',
|
|
7
|
-
europe: 'https://segment-esp-eu.aptrinsic.com/rte/segmentio/v1/push'
|
|
7
|
+
europe: 'https://segment-esp-eu.aptrinsic.com/rte/segmentio/v1/push',
|
|
8
|
+
us2: 'https://segment-esp-us2.aptrinsic.com/rte/segmentio/v1/push',
|
|
8
9
|
},
|
|
9
10
|
batch: {
|
|
10
11
|
north_america: 'https://segment-esp.aptrinsic.com/rte/segmentio/v1/batch',
|
|
11
|
-
europe: 'https://segment-esp-eu.aptrinsic.com/rte/segmentio/v1/batch'
|
|
12
|
+
europe: 'https://segment-esp-eu.aptrinsic.com/rte/segmentio/v1/batch',
|
|
13
|
+
us2: 'https://segment-esp-us2.aptrinsic.com/rte/segmentio/v1/push',
|
|
12
14
|
},
|
|
13
15
|
};
|
|
14
16
|
function getEndpointByRegion(endpoint, region) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"regional-endpoints.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/regional-endpoints.ts"],"names":[],"mappings":";;;AAAa,QAAA,SAAS,GAAG;IACvB,KAAK,EAAE;QACL,aAAa,EAAE,yDAAyD;QACxE,MAAM,EAAE,4DAA4D;
|
|
1
|
+
{"version":3,"file":"regional-endpoints.js","sourceRoot":"","sources":["../../../src/destinations/gainsight-px-cloud-action/regional-endpoints.ts"],"names":[],"mappings":";;;AAAa,QAAA,SAAS,GAAG;IACvB,KAAK,EAAE;QACL,aAAa,EAAE,yDAAyD;QACxE,MAAM,EAAE,4DAA4D;QACpE,GAAG,EAAE,6DAA6D;KAEnE;IACD,KAAK,EAAE;QACL,aAAa,EAAE,0DAA0D;QACzE,MAAM,EAAE,6DAA6D;QACrE,GAAG,EAAE,6DAA6D;KACnE;CACF,CAAA;AAYD,SAAgB,mBAAmB,CAAC,QAAgC,EAAE,MAAe;IACnF,OAAO,iBAAS,CAAC,QAAQ,CAAC,CAAC,MAAgB,CAAC,IAAI,iBAAS,CAAC,QAAQ,CAAC,CAAC,eAAe,CAAC,CAAA;AACtF,CAAC;AAFD,kDAEC;AAED,kBAAe,iBAAS,CAAA"}
|
|
@@ -1,60 +1,2 @@
|
|
|
1
1
|
export interface Payload {
|
|
2
|
-
event: string;
|
|
3
|
-
properties?: {
|
|
4
|
-
[k: string]: unknown;
|
|
5
|
-
};
|
|
6
|
-
anonymousId?: string | null;
|
|
7
|
-
context: {
|
|
8
|
-
campaign?: {
|
|
9
|
-
source?: string;
|
|
10
|
-
medium?: string;
|
|
11
|
-
name?: string;
|
|
12
|
-
term?: string;
|
|
13
|
-
content?: string;
|
|
14
|
-
};
|
|
15
|
-
location?: {
|
|
16
|
-
city?: string;
|
|
17
|
-
country?: string;
|
|
18
|
-
latitude?: number;
|
|
19
|
-
longitude?: number;
|
|
20
|
-
region?: string;
|
|
21
|
-
speed?: number;
|
|
22
|
-
};
|
|
23
|
-
page?: {
|
|
24
|
-
path?: string;
|
|
25
|
-
referrer?: string;
|
|
26
|
-
search?: string;
|
|
27
|
-
title?: string;
|
|
28
|
-
url?: string;
|
|
29
|
-
};
|
|
30
|
-
screen?: {
|
|
31
|
-
width?: number;
|
|
32
|
-
height?: number;
|
|
33
|
-
};
|
|
34
|
-
app?: {
|
|
35
|
-
name?: string;
|
|
36
|
-
version?: string;
|
|
37
|
-
build?: string;
|
|
38
|
-
};
|
|
39
|
-
device?: {
|
|
40
|
-
[k: string]: unknown;
|
|
41
|
-
};
|
|
42
|
-
network?: {
|
|
43
|
-
[k: string]: unknown;
|
|
44
|
-
};
|
|
45
|
-
library?: {
|
|
46
|
-
name?: string;
|
|
47
|
-
version?: string;
|
|
48
|
-
};
|
|
49
|
-
ip?: string;
|
|
50
|
-
locale?: string;
|
|
51
|
-
userAgent?: string;
|
|
52
|
-
};
|
|
53
|
-
messageId: string;
|
|
54
|
-
receivedAt: string | number;
|
|
55
|
-
sentAt: string | number;
|
|
56
|
-
timestamp: string | number;
|
|
57
|
-
userId: string | null;
|
|
58
|
-
type: string;
|
|
59
|
-
version?: number | null;
|
|
60
2
|
}
|
|
@@ -1,31 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const regional_endpoints_1 = require("../regional-endpoints");
|
|
4
|
-
const common_fields_1 = require("../common-fields");
|
|
5
4
|
const action = {
|
|
6
5
|
title: 'Track Event',
|
|
7
6
|
description: 'Send an event to Gainsight PX',
|
|
8
7
|
defaultSubscription: 'type = "track"',
|
|
9
|
-
fields: {
|
|
10
|
-
event: {
|
|
11
|
-
label: 'Event Name',
|
|
12
|
-
type: 'string',
|
|
13
|
-
description: 'A unique identifier for your event.',
|
|
14
|
-
required: true,
|
|
15
|
-
default: {
|
|
16
|
-
'@path': '$.event'
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
properties: {
|
|
20
|
-
label: 'Event Properties',
|
|
21
|
-
type: 'object',
|
|
22
|
-
description: 'An object of key-value pairs that represent additional data to be sent along with the event.',
|
|
23
|
-
default: {
|
|
24
|
-
'@path': '$.properties'
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
...common_fields_1.commonFields
|
|
28
|
-
},
|
|
8
|
+
fields: {},
|
|
29
9
|
perform: (request, { payload, settings }) => {
|
|
30
10
|
return request(regional_endpoints_1.getEndpointByRegion('track', settings.dataCenter), {
|
|
31
11
|
method: 'post',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/trackEvent/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/destinations/gainsight-px-cloud-action/trackEvent/index.ts"],"names":[],"mappings":";;AAGA,8DAA2D;AAE3D,MAAM,MAAM,GAAwC;IAClD,KAAK,EAAE,aAAa;IACpB,WAAW,EAAE,+BAA+B;IAC5C,mBAAmB,EAAE,gBAAgB;IACrC,MAAM,EAAE,EAAE;IACV,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE;QAE1C,OAAO,OAAO,CAAC,wCAAmB,CAAC,OAAO,EAAE,QAAQ,CAAC,UAAU,CAAC,EAAE;YAChE,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,OAAO;SACd,CAAC,CAAA;IACJ,CAAC;CACF,CAAA;AAED,kBAAe,MAAM,CAAA"}
|