@onesignal/node-onesignal 1.0.0-beta3 → 1.0.0-beta5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/ISSUE_TEMPLATE/ask-question.yml +25 -0
- package/.github/ISSUE_TEMPLATE/bug-report.yml +51 -0
- package/.github/ISSUE_TEMPLATE/general-feedback.yml +25 -0
- package/.github/pull_request_template.md +44 -0
- package/.github/workflows/npm_deploy.yml +21 -0
- package/CHANGELOG.md +26 -0
- package/DefaultApi.md +1232 -0
- package/LICENSE +24 -0
- package/README.md +205 -102
- package/RELEASE_INSTRUCTIONS.md +2 -0
- package/apis/DefaultApi.ts +519 -532
- package/apis/baseapi.ts +4 -4
- package/apis/exception.ts +4 -3
- package/auth/auth.ts +4 -1
- package/configuration.ts +21 -2
- package/http/http.ts +26 -26
- package/index.ts +1 -0
- package/middleware.ts +1 -1
- package/models/App.ts +8 -8
- package/models/BasicNotification.ts +1019 -0
- package/models/BasicNotificationAllOf.ts +897 -0
- package/models/{NotificationAllOfAndroidBackgroundLayout.ts → BasicNotificationAllOfAndroidBackgroundLayout.ts} +4 -4
- package/models/Button.ts +2 -2
- package/models/CancelNotificationSuccessResponse.ts +31 -0
- package/models/{InlineResponse400.ts → CreateNotificationBadRequestResponse.ts} +4 -4
- package/models/{InlineResponse200.ts → CreateNotificationSuccessResponse.ts} +7 -6
- package/models/{InlineResponse2004.ts → CreatePlayerSuccessResponse.ts} +4 -4
- package/models/CreateSegmentBadRequestResponse.ts +38 -0
- package/models/{InlineResponse409.ts → CreateSegmentConflictResponse.ts} +4 -4
- package/models/{InlineResponse201.ts → CreateSegmentSuccessResponse.ts} +4 -4
- package/models/DeletePlayerBadRequestResponse.ts +31 -0
- package/models/DeletePlayerNotFoundResponse.ts +31 -0
- package/models/{InlineResponse2003.ts → DeletePlayerSuccessResponse.ts} +4 -4
- package/models/{InlineResponse4002.ts → DeleteSegmentBadRequestResponse.ts} +4 -4
- package/models/DeleteSegmentNotFoundResponse.ts +31 -0
- package/models/DeleteSegmentSuccessResponse.ts +31 -0
- package/models/DeliveryData.ts +17 -2
- package/models/ExportPlayersRequestBody.ts +5 -5
- package/models/{InlineResponse2005.ts → ExportPlayersSuccessResponse.ts} +4 -4
- package/models/Filter.ts +4 -4
- package/models/FilterExpressions.ts +4 -4
- package/models/FilterNotificationTarget.ts +2 -2
- package/models/GetNotificationRequestBody.ts +2 -2
- package/models/InvalidIdentifierError.ts +44 -0
- package/models/Notification.ts +72 -174
- package/models/Notification200Errors.ts +45 -0
- package/models/NotificationAllOf.ts +3 -858
- package/models/{InlineResponse4001.ts → NotificationHistoryBadRequestResponse.ts} +4 -4
- package/models/{InlineResponse2002.ts → NotificationHistorySuccessResponse.ts} +6 -6
- package/models/NotificationSlice.ts +5 -5
- package/models/NotificationTarget.ts +3 -124
- package/models/NotificationWithMeta.ts +1127 -0
- package/models/NotificationWithMetaAllOf.ts +132 -0
- package/models/ObjectSerializer.ts +97 -46
- package/models/Operator.ts +2 -2
- package/models/OutcomeData.ts +2 -2
- package/models/OutcomesData.ts +32 -0
- package/models/PlatformDeliveryData.ts +18 -2
- package/models/PlatformDeliveryDataEmailAllOf.ts +94 -0
- package/models/PlatformDeliveryDataSmsAllOf.ts +54 -0
- package/models/Player.ts +14 -14
- package/models/PlayerNotificationTarget.ts +3 -3
- package/models/PlayerSlice.ts +2 -2
- package/models/Purchase.ts +2 -2
- package/models/Segment.ts +3 -3
- package/models/SegmentNotificationTarget.ts +2 -2
- package/models/StringMap.ts +3 -3
- package/models/{InlineResponse2001.ts → UpdatePlayerSuccessResponse.ts} +6 -6
- package/models/UpdatePlayerTagsRequestBody.ts +4 -4
- package/models/UpdatePlayerTagsSuccessResponse.ts +31 -0
- package/models/all.ts +28 -13
- package/package.json +14 -9
- package/tsconfig.json +1 -2
- package/types/ObjectParamAPI.ts +101 -86
- package/types/ObservableAPI.ts +116 -101
- package/types/PromiseAPI.ts +97 -82
- package/util.ts +10 -1
- package/git_push.sh +0 -52
|
@@ -0,0 +1,132 @@
|
|
|
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: 1.0.1
|
|
6
|
+
* Contact: devrel@onesignal.com
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { PlatformDeliveryData } from './PlatformDeliveryData';
|
|
10
|
+
import { HttpFile } from '../http/http';
|
|
11
|
+
|
|
12
|
+
export class NotificationWithMetaAllOf {
|
|
13
|
+
/**
|
|
14
|
+
* Number of notifications that have not been sent out yet. This can mean either our system is still processing the notification or you have delayed options set.
|
|
15
|
+
*/
|
|
16
|
+
'remaining'?: number;
|
|
17
|
+
/**
|
|
18
|
+
* Number of notifications that were successfully delivered.
|
|
19
|
+
*/
|
|
20
|
+
'successful'?: number;
|
|
21
|
+
/**
|
|
22
|
+
* Number of notifications that could not be delivered due to those devices being unsubscribed.
|
|
23
|
+
*/
|
|
24
|
+
'failed'?: number;
|
|
25
|
+
/**
|
|
26
|
+
* Number of notifications that could not be delivered due to an error. You can find more information by viewing the notification in the dashboard.
|
|
27
|
+
*/
|
|
28
|
+
'errored'?: number;
|
|
29
|
+
/**
|
|
30
|
+
* Number of users who have clicked / tapped on your notification.
|
|
31
|
+
*/
|
|
32
|
+
'converted'?: number;
|
|
33
|
+
/**
|
|
34
|
+
* Unix timestamp indicating when the notification was created.
|
|
35
|
+
*/
|
|
36
|
+
'queued_at'?: number;
|
|
37
|
+
/**
|
|
38
|
+
* Unix timestamp indicating when notification delivery should begin.
|
|
39
|
+
*/
|
|
40
|
+
'send_after'?: number;
|
|
41
|
+
/**
|
|
42
|
+
* Unix timestamp indicating when notification delivery completed. The delivery duration from start to finish can be calculated with completed_at - send_after.
|
|
43
|
+
*/
|
|
44
|
+
'completed_at'?: number;
|
|
45
|
+
'platform_delivery_stats'?: PlatformDeliveryData;
|
|
46
|
+
/**
|
|
47
|
+
* Confirmed Deliveries number of devices that received the push notification. Paid Feature Only. Free accounts will see 0.
|
|
48
|
+
*/
|
|
49
|
+
'received'?: number;
|
|
50
|
+
/**
|
|
51
|
+
* number of push notifications sent per minute. Paid Feature Only. If throttling is not enabled for the app or the notification, and for free accounts, null is returned. Refer to Throttling for more details.
|
|
52
|
+
*/
|
|
53
|
+
'throttle_rate_per_minute'?: number;
|
|
54
|
+
|
|
55
|
+
static readonly discriminator: string | undefined = undefined;
|
|
56
|
+
|
|
57
|
+
static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
|
|
58
|
+
{
|
|
59
|
+
"name": "remaining",
|
|
60
|
+
"baseName": "remaining",
|
|
61
|
+
"type": "number",
|
|
62
|
+
"format": ""
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"name": "successful",
|
|
66
|
+
"baseName": "successful",
|
|
67
|
+
"type": "number",
|
|
68
|
+
"format": ""
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"name": "failed",
|
|
72
|
+
"baseName": "failed",
|
|
73
|
+
"type": "number",
|
|
74
|
+
"format": ""
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"name": "errored",
|
|
78
|
+
"baseName": "errored",
|
|
79
|
+
"type": "number",
|
|
80
|
+
"format": ""
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"name": "converted",
|
|
84
|
+
"baseName": "converted",
|
|
85
|
+
"type": "number",
|
|
86
|
+
"format": ""
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"name": "queued_at",
|
|
90
|
+
"baseName": "queued_at",
|
|
91
|
+
"type": "number",
|
|
92
|
+
"format": "int64"
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
"name": "send_after",
|
|
96
|
+
"baseName": "send_after",
|
|
97
|
+
"type": "number",
|
|
98
|
+
"format": "int64"
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"name": "completed_at",
|
|
102
|
+
"baseName": "completed_at",
|
|
103
|
+
"type": "number",
|
|
104
|
+
"format": "int64"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"name": "platform_delivery_stats",
|
|
108
|
+
"baseName": "platform_delivery_stats",
|
|
109
|
+
"type": "PlatformDeliveryData",
|
|
110
|
+
"format": ""
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"name": "received",
|
|
114
|
+
"baseName": "received",
|
|
115
|
+
"type": "number",
|
|
116
|
+
"format": ""
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"name": "throttle_rate_per_minute",
|
|
120
|
+
"baseName": "throttle_rate_per_minute",
|
|
121
|
+
"type": "number",
|
|
122
|
+
"format": ""
|
|
123
|
+
} ];
|
|
124
|
+
|
|
125
|
+
static getAttributeTypeMap() {
|
|
126
|
+
return NotificationWithMetaAllOf.attributeTypeMap;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
public constructor() {
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
@@ -1,30 +1,43 @@
|
|
|
1
1
|
export * from './App';
|
|
2
|
+
export * from './BasicNotification';
|
|
3
|
+
export * from './BasicNotificationAllOf';
|
|
4
|
+
export * from './BasicNotificationAllOfAndroidBackgroundLayout';
|
|
2
5
|
export * from './Button';
|
|
6
|
+
export * from './CancelNotificationSuccessResponse';
|
|
7
|
+
export * from './CreateNotificationBadRequestResponse';
|
|
8
|
+
export * from './CreateNotificationSuccessResponse';
|
|
9
|
+
export * from './CreatePlayerSuccessResponse';
|
|
10
|
+
export * from './CreateSegmentBadRequestResponse';
|
|
11
|
+
export * from './CreateSegmentConflictResponse';
|
|
12
|
+
export * from './CreateSegmentSuccessResponse';
|
|
13
|
+
export * from './DeletePlayerBadRequestResponse';
|
|
14
|
+
export * from './DeletePlayerNotFoundResponse';
|
|
15
|
+
export * from './DeletePlayerSuccessResponse';
|
|
16
|
+
export * from './DeleteSegmentBadRequestResponse';
|
|
17
|
+
export * from './DeleteSegmentNotFoundResponse';
|
|
18
|
+
export * from './DeleteSegmentSuccessResponse';
|
|
3
19
|
export * from './DeliveryData';
|
|
4
20
|
export * from './ExportPlayersRequestBody';
|
|
21
|
+
export * from './ExportPlayersSuccessResponse';
|
|
5
22
|
export * from './Filter';
|
|
6
23
|
export * from './FilterExpressions';
|
|
7
|
-
export * from './FilterNotificationTarget';
|
|
8
24
|
export * from './GetNotificationRequestBody';
|
|
9
|
-
export * from './
|
|
10
|
-
export * from './InlineResponse2001';
|
|
11
|
-
export * from './InlineResponse2002';
|
|
12
|
-
export * from './InlineResponse2003';
|
|
13
|
-
export * from './InlineResponse2004';
|
|
14
|
-
export * from './InlineResponse2005';
|
|
15
|
-
export * from './InlineResponse201';
|
|
16
|
-
export * from './InlineResponse400';
|
|
17
|
-
export * from './InlineResponse4001';
|
|
18
|
-
export * from './InlineResponse4002';
|
|
19
|
-
export * from './InlineResponse409';
|
|
25
|
+
export * from './InvalidIdentifierError';
|
|
20
26
|
export * from './Notification';
|
|
27
|
+
export * from './Notification200Errors';
|
|
21
28
|
export * from './NotificationAllOf';
|
|
22
|
-
export * from './
|
|
29
|
+
export * from './NotificationHistoryBadRequestResponse';
|
|
30
|
+
export * from './NotificationHistorySuccessResponse';
|
|
23
31
|
export * from './NotificationSlice';
|
|
24
32
|
export * from './NotificationTarget';
|
|
33
|
+
export * from './NotificationWithMeta';
|
|
34
|
+
export * from './NotificationWithMetaAllOf';
|
|
25
35
|
export * from './Operator';
|
|
26
36
|
export * from './OutcomeData';
|
|
37
|
+
export * from './OutcomesData';
|
|
27
38
|
export * from './PlatformDeliveryData';
|
|
39
|
+
export * from './PlatformDeliveryDataEmailAllOf';
|
|
40
|
+
export * from './PlatformDeliveryDataSmsAllOf';
|
|
28
41
|
export * from './Player';
|
|
29
42
|
export * from './PlayerNotificationTarget';
|
|
30
43
|
export * from './PlayerSlice';
|
|
@@ -32,35 +45,50 @@ export * from './Purchase';
|
|
|
32
45
|
export * from './Segment';
|
|
33
46
|
export * from './SegmentNotificationTarget';
|
|
34
47
|
export * from './StringMap';
|
|
48
|
+
export * from './UpdatePlayerSuccessResponse';
|
|
35
49
|
export * from './UpdatePlayerTagsRequestBody';
|
|
50
|
+
export * from './UpdatePlayerTagsSuccessResponse';
|
|
36
51
|
|
|
37
52
|
import { App , AppApnsEnvEnum } from './App';
|
|
53
|
+
import { BasicNotification , BasicNotificationAggregationEnum } from './BasicNotification';
|
|
54
|
+
import { BasicNotificationAllOf , BasicNotificationAllOfAggregationEnum } from './BasicNotificationAllOf';
|
|
55
|
+
import { BasicNotificationAllOfAndroidBackgroundLayout } from './BasicNotificationAllOfAndroidBackgroundLayout';
|
|
38
56
|
import { Button } from './Button';
|
|
57
|
+
import { CancelNotificationSuccessResponse } from './CancelNotificationSuccessResponse';
|
|
58
|
+
import { CreateNotificationBadRequestResponse } from './CreateNotificationBadRequestResponse';
|
|
59
|
+
import { CreateNotificationSuccessResponse } from './CreateNotificationSuccessResponse';
|
|
60
|
+
import { CreatePlayerSuccessResponse } from './CreatePlayerSuccessResponse';
|
|
61
|
+
import { CreateSegmentBadRequestResponse } from './CreateSegmentBadRequestResponse';
|
|
62
|
+
import { CreateSegmentConflictResponse } from './CreateSegmentConflictResponse';
|
|
63
|
+
import { CreateSegmentSuccessResponse } from './CreateSegmentSuccessResponse';
|
|
64
|
+
import { DeletePlayerBadRequestResponse } from './DeletePlayerBadRequestResponse';
|
|
65
|
+
import { DeletePlayerNotFoundResponse } from './DeletePlayerNotFoundResponse';
|
|
66
|
+
import { DeletePlayerSuccessResponse } from './DeletePlayerSuccessResponse';
|
|
67
|
+
import { DeleteSegmentBadRequestResponse } from './DeleteSegmentBadRequestResponse';
|
|
68
|
+
import { DeleteSegmentNotFoundResponse } from './DeleteSegmentNotFoundResponse';
|
|
69
|
+
import { DeleteSegmentSuccessResponse } from './DeleteSegmentSuccessResponse';
|
|
39
70
|
import { DeliveryData } from './DeliveryData';
|
|
40
71
|
import { ExportPlayersRequestBody } from './ExportPlayersRequestBody';
|
|
72
|
+
import { ExportPlayersSuccessResponse } from './ExportPlayersSuccessResponse';
|
|
41
73
|
import { Filter , FilterRelationEnum } from './Filter';
|
|
42
74
|
import { FilterExpressions , FilterExpressionsRelationEnum , FilterExpressionsOperatorEnum } from './FilterExpressions';
|
|
43
|
-
import { FilterNotificationTarget } from './FilterNotificationTarget';
|
|
44
75
|
import { GetNotificationRequestBody, GetNotificationRequestBodyEventsEnum } from './GetNotificationRequestBody';
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
import { InlineResponse201 } from './InlineResponse201';
|
|
52
|
-
import { InlineResponse400 } from './InlineResponse400';
|
|
53
|
-
import { InlineResponse4001 } from './InlineResponse4001';
|
|
54
|
-
import { InlineResponse4002 } from './InlineResponse4002';
|
|
55
|
-
import { InlineResponse409 } from './InlineResponse409';
|
|
56
|
-
import { Notification , NotificationAggregationEnum } from './Notification';
|
|
57
|
-
import { NotificationAllOf , NotificationAllOfAggregationEnum } from './NotificationAllOf';
|
|
58
|
-
import { NotificationAllOfAndroidBackgroundLayout } from './NotificationAllOfAndroidBackgroundLayout';
|
|
76
|
+
import { InvalidIdentifierError } from './InvalidIdentifierError';
|
|
77
|
+
import { Notification , NotificationAggregationEnum } from './Notification';
|
|
78
|
+
import { Notification200Errors } from './Notification200Errors';
|
|
79
|
+
import { NotificationAllOf } from './NotificationAllOf';
|
|
80
|
+
import { NotificationHistoryBadRequestResponse } from './NotificationHistoryBadRequestResponse';
|
|
81
|
+
import { NotificationHistorySuccessResponse } from './NotificationHistorySuccessResponse';
|
|
59
82
|
import { NotificationSlice } from './NotificationSlice';
|
|
60
83
|
import { NotificationTarget } from './NotificationTarget';
|
|
84
|
+
import { NotificationWithMeta , NotificationWithMetaAggregationEnum } from './NotificationWithMeta';
|
|
85
|
+
import { NotificationWithMetaAllOf } from './NotificationWithMetaAllOf';
|
|
61
86
|
import { Operator, OperatorOperatorEnum } from './Operator';
|
|
62
87
|
import { OutcomeData , OutcomeDataAggregationEnum } from './OutcomeData';
|
|
88
|
+
import { OutcomesData } from './OutcomesData';
|
|
63
89
|
import { PlatformDeliveryData } from './PlatformDeliveryData';
|
|
90
|
+
import { PlatformDeliveryDataEmailAllOf } from './PlatformDeliveryDataEmailAllOf';
|
|
91
|
+
import { PlatformDeliveryDataSmsAllOf } from './PlatformDeliveryDataSmsAllOf';
|
|
64
92
|
import { Player } from './Player';
|
|
65
93
|
import { PlayerNotificationTarget } from './PlayerNotificationTarget';
|
|
66
94
|
import { PlayerSlice } from './PlayerSlice';
|
|
@@ -68,7 +96,9 @@ import { Purchase } from './Purchase';
|
|
|
68
96
|
import { Segment } from './Segment';
|
|
69
97
|
import { SegmentNotificationTarget } from './SegmentNotificationTarget';
|
|
70
98
|
import { StringMap } from './StringMap';
|
|
99
|
+
import { UpdatePlayerSuccessResponse } from './UpdatePlayerSuccessResponse';
|
|
71
100
|
import { UpdatePlayerTagsRequestBody } from './UpdatePlayerTagsRequestBody';
|
|
101
|
+
import { UpdatePlayerTagsSuccessResponse } from './UpdatePlayerTagsSuccessResponse';
|
|
72
102
|
|
|
73
103
|
/* tslint:disable:no-unused-variable */
|
|
74
104
|
let primitives = [
|
|
@@ -84,50 +114,66 @@ let primitives = [
|
|
|
84
114
|
|
|
85
115
|
const supportedMediaTypes: { [mediaType: string]: number } = {
|
|
86
116
|
"application/json": Infinity,
|
|
87
|
-
"application/octet-stream": 0
|
|
117
|
+
"application/octet-stream": 0,
|
|
118
|
+
"application/x-www-form-urlencoded": 0
|
|
88
119
|
}
|
|
89
120
|
|
|
90
|
-
|
|
121
|
+
|
|
91
122
|
let enumsMap: Set<string> = new Set<string>([
|
|
92
123
|
"AppApnsEnvEnum",
|
|
124
|
+
"BasicNotificationAggregationEnum",
|
|
125
|
+
"BasicNotificationAllOfAggregationEnum",
|
|
93
126
|
"FilterRelationEnum",
|
|
94
127
|
"FilterExpressionsRelationEnum",
|
|
95
128
|
"FilterExpressionsOperatorEnum",
|
|
96
129
|
"GetNotificationRequestBodyEventsEnum",
|
|
97
130
|
"NotificationAggregationEnum",
|
|
98
|
-
"
|
|
131
|
+
"NotificationWithMetaAggregationEnum",
|
|
99
132
|
"OperatorOperatorEnum",
|
|
100
133
|
"OutcomeDataAggregationEnum",
|
|
101
134
|
]);
|
|
102
135
|
|
|
103
136
|
let typeMap: {[index: string]: any} = {
|
|
104
137
|
"App": App,
|
|
138
|
+
"BasicNotification": BasicNotification,
|
|
139
|
+
"BasicNotificationAllOf": BasicNotificationAllOf,
|
|
140
|
+
"BasicNotificationAllOfAndroidBackgroundLayout": BasicNotificationAllOfAndroidBackgroundLayout,
|
|
105
141
|
"Button": Button,
|
|
142
|
+
"CancelNotificationSuccessResponse": CancelNotificationSuccessResponse,
|
|
143
|
+
"CreateNotificationBadRequestResponse": CreateNotificationBadRequestResponse,
|
|
144
|
+
"CreateNotificationSuccessResponse": CreateNotificationSuccessResponse,
|
|
145
|
+
"CreatePlayerSuccessResponse": CreatePlayerSuccessResponse,
|
|
146
|
+
"CreateSegmentBadRequestResponse": CreateSegmentBadRequestResponse,
|
|
147
|
+
"CreateSegmentConflictResponse": CreateSegmentConflictResponse,
|
|
148
|
+
"CreateSegmentSuccessResponse": CreateSegmentSuccessResponse,
|
|
149
|
+
"DeletePlayerBadRequestResponse": DeletePlayerBadRequestResponse,
|
|
150
|
+
"DeletePlayerNotFoundResponse": DeletePlayerNotFoundResponse,
|
|
151
|
+
"DeletePlayerSuccessResponse": DeletePlayerSuccessResponse,
|
|
152
|
+
"DeleteSegmentBadRequestResponse": DeleteSegmentBadRequestResponse,
|
|
153
|
+
"DeleteSegmentNotFoundResponse": DeleteSegmentNotFoundResponse,
|
|
154
|
+
"DeleteSegmentSuccessResponse": DeleteSegmentSuccessResponse,
|
|
106
155
|
"DeliveryData": DeliveryData,
|
|
107
156
|
"ExportPlayersRequestBody": ExportPlayersRequestBody,
|
|
157
|
+
"ExportPlayersSuccessResponse": ExportPlayersSuccessResponse,
|
|
108
158
|
"Filter": Filter,
|
|
109
159
|
"FilterExpressions": FilterExpressions,
|
|
110
|
-
"FilterNotificationTarget": FilterNotificationTarget,
|
|
111
160
|
"GetNotificationRequestBody": GetNotificationRequestBody,
|
|
112
|
-
"
|
|
113
|
-
"InlineResponse2001": InlineResponse2001,
|
|
114
|
-
"InlineResponse2002": InlineResponse2002,
|
|
115
|
-
"InlineResponse2003": InlineResponse2003,
|
|
116
|
-
"InlineResponse2004": InlineResponse2004,
|
|
117
|
-
"InlineResponse2005": InlineResponse2005,
|
|
118
|
-
"InlineResponse201": InlineResponse201,
|
|
119
|
-
"InlineResponse400": InlineResponse400,
|
|
120
|
-
"InlineResponse4001": InlineResponse4001,
|
|
121
|
-
"InlineResponse4002": InlineResponse4002,
|
|
122
|
-
"InlineResponse409": InlineResponse409,
|
|
161
|
+
"InvalidIdentifierError": InvalidIdentifierError,
|
|
123
162
|
"Notification": Notification,
|
|
163
|
+
"Notification200Errors": Notification200Errors,
|
|
124
164
|
"NotificationAllOf": NotificationAllOf,
|
|
125
|
-
"
|
|
165
|
+
"NotificationHistoryBadRequestResponse": NotificationHistoryBadRequestResponse,
|
|
166
|
+
"NotificationHistorySuccessResponse": NotificationHistorySuccessResponse,
|
|
126
167
|
"NotificationSlice": NotificationSlice,
|
|
127
168
|
"NotificationTarget": NotificationTarget,
|
|
169
|
+
"NotificationWithMeta": NotificationWithMeta,
|
|
170
|
+
"NotificationWithMetaAllOf": NotificationWithMetaAllOf,
|
|
128
171
|
"Operator": Operator,
|
|
129
172
|
"OutcomeData": OutcomeData,
|
|
173
|
+
"OutcomesData": OutcomesData,
|
|
130
174
|
"PlatformDeliveryData": PlatformDeliveryData,
|
|
175
|
+
"PlatformDeliveryDataEmailAllOf": PlatformDeliveryDataEmailAllOf,
|
|
176
|
+
"PlatformDeliveryDataSmsAllOf": PlatformDeliveryDataSmsAllOf,
|
|
131
177
|
"Player": Player,
|
|
132
178
|
"PlayerNotificationTarget": PlayerNotificationTarget,
|
|
133
179
|
"PlayerSlice": PlayerSlice,
|
|
@@ -135,7 +181,9 @@ let typeMap: {[index: string]: any} = {
|
|
|
135
181
|
"Segment": Segment,
|
|
136
182
|
"SegmentNotificationTarget": SegmentNotificationTarget,
|
|
137
183
|
"StringMap": StringMap,
|
|
184
|
+
"UpdatePlayerSuccessResponse": UpdatePlayerSuccessResponse,
|
|
138
185
|
"UpdatePlayerTagsRequestBody": UpdatePlayerTagsRequestBody,
|
|
186
|
+
"UpdatePlayerTagsSuccessResponse": UpdatePlayerTagsSuccessResponse,
|
|
139
187
|
}
|
|
140
188
|
|
|
141
189
|
export class ObjectSerializer {
|
|
@@ -206,7 +254,7 @@ export class ObjectSerializer {
|
|
|
206
254
|
if (!typeMap[type]) { // in case we dont know the type
|
|
207
255
|
return data;
|
|
208
256
|
}
|
|
209
|
-
|
|
257
|
+
|
|
210
258
|
// Get the actual type of this object
|
|
211
259
|
type = this.findCorrectType(data, type);
|
|
212
260
|
|
|
@@ -251,7 +299,10 @@ export class ObjectSerializer {
|
|
|
251
299
|
let attributeTypes = typeMap[type].getAttributeTypeMap();
|
|
252
300
|
for (let index in attributeTypes) {
|
|
253
301
|
let attributeType = attributeTypes[index];
|
|
254
|
-
|
|
302
|
+
let value = ObjectSerializer.deserialize(data[attributeType.baseName], attributeType.type, attributeType.format);
|
|
303
|
+
if (value !== undefined) {
|
|
304
|
+
instance[attributeType.name] = value;
|
|
305
|
+
}
|
|
255
306
|
}
|
|
256
307
|
return instance;
|
|
257
308
|
}
|
package/models/Operator.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* OneSignal
|
|
3
3
|
* A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
|
|
4
4
|
*
|
|
5
|
-
* API Version: 1.0.
|
|
5
|
+
* API Version: 1.0.1
|
|
6
6
|
* Contact: devrel@onesignal.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
@@ -27,7 +27,7 @@ export class Operator {
|
|
|
27
27
|
static getAttributeTypeMap() {
|
|
28
28
|
return Operator.attributeTypeMap;
|
|
29
29
|
}
|
|
30
|
-
|
|
30
|
+
|
|
31
31
|
public constructor() {
|
|
32
32
|
}
|
|
33
33
|
}
|
package/models/OutcomeData.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* OneSignal
|
|
3
3
|
* A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
|
|
4
4
|
*
|
|
5
|
-
* API Version: 1.0.
|
|
5
|
+
* API Version: 1.0.1
|
|
6
6
|
* Contact: devrel@onesignal.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
@@ -38,7 +38,7 @@ export class OutcomeData {
|
|
|
38
38
|
static getAttributeTypeMap() {
|
|
39
39
|
return OutcomeData.attributeTypeMap;
|
|
40
40
|
}
|
|
41
|
-
|
|
41
|
+
|
|
42
42
|
public constructor() {
|
|
43
43
|
}
|
|
44
44
|
}
|
|
@@ -0,0 +1,32 @@
|
|
|
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: 1.0.1
|
|
6
|
+
* Contact: devrel@onesignal.com
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { OutcomeData } from './OutcomeData';
|
|
10
|
+
import { HttpFile } from '../http/http';
|
|
11
|
+
|
|
12
|
+
export class OutcomesData {
|
|
13
|
+
'outcomes'?: Array<OutcomeData>;
|
|
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": "outcomes",
|
|
20
|
+
"baseName": "outcomes",
|
|
21
|
+
"type": "Array<OutcomeData>",
|
|
22
|
+
"format": ""
|
|
23
|
+
} ];
|
|
24
|
+
|
|
25
|
+
static getAttributeTypeMap() {
|
|
26
|
+
return OutcomesData.attributeTypeMap;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
public constructor() {
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
* OneSignal
|
|
3
3
|
* A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
|
|
4
4
|
*
|
|
5
|
-
* API Version: 1.0.
|
|
5
|
+
* API Version: 1.0.1
|
|
6
6
|
* Contact: devrel@onesignal.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { DeliveryData } from './DeliveryData';
|
|
10
|
+
import { PlatformDeliveryDataEmailAllOf } from './PlatformDeliveryDataEmailAllOf';
|
|
11
|
+
import { PlatformDeliveryDataSmsAllOf } from './PlatformDeliveryDataSmsAllOf';
|
|
10
12
|
import { HttpFile } from '../http/http';
|
|
11
13
|
|
|
12
14
|
/**
|
|
@@ -19,6 +21,8 @@ export class PlatformDeliveryData {
|
|
|
19
21
|
'safari_web_push'?: DeliveryData;
|
|
20
22
|
'android'?: DeliveryData;
|
|
21
23
|
'ios'?: DeliveryData;
|
|
24
|
+
'sms'?: DeliveryData & PlatformDeliveryDataSmsAllOf;
|
|
25
|
+
'email'?: DeliveryData & PlatformDeliveryDataEmailAllOf;
|
|
22
26
|
|
|
23
27
|
static readonly discriminator: string | undefined = undefined;
|
|
24
28
|
|
|
@@ -58,12 +62,24 @@ export class PlatformDeliveryData {
|
|
|
58
62
|
"baseName": "ios",
|
|
59
63
|
"type": "DeliveryData",
|
|
60
64
|
"format": ""
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"name": "sms",
|
|
68
|
+
"baseName": "sms",
|
|
69
|
+
"type": "DeliveryData & PlatformDeliveryDataSmsAllOf",
|
|
70
|
+
"format": ""
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"name": "email",
|
|
74
|
+
"baseName": "email",
|
|
75
|
+
"type": "DeliveryData & PlatformDeliveryDataEmailAllOf",
|
|
76
|
+
"format": ""
|
|
61
77
|
} ];
|
|
62
78
|
|
|
63
79
|
static getAttributeTypeMap() {
|
|
64
80
|
return PlatformDeliveryData.attributeTypeMap;
|
|
65
81
|
}
|
|
66
|
-
|
|
82
|
+
|
|
67
83
|
public constructor() {
|
|
68
84
|
}
|
|
69
85
|
}
|
|
@@ -0,0 +1,94 @@
|
|
|
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: 1.0.1
|
|
6
|
+
* Contact: devrel@onesignal.com
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { HttpFile } from '../http/http';
|
|
10
|
+
|
|
11
|
+
export class PlatformDeliveryDataEmailAllOf {
|
|
12
|
+
/**
|
|
13
|
+
* Number of times an email has been opened.
|
|
14
|
+
*/
|
|
15
|
+
'opened'?: number;
|
|
16
|
+
/**
|
|
17
|
+
* Number of unique recipients who have opened your email.
|
|
18
|
+
*/
|
|
19
|
+
'unique_opens'?: number;
|
|
20
|
+
/**
|
|
21
|
+
* Number of clicked links from your email. This can include the recipient clicking email links multiple times.
|
|
22
|
+
*/
|
|
23
|
+
'clicks'?: number;
|
|
24
|
+
/**
|
|
25
|
+
* Number of unique clicks that your recipients have made on links from your email.
|
|
26
|
+
*/
|
|
27
|
+
'unique_clicks'?: number;
|
|
28
|
+
/**
|
|
29
|
+
* Number of recipients who registered as a hard or soft bounce and didn\'t receive your email.
|
|
30
|
+
*/
|
|
31
|
+
'bounced'?: number;
|
|
32
|
+
/**
|
|
33
|
+
* Number of recipients who reported this email as spam.
|
|
34
|
+
*/
|
|
35
|
+
'reported_spam'?: number;
|
|
36
|
+
/**
|
|
37
|
+
* Number of recipients who opted out of your emails using the unsubscribe link in this email.
|
|
38
|
+
*/
|
|
39
|
+
'unsubscribed'?: number;
|
|
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": "opened",
|
|
46
|
+
"baseName": "opened",
|
|
47
|
+
"type": "number",
|
|
48
|
+
"format": ""
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"name": "unique_opens",
|
|
52
|
+
"baseName": "unique_opens",
|
|
53
|
+
"type": "number",
|
|
54
|
+
"format": ""
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"name": "clicks",
|
|
58
|
+
"baseName": "clicks",
|
|
59
|
+
"type": "number",
|
|
60
|
+
"format": ""
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"name": "unique_clicks",
|
|
64
|
+
"baseName": "unique_clicks",
|
|
65
|
+
"type": "number",
|
|
66
|
+
"format": ""
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"name": "bounced",
|
|
70
|
+
"baseName": "bounced",
|
|
71
|
+
"type": "number",
|
|
72
|
+
"format": ""
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"name": "reported_spam",
|
|
76
|
+
"baseName": "reported_spam",
|
|
77
|
+
"type": "number",
|
|
78
|
+
"format": ""
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"name": "unsubscribed",
|
|
82
|
+
"baseName": "unsubscribed",
|
|
83
|
+
"type": "number",
|
|
84
|
+
"format": ""
|
|
85
|
+
} ];
|
|
86
|
+
|
|
87
|
+
static getAttributeTypeMap() {
|
|
88
|
+
return PlatformDeliveryDataEmailAllOf.attributeTypeMap;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
public constructor() {
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
@@ -0,0 +1,54 @@
|
|
|
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: 1.0.1
|
|
6
|
+
* Contact: devrel@onesignal.com
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { HttpFile } from '../http/http';
|
|
10
|
+
|
|
11
|
+
export class PlatformDeliveryDataSmsAllOf {
|
|
12
|
+
/**
|
|
13
|
+
* Number of messages reported as delivered successfully by the SMS service provider.
|
|
14
|
+
*/
|
|
15
|
+
'provider_successful'?: number;
|
|
16
|
+
/**
|
|
17
|
+
* Number of recipients who didn\'t receive your message as reported by the SMS service provider.
|
|
18
|
+
*/
|
|
19
|
+
'provider_failed'?: number;
|
|
20
|
+
/**
|
|
21
|
+
* Number of errors reported by the SMS service provider.
|
|
22
|
+
*/
|
|
23
|
+
'provider_errored'?: number;
|
|
24
|
+
|
|
25
|
+
static readonly discriminator: string | undefined = undefined;
|
|
26
|
+
|
|
27
|
+
static readonly attributeTypeMap: Array<{name: string, baseName: string, type: string, format: string}> = [
|
|
28
|
+
{
|
|
29
|
+
"name": "provider_successful",
|
|
30
|
+
"baseName": "provider_successful",
|
|
31
|
+
"type": "number",
|
|
32
|
+
"format": ""
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"name": "provider_failed",
|
|
36
|
+
"baseName": "provider_failed",
|
|
37
|
+
"type": "number",
|
|
38
|
+
"format": ""
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"name": "provider_errored",
|
|
42
|
+
"baseName": "provider_errored",
|
|
43
|
+
"type": "number",
|
|
44
|
+
"format": ""
|
|
45
|
+
} ];
|
|
46
|
+
|
|
47
|
+
static getAttributeTypeMap() {
|
|
48
|
+
return PlatformDeliveryDataSmsAllOf.attributeTypeMap;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
public constructor() {
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|