Add a User - OsiriX-Foundation/KheopsAuthorization GitHub Wiki

Used to add an user to an album. For adding an user, the calling user must be an admin or an user with "addUser" permission.

URL : /albums/{album_id}/users/{user}

Method : PUT

Auth Required : Authorization with a JWT Bearer token with the user as the sub claim. The user must be an admin or an user with "addUser" permission of the {album_id}.

Headers

  • Accept : If present, require that this value be application/json

Success Response

  • Status : 201 Created

Error Response

If the calling user is not an admin or if he have not "addUser" permission. if the user tries to add himself to the album.

  • Status : 403 Forbidden

If the user is not found. If the album id does not exist. If the user is not a member of the album.

  • Status : 404 Not Found