def update(self, name, **kwargs):
        """
        Update existing role.

        http://www.keycloak.org/docs-api/3.4/rest-api/index.html#_roles_resource

        :param str name: Name for the role
        :param str description: (optional)
        :param str id: (optional)
        :param bool client_role: (optional)
        :param bool composite: (optional)
        :param object composites: (optional)
        :param str container_id: (optional)
        :param bool scope_param_required: (optional)
        """
        payload = OrderedDict(name=name)

        for key in ROLE_KWARGS:
            if key in kwargs:
                payload[to_camel_case(key)] = kwargs[key]

        return self._client.put(
            url=self._client.get_full_url(
                self.get_path('single',
                              realm=self._realm_name,
                              id=self._client_id,
                              role_name=self._role_name)
            ),
            data=json.dumps(payload, sort_keys=True)
        )
def update ( self , name , ** kwargs ) : payload = OrderedDict ( name = name ) for key in ROLE_KWARGS : if key in kwargs : payload [ to_camel_case ( key ) ] = kwargs [ key ] return self . _client . put ( url = self . _client . get_full_url ( self . get_path ( 'single' , realm = self . _realm_name , id = self . _client_id , role_name = self . _role_name ) ) , data = json . dumps ( payload , sort_keys = True ) )
Update existing role.

        http://www.keycloak.org/docs-api/3.4/rest-api/index.html#_roles_resource

        :param str name: Name for the role
        :param str description: (optional)
        :param str id: (optional)
        :param bool client_role: (optional)
        :param bool composite: (optional)
        :param object composites: (optional)
        :param str container_id: (optional)
        :param bool scope_param_required: (optional)