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

> Sets or updates permissions for a specific group scope

# Set Scope Permissions

For the complete error reference, see [Error Guide](/articles/error-guide).


## OpenAPI

````yaml put /groups/{guid}/scopes/{scope}/permissions
openapi: 3.0.0
info:
  title: Chat APIs
  description: Manage messages, users, groups for a particular app using our Chat API.
  version: '3.0'
servers:
  - url: https://{appId}.api-{region}.cometchat.io/v3
    variables:
      appId:
        default: appId
        description: (Required) App ID
      region:
        enum:
          - us
          - eu
          - in
        default: us
        description: Select Region
security: []
tags:
  - name: API Keys
    description: The API keys are used to authorise the APIs
  - name: Roles
    description: The roles are used to give user access rights
  - name: Users
    description: The REST collection for users.
  - name: Auth Tokens
    description: The auth tokens are used to login end users using client SDKs.
  - name: Blocked Users
    description: The REST collections for blocked users.
  - name: Friends
    description: List,add and remove friends by passing UID in path variables
  - name: Groups
    description: The REST collections for groups.
  - name: Banned Users
    description: Ban and Unban user by passing other UID in path variables.
  - name: Group Members
    description: The REST collections for group members.
  - name: Messages
    description: The REST collections for messages.
  - name: Conversations
    description: The REST collections for conversations.
  - name: Restrict Features
    description: Allows Restricting Features
  - name: Metrics
    description: Allows accessing Data Metrics
  - name: Triggers
    description: Allows adding triggers to a webhook.
  - name: Webhooks
    description: Allows accessing Webhooks.
  - name: Notifications
    description: Allows configuring Notifications core.
paths:
  /groups/{guid}/scopes/{scope}/permissions:
    put:
      tags:
        - RBAC
      summary: Set Scope Permissions
      description: Sets or updates permissions for a specific group scope
      operationId: set-scope-permissions
      parameters:
        - name: guid
          in: path
          description: The group GUID to update scope permissions for
          required: true
          schema:
            type: string
            example: supergroup
        - name: scope
          in: path
          description: The scope identifier (e.g., admin, moderator, participant)
          required: true
          schema:
            type: string
            example: admin
      requestBody:
        content:
          application/json:
            schema:
              required:
                - permissions
              properties:
                permissions:
                  description: >-
                    Permissions object containing key-value pairs for scope
                    permissions
                  type: object
                  example:
                    sendMessage: deny
                    initiateCall: friends
                  additionalProperties: true
              type: object
      responses:
        '200':
          description: Scope permissions updated successfully
          content:
            application/json:
              schema:
                properties:
                  data:
                    type: object
                type: object
              example:
                data:
                  sendMessage:
                    success: true
                    message: >-
                      Permission with id sendMessage have been mapped
                      successfully to scope admin on group cometchat-guid-1.
                  permissions:
                    sendMessage: allow
                    listMembers: allow
                    listMembers.allowedScopes: participant
                    addReaction: deny
                    listReactions.allowedScopes: moderator
                    listReactions: deny
                    sendThreadedMessage: allow
                    initiateCall: deny
                    initiateCall.allowedScopes: participant
                    initiateCall.allowedType: audio
                    editMessage: allow
      security:
        - apiKey: []
components:
  securitySchemes:
    apiKey:
      type: apiKey
      description: API Key with fullAccess scope(i.e. Rest API Key from the Dashboard).
      name: apikey
      in: header

````