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

# Get Fee Rule Configuration Detail

> Returns the effective configuration for a sub-account at a specified time. If omitted, the current effective configuration is returned.

## Overview

This page documents the institution-only API that returns the effective fee-setting snapshot for a sub-account at a specified time. Full fields, request parameters, and examples are rendered from the OpenAPI definition above.

## Notes

* Query the effective configuration for a sub-account at a specified time. If no time is provided, the current effective configuration is returned.
* It uses `X-GatePay-MerchantId` to identify the main-merchant context and does not use `X-GatePay-On-Behalf-Of`.
* For shared signing rules, see [/api-reference/version/100/en/common/securityAndSignature](/api-reference/version/100/en/common/securityAndSignature).


## OpenAPI

````yaml /api-reference/version/100/en/openapi/institution-fee-settings-openapi.json GET /rate/commission_rule
openapi: 3.1.0
info:
  title: GatePay Institution Fee Settings API
  version: 1.0.0
  description: >-
    Dedicated institution APIs for querying, creating, upgrading, and listing
    sub-account markup fee rules. Paths and business fields remain unchanged;
    only documentation naming and organization are improved.
servers:
  - url: https://openplatform.gateapi.io
    description: Production
security: []
tags:
  - name: Fee Settings
    description: Markup-based fee setting APIs for institution sub-accounts.
paths:
  /rate/commission_rule:
    get:
      tags:
        - Fee Settings
      summary: Get Fee Rule Configuration Detail
      description: >-
        Returns the effective configuration for a sub-account at a specified
        time. If omitted, the current effective configuration is returned.
      parameters:
        - $ref: '#/components/parameters/X-GatePay-Certificate-ClientId'
        - $ref: '#/components/parameters/X-GatePay-Signature'
        - $ref: '#/components/parameters/X-GatePay-Timestamp'
        - $ref: '#/components/parameters/X-GatePay-Nonce'
        - $ref: '#/components/parameters/X-GatePay-MerchantId'
        - $ref: '#/components/parameters/sub_merchant_id'
        - $ref: '#/components/parameters/effective_date_query'
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/StandardSuccessEnvelope_CommissionRuleQueryData
              examples:
                success:
                  summary: Success example
                  value:
                    status: SUCCESS
                    code: '000000'
                    errorMessage: ''
                    data:
                      sub_merchant_id: '123456789'
                      has_markup: true
                      config_id: cfg_202604150001
                      r_markup: 0.001
                      f_markup: 0
                      status: EFFECTIVE
                      effective_date: '2026-04-15 00:00:00'
                      expired_date: null
                      actual_rate:
                        r_total: 0.0035
                        f_total: 1
                      updated_at: '2026-04-15T08:30:00Z'
components:
  parameters:
    X-GatePay-Certificate-ClientId:
      name: X-GatePay-Certificate-ClientId
      in: header
      required: true
      description: Application ClientId.
      schema:
        type: string
      example: your_client_id
    X-GatePay-Signature:
      name: X-GatePay-Signature
      in: header
      required: true
      description: HMAC-SHA512 signature generated with the Payment API Secret.
      schema:
        type: string
      example: generated_signature
    X-GatePay-Timestamp:
      name: X-GatePay-Timestamp
      in: header
      required: true
      description: UTC timestamp in milliseconds.
      schema:
        type: string
      example: '1713433200000'
    X-GatePay-Nonce:
      name: X-GatePay-Nonce
      in: header
      required: true
      description: Random nonce used for replay protection.
      schema:
        type: string
      example: fee-setting-001
    X-GatePay-MerchantId:
      name: X-GatePay-MerchantId
      in: header
      required: true
      description: >-
        Main merchant ID. This header identifies the institution main-merchant
        context for this fee-setting API set.
      schema:
        type: string
      example: main_merchant_123456
    sub_merchant_id:
      name: sub_merchant_id
      in: query
      required: true
      description: Sub-account ID.
      schema:
        type: string
      example: '123456789'
    effective_date_query:
      name: effective_date
      in: query
      required: false
      description: >-
        Query time in `YYYY-MM-DD HH:mm:ss` format. If omitted, the current
        effective configuration is returned.
      schema:
        type: string
      example: '2026-04-15 00:00:00'
  schemas:
    StandardSuccessEnvelope_CommissionRuleQueryData:
      type: object
      properties:
        status:
          $ref: '#/components/schemas/ApiEnvelopeStatus'
        code:
          type: string
          description: Business result code.
          example: '000000'
        errorMessage:
          type: string
          description: Error message. Empty string on success.
          example: ''
        data:
          $ref: '#/components/schemas/CommissionRuleQueryData'
    ApiEnvelopeStatus:
      type: string
      description: API processing status.
      enum:
        - SUCCESS
        - FAIL
    CommissionRuleQueryData:
      type: object
      properties:
        sub_merchant_id:
          type: string
          description: Sub-account ID.
          example: '123456789'
        has_markup:
          type: boolean
          description: >-
            Whether a markup is configured. `false` means the sub-account
            inherits the main-account rate.
          example: true
        config_id:
          type: string
          nullable: true
          description: Configuration ID. May be null when no rule is configured.
          example: cfg_202604150001
        r_markup:
          type: number
          nullable: true
          description: Percentage markup. `null` when no markup is configured.
          example: 0.001
        f_markup:
          type: number
          nullable: true
          description: Fixed markup amount in USDT. `null` when no markup is configured.
          example: 0
        status:
          $ref: '#/components/schemas/FeeRuleStatus'
        effective_date:
          type: string
          description: >-
            Effective time of this configuration version, in `yyyy-MM-dd
            HH:mm:ss` format.
          example: '2026-04-15 00:00:00'
        expired_date:
          type: string
          nullable: true
          description: Expiration time. `null` when the rule is open-ended.
          example: null
        updated_at:
          type: string
          description: Last updated time in ISO8601.
          example: '2026-04-15T08:30:00Z'
    FeeRuleStatus:
      type: string
      description: Fee rule status.
      enum:
        - EFFECTIVE
        - PENDING_EFFECTIVE
        - EXPIRED

````