@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
package/http/http.ts DELETED
@@ -1,205 +0,0 @@
1
- // TODO: evaluate if we can easily get rid of this library
2
- import * as FormData from "form-data";
3
- import { Observable, from } from '../rxjsStub';
4
-
5
- export * from './isomorphic-fetch';
6
-
7
- /**
8
- * Represents an HTTP method.
9
- */
10
- export enum HttpMethod {
11
- GET = "GET",
12
- HEAD = "HEAD",
13
- POST = "POST",
14
- PUT = "PUT",
15
- DELETE = "DELETE",
16
- CONNECT = "CONNECT",
17
- OPTIONS = "OPTIONS",
18
- TRACE = "TRACE",
19
- PATCH = "PATCH"
20
- }
21
-
22
- /**
23
- * Represents an HTTP file which will be transferred from or to a server.
24
- */
25
- export type HttpFile = {
26
- data: Buffer,
27
- name: string
28
- };
29
-
30
-
31
- export class HttpException extends Error {
32
- public constructor(msg: string) {
33
- super(msg);
34
- }
35
- }
36
-
37
- /**
38
- * Represents the body of an outgoing HTTP request.
39
- */
40
- export type RequestBody = undefined | string | FormData;
41
-
42
- /**
43
- * Represents an HTTP request context
44
- */
45
- export class RequestContext {
46
- private headers: { [key: string]: string } = {};
47
- private body: RequestBody = undefined;
48
- private url: URL;
49
-
50
- /**
51
- * Creates the request context using a http method and request resource url
52
- *
53
- * @param url url of the requested resource
54
- * @param httpMethod http method
55
- */
56
- public constructor(url: string, private httpMethod: HttpMethod) {
57
- this.url = new URL(url);
58
- }
59
-
60
- /*
61
- * Returns the url set in the constructor including the query string
62
- *
63
- */
64
- public getUrl(): string {
65
- return this.url.toString();
66
- }
67
-
68
- /**
69
- * Replaces the url set in the constructor with this url.
70
- *
71
- */
72
- public setUrl(url: string) {
73
- this.url = new URL(url);
74
- }
75
-
76
- /**
77
- * Sets the body of the http request either as a string or FormData
78
- *
79
- * Note that setting a body on a HTTP GET, HEAD, DELETE, CONNECT or TRACE
80
- * request is discouraged.
81
- * https://httpwg.org/http-core/draft-ietf-httpbis-semantics-latest.html#rfc.section.7.3.1
82
- *
83
- * @param body the body of the request
84
- */
85
- public setBody(body: RequestBody) {
86
- this.body = body;
87
- }
88
-
89
- public getHttpMethod(): HttpMethod {
90
- return this.httpMethod;
91
- }
92
-
93
- public getHeaders(): { [key: string]: string } {
94
- return this.headers;
95
- }
96
-
97
- public getBody(): RequestBody {
98
- return this.body;
99
- }
100
-
101
- public setQueryParam(name: string, value: string) {
102
- this.url.searchParams.set(name, value);
103
- }
104
-
105
- /**
106
- * Sets a cookie with the name and value. NO check for duplicate cookies is performed
107
- *
108
- */
109
- public addCookie(name: string, value: string): void {
110
- if (!this.headers["Cookie"]) {
111
- this.headers["Cookie"] = "";
112
- }
113
- this.headers["Cookie"] += name + "=" + value + "; ";
114
- }
115
-
116
- public setHeaderParam(key: string, value: string): void {
117
- this.headers[key] = value;
118
- }
119
- }
120
-
121
- export interface ResponseBody {
122
- text(): Promise<string>;
123
- binary(): Promise<Buffer>;
124
- }
125
-
126
-
127
- /**
128
- * Helper class to generate a `ResponseBody` from binary data
129
- */
130
- export class SelfDecodingBody implements ResponseBody {
131
- constructor(private dataSource: Promise<Buffer>) {}
132
-
133
- binary(): Promise<Buffer> {
134
- return this.dataSource;
135
- }
136
-
137
- async text(): Promise<string> {
138
- const data: Buffer = await this.dataSource;
139
- return data.toString();
140
- }
141
- }
142
-
143
- export class ResponseContext {
144
- public constructor(
145
- public httpStatusCode: number,
146
- public headers: { [key: string]: string },
147
- public body: ResponseBody
148
- ) {}
149
-
150
- /**
151
- * Parse header value in the form `value; param1="value1"`
152
- *
153
- * E.g. for Content-Type or Content-Disposition
154
- * Parameter names are converted to lower case
155
- * The first parameter is returned with the key `""`
156
- */
157
- public getParsedHeader(headerName: string): { [parameter: string]: string } {
158
- const result: { [parameter: string]: string } = {};
159
- if (!this.headers[headerName]) {
160
- return result;
161
- }
162
-
163
- const parameters = this.headers[headerName].split(";");
164
- for (const parameter of parameters) {
165
- let [key, value] = parameter.split("=", 2);
166
- key = key.toLowerCase().trim();
167
- if (value === undefined) {
168
- result[""] = key;
169
- } else {
170
- value = value.trim();
171
- if (value.startsWith('"') && value.endsWith('"')) {
172
- value = value.substring(1, value.length - 1);
173
- }
174
- result[key] = value;
175
- }
176
- }
177
- return result;
178
- }
179
-
180
- public async getBodyAsFile(): Promise<HttpFile> {
181
- const data = await this.body.binary();
182
- const fileName = this.getParsedHeader("content-disposition")["filename"] || "";
183
- return { data, name: fileName };
184
- }
185
-
186
- public async getBodyAsAny(): Promise<any> {
187
- return this.body as any;
188
- }
189
- }
190
-
191
- export interface HttpLibrary {
192
- send(request: RequestContext): Observable<ResponseContext>;
193
- }
194
-
195
- export interface PromiseHttpLibrary {
196
- send(request: RequestContext): Promise<ResponseContext>;
197
- }
198
-
199
- export function wrapHttpLibrary(promiseHttpLibrary: PromiseHttpLibrary): HttpLibrary {
200
- return {
201
- send(request: RequestContext): Observable<ResponseContext> {
202
- return from(promiseHttpLibrary.send(request));
203
- }
204
- }
205
- }
@@ -1,30 +0,0 @@
1
- import {HttpLibrary, RequestContext, ResponseContext} from './http';
2
- import { from, Observable } from '../rxjsStub';
3
-
4
- export class IsomorphicFetchHttpLibrary implements HttpLibrary {
5
-
6
- public send(request: RequestContext): Observable<ResponseContext> {
7
- let method = request.getHttpMethod().toString();
8
- let body = request.getBody();
9
-
10
- const resultPromise = fetch(request.getUrl(), {
11
- method: method,
12
- body: body as any,
13
- headers: request.getHeaders(),
14
- }).then((resp: any) => {
15
- const headers: { [name: string]: string } = {};
16
- resp.headers.forEach((value: string, name: string) => {
17
- headers[name] = value;
18
- });
19
-
20
- const body = {
21
- text: () => resp.text(),
22
- binary: () => resp.buffer()
23
- };
24
- return new ResponseContext(resp.status, headers, body);
25
- });
26
-
27
- return from<Promise<ResponseContext>>(resultPromise);
28
-
29
- }
30
- }
package/index.ts DELETED
@@ -1,12 +0,0 @@
1
- export * from "./http/http";
2
- export * from "./auth/auth";
3
- export * from "./models/all";
4
- export { createConfiguration } from "./configuration"
5
- export { Configuration } from "./configuration"
6
- export * from "./apis/exception";
7
- export * from "./servers";
8
- export { RequiredError } from "./apis/baseapi";
9
-
10
- export { PromiseMiddleware as Middleware } from './middleware';
11
- export { PromiseDefaultApi as DefaultApi } from './types/PromiseAPI';
12
-
package/middleware.ts DELETED
@@ -1,66 +0,0 @@
1
- import {RequestContext, ResponseContext} from './http/http';
2
- import { Observable, from } from './rxjsStub';
3
-
4
- /**
5
- * Defines the contract for a middleware intercepting requests before
6
- * they are sent (but after the RequestContext was created)
7
- * and before the ResponseContext is unwrapped.
8
- *
9
- */
10
- export interface Middleware {
11
- /**
12
- * Modifies the request before the request is sent.
13
- *
14
- * @param context RequestContext of a request which is about to be sent to the server
15
- * @returns an observable of the updated request context
16
- *
17
- */
18
- pre(context: RequestContext): Observable<RequestContext>;
19
- /**
20
- * Modifies the returned response before it is deserialized.
21
- *
22
- * @param context ResponseContext of a sent request
23
- * @returns an observable of the modified response context
24
- */
25
- post(context: ResponseContext): Observable<ResponseContext>;
26
- }
27
-
28
- export class PromiseMiddlewareWrapper implements Middleware {
29
-
30
- public constructor(private middleware: PromiseMiddleware) {
31
-
32
- }
33
-
34
- pre(context: RequestContext): Observable<RequestContext> {
35
- return from(this.middleware.pre(context));
36
- }
37
-
38
- post(context: ResponseContext): Observable<ResponseContext> {
39
- return from(this.middleware.post(context));
40
- }
41
-
42
- }
43
-
44
- /**
45
- * Defines the contract for a middleware intercepting requests before
46
- * they are sent (but after the RequestContext was created)
47
- * and before the ResponseContext is unwrapped.
48
- *
49
- */
50
- export interface PromiseMiddleware {
51
- /**
52
- * Modifies the request before the request is sent.
53
- *
54
- * @param context RequestContext of a request which is about to be sent to the server
55
- * @returns an observable of the updated request context
56
- *
57
- */
58
- pre(context: RequestContext): Promise<RequestContext>;
59
- /**
60
- * Modifies the returned response before it is deserialized.
61
- *
62
- * @param context ResponseContext of a sent request
63
- * @returns an observable of the modified response context
64
- */
65
- post(context: ResponseContext): Promise<ResponseContext>;
66
- }
package/models/App.ts DELETED
@@ -1,328 +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.2.0
6
- * Contact: devrel@onesignal.com
7
- */
8
-
9
- import { HttpFile } from '../http/http';
10
-
11
- export class App {
12
- 'id'?: string;
13
- /**
14
- * The name of your app, as displayed on your apps list on the dashboard. This can be renamed.
15
- */
16
- 'name'?: string;
17
- 'players'?: number;
18
- 'messageable_players'?: number;
19
- 'updated_at'?: string;
20
- 'created_at'?: string;
21
- /**
22
- * Android: Your Google Project number. Also known as Sender ID.
23
- */
24
- 'android_gcm_sender_id'?: string;
25
- /**
26
- * Android: Your Google Push Messaging Auth Key
27
- */
28
- 'gcm_key'?: string;
29
- /**
30
- * Chrome (All Browsers except Safari) (Recommended): The URL to your website. This field is required if you wish to enable web push and specify other web push parameters.
31
- */
32
- 'chrome_web_origin'?: string;
33
- /**
34
- * Not for web push. Your Google Push Messaging Auth Key if you use Chrome Apps / Extensions.
35
- */
36
- 'chrome_key'?: string;
37
- /**
38
- * Chrome (All Browsers except Safari): Your default notification icon. Should be 256x256 pixels, min 80x80.
39
- */
40
- 'chrome_web_default_notification_icon'?: string;
41
- /**
42
- * Chrome (All Browsers except Safari): A subdomain of your choice in order to support Web Push on non-HTTPS websites. This field must be set in order for the chrome_web_gcm_sender_id property to be processed.
43
- */
44
- 'chrome_web_sub_domain'?: string;
45
- /**
46
- * iOS: Either sandbox or production
47
- */
48
- 'apns_env'?: AppApnsEnvEnum;
49
- /**
50
- * iOS: Your apple push notification p12 certificate file, converted to a string and Base64 encoded.
51
- */
52
- 'apns_p12'?: string;
53
- /**
54
- * iOS: Required if using p12 certificate. Password for the apns_p12 file.
55
- */
56
- 'apns_p12_password'?: string;
57
- 'apns_certificates'?: string;
58
- 'safari_apns_certificates'?: string;
59
- /**
60
- * Safari: Your apple push notification p12 certificate file for Safari Push Notifications, converted to a string and Base64 encoded.
61
- */
62
- 'safari_apns_p12'?: string;
63
- /**
64
- * Safari: Password for safari_apns_p12 file
65
- */
66
- 'safari_apns_p12_password'?: string;
67
- /**
68
- * iOS: Required if using p8. Unique identifier for the p8 authentication key.
69
- */
70
- 'apns_key_id'?: string;
71
- /**
72
- * iOS: Required if using p8. Team ID generated by Apple for your developer account.
73
- */
74
- 'apns_team_id'?: string;
75
- /**
76
- * iOS: Required if using p8. Bundle ID for your app in the Apple ecosystem.
77
- */
78
- 'apns_bundle_id'?: string;
79
- /**
80
- * iOS: Required if using p8. Base64 encoded p8 key
81
- */
82
- 'apns_p8'?: string;
83
- /**
84
- * Safari (Recommended): The hostname to your website including http(s)://
85
- */
86
- 'safari_site_origin'?: string;
87
- 'safari_push_id'?: string;
88
- 'safari_icon_16_16'?: string;
89
- 'safari_icon_32_32'?: string;
90
- 'safari_icon_64_64'?: string;
91
- 'safari_icon_128_128'?: string;
92
- /**
93
- * Safari: A url for a 256x256 png notification icon. This is the only Safari icon URL you need to provide.
94
- */
95
- 'safari_icon_256_256'?: string;
96
- /**
97
- * All Browsers (Recommended): The Site Name. Requires both chrome_web_origin and safari_site_origin to be set to add or update it.
98
- */
99
- 'site_name'?: string;
100
- 'basic_auth_key'?: string;
101
- /**
102
- * The Id of the Organization you would like to add this app to.
103
- */
104
- 'organization_id'?: string;
105
- /**
106
- * iOS: Notification data (additional data) values will be added to the root of the apns payload when sent to the device. Ignore if you\'re not using any other plugins, or not using OneSignal SDK methods to read the payload.
107
- */
108
- 'additional_data_is_root_payload'?: boolean;
109
-
110
- static readonly discriminator: string | undefined = undefined;
111
-
112
- static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
113
- {
114
- "name": "id",
115
- "baseName": "id",
116
- "type": "string",
117
- "format": ""
118
- },
119
- {
120
- "name": "name",
121
- "baseName": "name",
122
- "type": "string",
123
- "format": ""
124
- },
125
- {
126
- "name": "players",
127
- "baseName": "players",
128
- "type": "number",
129
- "format": ""
130
- },
131
- {
132
- "name": "messageable_players",
133
- "baseName": "messageable_players",
134
- "type": "number",
135
- "format": ""
136
- },
137
- {
138
- "name": "updated_at",
139
- "baseName": "updated_at",
140
- "type": "string",
141
- "format": "date-time"
142
- },
143
- {
144
- "name": "created_at",
145
- "baseName": "created_at",
146
- "type": "string",
147
- "format": "date-time"
148
- },
149
- {
150
- "name": "android_gcm_sender_id",
151
- "baseName": "android_gcm_sender_id",
152
- "type": "string",
153
- "format": ""
154
- },
155
- {
156
- "name": "gcm_key",
157
- "baseName": "gcm_key",
158
- "type": "string",
159
- "format": ""
160
- },
161
- {
162
- "name": "chrome_web_origin",
163
- "baseName": "chrome_web_origin",
164
- "type": "string",
165
- "format": ""
166
- },
167
- {
168
- "name": "chrome_key",
169
- "baseName": "chrome_key",
170
- "type": "string",
171
- "format": ""
172
- },
173
- {
174
- "name": "chrome_web_default_notification_icon",
175
- "baseName": "chrome_web_default_notification_icon",
176
- "type": "string",
177
- "format": ""
178
- },
179
- {
180
- "name": "chrome_web_sub_domain",
181
- "baseName": "chrome_web_sub_domain",
182
- "type": "string",
183
- "format": ""
184
- },
185
- {
186
- "name": "apns_env",
187
- "baseName": "apns_env",
188
- "type": "AppApnsEnvEnum",
189
- "format": ""
190
- },
191
- {
192
- "name": "apns_p12",
193
- "baseName": "apns_p12",
194
- "type": "string",
195
- "format": ""
196
- },
197
- {
198
- "name": "apns_p12_password",
199
- "baseName": "apns_p12_password",
200
- "type": "string",
201
- "format": ""
202
- },
203
- {
204
- "name": "apns_certificates",
205
- "baseName": "apns_certificates",
206
- "type": "string",
207
- "format": ""
208
- },
209
- {
210
- "name": "safari_apns_certificates",
211
- "baseName": "safari_apns_certificates",
212
- "type": "string",
213
- "format": ""
214
- },
215
- {
216
- "name": "safari_apns_p12",
217
- "baseName": "safari_apns_p12",
218
- "type": "string",
219
- "format": ""
220
- },
221
- {
222
- "name": "safari_apns_p12_password",
223
- "baseName": "safari_apns_p12_password",
224
- "type": "string",
225
- "format": ""
226
- },
227
- {
228
- "name": "apns_key_id",
229
- "baseName": "apns_key_id",
230
- "type": "string",
231
- "format": ""
232
- },
233
- {
234
- "name": "apns_team_id",
235
- "baseName": "apns_team_id",
236
- "type": "string",
237
- "format": ""
238
- },
239
- {
240
- "name": "apns_bundle_id",
241
- "baseName": "apns_bundle_id",
242
- "type": "string",
243
- "format": ""
244
- },
245
- {
246
- "name": "apns_p8",
247
- "baseName": "apns_p8",
248
- "type": "string",
249
- "format": ""
250
- },
251
- {
252
- "name": "safari_site_origin",
253
- "baseName": "safari_site_origin",
254
- "type": "string",
255
- "format": ""
256
- },
257
- {
258
- "name": "safari_push_id",
259
- "baseName": "safari_push_id",
260
- "type": "string",
261
- "format": ""
262
- },
263
- {
264
- "name": "safari_icon_16_16",
265
- "baseName": "safari_icon_16_16",
266
- "type": "string",
267
- "format": ""
268
- },
269
- {
270
- "name": "safari_icon_32_32",
271
- "baseName": "safari_icon_32_32",
272
- "type": "string",
273
- "format": ""
274
- },
275
- {
276
- "name": "safari_icon_64_64",
277
- "baseName": "safari_icon_64_64",
278
- "type": "string",
279
- "format": ""
280
- },
281
- {
282
- "name": "safari_icon_128_128",
283
- "baseName": "safari_icon_128_128",
284
- "type": "string",
285
- "format": ""
286
- },
287
- {
288
- "name": "safari_icon_256_256",
289
- "baseName": "safari_icon_256_256",
290
- "type": "string",
291
- "format": ""
292
- },
293
- {
294
- "name": "site_name",
295
- "baseName": "site_name",
296
- "type": "string",
297
- "format": ""
298
- },
299
- {
300
- "name": "basic_auth_key",
301
- "baseName": "basic_auth_key",
302
- "type": "string",
303
- "format": ""
304
- },
305
- {
306
- "name": "organization_id",
307
- "baseName": "organization_id",
308
- "type": "string",
309
- "format": ""
310
- },
311
- {
312
- "name": "additional_data_is_root_payload",
313
- "baseName": "additional_data_is_root_payload",
314
- "type": "boolean",
315
- "format": ""
316
- } ];
317
-
318
- static getAttributeTypeMap() {
319
- return App.attributeTypeMap;
320
- }
321
-
322
- public constructor() {
323
- }
324
- }
325
-
326
-
327
- export type AppApnsEnvEnum = "sandbox" | "production" ;
328
-