Social - Community - Member - Update - Status
/social/community/member/update/status/{communityid}/{personid}/{userstatus}
Changes a community member's status in the community.
Authentication
Required, see Auth - Login. The caller must either be the community moderator/owner, or an administrator.
Arguments
communityid (required)
Community ID to change a members status in, can also be a regex (community ID - regex) provided that matches only a single community.
personid (required)
Community member to change the status of - this will normally be the person's username (normally email address) but can also be their database "_id".
Can also be a comma-separated list of either "_id" or username address, in which case the same operation is applied to each user (for output format see below)
userstatus (required)
Status to change the member to (available statuses: "active", "disabled", "pending", "remove", the last of these removes the user from the community altogether )
Example
http://infinite.ikanow.com/api/social/community/member/update/status/50a7a290fbf01a3c159895c4/$status/remove?status=5233614ee4b02e1667b3b822,506c8616fbf042893dd6b3f3,50bcd83cfbf0fd0b27875a82,50bcd83cfbf0fd0b27875aaa
Example Response
{
response:
{
action: "Update member status"
success: true
message: "Updated member status successfully"
time: 45
}
}
The bulk operation has a slightly different format ("success" is false if any of the requests fail)
{
"response": {
"action": "Update member status",
"success": false,
"message": "succeeded=3 failed=1",
"time": 830
},
"data": {
"succeeded": [
"5233614ee4b02e1667b3b822",
"506c8616fbf042893dd6b3f3",
"50bcd83cfbf0fd0b27875a82"
],
"failed": {
"50bcd83cfbf0fd0b27875aaa": "User was not a member of the community"
}
}
}