def replace_memberships(id, memberships, tenant_id)
      data = {
        :memberships => memberships
      }
      put_request(address(tenant_id, "images/" + id + "/members"), data, @token)
    end
def replace_memberships(id, memberships, tenant_id)
      data = {
        :memberships => memberships
      }
      put_request(address(tenant_id, "images/" + id + "/members"), data, @token)
    end
Replaces the membership list for an image.
 @param memberships List of memberships in format [{'member_id': 'tenant1', 'can_share': 'false'}]