@mbanq/core-sdk-js 0.9.0 → 0.11.0
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 +53 -0
- package/dist/{user-RDPW38ut.d.ts → cardProduct-CUtYMnwz.d.ts} +751 -25
- package/dist/{user-Bjs4y9m9.d.mts → cardProduct-D2BhJVE-.d.mts} +751 -25
- package/dist/chunk-L6NVTSCE.mjs +32 -0
- package/dist/{chunk-TBHVC66F.js → chunk-Q4XYMUNW.js} +2 -2
- package/dist/commands/index.d.mts +2 -2
- package/dist/commands/index.d.ts +2 -2
- package/dist/commands/index.js +1 -1
- package/dist/commands/index.mjs +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/chunk-WPPEYW5X.mjs +0 -32
package/README.md
CHANGED
|
@@ -564,6 +564,59 @@ const rejectResult = await client.request(rejectCommand);
|
|
|
564
564
|
- `unmaskValue` - Set to `true` to return full document reference (unmasked)
|
|
565
565
|
- `fields` - Comma-separated list of fields to include in response
|
|
566
566
|
|
|
567
|
+
### User Operations
|
|
568
|
+
|
|
569
|
+
Manage user access and permissions.
|
|
570
|
+
|
|
571
|
+
```javascript
|
|
572
|
+
import { EnableSelfServiceAccess, UpdateSelfServiceUser, DeleteSelfServiceUser } from '@mbanq/core-sdk-js';
|
|
573
|
+
|
|
574
|
+
// Enable self-service access for a user
|
|
575
|
+
const enableAccessCommand = EnableSelfServiceAccess({
|
|
576
|
+
username: 'testUserName',
|
|
577
|
+
firstname: 'testFirstName',
|
|
578
|
+
lastname: 'testLastName',
|
|
579
|
+
officeId: 1,
|
|
580
|
+
roles: [1],
|
|
581
|
+
isSelfServiceUser: true,
|
|
582
|
+
sendPasswordToEmail: false,
|
|
583
|
+
email: 'test@gmail.com',
|
|
584
|
+
password: 'user1234',
|
|
585
|
+
repeatPassword: 'user1234',
|
|
586
|
+
enabled: true,
|
|
587
|
+
clients: [1]
|
|
588
|
+
});
|
|
589
|
+
|
|
590
|
+
const result = await client.request(enableAccessCommand);
|
|
591
|
+
|
|
592
|
+
// Update self-service user
|
|
593
|
+
const updateUserCommand = UpdateSelfServiceUser({
|
|
594
|
+
userId: 123,
|
|
595
|
+
username: 'updatedUserName',
|
|
596
|
+
firstname: 'updatedFirstName',
|
|
597
|
+
lastname: 'updatedLastName',
|
|
598
|
+
officeId: 1,
|
|
599
|
+
roles: [1, 2],
|
|
600
|
+
isSelfServiceUser: true,
|
|
601
|
+
sendPasswordToEmail: true,
|
|
602
|
+
email: 'updated@gmail.com',
|
|
603
|
+
password: 'newPass1234',
|
|
604
|
+
repeatPassword: 'newPass1234',
|
|
605
|
+
enabled: true,
|
|
606
|
+
clients: [1, 2]
|
|
607
|
+
});
|
|
608
|
+
|
|
609
|
+
const updateResult = await client.request(updateUserCommand);
|
|
610
|
+
|
|
611
|
+
// Delete self-service user
|
|
612
|
+
const deleteUserCommand = DeleteSelfServiceUser(123, { tenantId: 'default' });
|
|
613
|
+
const deleteResult = await client.request(deleteUserCommand);
|
|
614
|
+
// Returns: { officeId: 1, clientId: 1, resourceId: 123 }
|
|
615
|
+
```
|
|
616
|
+
|
|
617
|
+
**Available Commands:** `EnableSelfServiceAccess`, `UpdateSelfServiceUser`, `DeleteSelfServiceUser`, `GetUserDetail`
|
|
618
|
+
|
|
619
|
+
|
|
567
620
|
|
|
568
621
|
### Account Operations
|
|
569
622
|
|