code: def update_user(resource_root, user):
    
    return call(resource_root.put,
        '%s/%s' % (USERS_PATH, user.name), ApiUser, data=user)
docs: Update a user.
  
    Replaces the user's details with those provided.
  
    @param resource_root: The root Resource object
    @param user: An ApiUser object
    @return: An ApiUser object