Update
/api/v2/access/update
Post
profiles
jwt
Purpose
To allow a user to update an existing Access Group.
Body Content [input]
{
uid: string,
accessID: string,
name: string,
members: string[]
}
Returns if valid [output]
{
message: string,
error: 0
}
What the API does
- Loops through each of the
member
in the passedmembers
field and ensures that there’s a record for thatuser
in theprofiles
collection [404]. - Finds the
profile
of the record corresponding to theuid
passed from theprofiles
collection and updates the object inside of theaccess_groups
field corresponding to theaccessID
field passed [404] with the values of thename
and/ormembers
fields passed.