@onesignal/node-onesignal 1.0.0-beta4 → 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/dist/apis/DefaultApi.d.ts +0 -62
- package/dist/apis/DefaultApi.js +0 -1317
- package/dist/apis/DefaultApi.js.map +0 -1
- package/dist/apis/baseapi.d.ts +0 -16
- package/dist/apis/baseapi.js +0 -42
- package/dist/apis/baseapi.js.map +0 -1
- package/dist/apis/exception.d.ts +0 -5
- package/dist/apis/exception.js +0 -28
- package/dist/apis/exception.js.map +0 -1
- package/dist/auth/auth.d.ts +0 -40
- package/dist/auth/auth.js +0 -108
- package/dist/auth/auth.js.map +0 -1
- package/dist/configuration.d.ts +0 -18
- package/dist/configuration.js +0 -21
- package/dist/configuration.js.map +0 -1
- package/dist/http/http.d.ts +0 -72
- package/dist/http/http.js +0 -205
- package/dist/http/http.js.map +0 -1
- package/dist/http/isomorphic-fetch.d.ts +0 -5
- package/dist/http/isomorphic-fetch.js +0 -33
- package/dist/http/isomorphic-fetch.js.map +0 -1
- package/dist/index.d.ts +0 -9
- package/dist/index.js +0 -22
- package/dist/index.js.map +0 -1
- package/dist/middleware.d.ts +0 -16
- package/dist/middleware.js +0 -18
- package/dist/middleware.js.map +0 -1
- package/dist/models/App.d.ts +0 -47
- package/dist/models/App.js +0 -196
- package/dist/models/App.js.map +0 -1
- package/dist/models/Button.d.ts +0 -19
- package/dist/models/Button.js +0 -34
- package/dist/models/Button.js.map +0 -1
- package/dist/models/DeliveryData.d.ts +0 -21
- package/dist/models/DeliveryData.js +0 -46
- package/dist/models/DeliveryData.js.map +0 -1
- package/dist/models/ExportPlayersRequestBody.d.ts +0 -19
- package/dist/models/ExportPlayersRequestBody.js +0 -34
- package/dist/models/ExportPlayersRequestBody.js.map +0 -1
- package/dist/models/Filter.d.ts +0 -21
- package/dist/models/Filter.js +0 -40
- package/dist/models/Filter.js.map +0 -1
- package/dist/models/FilterExpressions.d.ts +0 -23
- package/dist/models/FilterExpressions.js +0 -46
- package/dist/models/FilterExpressions.js.map +0 -1
- package/dist/models/FilterNotificationTarget.d.ts +0 -28
- package/dist/models/FilterNotificationTarget.js +0 -88
- package/dist/models/FilterNotificationTarget.js.map +0 -1
- package/dist/models/GetNotificationRequestBody.d.ts +0 -20
- package/dist/models/GetNotificationRequestBody.js +0 -34
- package/dist/models/GetNotificationRequestBody.js.map +0 -1
- package/dist/models/InlineResponse200.d.ts +0 -20
- package/dist/models/InlineResponse200.js +0 -40
- package/dist/models/InlineResponse200.js.map +0 -1
- package/dist/models/InlineResponse2001.d.ts +0 -17
- package/dist/models/InlineResponse2001.js +0 -22
- package/dist/models/InlineResponse2001.js.map +0 -1
- package/dist/models/InlineResponse2002.d.ts +0 -18
- package/dist/models/InlineResponse2002.js +0 -28
- package/dist/models/InlineResponse2002.js.map +0 -1
- package/dist/models/InlineResponse2003.d.ts +0 -17
- package/dist/models/InlineResponse2003.js +0 -22
- package/dist/models/InlineResponse2003.js.map +0 -1
- package/dist/models/InlineResponse2004.d.ts +0 -18
- package/dist/models/InlineResponse2004.js +0 -28
- package/dist/models/InlineResponse2004.js.map +0 -1
- package/dist/models/InlineResponse2005.d.ts +0 -17
- package/dist/models/InlineResponse2005.js +0 -22
- package/dist/models/InlineResponse2005.js.map +0 -1
- package/dist/models/InlineResponse201.d.ts +0 -18
- package/dist/models/InlineResponse201.js +0 -28
- package/dist/models/InlineResponse201.js.map +0 -1
- package/dist/models/InlineResponse400.d.ts +0 -17
- package/dist/models/InlineResponse400.js +0 -22
- package/dist/models/InlineResponse400.js.map +0 -1
- package/dist/models/InlineResponse4001.d.ts +0 -18
- package/dist/models/InlineResponse4001.js +0 -28
- package/dist/models/InlineResponse4001.js.map +0 -1
- package/dist/models/InlineResponse4002.d.ts +0 -17
- package/dist/models/InlineResponse4002.js +0 -22
- package/dist/models/InlineResponse4002.js.map +0 -1
- package/dist/models/InlineResponse409.d.ts +0 -18
- package/dist/models/InlineResponse409.js +0 -28
- package/dist/models/InlineResponse409.js.map +0 -1
- package/dist/models/Notification.d.ts +0 -132
- package/dist/models/Notification.js +0 -688
- package/dist/models/Notification.js.map +0 -1
- package/dist/models/NotificationAllOf.d.ts +0 -108
- package/dist/models/NotificationAllOf.js +0 -544
- package/dist/models/NotificationAllOf.js.map +0 -1
- package/dist/models/NotificationAllOfAndroidBackgroundLayout.d.ts +0 -19
- package/dist/models/NotificationAllOfAndroidBackgroundLayout.js +0 -34
- package/dist/models/NotificationAllOfAndroidBackgroundLayout.js.map +0 -1
- package/dist/models/NotificationSlice.d.ts +0 -21
- package/dist/models/NotificationSlice.js +0 -40
- package/dist/models/NotificationSlice.js.map +0 -1
- package/dist/models/NotificationTarget.d.ts +0 -40
- package/dist/models/NotificationTarget.js +0 -160
- package/dist/models/NotificationTarget.js.map +0 -1
- package/dist/models/ObjectSerializer.d.ts +0 -44
- package/dist/models/ObjectSerializer.js +0 -312
- package/dist/models/ObjectSerializer.js.map +0 -1
- package/dist/models/Operator.d.ts +0 -18
- package/dist/models/Operator.js +0 -22
- package/dist/models/Operator.js.map +0 -1
- package/dist/models/OutcomeData.d.ts +0 -20
- package/dist/models/OutcomeData.js +0 -34
- package/dist/models/OutcomeData.js.map +0 -1
- package/dist/models/PlatformDeliveryData.d.ts +0 -23
- package/dist/models/PlatformDeliveryData.js +0 -52
- package/dist/models/PlatformDeliveryData.js.map +0 -1
- package/dist/models/Player.d.ts +0 -43
- package/dist/models/Player.js +0 -178
- package/dist/models/Player.js.map +0 -1
- package/dist/models/PlayerNotificationTarget.d.ts +0 -26
- package/dist/models/PlayerNotificationTarget.js +0 -76
- package/dist/models/PlayerNotificationTarget.js.map +0 -1
- package/dist/models/PlayerSlice.d.ts +0 -21
- package/dist/models/PlayerSlice.js +0 -40
- package/dist/models/PlayerSlice.js.map +0 -1
- package/dist/models/Purchase.d.ts +0 -19
- package/dist/models/Purchase.js +0 -34
- package/dist/models/Purchase.js.map +0 -1
- package/dist/models/Segment.d.ts +0 -20
- package/dist/models/Segment.js +0 -34
- package/dist/models/Segment.js.map +0 -1
- package/dist/models/SegmentNotificationTarget.d.ts +0 -18
- package/dist/models/SegmentNotificationTarget.js +0 -28
- package/dist/models/SegmentNotificationTarget.js.map +0 -1
- package/dist/models/StringMap.d.ts +0 -59
- package/dist/models/StringMap.js +0 -274
- package/dist/models/StringMap.js.map +0 -1
- package/dist/models/UpdatePlayerTagsRequestBody.d.ts +0 -17
- package/dist/models/UpdatePlayerTagsRequestBody.js +0 -22
- package/dist/models/UpdatePlayerTagsRequestBody.js.map +0 -1
- package/dist/models/all.d.ts +0 -35
- package/dist/models/all.js +0 -48
- package/dist/models/all.js.map +0 -1
- package/dist/rxjsStub.d.ts +0 -10
- package/dist/rxjsStub.js +0 -33
- package/dist/rxjsStub.js.map +0 -1
- package/dist/servers.d.ts +0 -17
- package/dist/servers.js +0 -32
- package/dist/servers.js.map +0 -1
- package/dist/types/ObjectParamAPI.d.ts +0 -121
- package/dist/types/ObjectParamAPI.js +0 -69
- package/dist/types/ObjectParamAPI.js.map +0 -1
- package/dist/types/ObservableAPI.d.ts +0 -45
- package/dist/types/ObservableAPI.js +0 -472
- package/dist/types/ObservableAPI.js.map +0 -1
- package/dist/types/PromiseAPI.d.ts +0 -42
- package/dist/types/PromiseAPI.js +0 -88
- package/dist/types/PromiseAPI.js.map +0 -1
- package/dist/util.d.ts +0 -1
- package/dist/util.js +0 -25
- package/dist/util.js.map +0 -1
- package/git_push.sh +0 -52
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
name: 🙋♂️ Ask a question
|
|
2
|
+
description: Tell us what's on your mind
|
|
3
|
+
title: "[question]: "
|
|
4
|
+
labels: ["triage"]
|
|
5
|
+
body:
|
|
6
|
+
- type: markdown
|
|
7
|
+
attributes:
|
|
8
|
+
value: |
|
|
9
|
+
Having issues integrating this API library?
|
|
10
|
+
- type: textarea
|
|
11
|
+
id: question
|
|
12
|
+
attributes:
|
|
13
|
+
label: How can we help?
|
|
14
|
+
description: Specific question regarding integrating this API library.
|
|
15
|
+
placeholder: How do I...?
|
|
16
|
+
validations:
|
|
17
|
+
required: true
|
|
18
|
+
- type: checkboxes
|
|
19
|
+
id: terms
|
|
20
|
+
attributes:
|
|
21
|
+
label: Code of Conduct
|
|
22
|
+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/OneSignal/api/blob/main/CONTRIBUTING.md)
|
|
23
|
+
options:
|
|
24
|
+
- label: I agree to follow this project's Code of Conduct
|
|
25
|
+
required: true
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
name: 🪳 Bug report
|
|
2
|
+
description: File a bug report
|
|
3
|
+
title: "[Bug]: "
|
|
4
|
+
labels: ["bug", "triage"]
|
|
5
|
+
body:
|
|
6
|
+
- type: markdown
|
|
7
|
+
attributes:
|
|
8
|
+
value: |
|
|
9
|
+
Thanks for taking the time to fill out this bug report!
|
|
10
|
+
- type: textarea
|
|
11
|
+
id: what-happened
|
|
12
|
+
attributes:
|
|
13
|
+
label: What happened?
|
|
14
|
+
description: Provide a thorough description of whats going on.
|
|
15
|
+
placeholder: The latest version of the API library throws an exception when creating a notification targetting all Active Users.
|
|
16
|
+
validations:
|
|
17
|
+
required: true
|
|
18
|
+
- type: textarea
|
|
19
|
+
id: reproduction-steps
|
|
20
|
+
attributes:
|
|
21
|
+
label: Steps to reproduce?
|
|
22
|
+
description: Provide as much detail as posible to reproduce the issue.
|
|
23
|
+
placeholder: |
|
|
24
|
+
1. Install vX.Y.Z of dependency
|
|
25
|
+
2. Run provided code snippet
|
|
26
|
+
3. Note that the app crashes
|
|
27
|
+
render: Markdown
|
|
28
|
+
validations:
|
|
29
|
+
required: true
|
|
30
|
+
- type: textarea
|
|
31
|
+
id: what-are-expectations
|
|
32
|
+
attributes:
|
|
33
|
+
label: What did you expect to happen?
|
|
34
|
+
description: Also tell us, what did you expect to happen?
|
|
35
|
+
placeholder: I expected the API library to properly deserialize any response returned by OneSignal.
|
|
36
|
+
validations:
|
|
37
|
+
required: true
|
|
38
|
+
- type: textarea
|
|
39
|
+
id: logs
|
|
40
|
+
attributes:
|
|
41
|
+
label: Relevant log output
|
|
42
|
+
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
|
|
43
|
+
render: Shell
|
|
44
|
+
- type: checkboxes
|
|
45
|
+
id: terms
|
|
46
|
+
attributes:
|
|
47
|
+
label: Code of Conduct
|
|
48
|
+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/OneSignal/api/blob/main/CONTRIBUTING.md)
|
|
49
|
+
options:
|
|
50
|
+
- label: I agree to follow this project's Code of Conduct
|
|
51
|
+
required: true
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
name: 📣 General feedback
|
|
2
|
+
description: Tell us what's on your mind
|
|
3
|
+
title: "[Bug]: "
|
|
4
|
+
labels: ["triage"]
|
|
5
|
+
body:
|
|
6
|
+
- type: markdown
|
|
7
|
+
attributes:
|
|
8
|
+
value: |
|
|
9
|
+
Thanks for sharing your valuable feedback!
|
|
10
|
+
- type: textarea
|
|
11
|
+
id: feedback
|
|
12
|
+
attributes:
|
|
13
|
+
label: What's on your mind?
|
|
14
|
+
description: Feedback regarding this API library.
|
|
15
|
+
placeholder: Share your feedback...
|
|
16
|
+
validations:
|
|
17
|
+
required: true
|
|
18
|
+
- type: checkboxes
|
|
19
|
+
id: terms
|
|
20
|
+
attributes:
|
|
21
|
+
label: Code of Conduct
|
|
22
|
+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/OneSignal/api/blob/main/CONTRIBUTING.md)
|
|
23
|
+
options:
|
|
24
|
+
- label: I agree to follow this project's Code of Conduct
|
|
25
|
+
required: true
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
<!-- START -->
|
|
2
|
+
# READ AND DELETE THIS SECTION BEFORE SUBMITTING PR
|
|
3
|
+
* **Fill out each _REQUIRED_ section**
|
|
4
|
+
* **Fill out _OPTIONAL_ sections, remove section if it doesn't apply to your PR**
|
|
5
|
+
* **Read and fill out each of the checklists below**
|
|
6
|
+
* **Remove this section after reading**
|
|
7
|
+
<!-- END -->
|
|
8
|
+
|
|
9
|
+
# Description
|
|
10
|
+
## One Line Summary
|
|
11
|
+
**REQUIRED** - Very short description that summaries the changes in this PR.
|
|
12
|
+
|
|
13
|
+
## Details
|
|
14
|
+
|
|
15
|
+
### Motivation
|
|
16
|
+
**REQUIRED -** Why is this code change being made? Or what is the goal of this PR? Examples: Fixes a specific bug, provides additional logging to debug future issues, feature to allow X.
|
|
17
|
+
|
|
18
|
+
### Scope
|
|
19
|
+
**RECOMMEND - OPTIONAL -** What is intended to be effected. What is known not to change. Example: Notifications are grouped when parameter X is set, not enabled by default.
|
|
20
|
+
|
|
21
|
+
### OPTIONAL - Other
|
|
22
|
+
**OPTIONAL -** Feel free to add any other sections or sub-sections that can explain your PR better.
|
|
23
|
+
|
|
24
|
+
# Testing
|
|
25
|
+
|
|
26
|
+
## Manual testing
|
|
27
|
+
**REQUIRED -** Explain what scenarios were tested and the environment.
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
# Checklist
|
|
31
|
+
## Overview
|
|
32
|
+
- [ ] I have filled out all **REQUIRED** sections above
|
|
33
|
+
- [ ] PR does one thing
|
|
34
|
+
- If it is hard to explain how any codes changes are related to each other then it most likely needs to be more than one PR
|
|
35
|
+
- [ ] Any Public API changes are explained in the PR details and conform to existing APIs
|
|
36
|
+
|
|
37
|
+
## Testing
|
|
38
|
+
- [ ] I have personally tested this on my device, or explained why that is not possible
|
|
39
|
+
|
|
40
|
+
## Final pass
|
|
41
|
+
- [ ] Code is as readable as possible.
|
|
42
|
+
- Simplify with less code, followed by splitting up code into well named functions and variables, followed by adding comments to the code.
|
|
43
|
+
- [ ] I have reviewed this PR myself, ensuring it meets each checklist item
|
|
44
|
+
- WIP (Work In Progress) is ok, but explain what is still in progress and what you would like feedback on. Start the PR title with "WIP" to indicate this.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
name: NPM Publish
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [created]
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
publish:
|
|
9
|
+
runs-on: ubuntu-latest
|
|
10
|
+
steps:
|
|
11
|
+
- uses: actions/checkout@v3
|
|
12
|
+
- uses: actions/setup-node@v3
|
|
13
|
+
with:
|
|
14
|
+
node-version: 18
|
|
15
|
+
- name: Install Node types
|
|
16
|
+
run: npm install @types/node
|
|
17
|
+
- name: Publish package
|
|
18
|
+
if: github.event_name == 'release' && github.event.action == 'created'
|
|
19
|
+
uses: JS-DevTools/npm-publish@v1
|
|
20
|
+
with:
|
|
21
|
+
token: ${{ secrets.NPM }}
|
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
All notable changes to this project will be documented in this file.
|
|
3
|
+
|
|
4
|
+
## January 2022
|
|
5
|
+
|
|
6
|
+
### `1.0.0-beta4` - 02/25/2022
|
|
7
|
+
#### Added
|
|
8
|
+
- .npmignore file
|
|
9
|
+
|
|
10
|
+
#### Fixed
|
|
11
|
+
- Missing `dist` directory since npm was ignoring it due to lack of .npmignore
|
|
12
|
+
|
|
13
|
+
### `1.0.0-beta5` - 10/1/2022
|
|
14
|
+
#### Api Changes
|
|
15
|
+
- Configuration setup has been simplified and streamlined. Now it looks like this:
|
|
16
|
+
```js
|
|
17
|
+
const configuration = OneSignal.createConfiguration({
|
|
18
|
+
userKey: USER_KEY_TOKEN,
|
|
19
|
+
appKey: APP_KEY_TOKEN,
|
|
20
|
+
});
|
|
21
|
+
```
|
|
22
|
+
- Player ID is no longer required when creating a player
|
|
23
|
+
|
|
24
|
+
#### Fixed
|
|
25
|
+
- Bug in the OpenAPI schema not allowing users to use filters when creating a notification.
|
|
26
|
+
- Bug in the OpenAPI schema not allowing to set the notification name.
|