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

# Update Protocol Group

> Update a protocol group's name and/or description.

Renaming a group affects every protocol in it, since membership is by
reference rather than by copied name.

Parameters
----------
group_id : str
    ID of the group to update.
body : UpdateProtocolGroupBody
    Fields to update. Omitted fields are left unchanged; an explicit
    ``description: null`` clears the description.

Returns
-------
ProtocolGroup
    The updated group.

Raises
------
NotFoundError
    If the group does not exist or belongs to another organization.
ConflictError
    If the new name collides with another group in the same project.



## OpenAPI

````yaml https://api.ionworks.com/openapi.json patch /protocol_groups/{group_id}
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://api.ionworks.com
    description: Production
security: []
paths:
  /protocol_groups/{group_id}:
    patch:
      tags:
        - protocol_groups
      summary: Update Protocol Group
      description: |-
        Update a protocol group's name and/or description.

        Renaming a group affects every protocol in it, since membership is by
        reference rather than by copied name.

        Parameters
        ----------
        group_id : str
            ID of the group to update.
        body : UpdateProtocolGroupBody
            Fields to update. Omitted fields are left unchanged; an explicit
            ``description: null`` clears the description.

        Returns
        -------
        ProtocolGroup
            The updated group.

        Raises
        ------
        NotFoundError
            If the group does not exist or belongs to another organization.
        ConflictError
            If the new name collides with another group in the same project.
      operationId: update_protocol_group_protocol_groups__group_id__patch
      parameters:
        - name: group_id
          in: path
          required: true
          schema:
            type: string
            title: Group Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateProtocolGroupBody'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProtocolGroup'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    UpdateProtocolGroupBody:
      properties:
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: New name for the group
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: New description
      type: object
      title: UpdateProtocolGroupBody
      description: >-
        Request body for updating a protocol group.


        All fields are optional (PATCH semantics). ``description`` is
        deliberately

        distinguishable from "absent": passing ``null`` clears it, while
        omitting it

        leaves the stored value alone.
    ProtocolGroup:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Unique identifier for the group
        name:
          type: string
          title: Name
          description: Name of the group, unique within the project
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Optional note on what relates the protocols in this group
        organization_id:
          type: string
          title: Organization Id
          description: ID of the organization that owns this group
        project_id:
          type: string
          title: Project Id
          description: ID of the project that owns this group
        created_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By
          description: User ID of the user who created this group
        created_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Created At
          description: When the group was created
        updated_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Updated At
          description: When the group was last updated
        protocol_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Protocol Count
          description: >-
            Number of protocols in this group. Present on list responses, None
            when the group is fetched on its own.
        created_by_email:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By Email
          description: Email of the user who created this group
      type: object
      required:
        - name
        - organization_id
        - project_id
      title: ProtocolGroup
      description: Database entity for a protocol group.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````