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

# 查詢交易狀態

> 查詢指定交易序號的狀態

<Accordion title="此 API 可能返回的錯誤代碼">
  | 代碼   | 說明      |
  | ---- | ------- |
  | 2    | 無效參數    |
  | 10   | 交易序號重複  |
  | 15   | 交易序號不存在 |
  | 36   | 伺服器錯誤   |
  | 9999 | 未知錯誤    |
</Accordion>


## OpenAPI

````yaml /transfer-openapi.json GET /api/v1/dt/transactions
openapi: 3.1.0
info:
  title: 轉帳錢包 API
  description: Game-API 用於 vendor 向遊戲取得遊戲相關數據
  version: 1.0.0
servers:
  - url: https://api.example.com
    description: Production server
security: []
paths:
  /api/v1/dt/transactions:
    get:
      tags:
        - Report API
      summary: 查詢交易狀態
      description: 查詢指定交易序號的狀態
      operationId: queryTransactionStatus
      parameters:
        - name: uuid
          in: query
          required: true
          schema:
            type: string
          description: 各平台自定義的唯一性請求序號，長度 >= 32 且 <= 128 字節
        - name: platform_id
          in: query
          required: true
          schema:
            type: string
          description: 平台方的產品 ID
        - name: transaction_id
          in: query
          required: true
          schema:
            type: string
          description: 交易序號 (長度 1~128 字元，僅允許 ASCII 32-126 可列印字元，禁止使用 ` 和 ~)
        - name: key
          in: query
          required: true
          schema:
            type: string
          description: md5(transaction_id + 平台密鑰)
      responses:
        '200':
          description: 成功
          content:
            application/json:
              schema:
                type: object
                properties:
                  transaction_id:
                    type: string
                    description: 交易序號
                  username:
                    type: string
                    description: 玩家帳號
                  type:
                    type: integer
                    description: '交易類型，請參閱附錄 : 交易類型一覽'
                  amount:
                    type: string
                    description: 交易金額
                  timestamp:
                    type: integer
                    description: 交易時間戳記
              example:
                transaction_id: TXN123456789
                username: player001
                type: 14
                amount: '10000'
                timestamp: 1763022853
        '400':
          description: 錯誤
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error:
                  code: 2
                  msg: >-
                    request hash signature(0FACF22B9E3DB5CDC670A0F7A65BB76A) is
                    error
                  uuid: 9e96610f-5388-42df-b3ed-ba1b3178c63b
components:
  schemas:
    Error:
      type: object
      properties:
        code:
          type: string
          description: 錯誤代碼
        message:
          type: string
          description: 錯誤訊息
        data:
          description: 資料（通常為 null）
        status_code:
          type: integer
          description: HTTP 狀態碼
        service:
          type: string
          description: 服務名稱

````