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

# Set merchant group override

> Update the group id for a merchant for the current user



## OpenAPI

````yaml https://app.herondata.io/swagger patch /api/merchants/{merchant_heron_id}/user_merchant_group
openapi: 3.0.0
info:
  contact:
    email: support@herondata.io
    name: Support
  title: Heron Data API
  version: '2021-07-19'
servers:
  - description: Production
    url: https://app.herondata.io
security:
  - ApiKeyAuth:
      - key_XXX
externalDocs:
  description: Read Tutorial
  url: https://docs.herondata.io/
paths:
  /api/merchants/{merchant_heron_id}/user_merchant_group:
    patch:
      tags:
        - Merchants
      summary: Set merchant group override
      description: Update the group id for a merchant for the current user
      parameters:
        - description: The Merchant `heron_id`
          in: path
          name: merchant_heron_id
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              properties:
                group_id:
                  example: debt.mca_or_rbf
                  nullable: true
                  type: string
              required:
                - group_id
              type: object
        description: Group ID to assign to the merchant
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserMerchantGroupSchema'
          description: OK
        '404':
          description: Merchant not found
      security:
        - ApiKeyAuth: []
components:
  schemas:
    UserMerchantGroupSchema:
      properties:
        group_id:
          type: string
        merchant_heron_id:
          type: string
        merchant_name:
          type: string
      required:
        - merchant_heron_id
        - merchant_name
      type: object
  securitySchemes:
    ApiKeyAuth:
      in: header
      name: x-api-key
      type: apiKey

````