> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hyra.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Role

> Update a role



## OpenAPI

````yaml put /workspace/{workspaceId}/roles/{roleId}
openapi: 3.0.3
info:
  title: Hyra API
  description: Hyra Monolythic API
  version: 2.0.0
servers:
  - url: https://api.hyra.io
security: []
paths:
  /workspace/{workspaceId}/roles/{roleId}:
    put:
      tags:
        - Workspace
      description: Update a role
      parameters:
        - schema:
            type: string
          in: path
          name: workspaceId
          required: true
        - schema:
            type: string
          in: path
          name: roleId
          required: true
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                group_roles:
                  type: array
                  items:
                    type: string
                permissions:
                  type: array
                  items:
                    type: string
                manual_users:
                  type: array
                  items:
                    type: string
              required:
                - name
                - group_roles
                - permissions
                - manual_users
        required: true
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  name:
                    type: string
                  group_roles:
                    type: array
                    items:
                      type: string
                  permissions:
                    type: array
                    items:
                      type: string
                  _id:
                    type: string
                required:
                  - name
                  - group_roles
                  - permissions
                  - _id
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````