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

# Get Merchant Configuration

> This endpoint returns the merchant's gift card configuration for UI rendering.

This endpoint retrieves the merchant's gift card configuration, including settings for external purchase links and card background styling. Use this information to customize how gift cards are displayed in your application and to provide users with links to purchase new gift cards.

<Info>
  This configuration is useful for rendering gift card purchase buttons and customizing the appearance of gift cards in your UI.
</Info>

<Note>
  Please review proper request headers [here](/consumer/usage/headers).
</Note>

### Response

<Snippet file="entities/gift-card-merchant-config.mdx" />

<RequestExample>
  ```bash Get Merchant Configuration theme={null}
  curl https://api.thanxsandbox.com/gift_cards/merchant_config \
    -X GET \
    -H "Content-Type: application/json"  \
    -H "Accept-Version: v4.0" \
    -H "Accept: application/json" \
    -H "Authorization: Bearer ${token}" \
    -H "X-ClientId: ${client_id}"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "merchant_config": {
      "id": "abc123def456ghi789j",
      "state": "active",
      "external_link": {
        "enabled": true,
        "url": "https://example.com/buy-gift-card",
        "image": {
          "small": "https://example.com/images/gift-card-button-2x.png",
          "large": "https://example.com/images/gift-card-button-3x.png",
          "default": "https://example.com/images/gift-card-button-2x.png"
        }
      },
      "card_background": {
        "color": "#1E88E5",
        "type": "image",
        "image": {
          "small": "https://example.com/images/card-bg-2x.png",
          "large": "https://example.com/images/card-bg-3x.png",
          "default": "https://example.com/images/card-bg-2x.png"
        }
      }
    }
  }
  ```

  ```json 404 Not Found theme={null}
  {
    "error": {
      "message": "Gift card merchant configuration not found"
    }
  }
  ```
</ResponseExample>
