feat: 实现快手电子凭证三个出站回调接口
- 新增 send-callback-service.ts: 卡券发码回调 (eticket/send) - 新增 consume-callback-service.ts: 核销回调 (eticket/consume) - 新增 destroy-callback-service.ts: 销毁回调 (eticket/destroy) - 三个回调均在对应入站接口处理成功后异步触发(fire-and-forget) - 共享 sendCallbackEnabled 开关控制,默认关闭 - 新增 accessToken 配置项(OAuth获取) - 新增 scripts/curl-send-callback.ts: 手动测试 curl 生成脚本 - docker-compose 添加 KUASHOU_INDUSTRY_ACCESS_TOKEN / SEND_CALLBACK_ENABLED 环境变量
This commit is contained in:
@@ -14,6 +14,8 @@
|
||||
"test": "node --import tsx --test $(find src \\( -name '*.test.ts' -o -name '*.test.js' \\) -print)",
|
||||
"test:industry": "tsx scripts/test-kuaishou-industry.ts",
|
||||
"test:industry:http": "tsx scripts/test-kuaishou-industry-http.ts",
|
||||
"test:industry:gen": "tsx scripts/gen-test-cases.ts",
|
||||
"test:industry:curl": "tsx scripts/curl-send-callback.ts",
|
||||
"typecheck": "tsc -p tsconfig.json --noEmit",
|
||||
"start": "node dist/index.js",
|
||||
"start:src": "tsx src/index.ts"
|
||||
|
||||
Reference in New Issue
Block a user