@insignia-education/api-sdk-js 0.15.61 → 0.15.63
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/workflows/npm-publish-github-packages.yml +95 -12
- package/coverage/clover.xml +132 -1512
- package/coverage/coverage-final.json +1 -47
- package/coverage/lcov-report/Client.js.html +463 -0
- package/coverage/lcov-report/index.html +20 -65
- package/coverage/lcov-report/src/Client.js.html +141 -132
- package/coverage/lcov-report/src/api/index.html +1 -1
- package/coverage/lcov-report/src/api/index.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Accounts.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Admin.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Auth.js.html +7 -7
- package/coverage/lcov-report/src/api/v1/Categories.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Changelogs.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Configs.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/ContactForms.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/ConversationalTopics.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Countries.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Coupons.js.html +16 -16
- package/coverage/lcov-report/src/api/v1/Courses.js.html +27 -27
- package/coverage/lcov-report/src/api/v1/Currencies.js.html +10 -10
- package/coverage/lcov-report/src/api/v1/Dashboard.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/EducationCenter.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Employee.js.html +5 -5
- package/coverage/lcov-report/src/api/v1/Files.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Forums.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Hashes.js.html +16 -13
- package/coverage/lcov-report/src/api/v1/Insignias.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Languages.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/MailBlacklist.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/MailingLists.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Offers.js.html +16 -16
- package/coverage/lcov-report/src/api/v1/Organizations.js.html +52 -52
- package/coverage/lcov-report/src/api/v1/PaymentMethods.js.html +7 -7
- package/coverage/lcov-report/src/api/v1/Payments.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Premiums.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Quizzes.js.html +42 -42
- package/coverage/lcov-report/src/api/v1/Sales.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Search.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/ShortLinks.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Surveys.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Taxes.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Teacher.js.html +100 -70
- package/coverage/lcov-report/src/api/v1/Telegram.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/TwoFactor.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/UserSessionTypes.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/UserTypes.js.html +8 -8
- package/coverage/lcov-report/src/api/v1/Users.js.html +112 -16
- package/coverage/lcov-report/src/api/v1/Utm.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Webauthn.js.html +3 -3
- package/coverage/lcov-report/src/api/v1/Zoom.js.html +19 -19
- package/coverage/lcov-report/src/api/v1/index.html +154 -184
- package/coverage/lcov-report/src/api/v1/index.js.html +52 -64
- package/coverage/lcov-report/src/index.html +21 -21
- package/coverage/lcov-report/src/index.js.html +3 -3
- package/coverage/lcov-report/tests/helpers.js.html +11 -11
- package/coverage/lcov-report/tests/index.html +7 -7
- package/coverage/lcov.info +146 -2451
- package/coverage/test-report.html +1 -10
- package/jest.config.mjs +12 -1
- package/package.json +2 -2
- package/src/api/v1/Coupons.js +11 -0
- package/src/api/v1/Courses.js +2 -0
- package/src/api/v1/Hashes.js +3 -2
- package/src/api/v1/Telegram.js +6 -0
- package/src/api/v1/Users.js +12 -0
- package/src/api/v1/index.js +0 -4
- package/tests/integration/api/v1/accounts.test.js +5 -11
- package/tests/integration/api/v1/auth/login.test.js +18 -34
- package/tests/integration/api/v1/conversational-topics.test.js +3 -5
- package/tests/integration/api/v1/countries.test.js +1 -1
- package/tests/integration/api/v1/coupons.test.js +2 -9
- package/tests/integration/api/v1/currencies/index.test.js +1 -1
- package/tests/integration/api/v1/files.test.js +18 -15
- package/tests/integration/api/v1/hashes.test.js +2 -10
- package/tests/integration/api/v1/mail-blacklist.test.js +2 -9
- package/tests/integration/api/v1/offers.test.js +2 -9
- package/tests/integration/api/v1/organizations.test.js +8 -8
- package/tests/integration/api/v1/quizzes/index.test.js +0 -2
- package/tests/integration/api/v1/short-links.test.js +2 -9
- package/tests/integration/api/v1/taxes.test.js +2 -3
- package/tests/integration/api/v1/teacher/index.test.js +1 -1
- package/tests/integration/api/v1/telegram.test.js +33 -0
- package/tests/integration/api/v1/user-types.test.js +2 -4
- package/tests/integration/api/v1/users/index.test.js +10 -13
- package/tests/integration/api/v1/users/telegram.test.js +36 -0
- package/tests/integration/api/v1/zoom.test.js +2 -9
- package/src/api/v1/Categories.js +0 -12
- package/src/api/v1/Configs.js +0 -12
- package/tests/integration/api/v1/categories.test.js +0 -19
- package/tests/integration/api/v1/configs.test.js +0 -20
|
@@ -1,14 +1,17 @@
|
|
|
1
|
-
name:
|
|
1
|
+
name: Bump version, publish, and sync front
|
|
2
2
|
|
|
3
3
|
on:
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
push:
|
|
5
|
+
branches: [master]
|
|
6
6
|
|
|
7
7
|
jobs:
|
|
8
|
-
publish:
|
|
8
|
+
bump-and-publish:
|
|
9
|
+
if: "!contains(github.event.head_commit.message, '[skip ci]')"
|
|
9
10
|
runs-on: ubuntu-latest
|
|
10
11
|
permissions:
|
|
11
|
-
contents:
|
|
12
|
+
contents: write
|
|
13
|
+
outputs:
|
|
14
|
+
version: ${{ steps.bump.outputs.version }}
|
|
12
15
|
steps:
|
|
13
16
|
- uses: actions/checkout@v4
|
|
14
17
|
|
|
@@ -18,14 +21,94 @@ jobs:
|
|
|
18
21
|
node-version: 25
|
|
19
22
|
registry-url: 'https://registry.npmjs.org/'
|
|
20
23
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
# - name: Run tests
|
|
26
|
-
# run: npm test
|
|
24
|
+
- name: Configure git
|
|
25
|
+
run: |
|
|
26
|
+
git config user.name "github-actions[bot]"
|
|
27
|
+
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
27
28
|
|
|
28
|
-
- name:
|
|
29
|
+
- name: Bump patch version
|
|
30
|
+
id: bump
|
|
31
|
+
run: |
|
|
32
|
+
NEW_VERSION=$(npm version patch -m "chore: release v%s [skip ci]")
|
|
33
|
+
echo "version=${NEW_VERSION#v}" >> "$GITHUB_OUTPUT"
|
|
34
|
+
|
|
35
|
+
- name: Push version bump
|
|
36
|
+
run: git push origin HEAD:master --follow-tags
|
|
37
|
+
|
|
38
|
+
- name: Publish to npm
|
|
29
39
|
run: npm publish --access public
|
|
30
40
|
env:
|
|
31
41
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
42
|
+
|
|
43
|
+
sync-front:
|
|
44
|
+
needs: bump-and-publish
|
|
45
|
+
runs-on: ubuntu-latest
|
|
46
|
+
env:
|
|
47
|
+
SDK_VERSION: ${{ needs.bump-and-publish.outputs.version }}
|
|
48
|
+
steps:
|
|
49
|
+
- name: Wait for npm registry propagation
|
|
50
|
+
run: sleep 15
|
|
51
|
+
|
|
52
|
+
- name: Setup node
|
|
53
|
+
uses: actions/setup-node@v4
|
|
54
|
+
with:
|
|
55
|
+
node-version: 24
|
|
56
|
+
|
|
57
|
+
# ---- beta: direct commit + push ----
|
|
58
|
+
- name: Checkout front (beta)
|
|
59
|
+
uses: actions/checkout@v4
|
|
60
|
+
with:
|
|
61
|
+
repository: insignia-education/front
|
|
62
|
+
ref: beta
|
|
63
|
+
token: ${{ secrets.FRONT_REPO_PAT }}
|
|
64
|
+
path: front-beta
|
|
65
|
+
|
|
66
|
+
- name: Bump SDK in front (beta)
|
|
67
|
+
working-directory: front-beta
|
|
68
|
+
run: npm install "@insignia-education/api-sdk-js@${SDK_VERSION}"
|
|
69
|
+
|
|
70
|
+
- name: Commit and push (beta)
|
|
71
|
+
working-directory: front-beta
|
|
72
|
+
run: |
|
|
73
|
+
git config user.name "github-actions[bot]"
|
|
74
|
+
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
75
|
+
git add package.json package-lock.json
|
|
76
|
+
if git diff --cached --quiet; then
|
|
77
|
+
echo "No changes, skipping"
|
|
78
|
+
else
|
|
79
|
+
git commit -m "chore: bump @insignia-education/api-sdk-js to ${SDK_VERSION}"
|
|
80
|
+
git push origin beta
|
|
81
|
+
fi
|
|
82
|
+
|
|
83
|
+
# ---- master: open a PR for review ----
|
|
84
|
+
- name: Checkout front (master)
|
|
85
|
+
uses: actions/checkout@v4
|
|
86
|
+
with:
|
|
87
|
+
repository: insignia-education/front
|
|
88
|
+
ref: master
|
|
89
|
+
token: ${{ secrets.FRONT_REPO_PAT }}
|
|
90
|
+
path: front-master
|
|
91
|
+
|
|
92
|
+
- name: Bump SDK in front (master branch)
|
|
93
|
+
working-directory: front-master
|
|
94
|
+
run: npm install "@insignia-education/api-sdk-js@${SDK_VERSION}"
|
|
95
|
+
|
|
96
|
+
- name: Open PR against master
|
|
97
|
+
working-directory: front-master
|
|
98
|
+
env:
|
|
99
|
+
GH_TOKEN: ${{ secrets.FRONT_REPO_PAT }}
|
|
100
|
+
run: |
|
|
101
|
+
git config user.name "github-actions[bot]"
|
|
102
|
+
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
103
|
+
if git diff --quiet; then
|
|
104
|
+
echo "No changes, skipping PR"
|
|
105
|
+
exit 0
|
|
106
|
+
fi
|
|
107
|
+
BRANCH="chore/bump-api-sdk-js-${SDK_VERSION}"
|
|
108
|
+
git checkout -b "$BRANCH"
|
|
109
|
+
git add package.json package-lock.json
|
|
110
|
+
git commit -m "chore: bump @insignia-education/api-sdk-js to ${SDK_VERSION}"
|
|
111
|
+
git push origin "$BRANCH"
|
|
112
|
+
gh pr create --repo insignia-education/front --base master --head "$BRANCH" \
|
|
113
|
+
--title "chore: bump @insignia-education/api-sdk-js to ${SDK_VERSION}" \
|
|
114
|
+
--body "Automated dependency bump triggered by insignia-education/api-sdk-js@${SDK_VERSION}."
|