收银台页面
Quick Reference
What托管支付页
Why卡数据不经过您的源站——A55 全面处理卡数据安全
Difficulty初级
Prerequisites身份验证 → 创建收款
在服务器上创建收费,然后将买家重定向至 A55 托管体验。卡数据不接触您的域名,完全由 A55 管理卡数据安全。
为何使用托管结账
| 收益 | 说明 |
|---|---|
| 源站零卡数据 | 卡输入完全由 A55 处理 |
| 多方式 | 卡、PIX、Apple Pay、Google Pay 同一流程 |
| 内置 3DS(3D Secure 验证) | A55 在 confirmacion.a55.tech 内运行 3DS |
| 移动优化 | 响应式托管页 |
| 最快上线 | 重定向之外前端工作量极少 |
流程
- 通过 API(应用程序编程接口)创建收费(
POSThttps://core-manager.a55.tech/api/v1/bank/wallet/charge/)。 - 从响应读取
charge_payment_url(或等效结账 URL(统一资源定位符))。 - 将买家重定向至
https://pay.a55.tech/checkout/v2/{uuid}(若 API 返回 URL 请优先使用返回的 URL)。
托管页负责的内容
卡输入、PIX QR 展示、Apple Pay/Google Pay,以及 A55 控制域名内的 3DS。
您的责任: 以正确金额与币种创建收费,按需设置 redirect_url/回跳 URL,并订阅 webhook(网络钩子) 获取最终状态。
重定向代码
- JavaScript
- Python
- Node.js
- Go
- Java
- PHP
window.location.href = chargePaymentUrl;
from flask import redirect
@app.route("/pay/<charge_uuid>")
def pay(charge_uuid):
charge_payment_url = create_charge(charge_uuid)
return redirect(charge_payment_url) # 重定向买家至托管结账页
app.get("/pay/:chargeUuid", async (req, res) => {
const chargePaymentUrl = await createCharge(req.params.chargeUuid);
res.redirect(302, chargePaymentUrl); // 302 重定向至 A55 结账页
});
http.HandleFunc("/pay/", func(w http.ResponseWriter, r *http.Request) {
chargePaymentURL := createCharge(r.PathValue("chargeUuid"))
http.Redirect(w, r, chargePaymentURL, http.StatusFound) // 重定向至托管结账
})
@GetMapping("/pay/{chargeUuid}")
public void pay(@PathVariable String chargeUuid, HttpServletResponse response)
throws IOException {
String chargePaymentUrl = createCharge(chargeUuid);
response.sendRedirect(chargePaymentUrl); // 重定向至 A55 结账页
}
<?php
$chargePaymentUrl = createCharge($chargeUuid);
header("Location: " . $chargePaymentUrl); // 重定向至托管结账页
exit;
环境
在各环境间保持收费 UUID 稳定;测试重定向时使用**沙箱(sandbox)**主机与凭证。
托管结账上的 3DS
认证在 A55 域名内运行。标准托管结账流程中您无需手动处理 url_3ds。