GetSettlement

GET /settlement/{merchant}

Merchant query settlement data.

Path parameters

  • merchant string Required

    Merchant name to payment company, e.g. wechat.sh_smk

Query parameters

  • profit_order_no string Required

    The settlement order no of the merchant, shall be unique within merchant system

  • transaction_id string Required

    Payment system internal order number

  • Must be wechatpay or alipay

    Values are wechatpay or alipay.

Responses

  • 200

    Query a settlement order successfully.

    Hide response attributes Show response attributes object
    • code integer(int32)
    • message string | null

      Response message

    • outOrderNo string | null

      The profit sharing number of the merchant

    • transactionId string | null

      Transaction ID of payment company

    • orderId string | null

      Payment system order number, the unique identifier returned by the payment system

    • status string | null

      Profit sharing order status

      Values are PROCESSING or FINISHED.

    • receivers array[object] | null

      Receivers of the profit sharing

      Hide receivers attributes Show receivers attributes
      • type string

        Receiver type of profit sharing. MERCHANT_ID: merchants, PERSONAL_OPENID: personal. PERSONAL_OPENID is not available

        Values are MERCHANT_ID or PERSONAL_OPENID.

      • The receiver account.

      • name string

        The receiver account.

      • amount integer(int32)

        The amount of account allocation, in cent, cannot exceed the payment amount of the original order and the maximum proportion of account allocation

      • Payment method, must be wechatpay or alipay

        Values are wechatpay or alipay.

      • The description of profit sharing.

      • Merchant ID of receiver.

      • result string | null

        Profit sharing order result

        Values are PENDING, SUCCESS, REFUND, or CLOSED.

      • The finish time of profit sharing with the rfc3339 standard format.

      • The failed reason of profit sharing.

        Values are ACCOUNT_ABNORMAL, NO_RELATION, or RECEIVER_HIGH_RISK.

      • detailId string

        Profit sharing detailed order number, which can be used for reconciliation with the fund bill.

    • finishDescription string | null

      Description of the end of the profit sharing

    • finishAmount integer | null

      The amount of the end of the profit sharing, in cent

  • 400

    Request validation failure

    Hide response attributes Show response attributes object
  • 401

    Not Authenticated.

    Hide response attributes Show response attributes object
  • 500

    Something wrong when query the payout.

    Hide response attributes Show response attributes object
GET /settlement/{merchant}
curl \
 -X GET https://nomad.samarkand-global.cn/broker/v1/settlement/wechat.sh_smk?profit_order_no=string&transaction_id=string \
 -H "app-api-key: $API_KEY"
Response examples (200)
{
  "code": 200,
  "message": "success",
  "outOrderNo": "string",
  "transactionId": "transaction_id_123",
  "orderId": "string",
  "status": "FINISHED",
  "receivers": [
    {
      "type": "MERCHANT_ID",
      "receiverAccount": "1900000109",
      "name": "1900000109",
      "amount": 12,
      "paymentMethod": "wechatpay",
      "description": "分帐1900000110",
      "receiverMchid": "Orange",
      "result": "SUCCESS",
      "finishTime": "2015-05-20T13:29:35.120+08:00",
      "failReason": "NO_RELATION",
      "detailId": "3601111111111111111111"
    }
  ],
  "finishDescription": "string",
  "finishAmount": 88
}
Response examples (400)
{
  "code": 200,
  "message": "success"
}
Response examples (401)
{
  "code": 200,
  "message": "success"
}
Response examples (500)
{
  "code": 200,
  "message": "success",
  "errors": "Something wrong when making the service."
}