@pushwoosh/rpc-v2-http-api-data 0.2.264 → 0.2.266

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/accounts.d.ts CHANGED
@@ -314,6 +314,13 @@ export type EmailTemplate = {
314
314
  updated: Date;
315
315
  categories: string[];
316
316
  previewSettings: object;
317
+ /**
318
+ * Number of the newest stored content version; 0 when the item has none. Compare it with
319
+ * the version an approval request was decided on: a lower one means the decision predates
320
+ * the content, which is what the send gate looks at. Filled only for accounts that run
321
+ * content approval.
322
+ */
323
+ contentVersionNo: number;
317
324
  };
318
325
  export type TestEmailTemplateRequest = {
319
326
  application?: string;
package/data.js CHANGED
@@ -11826,6 +11826,9 @@ export const data = {
11826
11826
  },
11827
11827
  "previewSettings": {
11828
11828
  "type": "object"
11829
+ },
11830
+ "contentVersionNo": {
11831
+ "type": "number"
11829
11832
  }
11830
11833
  }
11831
11834
  },
@@ -12592,6 +12595,18 @@ export const data = {
12592
12595
  "response": "pushwoosh.rpc_v2.events.GetTotalStatisticsResponse",
12593
12596
  "method": "post",
12594
12597
  "path": "/api/events:getTotalStatistics"
12598
+ },
12599
+ "GetConversionSettings": {
12600
+ "request": "pushwoosh.rpc_v2.events.GetConversionSettingsRequest",
12601
+ "response": "pushwoosh.rpc_v2.events.ConversionSettings",
12602
+ "method": "get",
12603
+ "path": "/api/events:conversion-settings"
12604
+ },
12605
+ "SaveConversionSettings": {
12606
+ "request": "pushwoosh.rpc_v2.events.SaveConversionSettingsRequest",
12607
+ "response": "pushwoosh.rpc_v2.events.ConversionSettings",
12608
+ "method": "put",
12609
+ "path": "/api/events:conversion-settings"
12595
12610
  }
12596
12611
  }
12597
12612
  },
@@ -13046,6 +13061,56 @@ export const data = {
13046
13061
  }
13047
13062
  }
13048
13063
  },
13064
+ "pushwoosh.rpc_v2.events.ContactType": {
13065
+ "type": "E",
13066
+ "values": [
13067
+ "CONTACT_TYPE_UNSPECIFIED",
13068
+ "CONTACT_TYPE_CLICK",
13069
+ "CONTACT_TYPE_SENT"
13070
+ ]
13071
+ },
13072
+ "pushwoosh.rpc_v2.events.ConversionEvent": {
13073
+ "type": "I",
13074
+ "fields": {
13075
+ "name": {
13076
+ "type": "string"
13077
+ },
13078
+ "attributionWindowSeconds": {
13079
+ "type": "number"
13080
+ }
13081
+ }
13082
+ },
13083
+ "pushwoosh.rpc_v2.events.ConversionSettings": {
13084
+ "type": "I",
13085
+ "fields": {
13086
+ "events": {
13087
+ "type": "pushwoosh.rpc_v2.events.ConversionEvent",
13088
+ "array": true
13089
+ },
13090
+ "contactType": {
13091
+ "type": "pushwoosh.rpc_v2.events.ContactType"
13092
+ }
13093
+ }
13094
+ },
13095
+ "pushwoosh.rpc_v2.events.GetConversionSettingsRequest": {
13096
+ "type": "I",
13097
+ "fields": {
13098
+ "application": {
13099
+ "type": "string"
13100
+ }
13101
+ }
13102
+ },
13103
+ "pushwoosh.rpc_v2.events.SaveConversionSettingsRequest": {
13104
+ "type": "I",
13105
+ "fields": {
13106
+ "application": {
13107
+ "type": "string"
13108
+ },
13109
+ "settings": {
13110
+ "type": "pushwoosh.rpc_v2.events.ConversionSettings"
13111
+ }
13112
+ }
13113
+ },
13049
13114
  "pushwoosh.rpc_v2.export_messages.ExportStatisticsService": {
13050
13115
  "type": "S",
13051
13116
  "key": "exportStatistics",
package/events.d.ts CHANGED
@@ -8,6 +8,8 @@ export type EventsService_GetAttributeValues = RpcMethod<GetAttributeValuesReque
8
8
  export type EventsService_GetTriggeredCount = RpcMethod<GetTriggeredCountRequest, GetTriggeredCountResponse>;
9
9
  export type EventsService_GetDetailedStatistics = RpcMethod<GetDetailedStatisticsRequest, GetDetailedStatisticsResponse>;
10
10
  export type EventsService_GetTotalStatistics = RpcMethod<GetTotalStatisticsRequest, GetTotalStatisticsResponse>;
11
+ export type EventsService_GetConversionSettings = RpcMethod<GetConversionSettingsRequest, ConversionSettings>;
12
+ export type EventsService_SaveConversionSettings = RpcMethod<SaveConversionSettingsRequest, ConversionSettings>;
11
13
  export interface EventsService {
12
14
  /** Returns one custom event by name for an application, including its attributes, store-days and revenue mapping. Use after list_events to inspect a single event's definition. */
13
15
  Get: EventsService_Get;
@@ -27,6 +29,10 @@ export interface EventsService {
27
29
  GetDetailedStatistics: EventsService_GetDetailedStatistics;
28
30
  /** Returns total and unique triggered counts for custom events over a date range, optionally scoped to a message code or campaign. Use to attribute event volume to a specific send or campaign. */
29
31
  GetTotalStatistics: EventsService_GetTotalStatistics;
32
+ /** Returns which custom events of an application count as conversions for campaign attribution, each with its attribution window, plus the contact type (click or send) conversions are counted from. Empty events means attribution is not configured yet. */
33
+ GetConversionSettings: EventsService_GetConversionSettings;
34
+ /** Replaces the conversion settings of an application: up to 3 events with an attribution window each (24h, 72h, 7d or 30d) and one contact type for all of them. Events left out of the request stop counting as conversions. */
35
+ SaveConversionSettings: EventsService_SaveConversionSettings;
30
36
  }
31
37
  export type GetEventRequest = {
32
38
  /** Application code (format XXXXX-XXXXX) the event belongs to. */
@@ -223,3 +229,27 @@ export type GetTotalStatisticsResponse = {
223
229
  /** Distinct users across all events at once; metrics are per event, so summing their uniq counts double-counts. */
224
230
  totalUniqTriggeredCount: number;
225
231
  };
232
+ /** ContactType is the touch a conversion is counted from: the click on the message (default) or the send itself. */
233
+ export type ContactType = 'CONTACT_TYPE_UNSPECIFIED' | 'CONTACT_TYPE_CLICK' | 'CONTACT_TYPE_SENT';
234
+ export type ConversionEvent = {
235
+ /** Name of the application's custom event that counts as a conversion. */
236
+ name: string;
237
+ /** Attribution window in seconds: 86400, 259200, 604800 or 2592000. Zero means the default 259200 (72h). */
238
+ attributionWindowSeconds: number;
239
+ };
240
+ export type ConversionSettings = {
241
+ /** Up to 3 events counted as conversions, each with its own window. */
242
+ events: ConversionEvent[];
243
+ /** Contact type shared by all events of the application; UNSPECIFIED reads as CLICK. */
244
+ contactType: ContactType;
245
+ };
246
+ export type GetConversionSettingsRequest = {
247
+ /** Application code (format XXXXX-XXXXX). */
248
+ application?: string;
249
+ };
250
+ export type SaveConversionSettingsRequest = {
251
+ /** Application code (format XXXXX-XXXXX). */
252
+ application?: string;
253
+ /** Full replacement of the application's conversion settings; events left out stop counting. */
254
+ settings?: ConversionSettings;
255
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushwoosh/rpc-v2-http-api-data",
3
- "version": "0.2.264",
3
+ "version": "0.2.266",
4
4
  "description": "RPC V2 HTTP API Types and Data",
5
5
  "main": "index.js",
6
6
  "module": "index.js",