@onesignal/node-onesignal 5.2.1-beta1 → 5.3.1-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 (198) hide show
  1. package/dist/apis/DefaultApi.d.ts +40 -0
  2. package/dist/apis/DefaultApi.js +1363 -100
  3. package/dist/models/ApiKeyToken.d.ts +23 -0
  4. package/dist/models/ApiKeyToken.js +52 -0
  5. package/dist/models/ApiKeyTokensListResponse.d.ts +18 -0
  6. package/dist/models/ApiKeyTokensListResponse.js +22 -0
  7. package/dist/models/CopyTemplateRequest.d.ts +17 -0
  8. package/dist/models/CopyTemplateRequest.js +22 -0
  9. package/dist/models/CreateApiKeyRequest.d.ts +20 -0
  10. package/dist/models/CreateApiKeyRequest.js +34 -0
  11. package/dist/models/CreateApiKeyResponse.d.ts +18 -0
  12. package/dist/models/CreateApiKeyResponse.js +28 -0
  13. package/dist/models/CreateTemplateRequest.d.ts +25 -0
  14. package/dist/models/CreateTemplateRequest.js +64 -0
  15. package/dist/models/CustomEvent.d.ts +23 -0
  16. package/dist/models/CustomEvent.js +46 -0
  17. package/dist/models/CustomEventsRequest.d.ts +18 -0
  18. package/dist/models/CustomEventsRequest.js +22 -0
  19. package/dist/models/NotificationWithMeta.d.ts +1 -0
  20. package/dist/models/NotificationWithMeta.js +6 -0
  21. package/dist/models/NotificationWithMetaAllOf.d.ts +1 -0
  22. package/dist/models/NotificationWithMetaAllOf.js +6 -0
  23. package/dist/models/ObjectSerializer.d.ts +14 -0
  24. package/dist/models/ObjectSerializer.js +47 -0
  25. package/dist/models/StartLiveActivityRequest.d.ts +37 -0
  26. package/dist/models/StartLiveActivityRequest.js +112 -0
  27. package/dist/models/StartLiveActivitySuccessResponse.d.ts +17 -0
  28. package/dist/models/StartLiveActivitySuccessResponse.js +22 -0
  29. package/dist/models/TemplateResource.d.ts +25 -0
  30. package/dist/models/TemplateResource.js +52 -0
  31. package/dist/models/TemplatesListResponse.d.ts +18 -0
  32. package/dist/models/TemplatesListResponse.js +22 -0
  33. package/dist/models/UpdateApiKeyRequest.d.ts +20 -0
  34. package/dist/models/UpdateApiKeyRequest.js +34 -0
  35. package/dist/models/UpdateTemplateRequest.d.ts +24 -0
  36. package/dist/models/UpdateTemplateRequest.js +58 -0
  37. package/dist/models/all.d.ts +14 -0
  38. package/dist/models/all.js +14 -0
  39. package/dist/types/ObjectParamAPI.d.ts +88 -0
  40. package/dist/types/ObjectParamAPI.js +42 -0
  41. package/dist/types/ObservableAPI.d.ts +26 -0
  42. package/dist/types/ObservableAPI.js +422 -86
  43. package/dist/types/PromiseAPI.d.ts +26 -0
  44. package/dist/types/PromiseAPI.js +56 -0
  45. package/package.json +9 -3
  46. package/.github/ISSUE_TEMPLATE/ask-question.yml +0 -25
  47. package/.github/ISSUE_TEMPLATE/bug-report.yml +0 -51
  48. package/.github/ISSUE_TEMPLATE/general-feedback.yml +0 -25
  49. package/.github/pull_request_template.md +0 -44
  50. package/.github/workflows/asana-add-comment.yml +0 -47
  51. package/.github/workflows/asana-create-task.yml +0 -119
  52. package/.github/workflows/asana-update-issue.yml +0 -172
  53. package/.github/workflows/npm_deploy.yml +0 -22
  54. package/.github/workflows/project.yml +0 -17
  55. package/CHANGELOG.md +0 -48
  56. package/DefaultApi.md +0 -2177
  57. package/RELEASE_INSTRUCTIONS.md +0 -2
  58. package/apis/DefaultApi.ts +0 -3270
  59. package/apis/baseapi.ts +0 -37
  60. package/apis/exception.ts +0 -15
  61. package/auth/auth.ts +0 -110
  62. package/configuration.ts +0 -85
  63. package/dist/apis/DefaultApi.js.map +0 -1
  64. package/dist/apis/baseapi.js.map +0 -1
  65. package/dist/apis/exception.js.map +0 -1
  66. package/dist/auth/auth.js.map +0 -1
  67. package/dist/configuration.js.map +0 -1
  68. package/dist/http/http.js.map +0 -1
  69. package/dist/http/isomorphic-fetch.js.map +0 -1
  70. package/dist/index.js.map +0 -1
  71. package/dist/middleware.js.map +0 -1
  72. package/dist/models/App.js.map +0 -1
  73. package/dist/models/BasicNotification.js.map +0 -1
  74. package/dist/models/BasicNotificationAllOf.js.map +0 -1
  75. package/dist/models/BasicNotificationAllOfAndroidBackgroundLayout.js.map +0 -1
  76. package/dist/models/Button.js.map +0 -1
  77. package/dist/models/CreateNotificationSuccessResponse.js.map +0 -1
  78. package/dist/models/CreateSegmentConflictResponse.js.map +0 -1
  79. package/dist/models/CreateSegmentSuccessResponse.js.map +0 -1
  80. package/dist/models/CreateUserConflictResponse.js.map +0 -1
  81. package/dist/models/CreateUserConflictResponseErrorsInner.js.map +0 -1
  82. package/dist/models/CreateUserConflictResponseErrorsItemsMeta.js.map +0 -1
  83. package/dist/models/DeliveryData.js.map +0 -1
  84. package/dist/models/ExportEventsSuccessResponse.js.map +0 -1
  85. package/dist/models/ExportSubscriptionsRequestBody.js.map +0 -1
  86. package/dist/models/ExportSubscriptionsSuccessResponse.js.map +0 -1
  87. package/dist/models/Filter.js.map +0 -1
  88. package/dist/models/FilterExpression.js.map +0 -1
  89. package/dist/models/GenericError.js.map +0 -1
  90. package/dist/models/GenericSuccessBoolResponse.js.map +0 -1
  91. package/dist/models/GetNotificationHistoryRequestBody.js.map +0 -1
  92. package/dist/models/GetSegmentsSuccessResponse.js.map +0 -1
  93. package/dist/models/LanguageStringMap.js.map +0 -1
  94. package/dist/models/Notification.js.map +0 -1
  95. package/dist/models/NotificationAllOf.js.map +0 -1
  96. package/dist/models/NotificationHistorySuccessResponse.js.map +0 -1
  97. package/dist/models/NotificationSlice.js.map +0 -1
  98. package/dist/models/NotificationTarget.js.map +0 -1
  99. package/dist/models/NotificationWithMeta.js.map +0 -1
  100. package/dist/models/NotificationWithMetaAllOf.js.map +0 -1
  101. package/dist/models/ObjectSerializer.js.map +0 -1
  102. package/dist/models/Operator.js.map +0 -1
  103. package/dist/models/OutcomeData.js.map +0 -1
  104. package/dist/models/OutcomesData.js.map +0 -1
  105. package/dist/models/PlatformDeliveryData.js.map +0 -1
  106. package/dist/models/PlatformDeliveryDataEmailAllOf.js.map +0 -1
  107. package/dist/models/PlatformDeliveryDataSmsAllOf.js.map +0 -1
  108. package/dist/models/PropertiesBody.js.map +0 -1
  109. package/dist/models/PropertiesDeltas.js.map +0 -1
  110. package/dist/models/PropertiesObject.js.map +0 -1
  111. package/dist/models/Purchase.js.map +0 -1
  112. package/dist/models/RateLimitError.js.map +0 -1
  113. package/dist/models/Segment.js.map +0 -1
  114. package/dist/models/SegmentData.js.map +0 -1
  115. package/dist/models/SegmentNotificationTarget.js.map +0 -1
  116. package/dist/models/Subscription.js.map +0 -1
  117. package/dist/models/SubscriptionBody.js.map +0 -1
  118. package/dist/models/SubscriptionNotificationTarget.js.map +0 -1
  119. package/dist/models/TransferSubscriptionRequestBody.js.map +0 -1
  120. package/dist/models/UpdateLiveActivityRequest.js.map +0 -1
  121. package/dist/models/UpdateLiveActivitySuccessResponse.js.map +0 -1
  122. package/dist/models/UpdateUserRequest.js.map +0 -1
  123. package/dist/models/User.js.map +0 -1
  124. package/dist/models/UserIdentityBody.js.map +0 -1
  125. package/dist/models/WebButton.js.map +0 -1
  126. package/dist/models/all.js.map +0 -1
  127. package/dist/rxjsStub.js.map +0 -1
  128. package/dist/servers.js.map +0 -1
  129. package/dist/types/ObjectParamAPI.js.map +0 -1
  130. package/dist/types/ObservableAPI.js.map +0 -1
  131. package/dist/types/PromiseAPI.js.map +0 -1
  132. package/dist/util.js.map +0 -1
  133. package/http/http.ts +0 -205
  134. package/http/isomorphic-fetch.ts +0 -30
  135. package/index.ts +0 -12
  136. package/middleware.ts +0 -66
  137. package/models/App.ts +0 -328
  138. package/models/BasicNotification.ts +0 -1088
  139. package/models/BasicNotificationAllOf.ts +0 -958
  140. package/models/BasicNotificationAllOfAndroidBackgroundLayout.ts +0 -57
  141. package/models/Button.ts +0 -45
  142. package/models/CreateNotificationSuccessResponse.ts +0 -48
  143. package/models/CreateSegmentConflictResponse.ts +0 -38
  144. package/models/CreateSegmentSuccessResponse.ts +0 -41
  145. package/models/CreateUserConflictResponse.ts +0 -32
  146. package/models/CreateUserConflictResponseErrorsInner.ts +0 -46
  147. package/models/CreateUserConflictResponseErrorsItemsMeta.ts +0 -31
  148. package/models/DeliveryData.ts +0 -74
  149. package/models/ExportEventsSuccessResponse.ts +0 -31
  150. package/models/ExportSubscriptionsRequestBody.ts +0 -54
  151. package/models/ExportSubscriptionsSuccessResponse.ts +0 -31
  152. package/models/Filter.ts +0 -107
  153. package/models/FilterExpression.ts +0 -120
  154. package/models/GenericError.ts +0 -45
  155. package/models/GenericSuccessBoolResponse.ts +0 -31
  156. package/models/GetNotificationHistoryRequestBody.ts +0 -54
  157. package/models/GetSegmentsSuccessResponse.ts +0 -65
  158. package/models/LanguageStringMap.ts +0 -454
  159. package/models/Notification.ts +0 -1098
  160. package/models/NotificationAllOf.ts +0 -34
  161. package/models/NotificationHistorySuccessResponse.ts +0 -38
  162. package/models/NotificationSlice.ts +0 -53
  163. package/models/NotificationTarget.ts +0 -156
  164. package/models/NotificationWithMeta.ts +0 -1196
  165. package/models/NotificationWithMetaAllOf.ts +0 -132
  166. package/models/ObjectSerializer.ts +0 -395
  167. package/models/Operator.ts +0 -37
  168. package/models/OutcomeData.ts +0 -48
  169. package/models/OutcomesData.ts +0 -32
  170. package/models/PlatformDeliveryData.ts +0 -86
  171. package/models/PlatformDeliveryDataEmailAllOf.ts +0 -94
  172. package/models/PlatformDeliveryDataSmsAllOf.ts +0 -54
  173. package/models/PropertiesBody.ts +0 -32
  174. package/models/PropertiesDeltas.ts +0 -46
  175. package/models/PropertiesObject.ts +0 -102
  176. package/models/Purchase.ts +0 -61
  177. package/models/RateLimitError.ts +0 -38
  178. package/models/Segment.ts +0 -55
  179. package/models/SegmentData.ts +0 -94
  180. package/models/SegmentNotificationTarget.ts +0 -44
  181. package/models/Subscription.ts +0 -146
  182. package/models/SubscriptionBody.ts +0 -32
  183. package/models/SubscriptionNotificationTarget.ts +0 -134
  184. package/models/TransferSubscriptionRequestBody.ts +0 -31
  185. package/models/UpdateLiveActivityRequest.ts +0 -109
  186. package/models/UpdateLiveActivitySuccessResponse.ts +0 -31
  187. package/models/UpdateUserRequest.ts +0 -47
  188. package/models/User.ts +0 -47
  189. package/models/UserIdentityBody.ts +0 -31
  190. package/models/WebButton.ts +0 -52
  191. package/models/all.ts +0 -53
  192. package/rxjsStub.ts +0 -27
  193. package/servers.ts +0 -53
  194. package/tsconfig.json +0 -28
  195. package/types/ObjectParamAPI.ts +0 -884
  196. package/types/ObservableAPI.ts +0 -831
  197. package/types/PromiseAPI.ts +0 -411
  198. package/util.ts +0 -37
@@ -1,884 +0,0 @@
1
- import { ResponseContext, RequestContext, HttpFile } from '../http/http';
2
- import * as models from '../models/all';
3
- import { Configuration} from '../configuration'
4
-
5
- import { App } from '../models/App';
6
- import { BasicNotification } from '../models/BasicNotification';
7
- import { BasicNotificationAllOf } from '../models/BasicNotificationAllOf';
8
- import { BasicNotificationAllOfAndroidBackgroundLayout } from '../models/BasicNotificationAllOfAndroidBackgroundLayout';
9
- import { Button } from '../models/Button';
10
- import { CreateNotificationSuccessResponse } from '../models/CreateNotificationSuccessResponse';
11
- import { CreateSegmentConflictResponse } from '../models/CreateSegmentConflictResponse';
12
- import { CreateSegmentSuccessResponse } from '../models/CreateSegmentSuccessResponse';
13
- import { CreateUserConflictResponse } from '../models/CreateUserConflictResponse';
14
- import { CreateUserConflictResponseErrorsInner } from '../models/CreateUserConflictResponseErrorsInner';
15
- import { CreateUserConflictResponseErrorsItemsMeta } from '../models/CreateUserConflictResponseErrorsItemsMeta';
16
- import { DeliveryData } from '../models/DeliveryData';
17
- import { ExportEventsSuccessResponse } from '../models/ExportEventsSuccessResponse';
18
- import { ExportSubscriptionsRequestBody } from '../models/ExportSubscriptionsRequestBody';
19
- import { ExportSubscriptionsSuccessResponse } from '../models/ExportSubscriptionsSuccessResponse';
20
- import { Filter } from '../models/Filter';
21
- import { FilterExpression } from '../models/FilterExpression';
22
- import { GenericError } from '../models/GenericError';
23
- import { GenericSuccessBoolResponse } from '../models/GenericSuccessBoolResponse';
24
- import { GetNotificationHistoryRequestBody } from '../models/GetNotificationHistoryRequestBody';
25
- import { GetSegmentsSuccessResponse } from '../models/GetSegmentsSuccessResponse';
26
- import { LanguageStringMap } from '../models/LanguageStringMap';
27
- import { Notification } from '../models/Notification';
28
- import { NotificationAllOf } from '../models/NotificationAllOf';
29
- import { NotificationHistorySuccessResponse } from '../models/NotificationHistorySuccessResponse';
30
- import { NotificationSlice } from '../models/NotificationSlice';
31
- import { NotificationTarget } from '../models/NotificationTarget';
32
- import { NotificationWithMeta } from '../models/NotificationWithMeta';
33
- import { NotificationWithMetaAllOf } from '../models/NotificationWithMetaAllOf';
34
- import { Operator } from '../models/Operator';
35
- import { OutcomeData } from '../models/OutcomeData';
36
- import { OutcomesData } from '../models/OutcomesData';
37
- import { PlatformDeliveryData } from '../models/PlatformDeliveryData';
38
- import { PlatformDeliveryDataEmailAllOf } from '../models/PlatformDeliveryDataEmailAllOf';
39
- import { PlatformDeliveryDataSmsAllOf } from '../models/PlatformDeliveryDataSmsAllOf';
40
- import { PropertiesBody } from '../models/PropertiesBody';
41
- import { PropertiesDeltas } from '../models/PropertiesDeltas';
42
- import { PropertiesObject } from '../models/PropertiesObject';
43
- import { Purchase } from '../models/Purchase';
44
- import { RateLimitError } from '../models/RateLimitError';
45
- import { Segment } from '../models/Segment';
46
- import { SegmentData } from '../models/SegmentData';
47
- import { SegmentNotificationTarget } from '../models/SegmentNotificationTarget';
48
- import { Subscription } from '../models/Subscription';
49
- import { SubscriptionBody } from '../models/SubscriptionBody';
50
- import { SubscriptionNotificationTarget } from '../models/SubscriptionNotificationTarget';
51
- import { TransferSubscriptionRequestBody } from '../models/TransferSubscriptionRequestBody';
52
- import { UpdateLiveActivityRequest } from '../models/UpdateLiveActivityRequest';
53
- import { UpdateLiveActivitySuccessResponse } from '../models/UpdateLiveActivitySuccessResponse';
54
- import { UpdateUserRequest } from '../models/UpdateUserRequest';
55
- import { User } from '../models/User';
56
- import { UserIdentityBody } from '../models/UserIdentityBody';
57
- import { WebButton } from '../models/WebButton';
58
-
59
- import { ObservableDefaultApi } from "./ObservableAPI";
60
- import { DefaultApiRequestFactory, DefaultApiResponseProcessor} from "../apis/DefaultApi";
61
-
62
- export interface DefaultApiCancelNotificationRequest {
63
- /**
64
- *
65
- * @type string
66
- * @memberof DefaultApicancelNotification
67
- */
68
- appId: string
69
- /**
70
- *
71
- * @type string
72
- * @memberof DefaultApicancelNotification
73
- */
74
- notificationId: string
75
- }
76
-
77
- export interface DefaultApiCreateAliasRequest {
78
- /**
79
- *
80
- * @type string
81
- * @memberof DefaultApicreateAlias
82
- */
83
- appId: string
84
- /**
85
- *
86
- * @type string
87
- * @memberof DefaultApicreateAlias
88
- */
89
- aliasLabel: string
90
- /**
91
- *
92
- * @type string
93
- * @memberof DefaultApicreateAlias
94
- */
95
- aliasId: string
96
- /**
97
- *
98
- * @type UserIdentityBody
99
- * @memberof DefaultApicreateAlias
100
- */
101
- userIdentityBody: UserIdentityBody
102
- }
103
-
104
- export interface DefaultApiCreateAliasBySubscriptionRequest {
105
- /**
106
- *
107
- * @type string
108
- * @memberof DefaultApicreateAliasBySubscription
109
- */
110
- appId: string
111
- /**
112
- *
113
- * @type string
114
- * @memberof DefaultApicreateAliasBySubscription
115
- */
116
- subscriptionId: string
117
- /**
118
- *
119
- * @type UserIdentityBody
120
- * @memberof DefaultApicreateAliasBySubscription
121
- */
122
- userIdentityBody: UserIdentityBody
123
- }
124
-
125
- export interface DefaultApiCreateAppRequest {
126
- /**
127
- *
128
- * @type App
129
- * @memberof DefaultApicreateApp
130
- */
131
- app: App
132
- }
133
-
134
- export interface DefaultApiCreateNotificationRequest {
135
- /**
136
- *
137
- * @type Notification
138
- * @memberof DefaultApicreateNotification
139
- */
140
- notification: Notification
141
- }
142
-
143
- export interface DefaultApiCreateSegmentRequest {
144
- /**
145
- * The OneSignal App ID for your app. Available in Keys & IDs.
146
- * @type string
147
- * @memberof DefaultApicreateSegment
148
- */
149
- appId: string
150
- /**
151
- *
152
- * @type Segment
153
- * @memberof DefaultApicreateSegment
154
- */
155
- segment?: Segment
156
- }
157
-
158
- export interface DefaultApiCreateSubscriptionRequest {
159
- /**
160
- *
161
- * @type string
162
- * @memberof DefaultApicreateSubscription
163
- */
164
- appId: string
165
- /**
166
- *
167
- * @type string
168
- * @memberof DefaultApicreateSubscription
169
- */
170
- aliasLabel: string
171
- /**
172
- *
173
- * @type string
174
- * @memberof DefaultApicreateSubscription
175
- */
176
- aliasId: string
177
- /**
178
- *
179
- * @type SubscriptionBody
180
- * @memberof DefaultApicreateSubscription
181
- */
182
- subscriptionBody: SubscriptionBody
183
- }
184
-
185
- export interface DefaultApiCreateUserRequest {
186
- /**
187
- *
188
- * @type string
189
- * @memberof DefaultApicreateUser
190
- */
191
- appId: string
192
- /**
193
- *
194
- * @type User
195
- * @memberof DefaultApicreateUser
196
- */
197
- user: User
198
- }
199
-
200
- export interface DefaultApiDeleteAliasRequest {
201
- /**
202
- *
203
- * @type string
204
- * @memberof DefaultApideleteAlias
205
- */
206
- appId: string
207
- /**
208
- *
209
- * @type string
210
- * @memberof DefaultApideleteAlias
211
- */
212
- aliasLabel: string
213
- /**
214
- *
215
- * @type string
216
- * @memberof DefaultApideleteAlias
217
- */
218
- aliasId: string
219
- /**
220
- *
221
- * @type string
222
- * @memberof DefaultApideleteAlias
223
- */
224
- aliasLabelToDelete: string
225
- }
226
-
227
- export interface DefaultApiDeleteSegmentRequest {
228
- /**
229
- * The OneSignal App ID for your app. Available in Keys & IDs.
230
- * @type string
231
- * @memberof DefaultApideleteSegment
232
- */
233
- appId: string
234
- /**
235
- * The segment_id can be found in the URL of the segment when viewing it in the dashboard.
236
- * @type string
237
- * @memberof DefaultApideleteSegment
238
- */
239
- segmentId: string
240
- }
241
-
242
- export interface DefaultApiDeleteSubscriptionRequest {
243
- /**
244
- *
245
- * @type string
246
- * @memberof DefaultApideleteSubscription
247
- */
248
- appId: string
249
- /**
250
- *
251
- * @type string
252
- * @memberof DefaultApideleteSubscription
253
- */
254
- subscriptionId: string
255
- }
256
-
257
- export interface DefaultApiDeleteUserRequest {
258
- /**
259
- *
260
- * @type string
261
- * @memberof DefaultApideleteUser
262
- */
263
- appId: string
264
- /**
265
- *
266
- * @type string
267
- * @memberof DefaultApideleteUser
268
- */
269
- aliasLabel: string
270
- /**
271
- *
272
- * @type string
273
- * @memberof DefaultApideleteUser
274
- */
275
- aliasId: string
276
- }
277
-
278
- export interface DefaultApiExportEventsRequest {
279
- /**
280
- * The ID of the notification to export events from.
281
- * @type string
282
- * @memberof DefaultApiexportEvents
283
- */
284
- notificationId: string
285
- /**
286
- * The ID of the app that the notification belongs to.
287
- * @type string
288
- * @memberof DefaultApiexportEvents
289
- */
290
- appId: string
291
- }
292
-
293
- export interface DefaultApiExportSubscriptionsRequest {
294
- /**
295
- * The app ID that you want to export devices from
296
- * @type string
297
- * @memberof DefaultApiexportSubscriptions
298
- */
299
- appId: string
300
- /**
301
- *
302
- * @type ExportSubscriptionsRequestBody
303
- * @memberof DefaultApiexportSubscriptions
304
- */
305
- exportSubscriptionsRequestBody?: ExportSubscriptionsRequestBody
306
- }
307
-
308
- export interface DefaultApiGetAliasesRequest {
309
- /**
310
- *
311
- * @type string
312
- * @memberof DefaultApigetAliases
313
- */
314
- appId: string
315
- /**
316
- *
317
- * @type string
318
- * @memberof DefaultApigetAliases
319
- */
320
- aliasLabel: string
321
- /**
322
- *
323
- * @type string
324
- * @memberof DefaultApigetAliases
325
- */
326
- aliasId: string
327
- }
328
-
329
- export interface DefaultApiGetAliasesBySubscriptionRequest {
330
- /**
331
- *
332
- * @type string
333
- * @memberof DefaultApigetAliasesBySubscription
334
- */
335
- appId: string
336
- /**
337
- *
338
- * @type string
339
- * @memberof DefaultApigetAliasesBySubscription
340
- */
341
- subscriptionId: string
342
- }
343
-
344
- export interface DefaultApiGetAppRequest {
345
- /**
346
- * An app id
347
- * @type string
348
- * @memberof DefaultApigetApp
349
- */
350
- appId: string
351
- }
352
-
353
- export interface DefaultApiGetAppsRequest {
354
- }
355
-
356
- export interface DefaultApiGetNotificationRequest {
357
- /**
358
- *
359
- * @type string
360
- * @memberof DefaultApigetNotification
361
- */
362
- appId: string
363
- /**
364
- *
365
- * @type string
366
- * @memberof DefaultApigetNotification
367
- */
368
- notificationId: string
369
- }
370
-
371
- export interface DefaultApiGetNotificationHistoryRequest {
372
- /**
373
- * The \"id\" of the message found in the Notification object
374
- * @type string
375
- * @memberof DefaultApigetNotificationHistory
376
- */
377
- notificationId: string
378
- /**
379
- *
380
- * @type GetNotificationHistoryRequestBody
381
- * @memberof DefaultApigetNotificationHistory
382
- */
383
- getNotificationHistoryRequestBody: GetNotificationHistoryRequestBody
384
- }
385
-
386
- export interface DefaultApiGetNotificationsRequest {
387
- /**
388
- * The app ID that you want to view notifications from
389
- * @type string
390
- * @memberof DefaultApigetNotifications
391
- */
392
- appId: string
393
- /**
394
- * How many notifications to return. Max is 50. Default is 50.
395
- * @type number
396
- * @memberof DefaultApigetNotifications
397
- */
398
- limit?: number
399
- /**
400
- * Page offset. Default is 0. Results are sorted by queued_at in descending order. queued_at is a representation of the time that the notification was queued at.
401
- * @type number
402
- * @memberof DefaultApigetNotifications
403
- */
404
- offset?: number
405
- /**
406
- * Kind of notifications returned: * unset - All notification types (default) * `0` - Dashboard only * `1` - API only * `3` - Automated only
407
- * @type 0 | 1 | 3
408
- * @memberof DefaultApigetNotifications
409
- */
410
- kind?: 0 | 1 | 3
411
- }
412
-
413
- export interface DefaultApiGetOutcomesRequest {
414
- /**
415
- * The OneSignal App ID for your app. Available in Keys & IDs.
416
- * @type string
417
- * @memberof DefaultApigetOutcomes
418
- */
419
- appId: string
420
- /**
421
- * Required Comma-separated list of names and the value (sum/count) for the returned outcome data. Note: Clicks only support count aggregation. For out-of-the-box OneSignal outcomes such as click and session duration, please use the \"os\" prefix with two underscores. For other outcomes, please use the name specified by the user. Example:os__session_duration.count,os__click.count,CustomOutcomeName.sum
422
- * @type string
423
- * @memberof DefaultApigetOutcomes
424
- */
425
- outcomeNames: string
426
- /**
427
- * Optional If outcome names contain any commas, then please specify only one value at a time. Example: outcome_names[]=os__click.count&outcome_names[]=Sales, Purchase.count where \"Sales, Purchase\" is the custom outcomes with a comma in the name.
428
- * @type string
429
- * @memberof DefaultApigetOutcomes
430
- */
431
- outcomeNames2?: string
432
- /**
433
- * Optional Time range for the returned data. The values can be 1h (for the last 1 hour data), 1d (for the last 1 day data), or 1mo (for the last 1 month data). Default is 1h if the parameter is omitted.
434
- * @type string
435
- * @memberof DefaultApigetOutcomes
436
- */
437
- outcomeTimeRange?: string
438
- /**
439
- * Optional Platform id. Refer device\'s platform ids for values. Example: outcome_platform=0 for iOS outcome_platform=7,8 for Safari and Firefox Default is data from all platforms if the parameter is omitted.
440
- * @type string
441
- * @memberof DefaultApigetOutcomes
442
- */
443
- outcomePlatforms?: string
444
- /**
445
- * Optional Attribution type for the outcomes. The values can be direct or influenced or unattributed. Example: outcome_attribution=direct Default is total (returns direct+influenced+unattributed) if the parameter is omitted.
446
- * @type string
447
- * @memberof DefaultApigetOutcomes
448
- */
449
- outcomeAttribution?: string
450
- }
451
-
452
- export interface DefaultApiGetSegmentsRequest {
453
- /**
454
- * The OneSignal App ID for your app. Available in Keys & IDs.
455
- * @type string
456
- * @memberof DefaultApigetSegments
457
- */
458
- appId: string
459
- /**
460
- * Segments are listed in ascending order of created_at date. offset will omit that number of segments from the beginning of the list. Eg offset 5, will remove the 5 earliest created Segments.
461
- * @type number
462
- * @memberof DefaultApigetSegments
463
- */
464
- offset?: number
465
- /**
466
- * The amount of Segments in the response. Maximum 300.
467
- * @type number
468
- * @memberof DefaultApigetSegments
469
- */
470
- limit?: number
471
- }
472
-
473
- export interface DefaultApiGetUserRequest {
474
- /**
475
- *
476
- * @type string
477
- * @memberof DefaultApigetUser
478
- */
479
- appId: string
480
- /**
481
- *
482
- * @type string
483
- * @memberof DefaultApigetUser
484
- */
485
- aliasLabel: string
486
- /**
487
- *
488
- * @type string
489
- * @memberof DefaultApigetUser
490
- */
491
- aliasId: string
492
- }
493
-
494
- export interface DefaultApiTransferSubscriptionRequest {
495
- /**
496
- *
497
- * @type string
498
- * @memberof DefaultApitransferSubscription
499
- */
500
- appId: string
501
- /**
502
- *
503
- * @type string
504
- * @memberof DefaultApitransferSubscription
505
- */
506
- subscriptionId: string
507
- /**
508
- *
509
- * @type TransferSubscriptionRequestBody
510
- * @memberof DefaultApitransferSubscription
511
- */
512
- transferSubscriptionRequestBody: TransferSubscriptionRequestBody
513
- }
514
-
515
- export interface DefaultApiUnsubscribeEmailWithTokenRequest {
516
- /**
517
- * The OneSignal App ID for your app. Available in Keys & IDs.
518
- * @type string
519
- * @memberof DefaultApiunsubscribeEmailWithToken
520
- */
521
- appId: string
522
- /**
523
- * The id of the message found in the creation notification POST response, View Notifications GET response, or URL within the Message Report.
524
- * @type string
525
- * @memberof DefaultApiunsubscribeEmailWithToken
526
- */
527
- notificationId: string
528
- /**
529
- * The unsubscribe token that is generated via liquid syntax in {{subscription.unsubscribe_token}} when personalizing an email.
530
- * @type string
531
- * @memberof DefaultApiunsubscribeEmailWithToken
532
- */
533
- token: string
534
- }
535
-
536
- export interface DefaultApiUpdateAppRequest {
537
- /**
538
- * An app id
539
- * @type string
540
- * @memberof DefaultApiupdateApp
541
- */
542
- appId: string
543
- /**
544
- *
545
- * @type App
546
- * @memberof DefaultApiupdateApp
547
- */
548
- app: App
549
- }
550
-
551
- export interface DefaultApiUpdateLiveActivityRequest {
552
- /**
553
- * The OneSignal App ID for your app. Available in Keys & IDs.
554
- * @type string
555
- * @memberof DefaultApiupdateLiveActivity
556
- */
557
- appId: string
558
- /**
559
- * Live Activity record ID
560
- * @type string
561
- * @memberof DefaultApiupdateLiveActivity
562
- */
563
- activityId: string
564
- /**
565
- *
566
- * @type UpdateLiveActivityRequest
567
- * @memberof DefaultApiupdateLiveActivity
568
- */
569
- updateLiveActivityRequest: UpdateLiveActivityRequest
570
- }
571
-
572
- export interface DefaultApiUpdateSubscriptionRequest {
573
- /**
574
- *
575
- * @type string
576
- * @memberof DefaultApiupdateSubscription
577
- */
578
- appId: string
579
- /**
580
- *
581
- * @type string
582
- * @memberof DefaultApiupdateSubscription
583
- */
584
- subscriptionId: string
585
- /**
586
- *
587
- * @type SubscriptionBody
588
- * @memberof DefaultApiupdateSubscription
589
- */
590
- subscriptionBody: SubscriptionBody
591
- }
592
-
593
- export interface DefaultApiUpdateUserRequest {
594
- /**
595
- *
596
- * @type string
597
- * @memberof DefaultApiupdateUser
598
- */
599
- appId: string
600
- /**
601
- *
602
- * @type string
603
- * @memberof DefaultApiupdateUser
604
- */
605
- aliasLabel: string
606
- /**
607
- *
608
- * @type string
609
- * @memberof DefaultApiupdateUser
610
- */
611
- aliasId: string
612
- /**
613
- *
614
- * @type UpdateUserRequest
615
- * @memberof DefaultApiupdateUser
616
- */
617
- updateUserRequest: UpdateUserRequest
618
- }
619
-
620
- export class ObjectDefaultApi {
621
- private api: ObservableDefaultApi
622
-
623
- public constructor(configuration: Configuration, requestFactory?: DefaultApiRequestFactory, responseProcessor?: DefaultApiResponseProcessor) {
624
- this.api = new ObservableDefaultApi(configuration, requestFactory, responseProcessor);
625
- }
626
-
627
- /**
628
- * Used to stop a scheduled or currently outgoing notification
629
- * Stop a scheduled or currently outgoing notification
630
- * @param param the request object
631
- */
632
- public cancelNotification(param: DefaultApiCancelNotificationRequest, options?: Configuration): Promise<GenericSuccessBoolResponse> {
633
- return this.api.cancelNotification(param.appId, param.notificationId, options).toPromise();
634
- }
635
-
636
- /**
637
- * Upserts one or more Aliases to an existing User identified by (:alias_label, :alias_id).
638
- * @param param the request object
639
- */
640
- public createAlias(param: DefaultApiCreateAliasRequest, options?: Configuration): Promise<UserIdentityBody> {
641
- return this.api.createAlias(param.appId, param.aliasLabel, param.aliasId, param.userIdentityBody, options).toPromise();
642
- }
643
-
644
- /**
645
- * Upserts one or more Aliases for the User identified by :subscription_id.
646
- * @param param the request object
647
- */
648
- public createAliasBySubscription(param: DefaultApiCreateAliasBySubscriptionRequest, options?: Configuration): Promise<UserIdentityBody> {
649
- return this.api.createAliasBySubscription(param.appId, param.subscriptionId, param.userIdentityBody, options).toPromise();
650
- }
651
-
652
- /**
653
- * Creates a new OneSignal app
654
- * Create an app
655
- * @param param the request object
656
- */
657
- public createApp(param: DefaultApiCreateAppRequest, options?: Configuration): Promise<App> {
658
- return this.api.createApp(param.app, options).toPromise();
659
- }
660
-
661
- /**
662
- * Sends notifications to your users
663
- * Create notification
664
- * @param param the request object
665
- */
666
- public createNotification(param: DefaultApiCreateNotificationRequest, options?: Configuration): Promise<CreateNotificationSuccessResponse> {
667
- return this.api.createNotification(param.notification, options).toPromise();
668
- }
669
-
670
- /**
671
- * Create a segment visible and usable in the dashboard and API - Required: OneSignal Paid Plan The Create Segment method is used when you want your server to programmatically create a segment instead of using the OneSignal Dashboard UI. Just like creating Segments from the dashboard you can pass in filters with multiple \"AND\" or \"OR\" operator\'s. &#x1F6A7; Does Not Update Segments This endpoint will only create segments, it does not edit or update currently created Segments. You will need to use the Delete Segment endpoint and re-create it with this endpoint to edit.
672
- * Create Segment
673
- * @param param the request object
674
- */
675
- public createSegment(param: DefaultApiCreateSegmentRequest, options?: Configuration): Promise<CreateSegmentSuccessResponse> {
676
- return this.api.createSegment(param.appId, param.segment, options).toPromise();
677
- }
678
-
679
- /**
680
- * Creates a new Subscription under the User provided. Useful to add email addresses and SMS numbers to the User.
681
- * @param param the request object
682
- */
683
- public createSubscription(param: DefaultApiCreateSubscriptionRequest, options?: Configuration): Promise<SubscriptionBody> {
684
- return this.api.createSubscription(param.appId, param.aliasLabel, param.aliasId, param.subscriptionBody, options).toPromise();
685
- }
686
-
687
- /**
688
- * Creates a User, optionally Subscriptions owned by the User as well as Aliases. Aliases provided in the payload will be used to look up an existing User.
689
- * @param param the request object
690
- */
691
- public createUser(param: DefaultApiCreateUserRequest, options?: Configuration): Promise<User> {
692
- return this.api.createUser(param.appId, param.user, options).toPromise();
693
- }
694
-
695
- /**
696
- * Deletes an alias by alias label
697
- * @param param the request object
698
- */
699
- public deleteAlias(param: DefaultApiDeleteAliasRequest, options?: Configuration): Promise<UserIdentityBody> {
700
- return this.api.deleteAlias(param.appId, param.aliasLabel, param.aliasId, param.aliasLabelToDelete, options).toPromise();
701
- }
702
-
703
- /**
704
- * Delete a segment (not user devices) - Required: OneSignal Paid Plan You can delete a segment under your app by calling this API. You must provide an API key in the Authorization header that has admin access on the app. The segment_id can be found in the URL of the segment when viewing it in the dashboard.
705
- * Delete Segment
706
- * @param param the request object
707
- */
708
- public deleteSegment(param: DefaultApiDeleteSegmentRequest, options?: Configuration): Promise<GenericSuccessBoolResponse> {
709
- return this.api.deleteSegment(param.appId, param.segmentId, options).toPromise();
710
- }
711
-
712
- /**
713
- * Deletes the Subscription.
714
- * @param param the request object
715
- */
716
- public deleteSubscription(param: DefaultApiDeleteSubscriptionRequest, options?: Configuration): Promise<void> {
717
- return this.api.deleteSubscription(param.appId, param.subscriptionId, options).toPromise();
718
- }
719
-
720
- /**
721
- * Removes the User identified by (:alias_label, :alias_id), and all Subscriptions and Aliases
722
- * @param param the request object
723
- */
724
- public deleteUser(param: DefaultApiDeleteUserRequest, options?: Configuration): Promise<void> {
725
- return this.api.deleteUser(param.appId, param.aliasLabel, param.aliasId, options).toPromise();
726
- }
727
-
728
- /**
729
- * Generate a compressed CSV report of all of the events data for a notification. This will return a URL immediately upon success but it may take several minutes for the CSV to become available at that URL depending on the volume of data. Only one export can be in-progress per OneSignal account at any given time.
730
- * Export CSV of Events
731
- * @param param the request object
732
- */
733
- public exportEvents(param: DefaultApiExportEventsRequest, options?: Configuration): Promise<ExportEventsSuccessResponse> {
734
- return this.api.exportEvents(param.notificationId, param.appId, options).toPromise();
735
- }
736
-
737
- /**
738
- * Generate a compressed CSV export of all of your current user data This method can be used to generate a compressed CSV export of all of your current user data. It is a much faster alternative than retrieving this data using the /players API endpoint. The file will be compressed using GZip. The file may take several minutes to generate depending on the number of users in your app. The URL generated will be available for 3 days and includes random v4 uuid as part of the resource name to be unguessable. &#x1F6A7; 403 Error Responses You can test if it is complete by making a GET request to the csv_file_url value. This file may take time to generate depending on how many device records are being pulled. If the file is not ready, a 403 error will be returned. Otherwise the file itself will be returned. &#x1F6A7; Requires Authentication Key Requires your OneSignal App\'s REST API Key, available in Keys & IDs. &#x1F6A7; Concurrent Exports Only one concurrent export is allowed per OneSignal account. Please ensure you have successfully downloaded the .csv.gz file before exporting another app. CSV File Format: - Default Columns: | Field | Details | | --- | --- | | id | OneSignal Player Id | | identifier | Push Token | | session_count | Number of times they visited the app or site | language | Device language code | | timezone | Number of seconds away from UTC. Example: -28800 | | game_version | Version of your mobile app gathered from Android Studio versionCode in your App/build.gradle and iOS uses kCFBundleVersionKey in Xcode. | | device_os | Device Operating System Version. Example: 80 = Chrome 80, 9 = Android 9 | | device_type | Device Operating System Type | | device_model | Device Hardware String Code. Example: Mobile Web Subscribers will have `Linux armv` | | ad_id | Based on the Google Advertising Id for Android, identifierForVendor for iOS. OptedOut means user turned off Advertising tracking on the device. | | tags | Current OneSignal Data Tags on the device. | | last_active | Date and time the user last opened the mobile app or visited the site. | | playtime | Total amount of time in seconds the user had the mobile app open. | | amount_spent | Mobile only - amount spent in USD on In-App Purchases. | | created_at | Date and time the device record was created in OneSignal. Mobile - first time they opened the app with OneSignal SDK. Web - first time the user subscribed to the site. | | invalid_identifier | t = unsubscribed, f = subscibed | | badge_count | Current number of badges on the device | - Extra Columns: | Field | Details | | --- | --- | | external_user_id | Your User Id set on the device | | notification_types | Notification types | | location | Location points (Latitude and Longitude) set on the device. | | country | Country code | | rooted | Android device rooted or not | | ip | IP Address of the device if being tracked. See Handling Personal Data. | | web_auth | Web Only authorization key. | | web_p256 | Web Only p256 key. |
739
- * Export CSV of Subscriptions
740
- * @param param the request object
741
- */
742
- public exportSubscriptions(param: DefaultApiExportSubscriptionsRequest, options?: Configuration): Promise<ExportSubscriptionsSuccessResponse> {
743
- return this.api.exportSubscriptions(param.appId, param.exportSubscriptionsRequestBody, options).toPromise();
744
- }
745
-
746
- /**
747
- * Lists all Aliases for the User identified by (:alias_label, :alias_id).
748
- * @param param the request object
749
- */
750
- public getAliases(param: DefaultApiGetAliasesRequest, options?: Configuration): Promise<UserIdentityBody> {
751
- return this.api.getAliases(param.appId, param.aliasLabel, param.aliasId, options).toPromise();
752
- }
753
-
754
- /**
755
- * Lists all Aliases for the User identified by :subscription_id.
756
- * @param param the request object
757
- */
758
- public getAliasesBySubscription(param: DefaultApiGetAliasesBySubscriptionRequest, options?: Configuration): Promise<UserIdentityBody> {
759
- return this.api.getAliasesBySubscription(param.appId, param.subscriptionId, options).toPromise();
760
- }
761
-
762
- /**
763
- * View the details of a single OneSignal app
764
- * View an app
765
- * @param param the request object
766
- */
767
- public getApp(param: DefaultApiGetAppRequest, options?: Configuration): Promise<App> {
768
- return this.api.getApp(param.appId, options).toPromise();
769
- }
770
-
771
- /**
772
- * View the details of all of your current OneSignal apps
773
- * View apps
774
- * @param param the request object
775
- */
776
- public getApps(param: DefaultApiGetAppsRequest = {}, options?: Configuration): Promise<Array<App>> {
777
- return this.api.getApps( options).toPromise();
778
- }
779
-
780
- /**
781
- * View the details of a single notification and outcomes associated with it
782
- * View notification
783
- * @param param the request object
784
- */
785
- public getNotification(param: DefaultApiGetNotificationRequest, options?: Configuration): Promise<NotificationWithMeta> {
786
- return this.api.getNotification(param.appId, param.notificationId, options).toPromise();
787
- }
788
-
789
- /**
790
- * -> View the devices sent a message - OneSignal Paid Plan Required This method will return all devices that were sent the given notification_id of an Email or Push Notification if used within 7 days of the date sent. After 7 days of the sending date, the message history data will be unavailable. After a successful response is received, the destination url may be polled until the file becomes available. Most exports are done in ~1-3 minutes, so setting a poll interval of 10 seconds should be adequate. For use cases that are not meant to be consumed by a script, an email will be sent to the supplied email address. &#x1F6A7; Requirements A OneSignal Paid Plan. Turn on Send History via OneSignal API in Settings -> Analytics. Cannot get data before this was turned on. Must be called within 7 days after sending the message. Messages targeting under 1000 recipients will not have \"sent\" events recorded, but will show \"clicked\" events. Requires your OneSignal App\'s REST API Key, available in Keys & IDs.
791
- * Notification History
792
- * @param param the request object
793
- */
794
- public getNotificationHistory(param: DefaultApiGetNotificationHistoryRequest, options?: Configuration): Promise<NotificationHistorySuccessResponse> {
795
- return this.api.getNotificationHistory(param.notificationId, param.getNotificationHistoryRequestBody, options).toPromise();
796
- }
797
-
798
- /**
799
- * View the details of multiple notifications
800
- * View notifications
801
- * @param param the request object
802
- */
803
- public getNotifications(param: DefaultApiGetNotificationsRequest, options?: Configuration): Promise<NotificationSlice> {
804
- return this.api.getNotifications(param.appId, param.limit, param.offset, param.kind, options).toPromise();
805
- }
806
-
807
- /**
808
- * View the details of all the outcomes associated with your app &#x1F6A7; Requires Authentication Key Requires your OneSignal App\'s REST API Key, available in Keys & IDs. &#x1F6A7; Outcome Data Limitations Outcomes are only accessible for around 30 days before deleted from our servers. You will need to export this data every month if you want to keep it.
809
- * View Outcomes
810
- * @param param the request object
811
- */
812
- public getOutcomes(param: DefaultApiGetOutcomesRequest, options?: Configuration): Promise<OutcomesData> {
813
- return this.api.getOutcomes(param.appId, param.outcomeNames, param.outcomeNames2, param.outcomeTimeRange, param.outcomePlatforms, param.outcomeAttribution, options).toPromise();
814
- }
815
-
816
- /**
817
- * Returns an array of segments from an app.
818
- * Get Segments
819
- * @param param the request object
820
- */
821
- public getSegments(param: DefaultApiGetSegmentsRequest, options?: Configuration): Promise<GetSegmentsSuccessResponse> {
822
- return this.api.getSegments(param.appId, param.offset, param.limit, options).toPromise();
823
- }
824
-
825
- /**
826
- * Returns the User’s properties, Aliases, and Subscriptions.
827
- * @param param the request object
828
- */
829
- public getUser(param: DefaultApiGetUserRequest, options?: Configuration): Promise<User> {
830
- return this.api.getUser(param.appId, param.aliasLabel, param.aliasId, options).toPromise();
831
- }
832
-
833
- /**
834
- * Transfers this Subscription to the User identified by the identity in the payload.
835
- * @param param the request object
836
- */
837
- public transferSubscription(param: DefaultApiTransferSubscriptionRequest, options?: Configuration): Promise<UserIdentityBody> {
838
- return this.api.transferSubscription(param.appId, param.subscriptionId, param.transferSubscriptionRequestBody, options).toPromise();
839
- }
840
-
841
- /**
842
- * Unsubscribe an email with a token when using your own custom email unsubscribe landing page
843
- * Unsubscribe with token
844
- * @param param the request object
845
- */
846
- public unsubscribeEmailWithToken(param: DefaultApiUnsubscribeEmailWithTokenRequest, options?: Configuration): Promise<GenericSuccessBoolResponse> {
847
- return this.api.unsubscribeEmailWithToken(param.appId, param.notificationId, param.token, options).toPromise();
848
- }
849
-
850
- /**
851
- * Updates the name or configuration settings of an existing OneSignal app
852
- * Update an app
853
- * @param param the request object
854
- */
855
- public updateApp(param: DefaultApiUpdateAppRequest, options?: Configuration): Promise<App> {
856
- return this.api.updateApp(param.appId, param.app, options).toPromise();
857
- }
858
-
859
- /**
860
- * Updates a specified live activity.
861
- * Update a Live Activity via Push
862
- * @param param the request object
863
- */
864
- public updateLiveActivity(param: DefaultApiUpdateLiveActivityRequest, options?: Configuration): Promise<UpdateLiveActivitySuccessResponse> {
865
- return this.api.updateLiveActivity(param.appId, param.activityId, param.updateLiveActivityRequest, options).toPromise();
866
- }
867
-
868
- /**
869
- * Updates an existing Subscription’s properties.
870
- * @param param the request object
871
- */
872
- public updateSubscription(param: DefaultApiUpdateSubscriptionRequest, options?: Configuration): Promise<void> {
873
- return this.api.updateSubscription(param.appId, param.subscriptionId, param.subscriptionBody, options).toPromise();
874
- }
875
-
876
- /**
877
- * Updates an existing User’s properties.
878
- * @param param the request object
879
- */
880
- public updateUser(param: DefaultApiUpdateUserRequest, options?: Configuration): Promise<PropertiesBody> {
881
- return this.api.updateUser(param.appId, param.aliasLabel, param.aliasId, param.updateUserRequest, options).toPromise();
882
- }
883
-
884
- }