> ## 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.

# Query Deduction Order Details

> Query deduction order details

## Overview

This page documents the `GET /open/v1/deduction/order/detail` endpoint. The full schema, parameters, and examples are rendered from the linked OpenAPI definition above.

## Notes

* Authentication uses the standard GatePay signed headers.
* This page documents the standard merchant endpoint.
* 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/subscription/deductionOrderDetail-openapi.json GET /open/v1/deduction/order/detail
openapi: 3.1.0
info:
  title: GatePay API
  description: GatePay Payment Platform API Documentation
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://openplatform.gateapi.io/pay-subscription
security: []
paths:
  /open/v1/deduction/order/detail:
    get:
      summary: Query Deduction Order Detail
      description: Query deduction order details
      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/deductionDetail_paymentOrderNo'
        - $ref: '#/components/parameters/deductionDetail_merchantDeductNo'
      responses:
        '200':
          description: Query deduction order details successful
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateSubscriptionPlanResponse'
              examples:
                successResponse:
                  summary: Success Response
                  value:
                    code: '0'
                    message: ''
                    data:
                      subscriptionOrderNo: '70778338049917032'
                      merchantSubscriptionOrderNo: rhys-81
                      planNo: '70778338049916930'
                      paymentOrderNo: '70778338049917033'
                      txHash: >-
                        0x658d3a403a4d6879dfd94229270a13e04249b50020ead15f6b7dceeb11286aee
                      merchantId: '10002'
                      cryptoCurrency: USDT
                      chain: BSC
                      userAddress: '0xbe6D780C23E77D979Fad5FbEa249a44E5cAC0463'
                      merchantAddress: '0xeEfAe46E6551E54879C80C16882f745c25361473'
                      cryptoAmount: '0.01000000'
                      isDiscounted: false
                      authorizeWalletAddress: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb0'
                      merchantDeductNo: ''
                      description: null
                      errMsg: ''
                      payTime: 1773989575000
                      payStatus: SUCCESS
                      totalFeeAmount: '0'
                      totalSettleAmount: ''
                      payDetails: []
                    success: true
components:
  parameters:
    X-GatePay-Certificate-ClientId:
      name: X-GatePay-Certificate-ClientId
      in: header
      required: true
      description: Merchant client ID, obtained from GatePay platform application
      schema:
        type: string
        example: 4186d0c6-6a35-55a9-8dc6-5312769dbff8
    X-GatePay-Signature:
      name: X-GatePay-Signature
      in: header
      required: true
      description: HMAC-SHA256 signature, used to verify request legitimacy
      schema:
        type: string
        example: >-
          672d5650dcc9bb22ebf25fa16c28d03c0e159d742a9176d4340a5da326d75dc8a2ec24c97fa6fc5d1533dd6e968863747e1d86a45e562cbe899f9ed7e9ca7f77
    X-GatePay-Timestamp:
      name: X-GatePay-Timestamp
      in: header
      required: true
      description: >-
        Timestamp (milliseconds), time difference with server cannot exceed 5
        minutes
      schema:
        type: string
        example: '1672905655498'
    X-GatePay-Nonce:
      name: X-GatePay-Nonce
      in: header
      required: true
      description: Random number, used to prevent replay attacks
      schema:
        type: string
        example: '9578'
    deductionDetail_paymentOrderNo:
      name: paymentOrderNo
      in: query
      required: false
      description: >-
        Order number for subscription deduction At least one of paymentOrderNo
        or merchantDeductNo is required
      schema:
        type: string
    deductionDetail_merchantDeductNo:
      name: merchantDeductNo
      in: query
      required: false
      description: >-
        Merchant deduction reference (choose one with paymentOrderNo) At least
        one of paymentOrderNo or merchantDeductNo is required
      schema:
        type: string
  schemas:
    CreateSubscriptionPlanResponse:
      type: object
      properties:
        code:
          type: string
          description: Response code, 0 indicates success
          example: '0'
        message:
          type: string
          description: Response description, empty when successful
          example: ''
        success:
          type: boolean
          description: Whether the request was successful
          example: true
        data:
          type: object
          description: Response data
          properties:
            subscriptionOrderNo:
              type: string
              description: Subscription order number
            merchantSubscriptionOrderNo:
              type: string
              description: Merchant subscription order number
            planNo:
              type: string
              description: Subscription plan number
            paymentOrderNo:
              type: string
              description: Order number for subscription deduction
            txHash:
              type: string
              description: On-chain transaction ID
            merchantId:
              type: string
              description: Merchant number who created the subscription plan
            cryptoCurrency:
              type: string
              description: Cryptocurrency type
            chain:
              type: string
              description: Cryptocurrency network
            userAddress:
              type: string
              description: User payment on-chain address
            merchantAddress:
              type: string
              description: Address for platform to receive deduction
            cryptoAmount:
              type: string
              description: Single deduction amount
            isDiscounted:
              type: boolean
              description: Whether it's a special price deduction
            authorizeWalletAddress:
              type: string
              description: Authorized contract wallet address
            merchantDeductNo:
              type: string
              description: Merchant deduction order number
            description:
              type: string
              description: Deduction description
            errMsg:
              type: string
              description: Failure reason; returned on failure, usually empty on success
            payTime:
              type: integer
              format: int64
              description: Time when deduction order was created
            payStatus:
              type: string
              description: 'Deduction status: SUCCESS/FAIL/BLOCK'
            totalFeeAmount:
              type: string
              description: >-
                Cumulative fees charged. May be empty or `0` when payment flows
                are not settled, unpaid, or in centralized-payment-only
                scenarios, etc.
            totalSettleAmount:
              type: string
              description: >-
                Cumulative settled amount. May be empty when payment flows are
                not settled, etc.
            payDetails:
              type: array
              description: Payment information
              items:
                $ref: '#/components/schemas/OrderQueryPayDetail'
    OrderQueryPayDetail:
      type: object
      description: >-
        Fee and settlement information for a single payment in the flow
        (payDetail).
      properties:
        transactionId:
          type: string
          description: Payment flow / transaction ID.
        payType:
          type: string
          description: 'Payment type: `GatePay` for Gate Pay, `Web3Pay` for Web3 payment.'
        payTime:
          type: string
          description: Payment time.
        payAmount:
          type: string
          description: Payment amount.
        payCurrency:
          type: string
          description: Payment currency
        feeAmount:
          type: string
          description: Fee amount.
        settleAmount:
          type: string
          description: Settled amount.
        settlementStatus:
          type: string
          description: 'Settlement status: `pending` not settled, `done` settled.'

````