- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (JSON) {long} time UTC时间戳
- * @apiParam (JSON) {String} nonce_str 随机字符串
- * @apiParam (JSON) {String} sign 签名
- * @apiParam (JSON) {String} partner_order_id 商户订单ID
- * @apiParam (JSON) {String} channel_order_id 渠道方(支付宝、微信)交易流水号
- * @apiParam (JSON) {String} order_id RoyalPay订单ID
- * @apiParam (JSON) {int} total_fee 订单金额,单位是最小货币单位
- * @apiParam (JSON) {int} real_fee 支付金额,单位是最小货币单位
- * @apiParam (JSON) {Double} rate 交易时使用的汇率,1AUD=?CNY
- * @apiParam (JSON) {String} currency 币种,AUD
- * @apiParam (JSON) {String} channel 支付渠道 Alipay|支付宝、AlipayOnline|支付宝线上、Wechat|微信、Bestpay|翼支付
- * @apiParam (JSON) {String} create_time 订单创建时间,格式为'yyyy-MM-dd HH:mm:ss',GMT+10
- * @apiParam (JSON) {String} pay_time 订单支付时间,格式为'yyyy-MM-dd HH:mm:ss',GMT+10
- *
- * @apiSuccess {String} return_code SUCCESS
- */
-/**
- * @api {PUT} /api/v1.0/jd_gateway/partners/{partner_code}/orders/{order_id} 创建京东Web订单
- * @apiName JDAPI
- * @apiDescription
- * 用于PC端京东支付,创建订单后跳转到返回的pay_url(需附加签名参数和redirect参数),随后进入京东支付页面完成支付
- * 该接口仅现仅支持京东支付。
- *
- * @apiVersion 1.0.0
- * @apiGroup JD_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {String} user_id 必填,商户平台用户的唯一账号
- * @apiParam (JSON) {String} mobile 必填,商户平台用户的手机号
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD 币种代码
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,同时也是支付渠道订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} pay_url 跳转URL
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/microapp_orders/{order_id} 创建小程序订单
- * @apiName microapp
- * @apiDescription
- * 接入微信小程序需完成海外主体认证,并且认证主体需要与在RoyalPay开通的商户主体一致。具体如何认证请查看微信公众平台相关文档。
- * 用于小程序中发起支付,创建订单后返回小程序支付所需参数,该接口现仅支持微信小程序。
- * 接入参考文档
- *
- *
- * @apiVersion 1.0.0
- * @apiGroup Miniprogram_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD 币种代码
- * @apiParam (JSON) {String=Alipay,Wechat} channel=Wechat 支付通道,微信小程序只能调用微信渠道,支付宝小程序只能调用支付宝渠道
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- * @apiParam (JSON) {String} appid 小程序appid(接入微信小程序必填,支付宝不需要)
- * @apiParam (JSON) {String} customer_id 小程序获取的用户id(微信为openid,支付宝为userid)
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,同时也是支付渠道订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} sdk_params 小程序支付所需参数(Json字符串)
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-
-
-/**
- * @api {PUT} /api/v1.0/alipay/partners/{partner_code}/orders/{order_id} 创建支付宝Web订单
- * @apiName AlipayOnline
- * @apiDescription
- * 用于PC端支付宝支付,创建订单后跳转到返回的pay_url(需附加签名参数和redirect参数),随后进入支付宝支付页面完成支付
- * 该接口现仅支持支付宝。
- *
- * @apiVersion 1.0.0
- * @apiGroup Alipay_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD 币种代码
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,同时也是支付渠道订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} pay_url 跳转URL
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/app_orders/{order_id} 创建SDK订单
- * @apiName SDK
- * @apiDescription
- * 用于移动端APP调用微信SDK支付,调用API创建订单,得到微信SDK调用参数,将参数传递给SDK拉起微信支付,并由微信客户端直接返回支付结果。
- * 强烈建议获得支付结果后再调用RoyalPay订单查询API确认完成支付后再进行后续流程,避免因超时自动撤单导致资金损失
- *
- * 关于客户端和支付宝整合的更多信息: 支付宝SDK文档
- * 关于客户端和微信整合的更多信息: 微信SDK文档
- * Alipay SDK for Android
- * Alipay SDK for iOS
- * Wechat SDK for Android
- * Wechat SDK for iOS
- *
- * @apiVersion 1.0.0
- * @apiGroup SDKPayment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD 币种代码
- * @apiParam (JSON) {String=Alipay,Wechat} channel 支付渠道,必填,大小写敏感
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- * @apiParam (JSON) {String=android,iphone,ipad} system 客户端操作系统类型,支付宝通道可选,微信不需要
- * @apiParam (JSON) {String} version 客户端版本号,支付宝通道可选,微信不需要
- * @apiParam (JSON) {String} appid 微信 appid,微信通道要求必填
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,同时也是支付渠道订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} sdk_params 调用SDK的参数字符串
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/hf_gateway/partners/{partner_code}/orders/{orderId} 创建汇付Web订单
- * @apiName hfapi
- * @apiDescription
- * 用于PC端汇付通支付,创建订单后跳转到返回的pay_url,随后进入汇付通支付页面完成支付
- * 该接口仅现仅支持汇付通支付。
- *
- * @apiVersion 1.0.0
- * @apiGroup HF_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {String} mobile 必填,商户平台用户的手机号
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String} product_id 必填,商品类别代码 * 商品类别代码
- * @apiParam (JSON) {String} product_name 必填 商品名称
- * @apiParam (JSON) {String} product_count 商品数量
- * @apiParam (JSON) {String=AUD} currency=AUD 币种代码(当前仅支持AUD)
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,同时也是支付渠道订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} pay_url 跳转URL
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-/**
- * @api {PUT} /api/v1.0/cb_bankpay/partners/{partner_code}/orders/{order_id} 创建网银快捷支付订单
- * @apiName cbbankpayapi
- * @apiDescription
- * 用于PC端网银快捷支付,创建订单后跳转到返回的pay_url,随后进入网银快捷支付页面完成支付
- *
- * @apiVersion 1.0.0
- * @apiGroup CB_BankPay
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4位大写字母或数字构成
- * @apiParam (PathVariable) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} description 必填,订单标题(最大长度128字符,超出自动截取)
- * @apiParam (JSON) {int} price 必填,金额,单位为货币最小单位,例如使用100表示AUD1.00
- * @apiParam (JSON) {String} product_name 必填 商品名称
- * @apiParam (JSON) {int} gateway_type 必填,8:跳转H5网关,9:跳转PC网关
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD 币种代码(若商户选择的通道为拉卡拉则只支持AUD)
- * @apiParam (JSON) {String} notify_url 支付通知url,详见支付通知api,不填则不会推送支付通知
- * @apiParam (JSON) {String} operator 操作人员标识
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} result_code SUCCESS表示创建订单成功,EXISTS表示订单已存在
- * @apiSuccess {String} partner_code 商户编码
- * @apiSuccess {String} full_name 商户注册全名
- * @apiSuccess {String} partner_name 商户名称
- * @apiSuccess {String} order_id RoyalPay订单ID,最终支付成功的订单ID可能不同
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} channel 支付渠道
- * @apiSuccess {String} pay_url 跳转URL
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- * @apiError (ERROR_CODE) ORDER_PAID 订单已支付
- *
- */
-/**
- * @api {PUT} /api/v1.0/customs/partners/{partner_code}/declare/report/{client_report_id} 创建报关单
- * @apiName declare_report
- * @apiDescription
- * 用于商户提交海关需要的订单附件信息。仅支持微信和支付宝,微信只支持一个月内的支付订单进行报关申请。
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4-6位大写字母或数字构成
- * @apiParam (PathVariable) {String} client_report_id 必填,商户申请报关单号,要求同一商户唯一
- * @apiUse Sign
- * @apiParam (JSON) {String} order_id 必填,商户支付订单号,要求同一商户唯一
- * @apiParam (JSON) {String} custom 必填,海关编号 * 渠道海关编号
- * @apiParam (JSON) {String} mch_custom_id 必填,商户在海关备案的编号
- * @apiParam (JSON) {String} mch_custom_name 必填,商户海关备案名称
- * @apiParam (JSON) {JSON[]} sub_order 子订单(拆单)
- *
- * @apiParam (SUB_JSON) {String} sub_order_no 商户子订单号
- * @apiParam (SUB_JSON) {String=CNY} fee_type=CNY 币种代码
- * @apiParam (SUB_JSON) {Double} order_fee 子订单金额
- * @apiParam (SUB_JSON) {Double} transport_fee 子订单物流金额
- *
- * @apiSuccess {String} report_id RoyalPay海关单号
- * @apiSuccess {String} client_report_id 商户申请报关单号
- * @apiSuccess {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} channel 支付渠道
- * @apiSuccess {String} custom 海关编号
- * @apiSuccess {String} mch_custom_no 商户在海关备案的编号
- * @apiSuccess {String} mch_custom_name 商户海关备案名称
- * @apiSuccess {String} order_id RoyalPay订单号
- * @apiSuccess {String} transaction_id 支付渠道订单号
- * @apiSuccess {String} order_currency 币种
- * @apiSuccess {Double} order_amount 订单金额
- * @apiSuccess {String} report_time 报关时间
- * @apiSuccess {String} creation_date 报关单创建时间
- * @apiSuccess {String} last_update_date 更新时间
- * @apiSuccess {String} error_code 错误代码
- * @apiSuccess {String} error_msg 错误返回的信息描述
- * @apiSuccess {String} verify_department 验核机构
- * @apiSuccess {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess {JSON[]} sub_orders 拆单信息(可能返回多个)
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no 商户子订单号
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY 币种代码
- * @apiSuccess (SUB_JSON) {Double} order_fee 子订单金额
- * @apiSuccess (SUB_JSON) {Double} transport_fee 子订单物流金额
- * @apiSuccess (SUB_JSON) {String} verify_department 验核机构
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess (SUB_JSON) {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code 错误代码
- * @apiSuccess (SUB_JSON) {String} error_msg 错误返回的信息描述
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/customs/partners/{partner_code}/redeclare/report/{client_report_id} 重新提交报关单
- * @apiName redeclare_report
- * @apiDescription
- * 用于重新提交未报关成功的报关单
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4-6位大写字母或数字构成
- * @apiParam (PathVariable) {String} client_report_id 必填,商户申请报关单号,要求同一商户唯一
- * @apiUse Sign
- *
- * @apiSuccess {String} report_id RoyalPay海关单号
- * @apiSuccess {String} client_report_id 商户申请报关单号
- * @apiSuccess {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} channel 支付渠道
- * @apiSuccess {String} custom 海关编号
- * @apiSuccess {String} mch_custom_no 商户在海关备案的编号
- * @apiSuccess {String} mch_custom_name 商户海关备案名称
- * @apiSuccess {String} order_id RoyalPay订单号
- * @apiSuccess {String} transaction_id 支付渠道订单号
- * @apiSuccess {String} order_currency 币种
- * @apiSuccess {Double} order_amount 订单金额
- * @apiSuccess {String} report_time 报关时间
- * @apiSuccess {String} creation_date 报关单创建时间
- * @apiSuccess {String} last_update_date 更新时间
- * @apiSuccess {String} error_code 错误代码
- * @apiSuccess {String} error_msg 错误返回的信息描述
- * @apiSuccess {String} verify_department 验核机构
- * @apiSuccess {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess {JSON[]} sub_orders 拆单信息(可能返回多个)
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no 商户子订单号
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY 币种代码
- * @apiSuccess (SUB_JSON) {Double} order_fee 子订单金额
- * @apiSuccess (SUB_JSON) {Double} transport_fee 子订单物流金额
- * @apiSuccess (SUB_JSON) {String} verify_department 验核机构
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess (SUB_JSON) {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code 错误代码
- * @apiSuccess (SUB_JSON) {String} error_msg 错误返回的信息描述
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- *
- */
-/**
- * @api {GET} /api/v1.0/customs/partners/{partner_code}/declare/query/{client_report_id} 查询报关单
- * @apiName declare_query
- * @apiDescription
- * 用于商户查询报关单号的状态。
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code 必填,商户编码,由4-6位大写字母或数字构成
- * @apiParam (PathVariable) {String} client_report_id 必填,商户申请报关单号,要求同一商户唯一
- * @apiUse Sign
- *
- * @apiSuccess {String} return_code 执行结果
- * @apiSuccess {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} report_id RoyalPay海关单号
- * @apiSuccess {String} client_report_id 商户申请报关单号
- * @apiSuccess {String} return_msg 错误描述,仅在执行结果不为SUCCESS情况下出现
- * @apiSuccess {String} order_id RoyalPay订单号
- * @apiSuccess {String} partner_order_id 商户订单ID
- * @apiSuccess {String} verify_department 验核机构
- * @apiSuccess {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess {JSON[]} sub_orders 拆单信息(可能返回多个)
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no 商户子订单号
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY 币种代码
- * @apiSuccess (SUB_JSON) {Double} order_fee 子订单金额
- * @apiSuccess (SUB_JSON) {Double} transport_fee 子订单物流金额
- * @apiSuccess (SUB_JSON) {String} verify_department 验核机构
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id 验核机构交易流水号
- * @apiSuccess (SUB_JSON) {String} report_status 报关单状态: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code 错误代码
- * @apiSuccess (SUB_JSON) {String} error_msg 错误返回的信息描述
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH 订单号与商户不匹配
- *
- */
-function apis() {
-
-}
diff --git a/src/document/cn/overview.md b/src/document/cn/overview.md
deleted file mode 100644
index 0b63621c3..000000000
--- a/src/document/cn/overview.md
+++ /dev/null
@@ -1,97 +0,0 @@
-# Overview
-
-## 域名
-
-#### 生产环境
-[https://mpay.royalpay.com.au/](https://mpay.royalpay.com.au/)
-
-## 请求方式和参数格式
-
-支付单和退款单提交均为PUT方式,订单查询均为GET方式;包含Request Entity的请求参数格式为json
-
-除跳转页面外,所有的Accept均为application/json;所有的PUT/POST请求Content-Type为application/json
-
-系统使用UTF-8字符集
-
-参数分为三种:Path Variable/Query Param/JSON entity
-+ PathVariable:包含在URI内的参数
-+ Query Param:在URI末尾?后的key=value形式的参数
-+ JSON entity:只在PUT/POST请求中使用
-
-所有返回JSON的API,成功访问返回状态值均为200(不论执行结果)。JSON固定包含字段return_code,若值为SUCCESS则表示执行成功;
-其他值表示执行失败,此时可查询错误码了解对应的错误类型,此时还会携带return_msg字段作为错误描述信息
-
-## 多语言支持
-
-系统错误提示支持中文、英文两种语言,默认根据Request Header中的Accept-Language值自动选择,如需调整亦可以添加locale cookie进行指定。
-
-## 选择接入API
-
-
-
-## 支付宝渠道区分
-
-支付宝根据调用接口不同分为线上和线下两个渠道,两个渠道分别使用不同的汇率和手续费费率,为避免混淆在此区分:
-+ 线上渠道:包含H5 Mobile、Web支付、APP SDK、JSAPI、QR Code 5种支付方式
-+ 线下渠道:Retail Pay 支付方式
-
-相似接口区别
-- JSAPI和H5 Mobile:JSAPI只能在支付宝客户端内访问的页面调起支付,H5可以在移动设备任意浏览器或App的WebView调起支付
-- Web支付和QR Code: Web支付会跳转到支付宝官方收银台,用户可以选择登陆账号或用客户端扫码完成支付;QR Code方式商户可以自行展示创建的二维码,也可以跳转到RoyalPay展示的收银台页面显示二维码,用户只能用支付宝客户端扫码完成支付。
-
-## 签名算法
-
-每次请求都必须加入签名信息作为请求校验。校验参数全部以Query Param参数的方式附加在URL后面,顺序不分先后。
-
-签名过程:
-1. 连接生成签名的原始字符串,需要4个参数,使用&连接,无需转码
-
-> valid_string=partner_code&time&nonce_str&credential_code
-
-参数说明:
-- partner_code:商户编码,由4位大写字母或数字构成
-- time:UTC毫秒时间戳,取当前UTC时间的毫秒数时间戳,Long类型,5分钟内有效
-- nonce_str:随机字符串,无长度限制,请使用URL安全字符(避开&,=等符号),请注意HTTP URL的最大长度限制,建议长度在10到30位
-- credential_code:系统为商户分配的开发校验码,请妥善保管,不要在公开场合泄露
-
-2. 使用SHA256进行签名,并转为Hex小写字符串
-> sign=hex(sha256(valid_string)).toLowerCase()
-
-3. 在请求中把签名使用的time,nonce_str和生成的sign一同作为Query Param参数发送
-> 案例
->
-> valid_string=RPAY&1468691301081&aaf2a94c8c2d56d5b43a1a3d9d811102&pQ5Jc9eoTcsxqPY5uQ3p2WmvSy0zEYeP
-> sign=64712672795f94fa3bfb2e88ac09cb75d09bcf8a3c3dcaa529d8290dd6587060
-
-> 测试地址:https://mpay.royalpay.com.au/sign_test.html
-
-## 币种代码
-
-由于微信端限制原因,RoyalPay只接受人民币和澳元两个币种的支付订单
-- AUD:澳元
-- CNY:人民币
-
-## 业务规则
-- QRCode支付是在网页上展示二维码,用户使用微信扫一扫扫码后直接进入微信支付页面,适用于商城类web网站;
-- JSAPI支付是在微信浏览器内直接跳转到RoyalPay让用户选择支付订单,页面只能在微信客户端打开,适用于微店;
-- 创建订单时需要提供订单号,同一个订单允许重复提交,系统会自动根据订单状态判断是否创建新订单并关闭旧订单。因此商户端应该同一个订单只用一个单号,避免重复付款;
-- 由于存在自动创建新订单机制,创建订单后返回的RoyalPay单号不代表最终支付的单号;
-- QRCode支付订单创建后会直接返回QRCode和pay_url,商户可以自行选择展示支付二维码或跳转至RoyalPay支付页;
-- JSAPI支付订单创建后会返回pay_url,商户应该跳转到这个地址让用户完成支付;
-- 跳转pay_url时必须加上签名信息;
-- 每次请求都应该生成新的签名;
-- 订单成功支付后会调用订单中提供的notify_url,详情可以查看API定义;若创建订单时未提供,商户需要在创建订单后轮询订单状态接口,直到订单被支付或过期;
-- 订单支付有效期为5分钟,超时可以用相同的订单号重新发起请求,建议重新发起请求的时机为用户再次打开支付页的时候;
-- 使用跳转支付页前应该先调用后台服务输入金额等参数创建订单后再跳转;
-- 创建订单、创建退款接口都允许同订单号重复调用,但是具体参数以初次请求的参数为准;
-- 所有和金额相关的数字均以货币最小面值为单位,以AUD为例,100表示AUD 1.00。
-
-## 案例
-
-https://example.royalpay.com.au/api/payment/order
-
-
-
-## 示例代码
-- PHP: [https://mpay.royalpay.com.au/static/phpdemo.zip](https://mpay.royalpay.com.au/static/phpdemo.zip)
-- Java: [https://mpay.royalpay.com.au/static/javademo.zip](https://mpay.royalpay.com.au/static/javademo.zip)
\ No newline at end of file
diff --git a/src/document/en/apidoc.json b/src/document/en/apidoc.json
deleted file mode 100644
index 4039388f3..000000000
--- a/src/document/en/apidoc.json
+++ /dev/null
@@ -1,55 +0,0 @@
-{
- "name": "RoyalPay Gateway Payment API",
- "version": "1.1.0",
- "description": "RoyalPay Gateway Payment API for Third-Party Developers",
- "title": "RoyalPay Gateway Payment API",
- "url": "https://mpay.royalpay.com.au",
- "header":{
- "title":"Overview",
- "filename":"overview.md"
- },
- "order":[
- "Overview",
- "QRCode",
- "NewQRCode",
- "NativeQRCode",
- "QRCodePay",
- "JSApi",
- "NewJSAPI",
- "WxJSAPIPay",
- "AliJSAPIPay",
- "MobileH5",
- "Miniprogram_Payment",
- "NewMobileH5Pay",
- "MobileH5Pay",
- "CardPayment",
- "CardPreOrder",
- "CardInputView",
- "CardOrder",
- "RetailPay",
- "RetailMicroPay",
- "RetailQRCode",
- "JD_Online_Payment",
- "Alipay_Online_Payment",
- "HF_Online_Payment",
- "CB_BankPay",
- "SDKPayment",
- "Customs_Declaration",
- "CommonApi",
- "GetExchange",
- "OrderStatus",
- "RefundOrder",
- "RefundQuery",
- "ListOrder",
- "ListTransaction",
- "SettleLog",
- "PayNotice",
- "update_file",
- "application_merchant",
- "query_merchant",
- "merchant_notice"
- ],
- "template":{
- "forceLanguage":"en"
- }
-}
diff --git a/src/document/en/apis.js b/src/document/en/apis.js
deleted file mode 100644
index 1e0a2d51c..000000000
--- a/src/document/en/apis.js
+++ /dev/null
@@ -1,1234 +0,0 @@
-/**
- * @apiDefine API API
- * API List
- */
-/**
- * @apiDefine Sign
- * @apiParam (QueryParam) {Long} time Required, UTC timestamp in milliseconds
- * @apiParam (QueryParam) {String} nonce_str Required, Random string
- * @apiParam (QueryParam) {String} sign Required, Sign
- */
-/**
- * @apiDefine PathVariable Path Variable
- */
-/**
- * @apiDefine QueryParam Query Params
- */
-/**
- * @apiDefine BINARY File data stream
- */
-/**
- * @apiDefine JSON JSON keys
- */
-/**
- * @apiDefine COMPANY_SUB_JSON company_info - JSON child keys
- */
-/**
- * @apiDefine CONTACT_SUB_JSON contact_info - JSON child keys
- */
-/**
- * @apiDefine LEGAL_SUB_JSON legal_info - JSON child keys
- */
-/**
- * @apiDefine PAY_SUB_JSON pay_info - JSON child keys
- */
-/**
- * @apiDefine SETTLE_SUB_JSON settle_info - JSON child keys
- */
-/**
- * @apiDefine COMPLIANCE_SUB_JSON compliance_file_info - JSON child keys
- */
-/**
- * @apiDefine SUB_JSON JSON child keys
- */
-/**
- * @apiDefine ERROR_CODE Error Code
- */
-/**
- * @apiDefine GlobalError
- * @apiError (ERROR) return_code Error Code
- * @apiError (ERROR) return_msg Error Description
- * @apiError (ERROR_CODE) SYSTEMERROR Exception inside system
- * @apiError (ERROR_CODE) INVALID_SHORT_ID Partner code is invalid or there is no partner associated with this code
- * @apiError (ERROR_CODE) SIGN_TIMEOUT Sign expired, the difference between time and the server time is more than 5 minutes
- * @apiError (ERROR_CODE) INVALID_SIGN Invalid sign
- * @apiError (ERROR_CODE) PARAM_INVALID Parameters are invalid. See return_msg for more details.
- * @apiError (ERROR_CODE) NOT_PERMITTED Gateway payment permission has not been enabled for this partner
- * @apiError (ERROR_CODE) INVALID_CHANNEL Channel name is not available, check the Capitalize
- *
- */
-/**
- * @apiDefine MerchantError
- * @apiError (ERROR_CODE) SYSTEMERROR SYSTEM ERROR
- * @apiError (ERROR_CODE) INVALID_SHORT_ID GateWay Short ID is invalid
- * @apiError (ERROR_CODE) INVALID_SIGN Sign invalid
- *
- */
-/**
- * @api {GET} /api/v1.0/gateway/partners/{partner_code}/exchange_rate Get Current Exchange Rate
- * @apiName GetExchange
- * @apiGroup CommonApi
- * @apiVersion 1.0.0
- * @apiDescription
- * Get current exchange rate from AUD to CNY provided by WeChat and Alipay(AUD 1=CNY ?). This exchange rate shown is for reference only, please refer to the real time exchange rate when processing the actual transaction.
- * @apiHeader Accept application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner Code
- * @apiUse Sign
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {Double} wechat_rate Exchange rate for WeChat
- * @apiSuccess {Double} alipay_retail_rate Exchange rate for Alipay Retail Trade
- * @apiSuccess {Double} alipay_online_rate Exchange rate for Alipay Online Trade
- *
- * @apiUse GlobalError
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/orders/{order_id} Create QR Code Payment
- * @apiName NewQRCode
- * @apiGroup QRCode
- * @apiVersion 1.0.0
- * @apiDescription
- * QR Code Payment is used for webpage/application on PC. Customers use WeChat or Alipay app to scan QR Code generated when creating order and finish the payment.
- *
- * Return value contains QR Code string, QR Ccode image and payment page address. Partners can decide how to finish the payment.
- * If the currency is CNY, equivalent AUD amount shall never less than 0.01AUD,
- * otherwise user will get Invalid Amount Error from WeChat when making the payment.
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner Code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. Shall be unique for the same partner. If repeated, order will be recognized as an existing order.
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Description of an order.
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String=Alipay,Wechat} channel Payment channel, case sensitive
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} channel Payment channel
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} code_url QR Code string. Partners can create the payment QR Code according to this value.
- * @apiSuccess {String} qrcode_img QR Code image formatted in Base64. Can be used as the src attribute on img element
- * @apiSuccess {String} pay_url Payment page in RoyalPay
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner.
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/native_orders/{order_id} Create QR Code Payment
- * @apiName NativeQRCode
- * @apiGroup QRCode
- * @apiVersion 1.0.0
- * @apiDescription
- * QR Code Payment is used for webpage/application on PC. Customers use WeChat or Alipay app to scan QR Code generated when creating order and finish the payment.
- *
- * Return value contains QR Code string, QR Ccode image and payment page address. Partners can decide how to finish the payment.
- * If the currency is CNY, equivalent AUD amount shall never less than 0.01 AUD,
- * otherwise user will get Invalid Amount Error from WeChat when making the payment.
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner Code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. Shall be unique for the same partner. If repeated, order will be recognized as an existing order.
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Description of an order.
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String=Alipay,Wechat} channel Payment channel, case sensitive
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} channel Payment channel
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in GlobalFreePay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} code_url QR Code string. Partners can create the payment QR Code according to this value.
- * @apiSuccess {String} qrcode_img QR Code image formatted in Base64. Can be used as the src attribute on img element
- * @apiSuccess {String} pay_url Payment page in GlobalFreePay
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner.
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {GET} /api/v1.0/gateway/partners/{partner_code}/orders/{order_id}/pay QR Code Payment Page in RoyalPay
- * @apiName QRCodePay
- * @apiDescription
- * This page mush be called after payment order has been created.
- * When jumping back to redirection URL, it is recommended to call the order query API to make sure the payment has succeeded.
- * @apiVersion 1.0.0
- * @apiGroup QRCode
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. It shall have already been created
- * @apiUse Sign
- * @apiParam (QueryParam) {String} redirect Required, Redirect url when payment succeeded. Contain sign parameters for validation.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- */
-/**
- * @api {PUT} /api/v1.0/h5_payment/partners/{partner_code}/orders/{order_id} Create H5 Payment(Only support Alipay)
- * @apiName NewMobileH5Pay
- * @apiGroup MobileH5
- * @apiVersion 1.0.0
- * @apiDescription
- *
- * Alipay has no limit at the moment.
- * H5 Payment is used for payment in Webpage or App on mobile outside WeChat or Alipay App. The browser would redirect to a webpage from WeChat or Alipay and call the App to finish the payment.
- * Return value contains a payment page. Partners shall guide users to redirect to this page. Sign params are required.
- * If the currency is CNY, equivalent AUD amount shall never less than 0.01AUD,
- * otherwise user will get Invalid Amount Error from WeChat when making the payment.
- *
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD currency
- * @apiParam (JSON) {String=Alipay} channel Payment channel, case sensitive
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} channel Payment channel
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {GET} /api/v1.0/h5_payment/partners/{partner_code}/orders/{order_id}/pay H5 Payment Page
- * @apiName MobileH5Pay
- * @apiDescription This page mush be called after payment order has been created.
- * When jumping back to redirection URL, it is recommended to call the order query API to make sure the payment has succeeded.
- * @apiVersion 1.0.0
- * @apiGroup MobileH5
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. It shall have already been created
- * @apiUse Sign
- * @apiParam (QueryParam) {String} redirect Required, Redirect url when payment succeeded. Contain sign parameters for validation.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/pre_card_orders/{order_id} Create Card Pre Order
- * @apiName CardPreOrder
- * @apiGroup CardPayment
- * @apiVersion 1.0.0
- * @apiDescription
- *
- * Card payment method is that customer provider their card information to finish payments. Enable card payment require addition compliance process.
- * Card Pre Order is the way merchant create order first and then redirect to the page on royalpay to ask customer input card information and finish payment.
- * Card Pre Order allows customer retry multiple times. So unless merchant call the closing api. Order will exists available until hit the expire time.
- *
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD currency, Only AUD supported
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- * @apiParam (JSON) {Boolean} domestic_only Default is false, Due to there is a huge rate difference between domestic cards and international cards. merchants can disable international cards
- * @apiParam (JSON) {Boolean} disable_credit_card Default is false, if merchants want to limit customers not using credit cards. this parameter can be helpful
- * @apiParam (JSON) {String} customer_id Optional, if merchants tokenized customer's card with a customer id, it can reference the card information and customers will only provide cvv2 code then.
- * @apiParam (JSON) {JSON} customer Optional, json object, provide customer's basic information in case there were a charge back happened
- *
- * @apiParam (customer) {String} name customer's name. optional. if not provided system will use card holder name
- * @apiParam (customer) {String} postcode optional
- * @apiParam (customer) {String} address optional
- * @apiParam (customer) {String} city optional,like Sydney
- * @apiParam (customer) {String} state optional, 3-character state name. like NSW
- * @apiParam (customer) {String} country optional, nation code, use 2-character code in ISO-3600-1
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} channel Payment channel
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/card_orders/{order_id} 创建卡支付订单
- * @apiName CardOrder
- * @apiGroup CardPayment
- * @apiVersion 1.0.0
- * @apiDescription
- *
- * Card payment method is that customer provider their card information to finish payments. Enable card payment require addition compliance process.
- * Card Order is the way merchant import our sdk in payment page and display a encrypting card input view. then collect the encrypted card info from callback and then pass them to royalpay to create order and finish payments
- * Card Order api do not need customers reaction any more. merchants can check payment result directly after created order.
- *
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD currency, Only AUD supported
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- * @apiParam (JSON) {String} key_id Required, key_id of encrypted callback
- * @apiParam (JSON) {String} card_info Required, secret of encrypted callback
- * @apiParam (JSON) {Boolean} domestic_only Default is false, Due to there is a huge rate difference between domestic cards and international cards. merchants can disable international cards
- * @apiParam (JSON) {Boolean} disable_credit_card Default is false, if merchants want to limit customers not using credit cards. this parameter can be helpful
- * @apiParam (JSON) {JSON} customer Optional, json object, provide customer's basic information in case there were a charge back happened
- *
- * @apiParam (customer) {String} name customer's name. optional. if not provided system will use card holder name
- * @apiParam (customer) {String} postcode optional
- * @apiParam (customer) {String} address optional
- * @apiParam (customer) {String} city optional,like Sydney
- * @apiParam (customer) {String} state optional, 3-character state name. like NSW
- * @apiParam (customer) {String} country optional, nation code, use 2-character code in ISO-3600-1
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} channel Payment channel
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {GET} /api/v1.0/card_payment_view/partners/{partner_code}/orders/{order_id}/view 卡支付跳转页
- * @apiName CardInputView
- * @apiDescription This page mush be called after payment order has been created.
- * When jumping back to redirection URL, it is recommended to call the order query API to make sure the payment has succeeded.
- * @apiVersion 1.0.0
- * @apiGroup CardPayment
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. It shall have already been created
- * @apiUse Sign
- * @apiParam (QueryParam) {String} redirect Required, Redirect url when payment succeeded. Contain sign parameters for validation.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- */
-/**
- * @api {PUT} /api/v1.0/jsapi_gateway/partners/{partner_code}/orders/{order_id} Create JSAPI Payment Order
- * @apiName NewJSAPI
- * @apiGroup JSApi
- * @apiVersion 1.1.0
- * @apiDescription
- * JSAPI Payment is used to pay in webpage which was opened in WeChat or Alipay App. If customers enter this page from WeChat Official Account, this Official Account is required to be authorized.
- * Customers will jump to RoyalPay order page and call WeChat or Alipay Payment Board to finish payment.
- *
- * Return value contains a payment page. Partners shall guide users to redirect to the page. Sign params is required when redirect happens.
- * If the currency is CNY, equivalent AUD amount shall never less than 0.01AUD,
- * otherwise user will get Invalid Amount Error from WeChat when making the payment.
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD currency
- * @apiParam (JSON) {String=Alipay,Wechat} channel Payment channel, case sensitive
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} channel Payment Channel
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay. Can only be accessed through WeChat
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {GET} /api/v1.0/wechat_jsapi_gateway/partners/{partner_code}_order_{order_id} WeChat JSAPI Payment Page in RoyalPay
- * @apiName WxJSAPIPay
- * @apiDescription This page must be called after Payment Order has been created. Actural url shall be according to pay_url param from order creation
- * @apiVersion 1.0.0
- * @apiGroup JSApi
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. Must have already been created
- * @apiUse Sign
- * @apiParam (QueryParam) {String} redirect Required, Redirect url when the payment succeeded
- * @apiParam (QueryParam) {Boolean=true,false} directpay='false' whether open direct pay mode.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- */
-/**
- * @api {GET} /api/v1.0/gateway/alipay/partners/{partner_code}/orders/{order_id}/app_pay Alipay JSAPI Payment Page in RoyalPay
- * @apiName AliJSAPIPay
- * @apiDescription This page must be called after Payment Order has been created. Actural url shall be according to pay_url param from order creation
- * @apiVersion 1.0.0
- * @apiGroup JSApi
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. Must have already been created
- * @apiUse Sign
- * @apiParam (QueryParam) {String} redirect Required, Redirect url when the payment succeeded
- * @apiParam (QueryParam) {Boolean=true,false} directpay='false' whether open direct pay mode.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- */
-/**
- * @api {PUT} /api/v1.0/micropay/partners/{partner_code}/orders/{order_id} Create Retail Passive Payment Order
- * @apiName RetailMicroPay
- * @apiDescription
- * Retail Passive Payment is used for cashier terminals which can scan BarCode or QRCode.
- * Shop staff input the payment amount and ask customers for their payment code, then system send price and payment code to server and finish the payment.
- * Retail Passive Payment now support both Alipay and WeChat
- *
- * @apiVersion 1.0.2
- * @apiGroup RetailPay
-
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD currency
- * @apiParam (JSON) {String} device_id Required, ID of the device which sends the request
- * @apiParam (JSON) {String} auth_code Required, The Payment QR Code scanned from customer's WeChat Wallet.
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code Order status
- *
- *
PAYING:Waiting for payment
- *
CREATE_FAIL:Fail to create order
- *
CLOSED:Order closed
- *
PAY_FAIL:Payment failed
- *
PAY_SUCCESS:Payment succeeded
- *
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id.
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {int} total_fee Order amount, which uses the base unit of current currency
- * @apiSuccess {int} real_fee Actual paid amount.(The same as total fee at the moment. After coupon feature is finished, this may be different.)
- * @apiSuccess {String} pay_time Time when order is paid(yyyy-MM-dd HH:mm:ss, UTC+10)
- * @apiSuccess {String} create_time Time when order is created(according to the latest order)(yyyy-MM-dd HH:mm:ss, UTC+10)
- * @apiSuccess {String} currency Currency. Default value is AUD.
- * @apiSuccess {String} channel Currency. Channel. Alipay,Wechat,Bestpay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order ID does not belongs to current partner.
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- * @apiError (ERROR_CODE) AUTHCODEEXPIRE QR Code expired
- * @apiError (ERROR_CODE) NOTENOUGH The customer does not have enough balance to finish the payment
- * @apiError (ERROR_CODE) NOTSUPORTCARD Card type is not supported
- * @apiError (ERROR_CODE) AUTH_CODE_ERROR Payment QR Code has been used twice
- * @apiError (ERROR_CODE) AUTH_CODE_INVALID The submitted QR Code is not a WeChat Payment QR Code
- */
-/**
- * @api {PUT} /api/v1.0/retail_qrcode/partners/{partner_code}/orders/{order_id} Create Retail Active Payment Order
- * @apiName RetailQRCode
- * @apiGroup RetailPay
- * @apiVersion 1.0.2
- * @apiDescription
- * Retail Active Payment is used for cashier terminals which cannot scan Barcode or QRCode.
- * Get the Code url after create the order, convert this url to a QRCode and ask customers use their app to scan this QRCode then finish the payment.
- * Retail Active Payment now support Alipay, WeChat and Bestpay
- *
- * If the currency is CNY, equivalent AUD amount shall never less than 0.01AUD,
- * otherwise user will get Invalid Amount Error from WeChat when making the payment.
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner Code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id. Shall be unique for the same partner. If repeated, order will be recognized as an existed order.
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Description of order.
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String} device_id Required, ID of the device which sends the request.
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} code_url QR Code string. Partners can create the payment QR Code according to this value.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner.
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- */
-
-
-/**
- * @api {GET} /api/v1.0/gateway/partners/{partner_code}/orders/{order_id} Query Order Status
- * @apiName OrderStatus
- * @apiGroup CommonApi
- * @apiVersion 1.0.1
- * @apiDescription Including QR Code orders, JSAPI orders and Retail orders
- * @apiHeader Accept application/json
- *
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code
- *
- *
PAYING: Waiting for payment
- *
CREATE_FAIL: Fail to create order
- *
CLOSED: Order closed
- *
PAY_FAIL: Payment failed
- *
PAY_SUCCESS: Payment succeeded
- *
PARTIAL_REFUND: Partial refunded
- *
Full_REFUND: Full refunded
- *
- * Use the same order id to call create order API can renew the order. PAYING, PAY_SUCCESS orders cannot be renewed.
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} channel_order_id PayChannel(Alipay、Wechat) Transaction Trade No
- * @apiSuccess {int} total_fee Order amount, which uses the base unit of current currency
- * @apiSuccess {int} real_fee Actual paid amount.(Equal to total fee at the moment. After coupon feature is finished, this value may be different. )
- * @apiSuccess {Double} rate Exchange Rate used while trading. 1AUD=?CNY
- * @apiSuccess {String} pay_time Time when order is paid(yyyy-MM-dd HH:mm:ss, UTC+10)
- * @apiSuccess {String} create_time Time when order is created(according to the latest order)(yyyy-MM-dd HH:mm:ss, UTC+10)
- * @apiSuccess {String} currency Currency. Default value is AUD.
- * @apiSuccess {String} channel Channel. Alipay,Wechat,Bestpay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- *
- */
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/orders/{order_id}/refunds/{refund_id} Apply for Refund
- * @apiName RefundOrder
- * @apiGroup CommonApi
- * @apiVersion 1.0.0
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiDescription
- * One payment order can create more than one refund orders. Total amount of all refund orders must be less than or equal to the actual paid amount and the currency of refund order is the same as the payment order.
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner payment order id
- * @apiParam (PathVariable) {String} refund_id Required, Partner refund order id
- * @apiUse Sign
- * @apiParam (JSON) {int} fee Required, Refund amount. Use base unit of the currency. Total amount of all refund orders must be less than actual paid amount.
- * @apiParam (JSON) {String} device_id is Optional, ID of the device which sends the request
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code
- *
- *
WAITING: Order is being submitted to WeChat
- *
CREATE_FAILED: Fail to submit to WeChat
- *
SUCCESS: Submission succeeded
- *
FAILED: Refund failed
- *
FINISHED: Refund success(funds has already been returned to user's account)
- *
CHANGE: Refund can not return to user's account. Manual operation is required
- *
- * @apiSuccess {String} refund_id RoyalPay Refund id
- * @apiSuccess {String} partner_refund_id Partner refund id
- * @apiSuccess {int} amount Refund amount
- * @apiSuccess {String} currency Refund currency
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Payment order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Payment order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_NOT_PAID Payment order is not paid
- */
-/**
- * @api {GET} /api/v1.0/gateway/partners/{partner_code}/orders/{order_id}/refunds/{refund_id} Query Refund Order Status
- * @apiName RefundQuery
- * @apiGroup CommonApi
- * @apiVersion 1.0.0
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- *
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner payment order id
- * @apiParam (PathVariable) {String} refund_id Required, Partner refund order id
- * @apiUse Sign
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code
- *
- *
WAITING: Order is being submitted to WeChat
- *
CREATE_FAILED: Fail to submit to WeChat
- *
SUCCESS: Submission succeeded
- *
FAILED: Refund failed
- *
FINISHED: Refund succeeded(funds have already been returned to user's account)
- *
CHANGE: Refund can not return to user's account. Manual operation is required
- *
- * @apiSuccess {String} refund_id RoyalPay Refund id
- * @apiSuccess {String} partner_refund_id Partner refund id
- * @apiSuccess {int} amount refund Amount
- * @apiSuccess {String} currency Refund currency
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_NOT_EXIST Payment order does not exist
- * @apiError (ERROR_CODE) ORDER_MISMATCH Payment order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_NOT_PAID Payment order is not paid
- * @apiError (ERROR_CODE) REFUND_NOT_EXIST Refund order does not exist
- * @apiError (ERROR_CODE) REFUND_MISMATCH Refund order is not belong to this payment order
- */
-
-/**
- * @api {GET} /api/v1.0/gateway/partners/{partner_code}/orders Check Orders
- * @apiName ListOrder
- * @apiGroup CommonApi
- * @apiVersion 1.0.0
- * @apiDescription
- * Get a list of orders. This api may change in the future.
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiUse Sign
- * @apiParam (QueryParam) {String} date Payment order creation date,which is formatted in 'yyyyMMdd' ,UTC+10. Query all orders if not provided
- * @apiParam (QueryParam) {String='ALL','PAID','REFUNDED'} status='ALL'
- * Order status
- *
- *
ALL: All orders, including orders not paid and closed
- *
PAID: Only paid orders. including orders which have refunds.
- *
REFUNDED: Only orders which have refunds
- *
- * @apiParam (QueryParam) {int} page=1 Page number. start with 1
- * @apiParam (QueryParam) {int} limit=10 Rows per page
- *
- * @apiSuccess (ROOT) {String} return_code Execution result
- * @apiSuccess (ROOT) {JSON[]} data Orders list
- * @apiSuccess (ROOT) {JSON} pagination Pagination information
- * @apiSuccess (ROOT) {JSON} analysis Payment analysis
- *
- * @apiSuccess (data) {String} order_id RoyalPay Order ID
- * @apiSuccess (data) {String} partner_order_id Partner Order ID
- * @apiSuccess (data) {int} total_fee Order amount
- * @apiSuccess (data) {int} real_fee Actual paid amount
- * @apiSuccess (data) {String} payment via channel: Alipay, Bestpay, Wechat
- * @apiSuccess (data) {String} currency Currency
- * @apiSuccess (data) {String} create_time Time when order is created, which is formatted in 'yyyy-MM-dd HH:mm:ss', UTC+10
- * @apiSuccess (data) {String} pay_time Time when order is paid, which is formatted in 'yyyy-MM-dd HH:mm:ss', UTC+10. will be null if not paid
- * @apiSuccess (data) {String} status
- * order status
- *
- *
SUBMITTING: Submitting to wechat
- *
SUBMIT_FAIL: Submission failed
- *
WAITING_PAYMENT: Submission succeeded and wait for payment
- * @apiSuccess (transactions) {String} currency currency(AUD/CNY)
- * @apiSuccess (transactions) {int} total_amount Total payment amount, which uses the base unit of order currency
- * @apiSuccess (transactions) {int} input_amount Order input amount, which uses the base unit of order currency
- * @apiSuccess (transactions) {int} settle_amount Amount to make settlement, AUD cents
- * @apiSuccess (transactions) {String} surcharge_rate Rate of surcharge (x%)
- * @apiSuccess (transactions) {int} surcharge Surcharge amount, AUD cents
- * @apiSuccess (transactions) {int} gst GST, AUD cents
- * @apiSuccess (transactions) {int} transfer_amount Amount send to merchant's bank account, AUD cents
- * @apiSuccess (transactions) {double} exchange_rate Using exchange rate
- * @apiSuccess (transactions) {String} remark Remark
- *
- * @apiUse GlobalError
- */
-/**
- * @api {POST} /notify_url Payment Success Notice
- * @apiName PayNotice
- * @apiGroup API
- * @apiVersion 1.0.0
- * @apiDescription
- * If notify_url is provided when order is created. System will post request to this url when the payment succeeds. Request method is POST.
- * Different from Server APIs, sign parameters will be included in json entity. Partner system shall valid them to prevent fake requests.
- * Partner system shall response with correct parameters. If RoyalPay did not receive valid response, system will regard as receiving failed and retry the notification.
- * System will retry up to3 times. Partner system shall be able to handle the repeated requests.
- *
- *
It is recommended to actively call the query API to confirm the payment status after receiving the push, so as to prevent other third parties from forging the push!
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (JSON) {long} time UTC timestamp in millis
- * @apiParam (JSON) {String} nonce_str Random string
- * @apiParam (JSON) {String} sign Sign
- * @apiParam (JSON) {String} partner_order_id Partner order id
- * @apiParam (JSON) {String} channel_order_id PayChannel(Alipay、Wechat) Transaction Trade No
- * @apiParam (JSON) {String} order_id RoyalPay order id
- * @apiParam (JSON) {int} total_fee Order amount
- * @apiParam (JSON) {int} real_fee Actual paid amount
- * @apiParam (JSON) {Double} rate Exchange Rate used while trading. 1AUD=?CNY
- * @apiParam (JSON) {String} currency Currency,AUD
- * @apiParam (JSON) {String} channel Payment Channel Alipay、AlipayOnline、Wechat、Bestpay
- * @apiParam (JSON) {String} create_time Time when order is created, which is formatted in 'yyyy-MM-dd HH:mm:ss', UTC+10
- * @apiParam (JSON) {String} pay_time Time when order is paid, which is formatted in 'yyyy-MM-dd HH:mm:ss', UTC+10.
- *
- * @apiSuccess {String} return_code SUCCESS
- */
-
-/**
- * @api {PUT} /api/v1.0/jd_gateway/partners/{partner_code}/orders/{order_id} Create JD Payment Order
- * @apiName JDPAY
- * @apiDescription
- * Use for JD Payment in PC Website. After create order, jump to the pay_url returned and attach sign params and redirect param.
- * Then enter JD Pay page to finish payment.
- * JD Channel Only.
- *
- * @apiVersion 1.0.0
- * @apiGroup JD_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {String} user_id Required,Only account number of the user on the merchant platform
- * @apiParam (JSON) {String} mobile Required,Mobile phone
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency (cent).
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay. Can only be accessed through WeChat
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/microapp_orders/{order_id} Create Miniprogram Order
- * @apiName microapp
- * @apiDescription
- Use for call Payment in Wechat/Alipay miniprogram. After create order, returned and redirect param.
- * *
- * MiniProgram_WechatPay doc
- *
- * @apiVersion 1.0.0
- * @apiGroup Miniprogram_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String=Wechat,Alipay} channel=Wechat Payment channel. Wechat for Wechat miniprogram and Alipay for Alipay miniprogram
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- * @apiParam (JSON) {String} appid Wechat channel required, miniprogram app_id
- * @apiParam (JSON) {String} customer_id wechat miniprogram open_id or alipay miniprogram userid
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay. Can only be accessed through WeChat
- * @apiSuccess {String} sdk_params The required parameters for payment.(Json String)
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-
-
-/**
- * @api {PUT} /api/v1.0/alipay/partners/{partner_code}/orders/{order_id} Create Alipay Online Order
- * @apiName AlipayOnline
- * @apiDescription
- * Use for Alipay Payment in PC Website. After create order, jump to the pay_url returned and attach sign params and redirect param.
- * Then enter Alipay page to finish payment.
- * Alipay Channel Only.
- *
- * @apiVersion 1.0.0
- * @apiGroup Alipay_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay. Can only be accessed through WeChat
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/gateway/partners/{partner_code}/app_orders/{order_id} Create SDK Order
- * @apiName SDK
- * @apiDescription
- * Used for mobile Apps calling Wechat payment with Wechat SDK. Call this api to create order and get param string for SDK calling. Call SDK api with the param to start payment and get payment result from Wechat app
- * It is strongly advised to request RoyalPay order query Api to confirm that the order has been paid in order to cancelling order by system at the same time.
- *
- * More information for integration with Alipay: Alipay SDK Document
- * More information for integration with Wehcat: Wechat SDK Document
-
- * Alipay SDK for Android
- * Alipay SDK for iOS
- * Wechat SDK for Android
- * Wechat SDK for iOS
- *
- * @apiVersion 1.0.0
- * @apiGroup SDKPayment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency
- * @apiParam (JSON) {String=Alipay,Wechat} channel payment channel, required, case sensitive
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- * @apiParam (JSON) {String=android,iphone,ipad} system os type of client app, optional for Alipay, not required for Wechat
- * @apiParam (JSON) {String} version client app version, optional for Alipay, not required for Wechat
- * @apiParam (JSON) {String} appid wechat appid, required for Wechat, not required for Alipay
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay, which is also payment channel(Wechat/Alipay) order id. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} sdk_params param string for calling SDK
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-
-
-/**
- * @api {PUT} /api/v1.0/hf_gateway/partners/{partner_code}/orders/{orderId} Create HF Web Order
- * @apiName hfapi
- * @apiDescription
- * Use for HF Payment in PC Website. After create order, jump to the pay_url returned and attach sign params and redirect param.
- * Then enter HF Pay page to finish payment.
- *
- * @apiVersion 1.0.0
- * @apiGroup HF_Online_Payment
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {String} mobile Required,Mobile phone
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String} product_id Product code Required * Product Code List
- * @apiParam (JSON) {String} product_name Product name Required
- * @apiParam (JSON) {String} product_count Product count
- * @apiParam (JSON) {String=AUD} currency=AUD Currency (only AUD)
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {PUT} /api/v1.0/cb_bankpay/partners/{partner_code}/orders/{order_id} Create CB BankPay Order
- * @apiName cbbankpayapi
- * @apiDescription
- * Use for CB BankPay in PC Website. After create order, jump to the pay_url returned and attach sign params and redirect param.
- *
- * @apiVersion 1.0.0
- * @apiGroup CB_BankPay
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} order_id Required, Partner order id
- * @apiUse Sign
- * @apiParam (JSON) {String} description Required, Order description
- * @apiParam (JSON) {int} price Required, Price of the order. Use the base unit of the currency.
- * @apiParam (JSON) {String} product_name Product name Required
- * @apiParam (JSON) {int} gateway_type Gateway Require 8: H5 gateway,9: PC gateway
- * @apiParam (JSON) {String=AUD,CNY} currency=AUD Currency (Only AUD When Merchants Choose LakalaPay)
- * @apiParam (JSON) {String} notify_url System will call the notify url if provided when the payment succeeds
- * @apiParam (JSON) {String} operator Note for the operator who created this order.
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} result_code SUCCESS means order created successfully, EXISTS means order has already existed.
- * @apiSuccess {String} partner_code Partner code
- * @apiSuccess {String} full_name Partner's full company name when registered
- * @apiSuccess {String} partner_name Partner's name
- * @apiSuccess {String} order_id Order id in RoyalPay. The final order id which is paid may be different from this one
- * @apiSuccess {String} partner_order_id Partner order id
- * @apiSuccess {String} pay_url Payment page in RoyalPay.
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- * @apiError (ERROR_CODE) ORDER_PAID Order has already been paid
- *
- */
-/**
- * @api {PUT} /api/v1.0/customs/partners/{partner_code}/declare/report/{client_report_id} Create Declare ID
- * @apiName declare_report
- * @apiDescription
- * Used to submit the attachment information of the order required by the merchant. WeChat and Alipay are only supported. WeChat only supports payment orders within one month for customs declaration.
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} client_report_id Required, Client declare ID
- * @apiUse Sign
- * @apiParam (JSON) {String} order_id Required, Partner order id
- * @apiParam (JSON) {String} custom Required, Customs No. * Customs No.
- * @apiParam (JSON) {String} mch_custom_id Required, Customs record id
- * @apiParam (JSON) {String} mch_custom_name Required, Customs record name
- * @apiParam (JSON) {JSON[]} sub_order Child orders
- *
- * @apiParam (SUB_JSON) {String} sub_order_no Child order ID
- * @apiParam (SUB_JSON) {String=CNY} fee_type=CNY Currency
- * @apiParam (SUB_JSON) {Double} order_fee Child Order Amount
- * @apiParam (SUB_JSON) {Double} transport_fee Child Order Logistics Amount
- *
- * @apiSuccess {String} report_id RoyalPay declare ID
- * @apiSuccess {String} client_report_id Client declare ID
- * @apiSuccess {String} report_status Result status: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} channel Channel
- * @apiSuccess {String} custom Customs No.
- * @apiSuccess {String} mch_custom_no Customs record ID
- * @apiSuccess {String} mch_custom_name Customs record name
- * @apiSuccess {String} order_id RoyalPay Order ID
- * @apiSuccess {String} transaction_id Channel Order ID
- * @apiSuccess {String} order_currency Currency
- * @apiSuccess {Double} order_amount Order Amount
- * @apiSuccess {String} report_time Declare Time
- * @apiSuccess {String} creation_date Create Time
- * @apiSuccess {String} last_update_date Update Time
- * @apiSuccess {String} error_code Error Code
- * @apiSuccess {String} error_msg Error Description
- * @apiSuccess {String} verify_department Verify Department
- * @apiSuccess {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess {JSON[]} sub_orders sub_order Child orders
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no Child order ID
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY Currency
- * @apiSuccess (SUB_JSON) {Double} order_fee Child Order Amount
- * @apiSuccess (SUB_JSON) {Double} transport_fee Child Order Logistics Amount
- * @apiSuccess (SUB_JSON) {String} verify_department Verify Department
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess (SUB_JSON) {String} report_status 0:PROCCESSING,1:SUBMITED,2:FAIL,3:SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code Error Code
- * @apiSuccess (SUB_JSON) {String} error_msg Error Description
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- *
- */
-
-/**
- * @api {PUT} /api/v1.0/customs/partners/{partner_code}/redeclare/report/{client_report_id} Redeclare
- * @apiName redeclare_report
- * @apiDescription
- * Used to resubmit the attachment information of the order required by the merchant.
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} client_report_id Required, Client declare ID
- * @apiUse Sign
- *
- * @apiSuccess {String} report_id RoyalPay declare ID
- * @apiSuccess {String} client_report_id Client declare ID
- * @apiSuccess {String} report_status Result status: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} channel Channel
- * @apiSuccess {String} custom Customs No.
- * @apiSuccess {String} mch_custom_no Customs record ID
- * @apiSuccess {String} mch_custom_name Customs record name
- * @apiSuccess {String} order_id RoyalPay Order ID
- * @apiSuccess {String} transaction_id Channel Order ID
- * @apiSuccess {String} order_currency Currency
- * @apiSuccess {Double} order_amount Order Amount
- * @apiSuccess {String} report_time Declare Time
- * @apiSuccess {String} creation_date Create Time
- * @apiSuccess {String} last_update_date Update Time
- * @apiSuccess {String} error_code Error Code
- * @apiSuccess {String} error_msg Error Description
- * @apiSuccess {String} verify_department Verify Department
- * @apiSuccess {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess {JSON[]} sub_orders sub_order Child orders
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no Child order ID
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY Currency
- * @apiSuccess (SUB_JSON) {Double} order_fee Child Order Amount
- * @apiSuccess (SUB_JSON) {Double} transport_fee Child Order Logistics Amount
- * @apiSuccess (SUB_JSON) {String} verify_department Verify Department
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess (SUB_JSON) {String} report_status 0:PROCCESSING,1:SUBMITED,2:FAIL,3:SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code Error Code
- * @apiSuccess (SUB_JSON) {String} error_msg Error Description
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- *
- */
-/**
- * @api {GET} /api/v1.0/customs/partners/{partner_code}/declare/query/{client_report_id} Query Declare ID
- * @apiName declare_query
- * @apiDescription
- * Used by the merchant to check the status of the customs declaration number.
- *
- * @apiVersion 1.0.0
- * @apiGroup Custom
- * @apiHeader Accept application/json
- * @apiHeader Content-Type application/json
- * @apiParam (PathVariable) {String} partner_code Required, Partner code
- * @apiParam (PathVariable) {String} client_report_id Required,Client declare ID
- * @apiUse Sign
- *
- * @apiSuccess {String} return_code Execution result
- * @apiSuccess {String} report_status Result status: PROCCESSING,SUBMITED,FAILED,SUCCESS
- * @apiSuccess {String} report_id RoyalPay declare ID
- * @apiSuccess {String} client_report_id Client declare ID
- * @apiSuccess {String} return_msg Error Description
- * @apiSuccess {String} order_id RoyalPay Order ID
- * @apiSuccess {String} partner_order_id Partner Order ID
- * @apiSuccess {String} verify_department Verify Department
- * @apiSuccess {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess {JSON[]} sub_orders sub_order Child orders
- *
- * @apiSuccess (SUB_JSON) {String} sub_order_no Child order ID
- * @apiSuccess (SUB_JSON) {String=CNY} fee_type=CNY Currency
- * @apiSuccess (SUB_JSON) {Double} order_fee Child Order Amount
- * @apiSuccess (SUB_JSON) {Double} transport_fee Child Order Logistics Amount
- * @apiSuccess (SUB_JSON) {String} verify_department Verify Department
- * @apiSuccess (SUB_JSON) {String} verify_department_trade_id Verify Department Trade Id
- * @apiSuccess (SUB_JSON) {String} report_status 0:PROCCESSING,1:SUBMITED,2:FAIL,3:SUCCESS
- * @apiSuccess (SUB_JSON) {String} error_code Error Code
- * @apiSuccess (SUB_JSON) {String} error_msg Error Description
- *
- * @apiUse GlobalError
- * @apiError (ERROR_CODE) ORDER_MISMATCH Order is not belong to this partner
- *
- */
-function apis() {
-
-}
diff --git a/src/document/en/overview.md b/src/document/en/overview.md
deleted file mode 100644
index 287ebaae2..000000000
--- a/src/document/en/overview.md
+++ /dev/null
@@ -1,103 +0,0 @@
-# Overview
-
-## Domain
-
-#### Production Environment
-[https://mpay.royalpay.com.au/](https://mpay.royalpay.com.au/)
-#### Sandbox Environment
-[https://sandbox.royalpay.com.au/](https://sandbox.royalpay.com.au/)
-
-Sandbox has different sign parameters. Contact us to configure it for you.
-
-## Request And Parameters
-
-Request for payment or refund shall use PUT method. Request for querying order
-shall use GET method. All requests including Request Entity are in JSON format.
-
-Accept in the request header shall be set to application/json for all requests except redirect pages.
-Content-Type in the request header shall be set to application/json for all PUT/POST requests.
-
-System charset is UTF-8.
-
-There are 3 groups of parameters: Path Variable, Query Param, JSON Entity
-+ Path Variable: included in the path as patterns
-+ Query Param: parameters after the URI '?' symbol and formatted like key=value
-+ JSON Entity: only used in PUT/POST requests
-
-Our API server will return 200 in JSON if the request has successfully reached the server, which does not indicate the success or failure of the actual operation. All responses in JSON format will include a return_code field which contains the operation result. The value SUCCESS indicates that the operation was successful while other values shows the type of error that happened. Response will also contain a return_msg field for detailed error message.
-
-## Multi-Language
-
-System error message supports Simplified Chinese and English. The system by default will automatically choose the language according to the Accept-Language value in request header. Cookie "locale" value (zh-CN or en-US) will affect the result language.
-
-## Which Gateway Api is for me?
-
-
-
-## Alipay Channels
-
-According to different Api used, Alipay channel was distributed to Retail channel and Online channel. Two channels has different exchange rate and surcharge rate.
-+ Online Channel: Including H5 Mobile, Online Payment, APP SDK, JSAPI and QR Code Api
-+ Retail Channel: Including Retail Pay
-
-Difference
-- JSAPI and H5 Mobile: JSAPI can only be called in the web page opened in Alipay Client. H5 Mobile can call the payment panel in any browser or webview in App in the mobile device.
-- Online Payment and QR Code: Online payment will jump to Alipay Official payment page. Customers can scan QR Code displayed in the page or sign in their account directly to finish payment. QR Code can provide a QR Code. Merchants can display this QR Code in their web page or jump to RoyalPay to display the QR Code. Customers can only scan the QR Code with their Alipay Client to finish payment.
-
-## Sign Algorithm
-
-Sign messages are required in each request for validation. Sign parameters are all attached to URL as query params, and the order is irrelevant.
-
-Sign Program:
-1. Connect 4 parameters with '&' symbol into an original valid string. Escape value is not required.
-
-> valid_string=partner_code&time&nonce_str&credential_code
-
-Parameters:
-- partner_code: Code for partner, including four uppercase letters or numbers.
-- time: UTC timestamp in milliseconds. Take current timestamp of UTC. Data type is Long. The difference between time and RoyalPay server time should be less than 5 minutes.
-- nonce_str: Random string. No limit for length. URL-Safe characters are required. The proposed length is 10-30 characters.
-- credential_code: Partner credential code for development provided by RoyalPay system. Keep it safe and never disclose it to the public. If compromised, contact us to change it.
-
-2. Sign the valid string with SHA256 and turn to lowercase Hex string
-> sign=hex(sha256(valid_string)).toLowerCase()
-
-3. Include the time,nonce_str and sign into Query Param when calling api.
-> Example
->
-> valid_string=RPAY&1468691301081&aaf2a94c8c2d56d5b43a1a3d9d811102&pQ5Jc9eoTcsxqPY5uQ3p2WmvSy0zEYeP
-> sign=64712672795f94fa3bfb2e88ac09cb75d09bcf8a3c3dcaa529d8290dd6587060
-
-> Test Page:https://mpay.royalpay.com.au/sign_test.html
-
-## Currency Codes
-
-RoyalPay can only accept the following currencies at the moment. Please note that the settlement currency will always be Australian Dollar.
-- AUD
-- CNY
-
-## Business Roles
-- QR Code Payment displays a QR code image in a web page. Customers will scan the code via their WeChat and complete the payment in the linked web page. It is suitable for online shopping websites.
-- JSAPI Payment redirects customers to a web page in WeChat. This page can only be opened within WeChat app and it is suitable for payment from micro-shops on WeChat platform.
-- Retail passive payment(Scan Payment Code in customers’ WeChat Wallet) and active payment(Generate Payment QR Code for customers to scan) are used in retail environment such as payment terminals and pos machines.
-- Order ID is required when creating an order. The same order id can be sent again. The system will decide to renew an order or close the old order according to the order status. System will recognise the same order id to avoid duplicated payments from customers.
-- As orders can be resubmitted, Order ID returned by our server might not represent the last Order ID paid.
-- QR Code order creation will return QR Code and pay_url. Merchants may decide whether to display the QR code on their website or to redirect customer to the payment page available at pay_url.
-- JSAPI order creation will return pay_url. Merchants shall redirect customer to the payment page available at pay_url, and complete the payment.
-- When redirecting to pay_url, sign information is required.
-- Each request shall use new timestamp, nonce_str and sign.
-- Our system will notify the caller after an order is paid successfully if notify_url was provided when creating an order. Otherwise, Merchants shall call the order query method repeatedly until order is paid or closed.
-- Each unpaid order will be valid for 5 minutes. Expired order can be renewed with same the order id. It is suggested to trigger the event when user open the payment page again.
-- Always redirect to RoyalPay’s payment page after calling the order creation method.
-- Same order id is allowed in both creating new payment order and creating refund order but order details shall refer back to the initial request details.
-- Price is specified in the base unit of the given currency. Using currency AUD as an example, 105 means 105 cents or $1.05.
-
-## Demo
-
-https://example.royalpay.com.au/api/payment/order
-
-
-
-## Demo Codes
-- PHP: [https://mpay.royalpay.com.au/static/phpdemo.zip](https://mpay.royalpay.com.au/static/phpdemo.zip)
-- Java: [https://mpay.royalpay.com.au/static/javademo.zip](https://mpay.royalpay.com.au/static/javademo.zip)
diff --git a/src/document/openapi/cn/document.yml b/src/document/openapi/cn/document.yml
index 05391c780..d220d0ef1 100644
--- a/src/document/openapi/cn/document.yml
+++ b/src/document/openapi/cn/document.yml
@@ -128,6 +128,15 @@ tags:
- name: CardPayment
description: |
卡支付即消费者输入银行卡信息进行下单的接口,接入卡支付需要额外的合规流程。
+ 卡支付分为预订单模式和直接下单模式。
+
+ 预订单模式即先提交订单基本信息(单号、金额等),得到返回的pay_url参数后跳转到对应收银台,消费者可以在收银台完成卡信息输入,同时可以通过customer_id机制允许同一个customer在后续支付中免于输入完整的卡信息实现快速支付。也支持开启3DS加强消费者的校验规避charge back风险
+
+
+ 直接下单模式即在商户自己收银台展示我们集成的加密卡信息输入框,消费者输入卡信息后会将加密后的卡信息通过页面回调给商户前端,商户提交订单的时候将加密信息同时提交,无需额外跳转即可完成支付流程,此模式暂不支持3DS校验
+
+
+ 两种支付模式后续的查账退款都使用了相同接口。
- name: RetailPay
description: |
线下支付订单接口用于线下零售收银,有B扫C和C扫B两种模式
@@ -495,6 +504,8 @@ paths:
allOf:
- $ref: 'components_order.yml#/orderWithChannel'
- type: object
+ required:
+ - customer_id
properties:
appid:
type: string
diff --git a/src/document/openapi/cn/img/UPayCardOrder_CN.jpg b/src/document/openapi/cn/img/UPayCardOrder_CN.jpg
new file mode 100644
index 000000000..4edd71a08
Binary files /dev/null and b/src/document/openapi/cn/img/UPayCardOrder_CN.jpg differ
diff --git a/src/document/openapi/cn/img/UPayCardPreOrder_CN.jpg b/src/document/openapi/cn/img/UPayCardPreOrder_CN.jpg
new file mode 100644
index 000000000..a4231a3ae
Binary files /dev/null and b/src/document/openapi/cn/img/UPayCardPreOrder_CN.jpg differ
diff --git a/src/document/openapi/en/document.yml b/src/document/openapi/en/document.yml
index 09e5846c4..e58001d0d 100644
--- a/src/document/openapi/en/document.yml
+++ b/src/document/openapi/en/document.yml
@@ -132,6 +132,16 @@ tags:
- name: CardPayment
description: |
Card payment method is that customer provider their card information to finish payments. Enable card payment require addition compliance process.
+
+ Card payment contains 2 ways to create an order: Pre-Order Mode and Direct-Order Mode
+
+ Pre-Order mode is that merchant submit other order info like order fee, order id, and will get a pay_url in response. Then guide customer visit this address so that they can type in their card information on our cashier page. And with customer_id parameter, it can allow same customers use card information in last payment so that they do not have to input entire card information. And pre-order mode also support 3-DS to decrease Charge back risk
+
+
+ Direct-Order mode allow merchants to embed our secure card input frame in their cashier page. It can supply encrypted card information with callback to merchant's ui. Merchants just submit the encrypted card information and order basic information together and will get the payment result directly. However, this mode do not support 3-DS now.
+
+
+ Both modes used same order check and refund api.
- name: RetailPay
description: |
Retail payment API for merchants has their own machine. Has 2 modes:
@@ -506,6 +516,8 @@ paths:
allOf:
- $ref: 'components_order.yml#/orderWithChannel'
- type: object
+ required:
+ - customer_id
properties:
appid:
type: string
diff --git a/src/document/openapi/en/img/UPayCardOrder_EN.jpg b/src/document/openapi/en/img/UPayCardOrder_EN.jpg
new file mode 100644
index 000000000..3c02c26a8
Binary files /dev/null and b/src/document/openapi/en/img/UPayCardOrder_EN.jpg differ
diff --git a/src/document/openapi/en/img/UPayCardPreOrder_EN.jpg b/src/document/openapi/en/img/UPayCardPreOrder_EN.jpg
new file mode 100644
index 000000000..a023d26f2
Binary files /dev/null and b/src/document/openapi/en/img/UPayCardPreOrder_EN.jpg differ
diff --git a/src/document/tpl/css/style.css b/src/document/tpl/css/style.css
deleted file mode 100644
index 7234953b1..000000000
--- a/src/document/tpl/css/style.css
+++ /dev/null
@@ -1,532 +0,0 @@
-/* ------------------------------------------------------------------------------------------
- * Content
- * ------------------------------------------------------------------------------------------ */
-body {
- min-width: 980px;
- max-width: 1280px;
-}
-
-body, p, a, div, th, td {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 400;
- font-size: 16px;
-}
-
-td.code {
- font-size: 14px;
- font-family: "Source Code Pro", monospace;
- font-style: normal;
- font-weight: 400;
-}
-
-#content {
- padding-top: 16px;
- z-Index: -1;
- margin-left: 270px;
-}
-
-p {
- color: #808080;
-}
-
-h1 {
- font-family: "Source Sans Pro Semibold", sans-serif;
- font-weight: normal;
- font-size: 44px;
- line-height: 50px;
- margin: 0 0 10px 0;
- padding: 0;
-}
-
-h2 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: normal;
- font-size: 24px;
- line-height: 40px;
- margin: 0 0 20px 0;
- padding: 0;
-}
-
-section {
- border-top: 1px solid #ebebeb;
- padding: 30px 0;
-}
-
-section h1 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 700;
- font-size: 32px;
- line-height: 40px;
- padding-bottom: 14px;
- margin: 0 0 20px 0;
- padding: 0;
-}
-
-article {
- padding: 14px 0 30px 0;
-}
-
-article h1 {
- font-family: "Source Sans Pro Bold", sans-serif;
- font-weight: 600;
- font-size: 24px;
- line-height: 26px;
-}
-
-article h2 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 600;
- font-size: 18px;
- line-height: 24px;
- margin: 0 0 10px 0;
-}
-
-article h3 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 600;
- font-size: 16px;
- line-height: 18px;
- margin: 0 0 10px 0;
-}
-
-article h4 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 600;
- font-size: 14px;
- line-height: 16px;
- margin: 0 0 8px 0;
-}
-
-table {
- border-collapse: collapse;
- width: 100%;
- margin: 0 0 20px 0;
-}
-
-th {
- background-color: #f5f5f5;
- text-align: left;
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 700;
- padding: 4px 8px;
- border: #e0e0e0 1px solid;
-}
-
-td {
- vertical-align: top;
- padding: 2px 8px;
- border: #e0e0e0 1px solid;
-}
-
-#generator .content {
- color: #b0b0b0;
- border-top: 1px solid #ebebeb;
- padding: 10px 0;
-}
-
-.label-optional {
- float: right;
-}
-
-.open-left {
- right: 0;
- left: auto;
-}
-
-/* ------------------------------------------------------------------------------------------
- * apidoc - intro
- * ------------------------------------------------------------------------------------------ */
-
-#apidoc .apidoc {
- border-top: 1px solid #ebebeb;
- padding: 30px 0;
-}
-
-#apidoc h1 {
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 700;
- font-size: 32px;
- line-height: 40px;
- padding-bottom: 14px;
- margin: 0 0 20px 0;
- padding: 0;
-}
-
-#apidoc h2 {
- font-family: "Source Sans Pro Bold", sans-serif;
- font-weight: 600;
- font-size: 22px;
- line-height: 26px;
- padding-top: 14px;
-}
-
-/* ------------------------------------------------------------------------------------------
- * pre / code
- * ------------------------------------------------------------------------------------------ */
-pre {
- background-color: #292b36;
- color: #ffffff;
- padding: 10px;
- border-radius: 6px;
- position: relative;
- margin: 10px 0 20px 0;
-}
-
-code.language-text {
- word-wrap: break-word;
-}
-
-pre.language-json {
- overflow: auto;
-}
-
-pre.language-html {
- margin: 40px 0 20px 0;
-}
-
-pre.language-html:before {
- content: attr(data-type);
- position: absolute;
- top: -30px;
- left: 0;
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 600;
- font-size: 15px;
- display: inline-block;
- padding: 2px 5px;
- border-radius: 6px;
- text-transform: uppercase;
- background-color: #3387CC;
- color: #ffffff;
-}
-
-pre.language-html[data-type="get"]:before {
- background-color: green;
-}
-
-pre.language-html[data-type="put"]:before {
- background-color: #e5c500;
-}
-
-pre.language-html[data-type="post"]:before {
- background-color: #4070ec;
-}
-
-pre.language-html[data-type="delete"]:before {
- background-color: #ed0039;
-}
-
-pre.language-api .str {
- color: #ffffff;
-}
-
-pre.language-api .pln,
-pre.language-api .pun {
- color: #65B042;
-}
-
-pre code {
- display: block;
- font-size: 14px;
- font-family: "Source Code Pro", monospace;
- font-style: normal;
- font-weight: 400;
- word-wrap: normal;
- white-space: pre;
-}
-
-pre code.sample-request-response-json {
- white-space: pre-wrap;
- max-height: 500px;
- overflow: auto;
-}
-
-/* ------------------------------------------------------------------------------------------
- * Sidenav
- * ------------------------------------------------------------------------------------------ */
-.sidenav {
- width: 228px;
- margin: 0;
- padding: 20px;
- position: fixed;
- top: 0;
- left: 0;
- bottom: 0;
- overflow-x: hidden;
- overflow-y: auto;
- background-color: #f5f5f5;
- z-index: 10;
-}
-
-.sidenav > li > a {
- display: block;
- width: 192px;
- margin: 0;
- padding: 2px 11px;
- border: 0;
- border-left: transparent 4px solid;
- border-right: transparent 4px solid;
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 400;
- font-size: 14px;
-}
-
-.sidenav > li.nav-header > a {
- padding: 5px 15px;
- border: 1px solid #e5e5e5;
- width: 190px;
- font-family: "Source Sans Pro", sans-serif;
- font-weight: 700;
- font-size: 16px;
- background-color: #ffffff;
-}
-
-.sidenav > li.nav-header.active > a {
- background-color: #0088cc;
-}
-
-.sidenav > .active > a {
- position: relative;
- z-index: 2;
-}
-
-.sidenav > li > a:hover {
- background-color: #ffffff;
-}
-
-.sidenav > li.has-modifications a {
- border-right: #60d060 4px solid;
-}
-
-.sidenav > li.is-new a {
- border-left: #e5e5e5 4px solid;
-}
-
-/* ------------------------------------------------------------------------------------------
- * Compare
- * ------------------------------------------------------------------------------------------ */
-
-ins {
- background: #60d060;
- text-decoration: none;
- color: #000000;
-}
-
-del {
- background: #f05050;
- color: #000000;
-}
-
-.label-ins {
- background-color: #60d060;
-}
-
-.label-del {
- background-color: #f05050;
- text-decoration: line-through;
-}
-
-pre.ins {
- background-color: #60d060;
-}
-
-pre.del {
- background-color: #f05050;
- text-decoration: line-through;
-}
-
-table.ins th,
-table.ins td {
- background-color: #60d060;
-}
-
-table.del th,
-table.del td {
- background-color: #f05050;
- text-decoration: line-through;
-}
-
-tr.ins td {
- background-color: #60d060;
-}
-
-tr.del td {
- background-color: #f05050;
- text-decoration: line-through;
-}
-
-/* ------------------------------------------------------------------------------------------
- * Spinner
- * ------------------------------------------------------------------------------------------ */
-
-#loader {
- position: absolute;
- width: 100%;
-}
-
-#loader p {
- padding-top: 80px;
- margin-left: -4px;
-}
-
-.spinner {
- margin: 200px auto;
- width: 60px;
- height: 60px;
- position: relative;
-}
-
-.container1 > div, .container2 > div, .container3 > div {
- width: 14px;
- height: 14px;
- background-color: #0088cc;
-
- border-radius: 100%;
- position: absolute;
- -webkit-animation: bouncedelay 1.2s infinite ease-in-out;
- animation: bouncedelay 1.2s infinite ease-in-out;
- /* Prevent first frame from flickering when animation starts */
- -webkit-animation-fill-mode: both;
- animation-fill-mode: both;
-}
-
-.spinner .spinner-container {
- position: absolute;
- width: 100%;
- height: 100%;
-}
-
-.container2 {
- -webkit-transform: rotateZ(45deg);
- transform: rotateZ(45deg);
-}
-
-.container3 {
- -webkit-transform: rotateZ(90deg);
- transform: rotateZ(90deg);
-}
-
-.circle1 { top: 0; left: 0; }
-.circle2 { top: 0; right: 0; }
-.circle3 { right: 0; bottom: 0; }
-.circle4 { left: 0; bottom: 0; }
-
-.container2 .circle1 {
- -webkit-animation-delay: -1.1s;
- animation-delay: -1.1s;
-}
-
-.container3 .circle1 {
- -webkit-animation-delay: -1.0s;
- animation-delay: -1.0s;
-}
-
-.container1 .circle2 {
- -webkit-animation-delay: -0.9s;
- animation-delay: -0.9s;
-}
-
-.container2 .circle2 {
- -webkit-animation-delay: -0.8s;
- animation-delay: -0.8s;
-}
-
-.container3 .circle2 {
- -webkit-animation-delay: -0.7s;
- animation-delay: -0.7s;
-}
-
-.container1 .circle3 {
- -webkit-animation-delay: -0.6s;
- animation-delay: -0.6s;
-}
-
-.container2 .circle3 {
- -webkit-animation-delay: -0.5s;
- animation-delay: -0.5s;
-}
-
-.container3 .circle3 {
- -webkit-animation-delay: -0.4s;
- animation-delay: -0.4s;
-}
-
-.container1 .circle4 {
- -webkit-animation-delay: -0.3s;
- animation-delay: -0.3s;
-}
-
-.container2 .circle4 {
- -webkit-animation-delay: -0.2s;
- animation-delay: -0.2s;
-}
-
-.container3 .circle4 {
- -webkit-animation-delay: -0.1s;
- animation-delay: -0.1s;
-}
-
-@-webkit-keyframes bouncedelay {
- 0%, 80%, 100% { -webkit-transform: scale(0.0) }
- 40% { -webkit-transform: scale(1.0) }
-}
-
-@keyframes bouncedelay {
- 0%, 80%, 100% {
- transform: scale(0.0);
- -webkit-transform: scale(0.0);
- } 40% {
- transform: scale(1.0);
- -webkit-transform: scale(1.0);
- }
-}
-
-/* ------------------------------------------------------------------------------------------
- * Tabs
- * ------------------------------------------------------------------------------------------ */
-ul.nav-tabs {
- margin: 0;
-}
-
-/* ------------------------------------------------------------------------------------------
- * Print
- * ------------------------------------------------------------------------------------------ */
-
-@media print {
-
- #sidenav,
- #version,
- #versions,
- section .version,
- section .versions {
- display: none;
- }
-
- #content {
- margin-left: 0;
- }
-
- a {
- text-decoration: none;
- color: inherit;
- }
-
- a:after {
- content: " [" attr(href) "] ";
- }
-
- p {
- color: #000000
- }
-
- pre {
- background-color: #ffffff;
- color: #000000;
- padding: 10px;
- border: #808080 1px solid;
- border-radius: 6px;
- position: relative;
- margin: 10px 0 20px 0;
- }
-
-} /* /@media print */
diff --git a/src/document/tpl/img/favicon.ico b/src/document/tpl/img/favicon.ico
deleted file mode 100644
index c307a0439..000000000
Binary files a/src/document/tpl/img/favicon.ico and /dev/null differ
diff --git a/src/document/tpl/index.html b/src/document/tpl/index.html
deleted file mode 100644
index 445151ae7..000000000
--- a/src/document/tpl/index.html
+++ /dev/null
@@ -1,672 +0,0 @@
-
-
-
-
- RoyalPay网关支付接口
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-