@opexa/portal-sdk 0.59.132 → 0.59.133
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/README.md +29 -0
- package/dist/{chunk-OVFU2CHD.js → chunk-ISVV44MD.js} +12 -2
- package/dist/chunk-ISVV44MD.js.map +1 -0
- package/dist/index.cjs +12 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/services/index.cjs +10 -0
- package/dist/services/index.cjs.map +1 -1
- package/dist/services/index.d.cts +2 -2
- package/dist/services/index.d.ts +2 -2
- package/dist/services/index.js +1 -1
- package/dist/{types-Dob6RZ3W.d.ts → types-DOm8J_aC.d.ts} +6 -0
- package/dist/{types-G9IODIto.d.cts → types-Lu2ILDtj.d.cts} +6 -0
- package/package.json +1 -1
- package/dist/chunk-OVFU2CHD.js.map +0 -1
package/README.md
CHANGED
|
@@ -43,6 +43,35 @@ function Page() {
|
|
|
43
43
|
}
|
|
44
44
|
```
|
|
45
45
|
|
|
46
|
+
### Mobile-number registration
|
|
47
|
+
|
|
48
|
+
Standard mobile registration supports branch IDs:
|
|
49
|
+
|
|
50
|
+
```ts
|
|
51
|
+
await sdk.createAccount__next({
|
|
52
|
+
type: 'MOBILE_NUMBER',
|
|
53
|
+
mobileNumber: '09190000000',
|
|
54
|
+
verificationCode: '123456',
|
|
55
|
+
branch: selectedBranch.id,
|
|
56
|
+
});
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Mobile-next registration also supports branch IDs:
|
|
60
|
+
|
|
61
|
+
```ts
|
|
62
|
+
await sdk.createAccount__next({
|
|
63
|
+
type: 'MOBILE_NUMBER[NEXT]',
|
|
64
|
+
mobileNumber: '09190000000',
|
|
65
|
+
mobileNumberVerificationCode: '123456',
|
|
66
|
+
branch: selectedBranch.id,
|
|
67
|
+
});
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
For both registration types, use `branch` for a branch ID or `branchCode` for a legacy branch code. A nonblank
|
|
71
|
+
`branch` takes precedence and omits `branchCode` from the mutation; a missing,
|
|
72
|
+
empty, or whitespace-only `branch` falls back to `branchCode`. The consumer
|
|
73
|
+
chooses which field to supply; no SDK feature flag is required.
|
|
74
|
+
|
|
46
75
|
## API
|
|
47
76
|
|
|
48
77
|
### `Sdk`
|
|
@@ -4191,6 +4191,11 @@ var AccountService = class {
|
|
|
4191
4191
|
}
|
|
4192
4192
|
async registerMemberAccountViaMobile(variables) {
|
|
4193
4193
|
const { reCAPTCHAResponse, domain, testPass, ...others } = variables;
|
|
4194
|
+
const { branch, branchCode, ...input } = others.input;
|
|
4195
|
+
others.input = {
|
|
4196
|
+
...input,
|
|
4197
|
+
...branch?.trim() ? { branch } : { branchCode }
|
|
4198
|
+
};
|
|
4194
4199
|
const res = await this.client.request(REGISTER_MEMBER_ACCOUNT_VIA_MOBILE_MUTATION, others, {
|
|
4195
4200
|
headers: {
|
|
4196
4201
|
...reCAPTCHAResponse && {
|
|
@@ -4632,6 +4637,11 @@ var AccountService = class {
|
|
|
4632
4637
|
}
|
|
4633
4638
|
async registerMemberAccountByMobileNumber__next(variables) {
|
|
4634
4639
|
const { reCAPTCHAResponse, domain, testPass, fingerprint, ...others } = variables;
|
|
4640
|
+
const { branch, branchCode, ...input } = others.input;
|
|
4641
|
+
others.input = {
|
|
4642
|
+
...input,
|
|
4643
|
+
...branch?.trim() ? { branch } : { branchCode }
|
|
4644
|
+
};
|
|
4635
4645
|
const res = await this.client.request(REGISTER_MEMBER_ACCOUNT_BY_MOBILE_NUMBER_MUTATION__NEXT, others, {
|
|
4636
4646
|
headers: {
|
|
4637
4647
|
...reCAPTCHAResponse && {
|
|
@@ -7132,5 +7142,5 @@ var ExtensionService = class {
|
|
|
7132
7142
|
};
|
|
7133
7143
|
|
|
7134
7144
|
export { AccountService, AuthService, CmsPortalService, ExtensionService, FileService, GameService, PortalService, ReportService, TriggerService, WalletService, getFingerPrint, isIOSPlatform };
|
|
7135
|
-
//# sourceMappingURL=chunk-
|
|
7136
|
-
//# sourceMappingURL=chunk-
|
|
7145
|
+
//# sourceMappingURL=chunk-ISVV44MD.js.map
|
|
7146
|
+
//# sourceMappingURL=chunk-ISVV44MD.js.map
|