1. Hosted Payment Page
ANexPay Docs
  • Introduction
  • Signature
  • API Keys
  • Get Started
  • Webhook Service
  • Enum Reference
  • Api Reference
    • Authentication
      • Get Auth Token
    • Hosted Payment Page
      • Hosted Payment Page
        POST
    • CreditCardPay
      • List Payment History
      • Get Payment Detail
      • Refund
      • List Subscriptions
      • Get Subscription Detail
      • Cancel Subscription
      • Get Subscription Bills
    • StableCoinPay
      • order
        • GetCheckoutOrderList
      • refund-order
        • CreateRefundOrder
        • CancelRefundOrder
        • GetRefundOrderInfo
        • GetRefundOrderList
      • settlement
        • CreateFiatSettlementOrder
        • CancelSettlementOrder
        • GetSettlementOrderList
      • abnormal-payment
        • GetAbnormalPaymentList
        • CreateAbnormalPaymentRefund
  • Schemas
    • Schemas
      • RefundOrderDTO
      • RefundPageReq
      • ApiPageApiPageRefundOrderDTO
      • ApiResponseApiPageRefundOrderDTO
      • CancelReq
  1. Hosted Payment Page

Hosted Payment Page

Developing
POST
/checkout/hpp/create-session
Initiates a hosted payment page (HPP) session. Supports both one-time and subscription payments. Returns a redirectUrl for the customer to complete payment.

Request

Body Params application/jsonRequired

Examples
{
  "orderNo": "TEST109",
  "amount": 0.1,
  "currency": "USD",
  "customerId": "user_1",
  "expiredIn": 3600,
  "payMode": "ONETIME",
  "successUrl": "https://www.google.com.hk/?hl=zh-CN",
  "cancelUrl": "https://www.google.com.hk/?hl=zh-CN"
}

Responses

🟢200成功
application/json
Bodyapplication/json

Example
{
  "retcode": "200",
  "retmsg": "success",
  "retdata": {
    "trxNo": "TRX1714012345678",
    "mchOrderNo": "ORD-20240423-001",
    "status": 1,
    "amount": 99.99,
    "redirectUrl": null
  }
}
Modified at 2026-06-03 07:54:01
Previous
Get Auth Token
Next
List Payment History
Built with