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

# Update group

> Update a group's name and/or slug.

You can update a group's name and/or slug.<br />You can pass only the fields you want to update; other fields will remain unchanged.<Warning>Changing the slug will affect how you reference the group in API calls.</Warning>


## OpenAPI

````yaml https://api.dnsradar.dev/openapi.json patch /groups/{group_id}
openapi: 3.0.3
info:
  title: DNSRadar API
  description: DNSRadar API - Monitor your DNS records and get notified when they change.
  version: 1.0.0
  contact:
    name: DNSRadar Support
    email: support@dnsradar.dev
    url: https://dnsradar.dev
servers:
  - url: https://api.dnsradar.dev
    description: Production server
security:
  - ApiKeyAuth: []
tags:
  - name: Agents
    description: Team member management and invitations
  - name: Organization
    description: Organization settings, billing, and subscription management
  - name: Monitors
    description: DNS monitoring configuration and management
  - name: Events
    description: DNS change events and history
  - name: Groups
    description: Monitor grouping and organization
  - name: Webhooks
    description: Webhook configuration for event notifications
paths:
  /groups/{group_id}:
    patch:
      tags:
        - Groups
      summary: Update group
      description: Update a group's name and/or slug.
      operationId: updateGroup
      parameters:
        - name: group_id
          in: path
          required: true
          schema:
            type: string
          description: 'Group ID (e.g: grp_abc123...)'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  maxLength: 250
                  example: Premium Accounts
                slug:
                  type: string
                  description: URL-friendly identifier for the group
                  example: premium-accounts
                webhooks:
                  type: array
                  items:
                    type: string
                  description: Array of webhook UUIDs to attach to this group
                  example:
                    - whk_abc123...
                    - whk_def456...
      responses:
        '200':
          description: Group updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Group'
        '400':
          $ref: '#/components/responses/ValidationError'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    Group:
      type: object
      description: Group for organizing monitors
      properties:
        id:
          type: string
          description: Group identifier with 'grp_' prefix
          example: grp_abc123...
        slug:
          type: string
          description: URL-friendly identifier
          example: production-servers
        name:
          type: string
          description: Display name
          example: Production Servers
        is_default:
          type: boolean
          description: Whether this is the default group
        monitors:
          type: integer
          description: Number of monitors in this group
          example: 42
        webhooks:
          type: array
          description: List of webhook UUIDs associated with this group
          items:
            type: string
            description: Webhook UUID with 'whk_' prefix
          example:
            - whk_abc123...
            - whk_def456...
    Error:
      type: object
      description: Error response
      properties:
        code:
          type: integer
          description: HTTP status code
        error:
          oneOf:
            - type: string
              description: Error message
            - type: object
              description: Validation errors by field
              additionalProperties:
                type: string
        errors:
          type: object
          description: Field-specific validation errors
          additionalProperties:
            type: string
  responses:
    ValidationError:
      description: Validation error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: 400
            errors:
              email: Invalid email format
    UnauthorizedError:
      description: Authentication is missing or invalid
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: 401
            error: Unauthorized
    NotFoundError:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: 404
            error: Not found
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: >-
        API key used to authenticate yourself on DNSRadar. Obtain your API key
        from your DNSRadar dashboard.

````