@36node/auth-sdk 1.1.1 → 1.2.0-pr-12-9569deef24

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/dist/main.js CHANGED
@@ -46,6 +46,9 @@ $parcel$export($00d9c40198a72115$exports, "$UpdateNamespaceDto", () => $00d9c401
46
46
  $parcel$export($00d9c40198a72115$exports, "$CreateSessionDto", () => $00d9c40198a72115$export$c383d7f32a575ab);
47
47
  $parcel$export($00d9c40198a72115$exports, "$Session", () => $00d9c40198a72115$export$90376f1cecfdbf1b);
48
48
  $parcel$export($00d9c40198a72115$exports, "$UpdateSessionDto", () => $00d9c40198a72115$export$8799e003f5e64a20);
49
+ $parcel$export($00d9c40198a72115$exports, "$CreateGroupDto", () => $00d9c40198a72115$export$f82ca5b68f88f064);
50
+ $parcel$export($00d9c40198a72115$exports, "$Group", () => $00d9c40198a72115$export$c90c1d4bd95ad384);
51
+ $parcel$export($00d9c40198a72115$exports, "$UpdateGroupDto", () => $00d9c40198a72115$export$1003ec321a8b124);
49
52
  $parcel$export($00d9c40198a72115$exports, "$CreateCaptchaDto", () => $00d9c40198a72115$export$7e72ed431ee59116);
50
53
  $parcel$export($00d9c40198a72115$exports, "$Captcha", () => $00d9c40198a72115$export$1f2dec6968d7e276);
51
54
  $parcel$export($00d9c40198a72115$exports, "$UpdateCaptchaDto", () => $00d9c40198a72115$export$9ccc176b5ae9cc36);
@@ -183,6 +186,46 @@ const $00d9c40198a72115$export$424b0b82fa10bdfa = {
183
186
  type: "string",
184
187
  description: "\u7528\u6237\u540D"
185
188
  },
189
+ employeeId: {
190
+ type: "string",
191
+ description: "\u5458\u5DE5\u7F16\u53F7"
192
+ },
193
+ permissions: {
194
+ description: "\u6743\u9650",
195
+ type: "array",
196
+ items: {
197
+ type: "string"
198
+ }
199
+ },
200
+ groups: {
201
+ description: "\u56E2\u961F",
202
+ type: "array",
203
+ items: {
204
+ type: "string"
205
+ }
206
+ },
207
+ lastLoginAt: {
208
+ format: "date-time",
209
+ type: "string",
210
+ description: "\u6700\u540E\u767B\u5F55\u65F6\u95F4"
211
+ },
212
+ active: {
213
+ type: "boolean",
214
+ description: "\u662F\u5426\u542F\u7528"
215
+ },
216
+ inviteCode: {
217
+ type: "string",
218
+ description: "\u9080\u8BF7\u7801"
219
+ },
220
+ status: {
221
+ type: "string",
222
+ description: "\u72B6\u6001"
223
+ },
224
+ expireAt: {
225
+ format: "date-time",
226
+ type: "string",
227
+ description: "\u8FC7\u671F\u65F6\u95F4"
228
+ },
186
229
  id: {
187
230
  type: "string",
188
231
  description: "Entity id"
@@ -540,6 +583,41 @@ const $00d9c40198a72115$export$42fb86b793a2c536 = {
540
583
  username: {
541
584
  type: "string",
542
585
  description: "\u7528\u6237\u540D"
586
+ },
587
+ employeeId: {
588
+ type: "string",
589
+ description: "\u5458\u5DE5\u7F16\u53F7"
590
+ },
591
+ permissions: {
592
+ description: "\u6743\u9650",
593
+ type: "array",
594
+ items: {
595
+ type: "string"
596
+ }
597
+ },
598
+ groups: {
599
+ description: "\u56E2\u961F",
600
+ type: "array",
601
+ items: {
602
+ type: "string"
603
+ }
604
+ },
605
+ active: {
606
+ type: "boolean",
607
+ description: "\u662F\u5426\u542F\u7528"
608
+ },
609
+ inviteCode: {
610
+ type: "string",
611
+ description: "\u9080\u8BF7\u7801"
612
+ },
613
+ status: {
614
+ type: "string",
615
+ description: "\u72B6\u6001"
616
+ },
617
+ expireAt: {
618
+ format: "date-time",
619
+ type: "string",
620
+ description: "\u8FC7\u671F\u65F6\u95F4"
543
621
  }
544
622
  }
545
623
  };
@@ -630,6 +708,46 @@ const $00d9c40198a72115$export$1b308892cefd8e3e = {
630
708
  username: {
631
709
  type: "string",
632
710
  description: "\u7528\u6237\u540D"
711
+ },
712
+ employeeId: {
713
+ type: "string",
714
+ description: "\u5458\u5DE5\u7F16\u53F7"
715
+ },
716
+ permissions: {
717
+ description: "\u6743\u9650",
718
+ type: "array",
719
+ items: {
720
+ type: "string"
721
+ }
722
+ },
723
+ groups: {
724
+ description: "\u56E2\u961F",
725
+ type: "array",
726
+ items: {
727
+ type: "string"
728
+ }
729
+ },
730
+ lastLoginAt: {
731
+ format: "date-time",
732
+ type: "string",
733
+ description: "\u6700\u540E\u767B\u5F55\u65F6\u95F4"
734
+ },
735
+ active: {
736
+ type: "boolean",
737
+ description: "\u662F\u5426\u542F\u7528"
738
+ },
739
+ inviteCode: {
740
+ type: "string",
741
+ description: "\u9080\u8BF7\u7801"
742
+ },
743
+ status: {
744
+ type: "string",
745
+ description: "\u72B6\u6001"
746
+ },
747
+ expireAt: {
748
+ format: "date-time",
749
+ type: "string",
750
+ description: "\u8FC7\u671F\u65F6\u95F4"
633
751
  }
634
752
  }
635
753
  };
@@ -689,6 +807,29 @@ const $00d9c40198a72115$export$3a0f0f379fb2f43f = {
689
807
  ns: {
690
808
  type: "string",
691
809
  description: "\u6240\u5C5E\u7684 namespace"
810
+ },
811
+ permissions: {
812
+ description: "\u6743\u9650",
813
+ type: "array",
814
+ items: {
815
+ type: "string"
816
+ }
817
+ },
818
+ active: {
819
+ type: "boolean",
820
+ description: "\u662F\u5426\u542F\u7528"
821
+ },
822
+ defaultPassword: {
823
+ type: "string",
824
+ description: "\u9ED8\u8BA4\u5BC6\u7801"
825
+ },
826
+ exportable: {
827
+ type: "boolean",
828
+ description: "\u662F\u5426\u53EF\u5BFC\u51FA"
829
+ },
830
+ userCount: {
831
+ type: "number",
832
+ description: "\u4EBA\u6570"
692
833
  }
693
834
  },
694
835
  required: [
@@ -728,6 +869,29 @@ const $00d9c40198a72115$export$fef09edac2f41dd6 = {
728
869
  type: "string",
729
870
  description: "\u6240\u5C5E\u7684 namespace"
730
871
  },
872
+ permissions: {
873
+ description: "\u6743\u9650",
874
+ type: "array",
875
+ items: {
876
+ type: "string"
877
+ }
878
+ },
879
+ active: {
880
+ type: "boolean",
881
+ description: "\u662F\u5426\u542F\u7528"
882
+ },
883
+ defaultPassword: {
884
+ type: "string",
885
+ description: "\u9ED8\u8BA4\u5BC6\u7801"
886
+ },
887
+ exportable: {
888
+ type: "boolean",
889
+ description: "\u662F\u5426\u53EF\u5BFC\u51FA"
890
+ },
891
+ userCount: {
892
+ type: "number",
893
+ description: "\u4EBA\u6570"
894
+ },
731
895
  id: {
732
896
  type: "string",
733
897
  description: "Entity id"
@@ -778,6 +942,29 @@ const $00d9c40198a72115$export$532a2356385b479a = {
778
942
  name: {
779
943
  type: "string",
780
944
  description: "\u540D\u79F0"
945
+ },
946
+ permissions: {
947
+ description: "\u6743\u9650",
948
+ type: "array",
949
+ items: {
950
+ type: "string"
951
+ }
952
+ },
953
+ active: {
954
+ type: "boolean",
955
+ description: "\u662F\u5426\u542F\u7528"
956
+ },
957
+ defaultPassword: {
958
+ type: "string",
959
+ description: "\u9ED8\u8BA4\u5BC6\u7801"
960
+ },
961
+ exportable: {
962
+ type: "boolean",
963
+ description: "\u662F\u5426\u53EF\u5BFC\u51FA"
964
+ },
965
+ userCount: {
966
+ type: "number",
967
+ description: "\u4EBA\u6570"
781
968
  }
782
969
  }
783
970
  };
@@ -887,6 +1074,107 @@ const $00d9c40198a72115$export$8799e003f5e64a20 = {
887
1074
  }
888
1075
  }
889
1076
  };
1077
+ const $00d9c40198a72115$export$f82ca5b68f88f064 = {
1078
+ type: "object",
1079
+ properties: {
1080
+ name: {
1081
+ type: "string",
1082
+ description: "\u540D\u79F0"
1083
+ },
1084
+ permissions: {
1085
+ description: "\u6743\u9650",
1086
+ type: "array",
1087
+ items: {
1088
+ type: "string"
1089
+ }
1090
+ },
1091
+ active: {
1092
+ type: "boolean",
1093
+ description: "\u662F\u5426\u542F\u7528"
1094
+ },
1095
+ userCount: {
1096
+ type: "number",
1097
+ description: "\u4EBA\u6570"
1098
+ }
1099
+ },
1100
+ required: [
1101
+ "name"
1102
+ ]
1103
+ };
1104
+ const $00d9c40198a72115$export$c90c1d4bd95ad384 = {
1105
+ type: "object",
1106
+ properties: {
1107
+ name: {
1108
+ type: "string",
1109
+ description: "\u540D\u79F0"
1110
+ },
1111
+ permissions: {
1112
+ description: "\u6743\u9650",
1113
+ type: "array",
1114
+ items: {
1115
+ type: "string"
1116
+ }
1117
+ },
1118
+ active: {
1119
+ type: "boolean",
1120
+ description: "\u662F\u5426\u542F\u7528"
1121
+ },
1122
+ userCount: {
1123
+ type: "number",
1124
+ description: "\u4EBA\u6570"
1125
+ },
1126
+ id: {
1127
+ type: "string",
1128
+ description: "Entity id"
1129
+ },
1130
+ createdAt: {
1131
+ format: "date-time",
1132
+ type: "string",
1133
+ description: "Entity created at when"
1134
+ },
1135
+ updatedAt: {
1136
+ format: "date-time",
1137
+ type: "string",
1138
+ description: "Entity updated at when"
1139
+ },
1140
+ createdBy: {
1141
+ type: "string",
1142
+ description: "Entity created by who"
1143
+ },
1144
+ updatedBy: {
1145
+ type: "string",
1146
+ description: "Entity updated by who"
1147
+ }
1148
+ },
1149
+ required: [
1150
+ "name",
1151
+ "id"
1152
+ ]
1153
+ };
1154
+ const $00d9c40198a72115$export$1003ec321a8b124 = {
1155
+ type: "object",
1156
+ properties: {
1157
+ name: {
1158
+ type: "string",
1159
+ description: "\u540D\u79F0"
1160
+ },
1161
+ permissions: {
1162
+ description: "\u6743\u9650",
1163
+ type: "array",
1164
+ items: {
1165
+ type: "string"
1166
+ }
1167
+ },
1168
+ active: {
1169
+ type: "boolean",
1170
+ description: "\u662F\u5426\u542F\u7528"
1171
+ },
1172
+ userCount: {
1173
+ type: "number",
1174
+ description: "\u4EBA\u6570"
1175
+ }
1176
+ }
1177
+ };
890
1178
  const $00d9c40198a72115$export$7e72ed431ee59116 = {
891
1179
  type: "object",
892
1180
  properties: {
@@ -1350,11 +1638,13 @@ $parcel$export($f3613dc0d7a37c99$exports, "registerByPhone", () => $f3613dc0d7a3
1350
1638
  $parcel$export($f3613dc0d7a37c99$exports, "registerByEmail", () => $f3613dc0d7a37c99$export$81b4f1bef0778e97);
1351
1639
  $parcel$export($f3613dc0d7a37c99$exports, "signToken", () => $f3613dc0d7a37c99$export$6fa58217127c2be5);
1352
1640
  $parcel$export($f3613dc0d7a37c99$exports, "refresh", () => $f3613dc0d7a37c99$export$2d6e9b4c68afb6c8);
1641
+ $parcel$export($f3613dc0d7a37c99$exports, "cleanupAllData", () => $f3613dc0d7a37c99$export$1d732abae8c2178b);
1353
1642
  $parcel$export($f3613dc0d7a37c99$exports, "createUser", () => $f3613dc0d7a37c99$export$3493b8991d49f558);
1354
1643
  $parcel$export($f3613dc0d7a37c99$exports, "listUsers", () => $f3613dc0d7a37c99$export$1c4bb93498097c2d);
1355
1644
  $parcel$export($f3613dc0d7a37c99$exports, "getUser", () => $f3613dc0d7a37c99$export$7cbf767827cd68ba);
1356
1645
  $parcel$export($f3613dc0d7a37c99$exports, "updateUser", () => $f3613dc0d7a37c99$export$e3ac7a5d19605772);
1357
1646
  $parcel$export($f3613dc0d7a37c99$exports, "deleteUser", () => $f3613dc0d7a37c99$export$7d0f10f273c0438a);
1647
+ $parcel$export($f3613dc0d7a37c99$exports, "upsertUserByEmployeeId", () => $f3613dc0d7a37c99$export$6bae5989866b69dc);
1358
1648
  $parcel$export($f3613dc0d7a37c99$exports, "verifyIdentity", () => $f3613dc0d7a37c99$export$ba1d92ba04505a80);
1359
1649
  $parcel$export($f3613dc0d7a37c99$exports, "resetPassword", () => $f3613dc0d7a37c99$export$dc726c8e334dd814);
1360
1650
  $parcel$export($f3613dc0d7a37c99$exports, "updatePassword", () => $f3613dc0d7a37c99$export$e2853351e15b7895);
@@ -1368,6 +1658,11 @@ $parcel$export($f3613dc0d7a37c99$exports, "listSessions", () => $f3613dc0d7a37c9
1368
1658
  $parcel$export($f3613dc0d7a37c99$exports, "getSession", () => $f3613dc0d7a37c99$export$12151e9ef3722552);
1369
1659
  $parcel$export($f3613dc0d7a37c99$exports, "updateSession", () => $f3613dc0d7a37c99$export$531818e825e774db);
1370
1660
  $parcel$export($f3613dc0d7a37c99$exports, "deleteSession", () => $f3613dc0d7a37c99$export$f3b72123251cadf);
1661
+ $parcel$export($f3613dc0d7a37c99$exports, "createGroup", () => $f3613dc0d7a37c99$export$856f728536d122cb);
1662
+ $parcel$export($f3613dc0d7a37c99$exports, "listGroups", () => $f3613dc0d7a37c99$export$6e0114716bd43025);
1663
+ $parcel$export($f3613dc0d7a37c99$exports, "getGroup", () => $f3613dc0d7a37c99$export$dd8fe8767b0c9948);
1664
+ $parcel$export($f3613dc0d7a37c99$exports, "updateGroup", () => $f3613dc0d7a37c99$export$7266cde9e95c4de8);
1665
+ $parcel$export($f3613dc0d7a37c99$exports, "deleteGroup", () => $f3613dc0d7a37c99$export$ae2679b329fc10b6);
1371
1666
  $parcel$export($f3613dc0d7a37c99$exports, "createCaptcha", () => $f3613dc0d7a37c99$export$a6205785190db785);
1372
1667
  $parcel$export($f3613dc0d7a37c99$exports, "listCaptchas", () => $f3613dc0d7a37c99$export$72a6916a1591271b);
1373
1668
  $parcel$export($f3613dc0d7a37c99$exports, "getCaptcha", () => $f3613dc0d7a37c99$export$3f7c59539a3d9e70);
@@ -1444,6 +1739,12 @@ const $f3613dc0d7a37c99$export$2d6e9b4c68afb6c8 = (options)=>{
1444
1739
  url: "/auth/@refresh"
1445
1740
  });
1446
1741
  };
1742
+ const $f3613dc0d7a37c99$export$1d732abae8c2178b = (options)=>{
1743
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).delete({
1744
+ ...options,
1745
+ url: "/auth/@cleanup"
1746
+ });
1747
+ };
1447
1748
  const $f3613dc0d7a37c99$export$3493b8991d49f558 = (options)=>{
1448
1749
  return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).post({
1449
1750
  ...options,
@@ -1474,6 +1775,12 @@ const $f3613dc0d7a37c99$export$7d0f10f273c0438a = (options)=>{
1474
1775
  url: "/users/{userId}"
1475
1776
  });
1476
1777
  };
1778
+ const $f3613dc0d7a37c99$export$6bae5989866b69dc = (options)=>{
1779
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).patch({
1780
+ ...options,
1781
+ url: "/users/employee/{userEmployeeId}"
1782
+ });
1783
+ };
1477
1784
  const $f3613dc0d7a37c99$export$ba1d92ba04505a80 = (options)=>{
1478
1785
  return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).post({
1479
1786
  ...options,
@@ -1513,7 +1820,7 @@ const $f3613dc0d7a37c99$export$becf4f9e48e6290a = (options)=>{
1513
1820
  const $f3613dc0d7a37c99$export$9c52b148e3e82e = (options)=>{
1514
1821
  return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).patch({
1515
1822
  ...options,
1516
- url: "/namespaces/{namespaceId}"
1823
+ url: "/namespaces/{namespaceIdOrKey}"
1517
1824
  });
1518
1825
  };
1519
1826
  const $f3613dc0d7a37c99$export$4b83ac7774adea2f = (options)=>{
@@ -1552,6 +1859,36 @@ const $f3613dc0d7a37c99$export$f3b72123251cadf = (options)=>{
1552
1859
  url: "/sessions/{sessionId}"
1553
1860
  });
1554
1861
  };
1862
+ const $f3613dc0d7a37c99$export$856f728536d122cb = (options)=>{
1863
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).post({
1864
+ ...options,
1865
+ url: "/groups"
1866
+ });
1867
+ };
1868
+ const $f3613dc0d7a37c99$export$6e0114716bd43025 = (options)=>{
1869
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).get({
1870
+ ...options,
1871
+ url: "/groups"
1872
+ });
1873
+ };
1874
+ const $f3613dc0d7a37c99$export$dd8fe8767b0c9948 = (options)=>{
1875
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).get({
1876
+ ...options,
1877
+ url: "/groups/{groupIdOrName}"
1878
+ });
1879
+ };
1880
+ const $f3613dc0d7a37c99$export$7266cde9e95c4de8 = (options)=>{
1881
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).patch({
1882
+ ...options,
1883
+ url: "/groups/{groupId}"
1884
+ });
1885
+ };
1886
+ const $f3613dc0d7a37c99$export$ae2679b329fc10b6 = (options)=>{
1887
+ return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).delete({
1888
+ ...options,
1889
+ url: "/groups/{groupId}"
1890
+ });
1891
+ };
1555
1892
  const $f3613dc0d7a37c99$export$a6205785190db785 = (options)=>{
1556
1893
  return (options?.client ?? $f3613dc0d7a37c99$export$388e0302ca0d9a41).post({
1557
1894
  ...options,