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

# Update Merchant

> Update specific fields of an existing merchant.

## Overview

The Update Merchant endpoint allows Payment Aggregators (PSPs) to update an existing sub-merchant's company details, settlement information, contact details, and business information.

This is a **partial update** (PATCH) — only include the fields you want to change. Fields not included in the request will remain unchanged.

**Important**: Updates are only allowed when the sub-merchant is in `PENDING` or `CHANGES_REQUESTED` status. Merchants in other statuses (APPROVED, IN\_REVIEW, REJECTED) cannot be edited.

## Request Parameters

The request structure mirrors the [Create Merchant](/api-reference/v1/merchant/create) endpoint. All fields are optional for partial updates.

### Parameter Definitions

#### Top-level

| Name                | Type   | Required | Description                                                |
| ------------------- | ------ | -------- | ---------------------------------------------------------- |
| company\_details    | object | No       | Company and contact details to update. See Company Details |
| settlement\_details | object | No       | Bank account details to update. See Settlement Details     |

#### Company Details

All fields from the [Create Merchant](/api-reference/v1/merchant/create#company-details) are accepted, but none are required. Only include fields you want to change.

Key fields:

| Name                              | Type   | Description                              | Constraints                          |
| --------------------------------- | ------ | ---------------------------------------- | ------------------------------------ |
| email                             | string | Contact email.                           | RFC 5322 email format                |
| phone\_number                     | string | Contact phone number.                    | E.164 format (e.g., `+919876543210`) |
| legal\_name                       | string | Legal name of the company.               | Max 255 chars                        |
| brand\_name                       | string | Brand/trade name.                        | Max 255 chars                        |
| website                           | string | Company website URL.                     | Must include `https://` prefix       |
| international\_org\_type          | string | Type of organization.                    | Same enum as Create                  |
| monthly\_avg\_transaction\_volume | string | Transaction volume range.                | Same enum as Create                  |
| business\_category                | string | Business category.                       | Same values as Create                |
| business\_category\_other         | string | Required when category includes "Other". |                                      |
| business\_mode                    | string | Mode of business.                        | Enum: `b2b`, `b2c`, `marketplace`    |
| mcc                               | string | Merchant Category Codes.                 | Comma-separated 4-digit codes        |

For the complete field reference, see [Create Merchant — Company Details](/api-reference/v1/merchant/create#company-details).

#### Settlement Details

All fields from the [Create Merchant](/api-reference/v1/merchant/create#settlement-details) are accepted. Only include fields you want to change.

## Examples

<CodeGroup>
  ```json Update Company Details theme={null}
  {
    "company_details": {
      "brand_name": "AcmeTech Global",
      "website": "https://acmetech-global.com",
      "business_category": "Digital goods / software / downloads,SaaS / subscriptions / recurring billing",
      "monthly_avg_transaction_volume": "BETWEEN_50_K_AND_100_K",
      "description_of_products_and_services": "Updated: Enterprise SaaS platform for supply chain management"
    }
  }
  ```

  ```json Update Contact Details theme={null}
  {
    "company_details": {
      "email": "new-contact@acmetech.com",
      "phone_number": "+919876500000"
    }
  }
  ```

  ```json Update Settlement Details theme={null}
  {
    "settlement_details": {
      "bank_account_number": "9876543210123456",
      "bank_account_name": "AcmeTech Global Pvt Ltd",
      "bank_swift_code": "ABORINBB",
      "bank_name": "RBL Bank",
      "bank_branch_name": "BKC Branch",
      "bank_address": "One BKC, Bandra Kurla Complex",
      "bank_city": "Mumbai",
      "bank_state": "Maharashtra",
      "bank_country": "India",
      "bank_pincode": "400051",
      "routing_number": "RATN0000001"
    }
  }
  ```

  ```json Update Address theme={null}
  {
    "company_details": {
      "registered_address": "New Tower B, IT Park",
      "registered_city": "Pune",
      "registered_state": "Maharashtra",
      "registered_country": "India",
      "registered_pincode": "411057",
      "same_as_registered_address": true,
      "communication_address": "New Tower B, IT Park",
      "communication_city": "Pune",
      "communication_state": "Maharashtra",
      "communication_country": "India",
      "communication_pincode": "411057"
    }
  }
  ```
</CodeGroup>

## Response Examples

<CodeGroup>
  ```json Success theme={null}
  {
    "success": true,
    "message": "Sub-merchant updated successfully",
    "data": {
      "id": "6182929449",
      "company_details": {
        "legal_name": "Acme Technologies Pvt Ltd",
        "brand_name": "AcmeTech Global",
        "email": "new-contact@acmetech.com",
        "phone_number": "+919876500000",
        "registration_number": "U72200MH2020PTC123456",
        "international_org_type": "Private Limited Company",
        "tax_id": "AACCA1234A",
        "website": "https://acmetech-global.com",
        "monthly_avg_transaction_volume": "BETWEEN_50_K_AND_100_K",
        "communication_address": "Tower A, Techpark, Whitefield",
        "communication_city": "Bangalore",
        "communication_state": "Karnataka",
        "communication_country": "India",
        "communication_pincode": "560066",
        "same_as_registered_address": true,
        "registered_address": "Tower A, Techpark, Whitefield",
        "registered_city": "Bangalore",
        "registered_state": "Karnataka",
        "registered_country": "India",
        "registered_pincode": "560066",
        "business_category": "Digital goods / software / downloads,SaaS / subscriptions / recurring billing",
        "business_category_other": null,
        "business_mode": "b2b",
        "hs_codes": [],
        "description_of_products_and_services": "Updated: Enterprise SaaS platform for supply chain management",
        "agreement_details": null
      },
      "settlement_details": {
        "bank_account_number": "9876543210123456",
        "bank_account_name": "AcmeTech Global Pvt Ltd",
        "bank_swift_code": "ABORINBB",
        "bank_name": "RBL Bank",
        "bank_branch_name": "BKC Branch",
        "bank_address": "One BKC, Bandra Kurla Complex",
        "bank_city": "Mumbai",
        "bank_state": "Maharashtra",
        "bank_country": "India",
        "bank_pincode": "400051",
        "routing_number": "RATN0000001",
        "settlement_currency": "USD"
      },
      "kyc_status": "PENDING",
      "created_at": "2026-04-28T06:30:00.000000Z",
      "last_updated_at": "2026-04-28T09:15:00.000000Z"
    }
  }
  ```

  ```json Status Not Editable theme={null}
  {
    "success": false,
    "error": {
      "code": "ERR_MERCHANT_001",
      "message": "Validation error",
      "details": {
        "kyc_status": "Sub-merchant can only be edited in PENDING or CHANGES_REQUESTED status, current status is APPROVED"
      }
    }
  }
  ```

  ```json Validation Error theme={null}
  {
    "success": false,
    "error": {
      "code": "ERR_MERCHANT_001",
      "message": "Validation error",
      "details": {
        "company_details": {
          "website": "Enter a valid URL.",
          "business_mode": "\"invalid\" is not a valid choice."
        }
      }
    }
  }
  ```
</CodeGroup>

## Error Codes

| Code               | Message          | Description                                                        |
| ------------------ | ---------------- | ------------------------------------------------------------------ |
| ERR\_MERCHANT\_001 | Validation error | Request validation failed — check `details` for field-level errors |

## Implementation Notes

### Editable Statuses

Only sub-merchants in these statuses can be updated:

* **PENDING** — Initial state after creation
* **CHANGES\_REQUESTED** — After review, when additional information is needed

Sub-merchants in APPROVED, IN\_REVIEW, or REJECTED status will return a validation error.

### Partial Updates

This endpoint supports partial updates — only send the fields you want to change. Omitted fields retain their current values.

### Address Handling

When `same_as_registered_address` is set to `true`, communication address fields are automatically copied from registered address fields. If you update registered address fields and want communication to match, include `same_as_registered_address: true`.

### Validation

All the same validations from the [Create Merchant](/api-reference/v1/merchant/create) endpoint apply:

* `website` must include `https://` prefix
* `phone_number` must be E.164 format
* `business_category`, `business_mode`, `international_org_type`, `monthly_avg_transaction_volume` must use valid enum values
* `mcc` must be comma-separated 4-digit codes
* `business_category_other` is required when category includes "Other"


## OpenAPI

````yaml PATCH /partners/merchants/{merchant_id}/
openapi: 3.0.0
info:
  title: Eximpe Payment Gateway API
  description: >-
    API for payment processing and order management through Eximpe payment
    gateway. This specification includes v1, v2, and v3 API versions.
  license:
    name: Proprietary
  version: 2.0.0
servers:
  - url: https://api-pacb-uat.eximpe.com
    description: Payment Gateway Sandbox URL
security:
  - clientAuth: []
    clientSecretAuth: []
    apiVersionHeader: []
tags:
  - name: Card Tokens
  - name: Merchants
  - name: Orders
  - name: Payment Links
  - name: Payments
  - name: Refunds
  - name: Settlements
  - name: Subscriptions
paths:
  /partners/merchants/{merchant_id}/:
    patch:
      tags:
        - Merchants
      summary: Update Merchant
      description: Update specific fields of an existing merchant.
      operationId: v1_patch_partners_merchants_merchant_id_
      parameters:
        - name: merchant_id
          in: path
          description: The ID of the merchant to update.
          required: true
          schema:
            type: string
      requestBody:
        description: Merchant update request - only include fields to update
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/v1_UpdateMerchantRequest'
            example:
              company_details:
                legal_name: Shakti Logistics & Exports Pvt Ltd
                brand_name: ShaktiXpress
                registration_number: IN09DEL2021PTC987654
                international_org_type: Private Limited Company
                tax_id: 29AABCT1234D1Z9
                website: https://www.shaktiexpress.in
                monthly_avg_transaction_volume: BETWEEN_20_K_AND_50_K
                business_category: E-commerce (physical goods & cross-border shipping)
                business_mode: b2b
                description_of_products_and_services: >-
                  ShaktiXpress provides export logistics and warehousing
                  services for textile machinery and automotive components
                  across Asia and Europe.
                agreement_details: Master Logistics Agreement valid until 2027-12-31
                communication_address: Plot No. 56, Electronic City Phase 1
                communication_city: Bengaluru
                communication_state: Karnataka
                communication_country: India
                communication_pincode: '560100'
                same_as_registered_address: false
                registered_address: 7th Floor, Sagar Tech Plaza, Andheri-Kurla Road
                registered_city: Mumbai
                registered_state: Maharashtra
                registered_country: India
                registered_pincode: '400072'
                hs_codes:
                  - '85234910'
                  - '84715000'
              settlement_details:
                bank_account_number: '5087654321123456'
                bank_account_name: Shakti Logistics & Exports Pvt Ltd
                bank_swift_code: HDFCINBBXXX
                bank_name: HDFC Bank Ltd.
                bank_branch_name: Andheri East Branch
                bank_address: Unit 3A, Ground Floor, Hiranandani Business Park, Powai
                bank_city: Mumbai
                bank_state: Maharashtra
                bank_country: India
                bank_pincode: '400076'
                routing_number: HDFC0000001
      responses:
        '200':
          description: Merchant updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/v1_UpdateMerchantResponse'
              example:
                success: true
                message: Merchant updated successfully
                data:
                  merchant_id: '3604346598'
                  updated_fields:
                    - company_details
                    - settlement_details
        '400':
          description: Bad request - Invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/v1_ErrorResponse'
        '404':
          description: Merchant not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/v1_ErrorResponse'
      security:
        - clientAuth: []
          clientSecretAuth: []
          apiVersionHeader: []
components:
  schemas:
    v1_UpdateMerchantRequest:
      type: object
      description: Request body for updating merchant - only include fields to update
      properties:
        company_details:
          type: object
          description: Company details to update
          properties:
            legal_name:
              type: string
              description: Updated legal name of the company
            brand_name:
              type: string
              description: Updated brand/trading name of the company
            registration_number:
              type: string
              description: Updated company registration number
            international_org_type:
              type: string
              description: Updated type of international organization
              enum:
                - Private Limited Company
                - Public Limited Company
                - Limited Liability Company
                - Free Zone Company / Entity
                - Partnership / LLP
                - Sole Proprietorship
                - Other
            tax_id:
              type: string
              description: Updated tax identification number
            website:
              type: string
              format: uri
              description: Updated company website URL
            monthly_avg_transaction_volume:
              type: string
              description: Updated average monthly transaction volume
            communication_address:
              type: string
              description: Updated communication address
            communication_city:
              type: string
              description: Updated communication city
            communication_state:
              type: string
              description: Updated communication state
            communication_country:
              type: string
              description: Updated communication country
            communication_pincode:
              type: string
              description: Updated communication pincode/postal code
            same_as_registered_address:
              type: boolean
              description: Updated flag for same as registered address
            registered_address:
              type: string
              description: Updated registered address
            registered_city:
              type: string
              description: Updated registered city
            registered_state:
              type: string
              description: Updated registered state
            registered_country:
              type: string
              description: Updated registered country
            registered_pincode:
              type: string
              description: Updated registered pincode/postal code
            business_category:
              type: string
              description: Updated business category
              enum:
                - E-commerce (physical goods & cross-border shipping)
                - Digital goods / software / downloads
                - SaaS / subscriptions / recurring billing
                - Services (delivered cross-border)
                - Marketplace / platform (multiple sellers)
                - Other
            business_mode:
              type: string
              description: Updated business mode
              enum:
                - b2b
                - b2c
            hs_codes:
              type: array
              items:
                type: string
              description: >-
                Updated Harmonized System codes for products/services, required
                for physical goods
            description_of_products_and_services:
              type: string
              description: Updated description of products and services
            agreement_details:
              type: string
              description: Updated agreement details
        settlement_details:
          type: object
          description: Settlement details to update
          properties:
            bank_account_number:
              type: string
              description: Updated bank account number
            bank_account_name:
              type: string
              description: Updated bank account name
            bank_swift_code:
              type: string
              description: Updated bank SWIFT/BIC code
            bank_name:
              type: string
              description: Updated name of the bank
            bank_branch_name:
              type: string
              description: Updated bank branch name
            bank_address:
              type: string
              description: Updated bank address
            bank_city:
              type: string
              description: Updated bank city
            bank_state:
              type: string
              description: Updated bank state
            bank_country:
              type: string
              description: Updated bank country
            bank_pincode:
              type: string
              description: Updated bank pincode/postal code
            routing_number:
              type: string
              description: Updated bank routing number
    v1_UpdateMerchantResponse:
      type: object
      required:
        - success
        - message
        - data
      properties:
        success:
          type: boolean
          description: Indicates if the request was successful
        message:
          type: string
          description: Response message
        data:
          type: object
          description: Contains the updated merchant fields
          properties:
            merchant_id:
              type: string
              description: The ID of the updated merchant
            updated_fields:
              type: array
              items:
                type: string
    v1_ErrorResponse:
      type: object
      required:
        - success
        - error
      properties:
        success:
          type: boolean
          enum:
            - false
          description: >-
            Indicates if the request was successful. Always false for error
            responses.
        error:
          $ref: '#/components/schemas/v1_ErrorDetails'
    v1_ErrorDetails:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          description: Error code (e.g., ERR_ORDER_002)
        message:
          type: string
          description: Error message
        details:
          type: object
          description: Detailed validation error information with field-specific errors
          additionalProperties:
            type: string
            description: Error message for the specific field
  securitySchemes:
    clientAuth:
      type: apiKey
      name: X-Client-ID
      in: header
      description: >-
        **Client Application ID** - Your unique application identifier used to
        authenticate API requests. You can find your Client ID in the Developer
        Settings section of the merchant dashboard.
      x-displayName: Client ID
      x-example: your-client-id
    clientSecretAuth:
      type: apiKey
      name: X-Client-Secret
      in: header
      description: >-
        **Client Secret Key** - Your secret key used alongside the Client ID for
        secure authentication. Keep this confidential and never expose it in
        client-side code. Available in the Developer Settings section of the
        merchant dashboard.
      x-displayName: Client Secret
      x-example: your-client-secret
    apiVersionHeader:
      type: apiKey
      name: X-API-Version
      in: header
      description: >-
        **API Version** - Specifies which version of the API to use (e.g.,
        '1.X.X', '2.X.X', or '3.X.X'). This header allows you to control which
        API version your integration uses. Default version information is
        available in the Developer Settings.
      x-displayName: API Version
      x-example: 3.0.0

````