llms.txt API v1 · 2026-11-02
Go live上线

Conformance test接口对接测试

The fixed test suite run against the merchant wallet before go-live.上线前对商户钱包执行的固定测试用例。

Before go-live — and after any change to your wallet — we run a fixed test suite against your Wallet API from our test console. Every request is a real signed request from our egress IPs, marked with X-Test-Run. You receive the full test report.

上线前、以及商户钱包有任何改动后,平台从测试控制台对商户钱包接口跑一套固定用例。每个请求都是从平台出口 IP 发出的真实签名请求,带 X-Test-Run 头。测试完成后商户会收到完整的测试报告。

What you prepare商户准备

One test account is enough:

只需要一个测试账号:

Item项Requirement要求
Test player测试玩家Normal status, in the currency you will go live with, balance ≥ 50 × test amount. Use it only for testing.状态正常,币种与上线币种一致,余额 ≥ 50 倍测试金额,只用于测试。
Test token测试 tokenA long-lived token for that player that /auth accepts repeatedly during the test.该玩家的长期 token,测试期间 /auth 可以反复接受。
Test amount测试金额A stake your limits accept, e.g. 1.00 USD or 1000 IDR.商户限额能接受的下注额,如 1.00 USD 或 1000 IDR。

Everything else is derived from this one account: an unknown player is a random extPlayerId, an invalid token is a random string, a currency mismatch uses another currency, and insufficient balance is a debit of current balance + test amount.

其余情况都从这一个账号推出来:「玩家不存在」用随机的 extPlayerId,「token 无效」用随机字符串,「币种不匹配」换一个别的币种,「余额不足」扣当前余额 + 测试金额。

How we judge判定方式

  • Every case asserts the exact code, the response data against Strict response validation, and the exact balance change (via the response and a follow-up /balance).
  • The suite is designed to leave the test player's balance unchanged. The last case checks that the final balance equals the starting balance — any hidden double debit or double credit fails it.
  • Cases are blocking (violates the protocol or poses a risk to funds; must be remediated before go-live) or warning (does not affect the safety of funds; remediation is recommended).
  • 每条用例都强制校验:返回的 code 必须完全一致、响应数据满足 响应强制校验、余额变化精确相等(看响应,再用 /balance 复核)。
  • 整套用例设计为跑完后测试玩家余额不变。最后一条用例核对最终余额等于初始余额——任何暗中的重复扣款或重复派彩都会被它抓到。
  • 用例分阻断级(违反协议或存在资金风险,上线前必须整改)与警告级(不影响资金安全,建议整改)两级。

Test report测试报告

After each test the platform issues a formal test report to the merchant, in Chinese and English (HTML and Markdown, identical in structure, plus the raw data in JSON). The test token is masked and the secret key never appears in the report. The report contains:

每次测试完成后,平台向商户出具正式测试报告,中英文各一份(HTML 与 Markdown 结构一致,另附 JSON 原始数据)。报告中的测试 token 已打码,商户密钥不出现在报告中。报告包含以下章节:

#Section章节Content内容
1Report information报告信息Report number (the X-Test-Run value), test object, test type, protocol and test suite versions, environment, start and end time, executing party.报告编号(即 X-Test-Run 的值)、测试对象、测试类型、协议与用例集版本、测试环境、开始与结束时间、执行方。
2Test conclusion测试结论Passed, failed, aborted or stopped, with a formal statement and the number of blocking and warning issues.通过、不通过、中止或已停止,附正式结论与阻断级、警告级问题数。
3Scope and acceptance criteria测试范围与判定依据Test suite, execution order, the common checks K1–K7 applied to every case, severity levels and decision rules.用例集、执行顺序、每条用例统一核对的 K1–K7、级别定义与判定规则。
4Test environment and data测试环境与数据Callback URL, test player, currency, test amount, opening and closing balance and their difference, masked test token.回调地址、测试玩家、币种、测试金额、起始与结束余额及差额、打码后的测试 token。
5Results summary结果统计Passed, failed and skipped cases by phase and by level.按阶段与按级别统计通过、失败、跳过的用例数。
6Issue list问题清单For each failed case: case ID, level, description, expected and actual result, the clause of this guide it is based on, and the recommended remediation.每条失败用例的用例编号、级别、问题描述、期望结果、实际结果、依据条款(本文档章节)与整改建议。
7Test case details用例执行明细Every case with endpoint, level, result, expected and actual result code and balance check; the HTML report also contains the raw requests and responses.全部用例的接口、级别、判定、期望与实际结果码、余额核对;HTML 报告另附请求与响应原文。
8Performance性能统计Requests, P50 / P95 / P99 and timeouts per endpoint.各接口的请求数、P50 / P95 / P99 与超时数。
9Test data cleanup测试数据清理How wallet rounds left open by the test were closed (resends and rollbacks) and their results.测试中未关闭钱包局的处理方式(重发与冲正)及结果。
10Appendix附录Result codes and how the platform handles them, terms and notation, key protocol requirements.结果码与平台处理方式、术语与符号、协议要点。
Full list完整列表Every case in execution order, with its request, expected code and balance after: Wallet API Test Cases.按执行顺序列出每条用例的请求、期望 code 与之后余额:钱包接口对接测试用例。

Case groups用例分组

Group组Covers覆盖
SIGWrong signature; body tampered after signing; stale and future timestamp; missing signature; wrong merchant code; unknown field ignored; a badly signed debit moves no money while the same debit correctly signed is processed. (HTTP 200 for business errors is checked on every case by Strict response validation V1.)错误签名;签完后改正文;过期与未来的时间戳;缺签名头;商户编码不对;未知字段被忽略;签名错的扣款不动钱、同一笔签对了照常处理。(业务错误返回 HTTP 200 由 响应强制校验 V1 在每条用例上检查。)
AUTHValid token; invalid token; data validation of the response.有效 token;无效 token;响应数据校验。
BALBalance format and precision; unknown player; currency mismatch.余额格式与精度;玩家不存在;币种不匹配。
DEBDebit and balance change; idempotent repeat; same txnId different amount; insufficient balance (amount above the current balance) and its persistence; precision; currency mismatch; unknown player.扣款与余额变化;幂等重发;同 txnId 不同金额;余额不足(扣款额高于当前余额)及失败结果的持久化;精度;币种不匹配;玩家不存在。
MULSeveral debits in one round; closing credit; new transactions after close; repeat after close; mid-round credit; zero credit.一局多笔扣款;关局派彩;关局后的新交易;关局后重发;局中派彩;0 派彩。
CRECredit for an unknown round; conflicting repeat.派彩指向不存在的局;内容冲突的重发。
ROLRollback and refund; idempotent repeat; unknown debit; late debit after rollback; amount mismatch; rollback of one of several debits; rollback after close; rollback of a failed debit.冲正退款;幂等重发;冲正不存在的扣款;冲正之后迟到的扣款;金额不符;多笔扣款中冲正一笔;关局后冲正;冲正失败的扣款。
CONThe same debit sent concurrently; many rounds concurrently for one player.同一笔扣款并发发送;同一玩家多局并发。
PERFP99 below 1 s (warning); any call over its timeout (blocking).P99 低于 1 秒(警告级);任何一次超过超时上限(阻断级)。
ENDFinal balance equals the starting balance.最终余额等于初始余额。