[[reference-security-bulk_put_role]] //////// =========================================================================================================================== || || || || || || || ██████╗ ███████╗ █████╗ ██████╗ ███╗ ███╗███████╗ || || ██╔══██╗██╔════╝██╔══██╗██╔══██╗████╗ ████║██╔════╝ || || ██████╔╝█████╗ ███████║██║ ██║██╔████╔██║█████╗ || || ██╔══██╗██╔══╝ ██╔══██║██║ ██║██║╚██╔╝██║██╔══╝ || || ██║ ██║███████╗██║ ██║██████╔╝██║ ╚═╝ ██║███████╗ || || ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝╚═════╝ ╚═╝ ╚═╝╚══════╝ || || || || || || This file is autogenerated, DO NOT send pull requests that changes this file directly. || || You should update the script that does the generation, which can be found in: || || https://github.com/elastic/elastic-client-generator-js || || || || You can run the script with the following command: || || npm run elasticsearch -- --version || || || || || || || =========================================================================================================================== //////// [discrete] === client.security.bulkPutRole Bulk create or update roles. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The bulk create or update roles API cannot update roles that are defined in roles files. {ref}/security-api-bulk-put-role.html[{es} documentation] [discrete] ==== Function signature [source,ts] ---- (SecurityBulkPutRoleRequest, options?): Promise ---- [discrete] ===== `SecurityBulkPutRoleRequest` [source,ts] ---- interface SecurityBulkPutRoleRequest extends <> { refresh?: <> roles: Record } ---- [discrete] ===== `SecurityBulkPutRoleResponse` [source,ts] ---- interface SecurityBulkPutRoleResponse { created?: string[] updated?: string[] noop?: string[] errors?: SecurityBulkError } ----