$fn.removeUsers(param)
Exclude registered users from application authorization groups."asynchronous"
Arguments
Name | Type | Description |
---|---|---|
param | object | Group name and user information to be excluded |
param details
Property | Type | Description |
---|---|---|
groupName | string | Group Name |
emails | array of string | Array of email addresses of users to exclude from the group |
Return value
None
Sample
try { /* CSV content * --------------------------- * "email" * "user01@test.co.jp" * "user02@test.co.jp" * --------------------------- */ const file = await $fn.getFile('/removeUsers.csv'); const buffer = file.data; const addUsers = $fn.csvToObject(buffer); const emails = addUsers.map(function (item) { return item['email']; }); // Exclude users from authorization group [Group01] await $fn.removeUsers({ groupName: "Group01", emails: emails });} catch(err) { console.log("Error", err);}