@onesignal/node-onesignal 5.3.0-beta1 → 5.4.0-beta1

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 (194) hide show
  1. package/dist/apis/DefaultApi.js +44 -44
  2. package/dist/index.d.ts +1 -1
  3. package/dist/models/BasicNotification.d.ts +7 -0
  4. package/dist/models/BasicNotification.js +36 -0
  5. package/dist/models/BasicNotificationAllOf.d.ts +7 -0
  6. package/dist/models/BasicNotificationAllOf.js +36 -0
  7. package/dist/models/Notification.d.ts +7 -0
  8. package/dist/models/Notification.js +36 -0
  9. package/dist/models/NotificationWithMeta.d.ts +7 -0
  10. package/dist/models/NotificationWithMeta.js +36 -0
  11. package/dist/models/ObjectSerializer.js +4 -0
  12. package/package.json +9 -3
  13. package/.github/ISSUE_TEMPLATE/ask-question.yml +0 -25
  14. package/.github/ISSUE_TEMPLATE/bug-report.yml +0 -51
  15. package/.github/ISSUE_TEMPLATE/general-feedback.yml +0 -25
  16. package/.github/pull_request_template.md +0 -44
  17. package/.github/workflows/asana-add-comment.yml +0 -47
  18. package/.github/workflows/asana-create-task.yml +0 -119
  19. package/.github/workflows/asana-update-issue.yml +0 -172
  20. package/.github/workflows/npm_deploy.yml +0 -22
  21. package/.github/workflows/project.yml +0 -17
  22. package/CHANGELOG.md +0 -48
  23. package/DefaultApi.md +0 -3293
  24. package/RELEASE_INSTRUCTIONS.md +0 -2
  25. package/apis/DefaultApi.ts +0 -4673
  26. package/apis/baseapi.ts +0 -37
  27. package/apis/exception.ts +0 -15
  28. package/auth/auth.ts +0 -110
  29. package/configuration.ts +0 -85
  30. package/dist/apis/DefaultApi.js.map +0 -1
  31. package/dist/apis/baseapi.js.map +0 -1
  32. package/dist/apis/exception.js.map +0 -1
  33. package/dist/auth/auth.js.map +0 -1
  34. package/dist/configuration.js.map +0 -1
  35. package/dist/http/http.js.map +0 -1
  36. package/dist/http/isomorphic-fetch.js.map +0 -1
  37. package/dist/index.js.map +0 -1
  38. package/dist/middleware.js.map +0 -1
  39. package/dist/models/ApiKeyToken.js.map +0 -1
  40. package/dist/models/ApiKeyTokensListResponse.js.map +0 -1
  41. package/dist/models/App.js.map +0 -1
  42. package/dist/models/BasicNotification.js.map +0 -1
  43. package/dist/models/BasicNotificationAllOf.js.map +0 -1
  44. package/dist/models/BasicNotificationAllOfAndroidBackgroundLayout.js.map +0 -1
  45. package/dist/models/Button.js.map +0 -1
  46. package/dist/models/CopyTemplateRequest.js.map +0 -1
  47. package/dist/models/CreateApiKeyRequest.js.map +0 -1
  48. package/dist/models/CreateApiKeyResponse.js.map +0 -1
  49. package/dist/models/CreateNotificationSuccessResponse.js.map +0 -1
  50. package/dist/models/CreateSegmentConflictResponse.js.map +0 -1
  51. package/dist/models/CreateSegmentSuccessResponse.js.map +0 -1
  52. package/dist/models/CreateTemplateRequest.js.map +0 -1
  53. package/dist/models/CreateUserConflictResponse.js.map +0 -1
  54. package/dist/models/CreateUserConflictResponseErrorsInner.js.map +0 -1
  55. package/dist/models/CreateUserConflictResponseErrorsItemsMeta.js.map +0 -1
  56. package/dist/models/CustomEvent.js.map +0 -1
  57. package/dist/models/CustomEventsRequest.js.map +0 -1
  58. package/dist/models/DeliveryData.js.map +0 -1
  59. package/dist/models/ExportEventsSuccessResponse.js.map +0 -1
  60. package/dist/models/ExportSubscriptionsRequestBody.js.map +0 -1
  61. package/dist/models/ExportSubscriptionsSuccessResponse.js.map +0 -1
  62. package/dist/models/Filter.js.map +0 -1
  63. package/dist/models/FilterExpression.js.map +0 -1
  64. package/dist/models/GenericError.js.map +0 -1
  65. package/dist/models/GenericSuccessBoolResponse.js.map +0 -1
  66. package/dist/models/GetNotificationHistoryRequestBody.js.map +0 -1
  67. package/dist/models/GetSegmentsSuccessResponse.js.map +0 -1
  68. package/dist/models/LanguageStringMap.js.map +0 -1
  69. package/dist/models/Notification.js.map +0 -1
  70. package/dist/models/NotificationAllOf.js.map +0 -1
  71. package/dist/models/NotificationHistorySuccessResponse.js.map +0 -1
  72. package/dist/models/NotificationSlice.js.map +0 -1
  73. package/dist/models/NotificationTarget.js.map +0 -1
  74. package/dist/models/NotificationWithMeta.js.map +0 -1
  75. package/dist/models/NotificationWithMetaAllOf.js.map +0 -1
  76. package/dist/models/ObjectSerializer.js.map +0 -1
  77. package/dist/models/Operator.js.map +0 -1
  78. package/dist/models/OutcomeData.js.map +0 -1
  79. package/dist/models/OutcomesData.js.map +0 -1
  80. package/dist/models/PlatformDeliveryData.js.map +0 -1
  81. package/dist/models/PlatformDeliveryDataEmailAllOf.js.map +0 -1
  82. package/dist/models/PlatformDeliveryDataSmsAllOf.js.map +0 -1
  83. package/dist/models/PropertiesBody.js.map +0 -1
  84. package/dist/models/PropertiesDeltas.js.map +0 -1
  85. package/dist/models/PropertiesObject.js.map +0 -1
  86. package/dist/models/Purchase.js.map +0 -1
  87. package/dist/models/RateLimitError.js.map +0 -1
  88. package/dist/models/Segment.js.map +0 -1
  89. package/dist/models/SegmentData.js.map +0 -1
  90. package/dist/models/SegmentNotificationTarget.js.map +0 -1
  91. package/dist/models/StartLiveActivityRequest.js.map +0 -1
  92. package/dist/models/StartLiveActivitySuccessResponse.js.map +0 -1
  93. package/dist/models/Subscription.js.map +0 -1
  94. package/dist/models/SubscriptionBody.js.map +0 -1
  95. package/dist/models/SubscriptionNotificationTarget.js.map +0 -1
  96. package/dist/models/TemplateResource.js.map +0 -1
  97. package/dist/models/TemplatesListResponse.js.map +0 -1
  98. package/dist/models/TransferSubscriptionRequestBody.js.map +0 -1
  99. package/dist/models/UpdateApiKeyRequest.js.map +0 -1
  100. package/dist/models/UpdateLiveActivityRequest.js.map +0 -1
  101. package/dist/models/UpdateLiveActivitySuccessResponse.js.map +0 -1
  102. package/dist/models/UpdateTemplateRequest.js.map +0 -1
  103. package/dist/models/UpdateUserRequest.js.map +0 -1
  104. package/dist/models/User.js.map +0 -1
  105. package/dist/models/UserIdentityBody.js.map +0 -1
  106. package/dist/models/WebButton.js.map +0 -1
  107. package/dist/models/all.js.map +0 -1
  108. package/dist/rxjsStub.js.map +0 -1
  109. package/dist/servers.js.map +0 -1
  110. package/dist/types/ObjectParamAPI.js.map +0 -1
  111. package/dist/types/ObservableAPI.js.map +0 -1
  112. package/dist/types/PromiseAPI.js.map +0 -1
  113. package/dist/util.js.map +0 -1
  114. package/http/http.ts +0 -205
  115. package/http/isomorphic-fetch.ts +0 -30
  116. package/index.ts +0 -12
  117. package/middleware.ts +0 -66
  118. package/models/ApiKeyToken.ts +0 -69
  119. package/models/ApiKeyTokensListResponse.ts +0 -32
  120. package/models/App.ts +0 -328
  121. package/models/BasicNotification.ts +0 -1088
  122. package/models/BasicNotificationAllOf.ts +0 -958
  123. package/models/BasicNotificationAllOfAndroidBackgroundLayout.ts +0 -57
  124. package/models/Button.ts +0 -45
  125. package/models/CopyTemplateRequest.ts +0 -34
  126. package/models/CreateApiKeyRequest.ts +0 -48
  127. package/models/CreateApiKeyResponse.ts +0 -38
  128. package/models/CreateNotificationSuccessResponse.ts +0 -48
  129. package/models/CreateSegmentConflictResponse.ts +0 -38
  130. package/models/CreateSegmentSuccessResponse.ts +0 -41
  131. package/models/CreateTemplateRequest.ts +0 -102
  132. package/models/CreateUserConflictResponse.ts +0 -32
  133. package/models/CreateUserConflictResponseErrorsInner.ts +0 -46
  134. package/models/CreateUserConflictResponseErrorsItemsMeta.ts +0 -31
  135. package/models/CustomEvent.ts +0 -74
  136. package/models/CustomEventsRequest.ts +0 -32
  137. package/models/DeliveryData.ts +0 -74
  138. package/models/ExportEventsSuccessResponse.ts +0 -31
  139. package/models/ExportSubscriptionsRequestBody.ts +0 -54
  140. package/models/ExportSubscriptionsSuccessResponse.ts +0 -31
  141. package/models/Filter.ts +0 -107
  142. package/models/FilterExpression.ts +0 -120
  143. package/models/GenericError.ts +0 -45
  144. package/models/GenericSuccessBoolResponse.ts +0 -31
  145. package/models/GetNotificationHistoryRequestBody.ts +0 -54
  146. package/models/GetSegmentsSuccessResponse.ts +0 -65
  147. package/models/LanguageStringMap.ts +0 -454
  148. package/models/Notification.ts +0 -1098
  149. package/models/NotificationAllOf.ts +0 -34
  150. package/models/NotificationHistorySuccessResponse.ts +0 -38
  151. package/models/NotificationSlice.ts +0 -53
  152. package/models/NotificationTarget.ts +0 -156
  153. package/models/NotificationWithMeta.ts +0 -1206
  154. package/models/NotificationWithMetaAllOf.ts +0 -142
  155. package/models/ObjectSerializer.ts +0 -442
  156. package/models/Operator.ts +0 -37
  157. package/models/OutcomeData.ts +0 -48
  158. package/models/OutcomesData.ts +0 -32
  159. package/models/PlatformDeliveryData.ts +0 -86
  160. package/models/PlatformDeliveryDataEmailAllOf.ts +0 -94
  161. package/models/PlatformDeliveryDataSmsAllOf.ts +0 -54
  162. package/models/PropertiesBody.ts +0 -32
  163. package/models/PropertiesDeltas.ts +0 -46
  164. package/models/PropertiesObject.ts +0 -102
  165. package/models/Purchase.ts +0 -61
  166. package/models/RateLimitError.ts +0 -38
  167. package/models/Segment.ts +0 -55
  168. package/models/SegmentData.ts +0 -94
  169. package/models/SegmentNotificationTarget.ts +0 -44
  170. package/models/StartLiveActivityRequest.ts +0 -177
  171. package/models/StartLiveActivitySuccessResponse.ts +0 -31
  172. package/models/Subscription.ts +0 -146
  173. package/models/SubscriptionBody.ts +0 -32
  174. package/models/SubscriptionNotificationTarget.ts +0 -134
  175. package/models/TemplateResource.ts +0 -72
  176. package/models/TemplatesListResponse.ts +0 -32
  177. package/models/TransferSubscriptionRequestBody.ts +0 -31
  178. package/models/UpdateApiKeyRequest.ts +0 -48
  179. package/models/UpdateLiveActivityRequest.ts +0 -109
  180. package/models/UpdateLiveActivitySuccessResponse.ts +0 -31
  181. package/models/UpdateTemplateRequest.ts +0 -92
  182. package/models/UpdateUserRequest.ts +0 -47
  183. package/models/User.ts +0 -47
  184. package/models/UserIdentityBody.ts +0 -31
  185. package/models/WebButton.ts +0 -52
  186. package/models/all.ts +0 -67
  187. package/onesignal-node-onesignal-5.3.0-beta1.tgz +0 -0
  188. package/rxjsStub.ts +0 -27
  189. package/servers.ts +0 -53
  190. package/tsconfig.json +0 -28
  191. package/types/ObjectParamAPI.ts +0 -1270
  192. package/types/ObservableAPI.ts +0 -1201
  193. package/types/PromiseAPI.ts +0 -585
  194. package/util.ts +0 -37
@@ -1,94 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class SegmentData {
12
- /**
13
- * The segment ID
14
- */
15
- 'id'?: string;
16
- /**
17
- * The segment name
18
- */
19
- 'name'?: string;
20
- /**
21
- * Date segment created
22
- */
23
- 'created_at'?: string;
24
- /**
25
- * Date segment last updated
26
- */
27
- 'updated_at'?: string;
28
- /**
29
- * The app id
30
- */
31
- 'app_id'?: string;
32
- /**
33
- * Is the segment read only?
34
- */
35
- 'read_only'?: boolean;
36
- /**
37
- * Is the segment active?
38
- */
39
- 'is_active'?: boolean;
40
-
41
- static readonly discriminator: string | undefined = undefined;
42
-
43
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
44
- {
45
- "name": "id",
46
- "baseName": "id",
47
- "type": "string",
48
- "format": ""
49
- },
50
- {
51
- "name": "name",
52
- "baseName": "name",
53
- "type": "string",
54
- "format": ""
55
- },
56
- {
57
- "name": "created_at",
58
- "baseName": "created_at",
59
- "type": "string",
60
- "format": ""
61
- },
62
- {
63
- "name": "updated_at",
64
- "baseName": "updated_at",
65
- "type": "string",
66
- "format": ""
67
- },
68
- {
69
- "name": "app_id",
70
- "baseName": "app_id",
71
- "type": "string",
72
- "format": ""
73
- },
74
- {
75
- "name": "read_only",
76
- "baseName": "read_only",
77
- "type": "boolean",
78
- "format": ""
79
- },
80
- {
81
- "name": "is_active",
82
- "baseName": "is_active",
83
- "type": "boolean",
84
- "format": ""
85
- } ];
86
-
87
- static getAttributeTypeMap() {
88
- return SegmentData.attributeTypeMap;
89
- }
90
-
91
- public constructor() {
92
- }
93
- }
94
-
@@ -1,44 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class SegmentNotificationTarget {
12
- /**
13
- * The segment names you want to target. Users in these segments will receive a notification. This targeting parameter is only compatible with excluded_segments. Example: [\"Active Users\", \"Inactive Users\"]
14
- */
15
- 'included_segments'?: Array<string>;
16
- /**
17
- * Segment that will be excluded when sending. Users in these segments will not receive a notification, even if they were included in included_segments. This targeting parameter is only compatible with included_segments. Example: [\"Active Users\", \"Inactive Users\"]
18
- */
19
- 'excluded_segments'?: Array<string>;
20
-
21
- static readonly discriminator: string | undefined = undefined;
22
-
23
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
24
- {
25
- "name": "included_segments",
26
- "baseName": "included_segments",
27
- "type": "Array<string>",
28
- "format": ""
29
- },
30
- {
31
- "name": "excluded_segments",
32
- "baseName": "excluded_segments",
33
- "type": "Array<string>",
34
- "format": ""
35
- } ];
36
-
37
- static getAttributeTypeMap() {
38
- return SegmentNotificationTarget.attributeTypeMap;
39
- }
40
-
41
- public constructor() {
42
- }
43
- }
44
-
@@ -1,177 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { FilterExpression } from './FilterExpression';
10
- import { LanguageStringMap } from './LanguageStringMap';
11
- import { HttpFile } from '../http/http';
12
-
13
- export class StartLiveActivityRequest {
14
- /**
15
- * An internal name to assist with your campaign organization. This does not get displayed in the message itself.
16
- */
17
- 'name': string;
18
- 'event': StartLiveActivityRequestEventEnum;
19
- /**
20
- * Set a unique activity_id to track and manage the Live Activity.
21
- */
22
- 'activity_id': string;
23
- /**
24
- * Default/static data to initialize the Live Activity upon start.
25
- */
26
- 'event_attributes': object;
27
- /**
28
- * Dynamic content used to update the running Live Activity at start. Must match the ContentState interface defined in your app.
29
- */
30
- 'event_updates': object;
31
- 'contents': LanguageStringMap;
32
- 'headings': LanguageStringMap;
33
- /**
34
- * Accepts Unix timestamp in seconds. When time reaches the configured stale date, the system considers the Live Activity out of date, and the ActivityState of the Live Activity changes to ActivityState.stale.
35
- */
36
- 'stale_date'?: number;
37
- /**
38
- * Delivery priority through the push provider (APNs). Pass 10 for higher priority notifications, or 5 for lower priority notifications. Lower priority notifications are sent based on the power considerations of the end user\'s device. If not set, defaults to 10.
39
- */
40
- 'priority'?: number;
41
- /**
42
- * iOS 15+. A score to indicate how a notification should be displayed when grouped. Use a float between 0-1.
43
- */
44
- 'ios_relevance_score'?: number;
45
- /**
46
- * Correlation and idempotency key. A request received with this parameter will first look for another notification with the same idempotency key. If one exists, a notification will not be sent, and result of the previous operation will instead be returned. Therefore, if you plan on using this feature, it\'s important to use a good source of randomness to generate the UUID passed here. This key is only idempotent for 30 days. After 30 days, the notification could be removed from our system and a notification with the same idempotency key will be sent again. See Idempotent Notification Requests for more details writeOnly: true
47
- */
48
- 'idempotency_key'?: string;
49
- /**
50
- * Target specific users by aliases assigned via API. An alias can be an external_id, onesignal_id, or a custom alias. Accepts an object where keys are alias labels and values are arrays of alias IDs to include Example usage: { \"external_id\": [\"exId1\", \"extId2\"], \"internal_label\": [\"id1\", \"id2\"] } Not compatible with any other targeting parameters. REQUIRED: REST API Key Authentication Limit of 2,000 entries per REST API call Note: If targeting push, email, or sms subscribers with same ids, use with target_channel to indicate you are sending a push or email or sms.
51
- */
52
- 'include_aliases'?: { [key: string]: Array<string>; };
53
- /**
54
- * Specific subscription ids to target. Not compatible with other targeting parameters.
55
- */
56
- 'include_subscription_ids'?: Array<string>;
57
- /**
58
- * Segment names to include. Only compatible with excluded_segments.
59
- */
60
- 'included_segments'?: Array<string>;
61
- /**
62
- * Segment names to exclude. Only compatible with included_segments.
63
- */
64
- 'excluded_segments'?: Array<string>;
65
- 'filters'?: Array<FilterExpression>;
66
-
67
- static readonly discriminator: string | undefined = undefined;
68
-
69
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
70
- {
71
- "name": "name",
72
- "baseName": "name",
73
- "type": "string",
74
- "format": ""
75
- },
76
- {
77
- "name": "event",
78
- "baseName": "event",
79
- "type": "StartLiveActivityRequestEventEnum",
80
- "format": ""
81
- },
82
- {
83
- "name": "activity_id",
84
- "baseName": "activity_id",
85
- "type": "string",
86
- "format": ""
87
- },
88
- {
89
- "name": "event_attributes",
90
- "baseName": "event_attributes",
91
- "type": "object",
92
- "format": ""
93
- },
94
- {
95
- "name": "event_updates",
96
- "baseName": "event_updates",
97
- "type": "object",
98
- "format": ""
99
- },
100
- {
101
- "name": "contents",
102
- "baseName": "contents",
103
- "type": "LanguageStringMap",
104
- "format": ""
105
- },
106
- {
107
- "name": "headings",
108
- "baseName": "headings",
109
- "type": "LanguageStringMap",
110
- "format": ""
111
- },
112
- {
113
- "name": "stale_date",
114
- "baseName": "stale_date",
115
- "type": "number",
116
- "format": ""
117
- },
118
- {
119
- "name": "priority",
120
- "baseName": "priority",
121
- "type": "number",
122
- "format": ""
123
- },
124
- {
125
- "name": "ios_relevance_score",
126
- "baseName": "ios_relevance_score",
127
- "type": "number",
128
- "format": ""
129
- },
130
- {
131
- "name": "idempotency_key",
132
- "baseName": "idempotency_key",
133
- "type": "string",
134
- "format": ""
135
- },
136
- {
137
- "name": "include_aliases",
138
- "baseName": "include_aliases",
139
- "type": "{ [key: string]: Array<string>; }",
140
- "format": ""
141
- },
142
- {
143
- "name": "include_subscription_ids",
144
- "baseName": "include_subscription_ids",
145
- "type": "Array<string>",
146
- "format": ""
147
- },
148
- {
149
- "name": "included_segments",
150
- "baseName": "included_segments",
151
- "type": "Array<string>",
152
- "format": ""
153
- },
154
- {
155
- "name": "excluded_segments",
156
- "baseName": "excluded_segments",
157
- "type": "Array<string>",
158
- "format": ""
159
- },
160
- {
161
- "name": "filters",
162
- "baseName": "filters",
163
- "type": "Array<FilterExpression>",
164
- "format": ""
165
- } ];
166
-
167
- static getAttributeTypeMap() {
168
- return StartLiveActivityRequest.attributeTypeMap;
169
- }
170
-
171
- public constructor() {
172
- }
173
- }
174
-
175
-
176
- export type StartLiveActivityRequestEventEnum = "start" ;
177
-
@@ -1,31 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class StartLiveActivitySuccessResponse {
12
- 'notification_id'?: string;
13
-
14
- static readonly discriminator: string | undefined = undefined;
15
-
16
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
17
- {
18
- "name": "notification_id",
19
- "baseName": "notification_id",
20
- "type": "string",
21
- "format": ""
22
- } ];
23
-
24
- static getAttributeTypeMap() {
25
- return StartLiveActivitySuccessResponse.attributeTypeMap;
26
- }
27
-
28
- public constructor() {
29
- }
30
- }
31
-
@@ -1,146 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class Subscription {
12
- 'id'?: string;
13
- 'type'?: SubscriptionTypeEnum;
14
- 'token'?: string;
15
- 'enabled'?: boolean;
16
- 'notification_types'?: number;
17
- 'session_time'?: number;
18
- 'session_count'?: number;
19
- 'sdk'?: string;
20
- 'device_model'?: string;
21
- 'device_os'?: string;
22
- 'rooted'?: boolean;
23
- 'test_type'?: number;
24
- 'app_version'?: string;
25
- 'net_type'?: number;
26
- 'carrier'?: string;
27
- 'web_auth'?: string;
28
- 'web_p256'?: string;
29
-
30
- static readonly discriminator: string | undefined = undefined;
31
-
32
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
33
- {
34
- "name": "id",
35
- "baseName": "id",
36
- "type": "string",
37
- "format": ""
38
- },
39
- {
40
- "name": "type",
41
- "baseName": "type",
42
- "type": "SubscriptionTypeEnum",
43
- "format": ""
44
- },
45
- {
46
- "name": "token",
47
- "baseName": "token",
48
- "type": "string",
49
- "format": ""
50
- },
51
- {
52
- "name": "enabled",
53
- "baseName": "enabled",
54
- "type": "boolean",
55
- "format": ""
56
- },
57
- {
58
- "name": "notification_types",
59
- "baseName": "notification_types",
60
- "type": "number",
61
- "format": ""
62
- },
63
- {
64
- "name": "session_time",
65
- "baseName": "session_time",
66
- "type": "number",
67
- "format": ""
68
- },
69
- {
70
- "name": "session_count",
71
- "baseName": "session_count",
72
- "type": "number",
73
- "format": ""
74
- },
75
- {
76
- "name": "sdk",
77
- "baseName": "sdk",
78
- "type": "string",
79
- "format": ""
80
- },
81
- {
82
- "name": "device_model",
83
- "baseName": "device_model",
84
- "type": "string",
85
- "format": ""
86
- },
87
- {
88
- "name": "device_os",
89
- "baseName": "device_os",
90
- "type": "string",
91
- "format": ""
92
- },
93
- {
94
- "name": "rooted",
95
- "baseName": "rooted",
96
- "type": "boolean",
97
- "format": ""
98
- },
99
- {
100
- "name": "test_type",
101
- "baseName": "test_type",
102
- "type": "number",
103
- "format": ""
104
- },
105
- {
106
- "name": "app_version",
107
- "baseName": "app_version",
108
- "type": "string",
109
- "format": ""
110
- },
111
- {
112
- "name": "net_type",
113
- "baseName": "net_type",
114
- "type": "number",
115
- "format": ""
116
- },
117
- {
118
- "name": "carrier",
119
- "baseName": "carrier",
120
- "type": "string",
121
- "format": ""
122
- },
123
- {
124
- "name": "web_auth",
125
- "baseName": "web_auth",
126
- "type": "string",
127
- "format": ""
128
- },
129
- {
130
- "name": "web_p256",
131
- "baseName": "web_p256",
132
- "type": "string",
133
- "format": ""
134
- } ];
135
-
136
- static getAttributeTypeMap() {
137
- return Subscription.attributeTypeMap;
138
- }
139
-
140
- public constructor() {
141
- }
142
- }
143
-
144
-
145
- export type SubscriptionTypeEnum = "iOSPush" | "AndroidPush" | "FireOSPush" | "ChromeExtensionPush" | "ChromePush" | "WindowsPush" | "SafariLegacyPush" | "FirefoxPush" | "macOSPush" | "HuaweiPush" | "SafariPush" | "Email" | "SMS" ;
146
-
@@ -1,32 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { Subscription } from './Subscription';
10
- import { HttpFile } from '../http/http';
11
-
12
- export class SubscriptionBody {
13
- 'subscription'?: Subscription;
14
-
15
- static readonly discriminator: string | undefined = undefined;
16
-
17
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
18
- {
19
- "name": "subscription",
20
- "baseName": "subscription",
21
- "type": "Subscription",
22
- "format": ""
23
- } ];
24
-
25
- static getAttributeTypeMap() {
26
- return SubscriptionBody.attributeTypeMap;
27
- }
28
-
29
- public constructor() {
30
- }
31
- }
32
-
@@ -1,134 +0,0 @@
1
- /**
2
- * OneSignal
3
- * A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
4
- *
5
- * API Version: 5.3.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class SubscriptionNotificationTarget {
12
- /**
13
- * Specific subscription ids to send your notification to. _Does not require API Auth Key._ Not compatible with any other targeting parameters. Example: [\"1dd608f2-c6a1-11e3-851d-000c2940e62c\"] Limit of 2,000 entries per REST API call
14
- */
15
- 'include_subscription_ids'?: Array<string>;
16
- /**
17
- * Recommended for Sending Emails - Target specific email addresses. If an email does not correspond to an existing user, a new user will be created. Example: nick@catfac.ts Limit of 2,000 entries per REST API call
18
- */
19
- 'include_email_tokens'?: Array<string>;
20
- /**
21
- * Recommended for Sending SMS - Target specific phone numbers. The phone number should be in the E.164 format. Phone number should be an existing subscriber on OneSignal. Refer our docs to learn how to add phone numbers to OneSignal. Example phone number: +1999999999 Limit of 2,000 entries per REST API call
22
- */
23
- 'include_phone_numbers'?: Array<string>;
24
- /**
25
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using iOS device tokens. Warning: Only works with Production tokens. All non-alphanumeric characters must be removed from each token. If a token does not correspond to an existing user, a new user will be created. Example: ce777617da7f548fe7a9ab6febb56cf39fba6d38203... Limit of 2,000 entries per REST API call
26
- */
27
- 'include_ios_tokens'?: Array<string>;
28
- /**
29
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using Windows URIs. If a token does not correspond to an existing user, a new user will be created. Example: http://s.notify.live.net/u/1/bn1/HmQAAACPaLDr-... Limit of 2,000 entries per REST API call
30
- */
31
- 'include_wp_wns_uris'?: Array<string>;
32
- /**
33
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using Amazon ADM registration IDs. If a token does not correspond to an existing user, a new user will be created. Example: amzn1.adm-registration.v1.XpvSSUk0Rc3hTVVV... Limit of 2,000 entries per REST API call
34
- */
35
- 'include_amazon_reg_ids'?: Array<string>;
36
- /**
37
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using Chrome App registration IDs. If a token does not correspond to an existing user, a new user will be created. Example: APA91bEeiUeSukAAUdnw3O2RB45FWlSpgJ7Ji_... Limit of 2,000 entries per REST API call
38
- */
39
- 'include_chrome_reg_ids'?: Array<string>;
40
- /**
41
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using Chrome Web Push registration IDs. If a token does not correspond to an existing user, a new user will be created. Example: APA91bEeiUeSukAAUdnw3O2RB45FWlSpgJ7Ji_... Limit of 2,000 entries per REST API call
42
- */
43
- 'include_chrome_web_reg_ids'?: Array<string>;
44
- /**
45
- * Not Recommended: Please consider using include_subscription_ids or include_aliases instead. Target using Android device registration IDs. If a token does not correspond to an existing user, a new user will be created. Example: APA91bEeiUeSukAAUdnw3O2RB45FWlSpgJ7Ji_... Limit of 2,000 entries per REST API call
46
- */
47
- 'include_android_reg_ids'?: Array<string>;
48
- /**
49
- * Target specific users by aliases assigned via API. An alias can be an external_id, onesignal_id, or a custom alias. Accepts an object where keys are alias labels and values are arrays of alias IDs to include Example usage: { \"external_id\": [\"exId1\", \"extId2\"], \"internal_label\": [\"id1\", \"id2\"] } Not compatible with any other targeting parameters. REQUIRED: REST API Key Authentication Limit of 2,000 entries per REST API call Note: If targeting push, email, or sms subscribers with same ids, use with target_channel to indicate you are sending a push or email or sms.
50
- */
51
- 'include_aliases'?: { [key: string]: Array<string>; };
52
- 'target_channel'?: SubscriptionNotificationTargetTargetChannelEnum;
53
-
54
- static readonly discriminator: string | undefined = undefined;
55
-
56
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
57
- {
58
- "name": "include_subscription_ids",
59
- "baseName": "include_subscription_ids",
60
- "type": "Array<string>",
61
- "format": ""
62
- },
63
- {
64
- "name": "include_email_tokens",
65
- "baseName": "include_email_tokens",
66
- "type": "Array<string>",
67
- "format": ""
68
- },
69
- {
70
- "name": "include_phone_numbers",
71
- "baseName": "include_phone_numbers",
72
- "type": "Array<string>",
73
- "format": ""
74
- },
75
- {
76
- "name": "include_ios_tokens",
77
- "baseName": "include_ios_tokens",
78
- "type": "Array<string>",
79
- "format": ""
80
- },
81
- {
82
- "name": "include_wp_wns_uris",
83
- "baseName": "include_wp_wns_uris",
84
- "type": "Array<string>",
85
- "format": ""
86
- },
87
- {
88
- "name": "include_amazon_reg_ids",
89
- "baseName": "include_amazon_reg_ids",
90
- "type": "Array<string>",
91
- "format": ""
92
- },
93
- {
94
- "name": "include_chrome_reg_ids",
95
- "baseName": "include_chrome_reg_ids",
96
- "type": "Array<string>",
97
- "format": ""
98
- },
99
- {
100
- "name": "include_chrome_web_reg_ids",
101
- "baseName": "include_chrome_web_reg_ids",
102
- "type": "Array<string>",
103
- "format": ""
104
- },
105
- {
106
- "name": "include_android_reg_ids",
107
- "baseName": "include_android_reg_ids",
108
- "type": "Array<string>",
109
- "format": ""
110
- },
111
- {
112
- "name": "include_aliases",
113
- "baseName": "include_aliases",
114
- "type": "{ [key: string]: Array<string>; }",
115
- "format": ""
116
- },
117
- {
118
- "name": "target_channel",
119
- "baseName": "target_channel",
120
- "type": "SubscriptionNotificationTargetTargetChannelEnum",
121
- "format": ""
122
- } ];
123
-
124
- static getAttributeTypeMap() {
125
- return SubscriptionNotificationTarget.attributeTypeMap;
126
- }
127
-
128
- public constructor() {
129
- }
130
- }
131
-
132
-
133
- export type SubscriptionNotificationTargetTargetChannelEnum = "push" | "email" | "sms" ;
134
-