@alipay/alipay-aipay 1.4.9 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -2
- package/skill/SKILL.md +2 -2
- package/skill/VERSION +1 -1
- package/skill/references/integration/flow.md +109 -41
- package/skill/references/integration/modules/checklist.md +25 -17
- package/skill/references/integration/modules/code-examples/csharp/1-/351/200/232/347/224/250/346/216/245/345/217/243//345/274/202/346/255/245/351/200/232/347/237/245/345/244/204/347/220/206/344/273/243/347/240/201/347/244/272/344/276/213.md +1 -1
- package/skill/references/integration/modules/code-examples/java/1-/351/200/232/347/224/250/346/216/245/345/217/243//345/274/202/346/255/245/351/200/232/347/237/245/345/244/204/347/220/206/344/273/243/347/240/201/347/244/272/344/276/213.md +1 -1
- package/skill/references/integration/modules/code-examples/nodejs/1-/351/200/232/347/224/250/346/216/245/345/217/243//345/274/202/346/255/245/351/200/232/347/237/245/345/244/204/347/220/206/344/273/243/347/240/201/347/244/272/344/276/213.md +1 -1
- package/skill/references/integration/modules/code-examples/php/1-/351/200/232/347/224/250/346/216/245/345/217/243//345/274/202/346/255/245/351/200/232/347/237/245/345/244/204/347/220/206/344/273/243/347/240/201/347/244/272/344/276/213.md +1 -1
- package/skill/references/integration/modules/code-examples/python/1-/351/200/232/347/224/250/346/216/245/345/217/243//345/274/202/346/255/245/351/200/232/347/237/245/345/244/204/347/220/206/344/273/243/347/240/201/347/244/272/344/276/213.md +1 -1
- package/skill/references/integration/modules/interface-contract/aipay-interface-contract.md +3 -4
- package/skill/references/integration/modules/interface-contract/apppay-interface-contract.md +4 -4
- package/skill/references/integration/modules/interface-contract/common-trade-contract.md +1 -1
- package/skill/references/integration/modules/interface-contract/notify-url-contract.md +4 -4
- package/skill/references/integration/modules/interface-contract/webpay-interface-contract.md +4 -4
- package/skill/references/integration/modules/interface-guide.md +15 -13
- package/skill/references/integration/modules/product-decision.md +13 -13
- package/skill/references/integration/modules/sandbox/a2m-sandbox-test.md +2 -2
- package/skill/references/integration/modules/scripts/local_402_sandbox_pay.py +1 -1
- package/skill/references/integration/modules/scripts/sandbox_config.sh +1 -1
- package/skill/references/integration/modules/troubleshooting-flow.md +3 -3
- package/skill/references/normal/alipay-cli-env.md +2 -2
- package/skill/references/normal/full-process-routing.md +7 -5
- package/skill/references/normal/json/customer-messages.json +56 -51
- package/skill/references/normal/json/policy-rules.json +6 -6
- package/skill/references/normal/rejection-guide.md +1 -1
- package/skill/references/normal/scripts/alipay_cli_env.mjs +6 -2
- package/skill/references/normal/scripts/alipay_cli_env.sh +36 -2
- package/skill/references/normal/scripts/common.sh +64 -0
- package/skill/references/normal/scripts/flow_loader.mjs +241 -0
- package/skill/references/normal/scripts/integration_context_runner.mjs +166 -0
- package/skill/references/normal/scripts/integration_message_runner.mjs +237 -15
- package/skill/references/normal/scripts/interaction_reply.mjs +133 -0
- package/skill/references/normal/scripts/onboarding_discovery_runner.mjs +224 -0
- package/skill/references/normal/scripts/onboarding_message_runner.mjs +27 -12
- package/skill/references/normal/scripts/onboarding_recovery_runner.mjs +96 -0
- package/skill/references/normal/scripts/project_route_inspector.sh +3 -3
- package/skill/references/normal/scripts/python_script_runner.mjs +1 -1
- package/skill/references/normal/scripts/render_customer_message.mjs +67 -42
- package/skill/references/normal/scripts/telemetry.mjs +54 -5
- package/skill/references/normal/telemetry.md +26 -0
- package/skill/references/onboarding/flow.md +166 -152
- package/skill/references/onboarding/modules/app-release.md +39 -386
- package/skill/references/onboarding/modules/authorization.md +25 -270
- package/skill/references/onboarding/modules/error-handling.md +50 -253
- package/skill/references/onboarding/modules/product-sign.md +24 -289
- package/skill/references/onboarding/modules/scripts/app.sh +58 -21
- package/skill/references/onboarding/modules/scripts/ar_sign_apply.sh +15 -12
- package/skill/references/onboarding/modules/scripts/auth.sh +6 -1
- package/skill/references/onboarding/modules/scripts/error_handler.sh +1 -0
- package/skill/references/onboarding/modules/scripts/query_sign_status.sh +5 -3
- package/skill/references/onboarding/modules/scripts/service.sh +3 -2
- package/skill/references/onboarding/modules/scripts/upload_screenshots.sh +24 -12
- package/skill/references/onboarding/modules/service-registration.md +20 -312
- package/skill/references/runtime-entry.md +17 -16
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"interactionPrompts": {
|
|
4
|
-
"confirmInputHint": "
|
|
5
|
-
"authorizationCompletionInputHint": "
|
|
6
|
-
"publicKeyConfirmationCompletionInputHint": "
|
|
7
|
-
"completionInputHint": "
|
|
4
|
+
"confirmInputHint": "如确认,可以回复“继续”“确认”“OK”,也可以输入 1;如需调整,请直接说明。",
|
|
5
|
+
"authorizationCompletionInputHint": "授权完成后可回复“继续”“好了”“OK”或输入 1",
|
|
6
|
+
"publicKeyConfirmationCompletionInputHint": "支付宝扫码确认应用公钥完成后可回复“继续”“好了”“OK”或输入 1",
|
|
7
|
+
"completionInputHint": "完成后可回复“继续”“好了”“已完成”“OK”或输入 1;如需调整,请直接说明。",
|
|
8
8
|
"scanReturnHint": "扫码完成后请回到 Agent 对话页面"
|
|
9
9
|
},
|
|
10
|
+
"interactionReplySets": {
|
|
11
|
+
"affirmative": ["1", "继续", "继续推进", "继续执行", "继续处理", "继续下一步", "请继续", "请继续推进", "继续吧", "确认", "确认继续", "确定", "同意", "可以", "可以继续", "可以继续推进", "没问题", "好", "好的", "好了", "好的继续", "已完成", "完成", "完成了", "操作完成", "操作好了", "已经完成", "已经好了", "处理好了", "确认好了", "弄好了", "OK", "Okay", "Yes", "Y"]
|
|
12
|
+
},
|
|
10
13
|
"messages": [
|
|
11
14
|
{
|
|
12
15
|
"messageId": "product.unsupported",
|
|
@@ -17,7 +20,7 @@
|
|
|
17
20
|
"variables": [{ "name": "productName", "type": "singleLine", "required": true }],
|
|
18
21
|
"requiredPolicyIds": ["P-MCP-CONTRACT-FROZEN"],
|
|
19
22
|
"variants": {
|
|
20
|
-
"DEFAULT": { "templateLines": ["当前 Skill
|
|
23
|
+
"DEFAULT": { "templateLines": ["当前 Skill 只支持接入 AI 按量付费、AI 网页应用收款和 AI 移动应用收款,不支持 `{{productName}}`。", "", "- 查看支付宝其他收单产品请前往:[支付宝开放平台](https://open.alipay.com)", "- 开通支付宝其他收单产品请前往:[支付宝商家平台](https://b.alipay.com/page/portal/home)"] }
|
|
21
24
|
}
|
|
22
25
|
},
|
|
23
26
|
{
|
|
@@ -29,7 +32,7 @@
|
|
|
29
32
|
"variables": [],
|
|
30
33
|
"requiredPolicyIds": [],
|
|
31
34
|
"variants": {
|
|
32
|
-
"ONBOARDING_ONLY": { "templateLines": ["暂不支持企业账号通过 Skill 完成产品开通。", "", "请前往支付宝商家平台开通:https://b.alipay.com/page/portal/home", "", "如需继续进行代码开发,试试对 Agent
|
|
35
|
+
"ONBOARDING_ONLY": { "templateLines": ["暂不支持企业账号通过 Skill 完成产品开通。", "", "请前往支付宝商家平台开通:https://b.alipay.com/page/portal/home", "", "如需继续进行代码开发,试试对 Agent 说:为我集成 AI 网页应用收款/AI 移动应用收款/AI 按量付费"] },
|
|
33
36
|
"FULL_PROCESS": { "templateLines": ["暂不支持企业账号通过 Skill 完成产品开通。", "", "请前往支付宝商家平台开通:https://b.alipay.com/page/portal/home"] }
|
|
34
37
|
}
|
|
35
38
|
},
|
|
@@ -55,7 +58,7 @@
|
|
|
55
58
|
"variables": [],
|
|
56
59
|
"requiredPolicyIds": [],
|
|
57
60
|
"variants": {
|
|
58
|
-
"DEFAULT": { "templateLines": ["请确认您的业务场景:", "", "1. 按量付费:买家通过 Agent 使用支付宝完成支付,适用于 API、MCP、算力资源等按调用付费。", "2.
|
|
61
|
+
"DEFAULT": { "templateLines": ["请确认您的业务场景:", "", "1. AI 按量付费:买家通过 Agent 使用支付宝完成支付,适用于 API、MCP、算力资源等按调用付费。", "2. AI 网页应用收款:买家在电脑网页或手机浏览器页面使用支付宝付款。", "3. AI 移动应用收款:买家在 APP 内调起支付宝完成付款。"] }
|
|
59
62
|
}
|
|
60
63
|
},
|
|
61
64
|
{
|
|
@@ -66,7 +69,7 @@
|
|
|
66
69
|
"allowedReplies": [],
|
|
67
70
|
"replyMode": "freeform",
|
|
68
71
|
"variables": [
|
|
69
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
72
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] }
|
|
70
73
|
],
|
|
71
74
|
"requiredPolicyIds": [],
|
|
72
75
|
"variants": {
|
|
@@ -107,11 +110,11 @@
|
|
|
107
110
|
"owner": "catalog_owned",
|
|
108
111
|
"trigger": "integration.step2.ready",
|
|
109
112
|
"blocking": true,
|
|
110
|
-
"
|
|
113
|
+
"allowedReplySet": "affirmative",
|
|
111
114
|
"inputHintType": "confirm",
|
|
112
115
|
"expiresWithPrompt": true,
|
|
113
116
|
"variables": [
|
|
114
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
117
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] },
|
|
115
118
|
{ "name": "projectPath", "type": "path", "required": true },
|
|
116
119
|
{ "name": "projectOriginLabel", "type": "enum", "required": true, "values": ["现有项目", "本轮新建项目"] },
|
|
117
120
|
{ "name": "integrationStatus", "type": "enum", "required": true, "values": ["TARGET_PARTIAL", "OTHER_PRODUCT_ONLY", "NO_PAYMENT"] },
|
|
@@ -140,7 +143,7 @@
|
|
|
140
143
|
] },
|
|
141
144
|
"WEBPAY": { "templateLines": [
|
|
142
145
|
"请确认代码开发方案:", "", "| 项目 | 内容 |", "|---|---|",
|
|
143
|
-
"| 目标产品 |
|
|
146
|
+
"| 目标产品 | AI 网页应用收款 |", "| 项目路径 | `{{projectPath}}` |", "| 项目来源 | {{projectOriginLabel}} |",
|
|
144
147
|
"| 代码开发状态 | {{integrationStatus}} |", "| 检测到的其他支付产品 | {{otherProducts}} |",
|
|
145
148
|
"| 语言 / 框架 | {{language}} / {{framework}} |",
|
|
146
149
|
"", "服务声明:",
|
|
@@ -149,11 +152,11 @@
|
|
|
149
152
|
] },
|
|
150
153
|
"APPPAY": { "templateLines": [
|
|
151
154
|
"请确认代码开发方案:", "", "| 项目 | 内容 |", "|---|---|",
|
|
152
|
-
"| 目标产品 |
|
|
155
|
+
"| 目标产品 | AI 移动应用收款 |", "| 项目路径 | `{{projectPath}}` |", "| 项目来源 | {{projectOriginLabel}} |",
|
|
153
156
|
"| 代码开发状态 | {{integrationStatus}} |", "| 检测到的其他支付产品 | {{otherProducts}} |",
|
|
154
157
|
"| 语言 / 框架 | {{language}} / {{framework}} |",
|
|
155
158
|
"",
|
|
156
|
-
"【前置提醒】接
|
|
159
|
+
"【前置提醒】接 AI 移动应用收款需要你有自己的 APP,本轮代码开发主要覆盖商家服务端支付接口的实现,APP 还需接入支付宝客户端 SDK 后才能调起支付。你可以在当前 AI 移动应用收款服务端代码开发完毕后,对 Agent 说:“给我做个 APP /给我的 APP 接支付宝客户端 SDK /把我的 APP 客户端和接了支付宝的服务端联动起来”。",
|
|
157
160
|
"", "服务声明:",
|
|
158
161
|
"1. 使用本服务需遵守法律法规、自行审核测试并承担使用责任,我方不对使用效果、正确性担保。",
|
|
159
162
|
"2. 生产环境账号密码、API Keys、应用私钥等敏感信息切勿暴露给 Agent;仅沙箱环境信息可按本 Skill 的沙箱配置流程提供和使用。"
|
|
@@ -165,7 +168,7 @@
|
|
|
165
168
|
"owner": "catalog_owned",
|
|
166
169
|
"trigger": "onboarding.step2.ready",
|
|
167
170
|
"blocking": true,
|
|
168
|
-
"
|
|
171
|
+
"allowedReplySet": "affirmative",
|
|
169
172
|
"inputHintType": "confirm",
|
|
170
173
|
"expiresWithPrompt": true,
|
|
171
174
|
"variables": [
|
|
@@ -180,7 +183,7 @@
|
|
|
180
183
|
"",
|
|
181
184
|
"| 项目 | 内容 |",
|
|
182
185
|
"|---|---|",
|
|
183
|
-
"| 产品 | 按量付费 |",
|
|
186
|
+
"| 产品 | AI 按量付费 |",
|
|
184
187
|
"| 产品码 | `I1080300001000160457` |",
|
|
185
188
|
"| 经营类目 | {{mccName}} (`{{mccCode}}`) |",
|
|
186
189
|
"| 特殊资质 | {{mccQualification}} |",
|
|
@@ -194,7 +197,7 @@
|
|
|
194
197
|
] },
|
|
195
198
|
"WEBPAY": { "templateLines": [
|
|
196
199
|
"请确认产品开通方案:", "", "| 项目 | 内容 |", "|---|---|",
|
|
197
|
-
"| 产品 |
|
|
200
|
+
"| 产品 | AI 网页应用收款 |", "| 产品码 | `I1080300001000041203` |", "| 经营类目 | {{mccName}} (`{{mccCode}}`) |", "| 特殊资质 | {{mccQualification}} |",
|
|
198
201
|
"| 授权范围 | `app:all,fast_instant_trade_pay:write` |",
|
|
199
202
|
"| 材料预告 | 1、未签约时收集首页、商品页、支付页 3 张截图;支付页是展示支付宝付款方式,等待用户去支付的页面;2、新建应用设置应用公钥时由用户提供 |",
|
|
200
203
|
"",
|
|
@@ -206,7 +209,7 @@
|
|
|
206
209
|
"APPPAY": {
|
|
207
210
|
"templateLines": [
|
|
208
211
|
"请确认产品开通方案:", "", "| 项目 | 内容 |", "|---|---|",
|
|
209
|
-
"| 产品 |
|
|
212
|
+
"| 产品 | AI 移动应用收款 |", "| 产品码 | `I1080300001000041313` |", "| 经营类目 | {{mccName}} (`{{mccCode}}`) |", "| 特殊资质 | {{mccQualification}} |",
|
|
210
213
|
"| 授权范围 | `app:all,auth_alipay_apppay:write` |",
|
|
211
214
|
"| 材料预告 | 1、未签约时收集 APP 名称和首页、商品页、支付页 3 张截图;支付页是展示支付宝付款方式,等待用户去支付的页面;2、新建应用支持 iOS、Android 或 ALL(二者同时);3、新建应用设置应用公钥时由用户提供 |",
|
|
212
215
|
"| 特别提醒 | 鸿蒙系统移动应用暂不支持通过 Skill 创建,请前往支付宝开放平台-控制台手动创建:https://open.alipay.com/ |",
|
|
@@ -228,7 +231,7 @@
|
|
|
228
231
|
"postRenderHintType": "scanReturn",
|
|
229
232
|
"expiresWithPrompt": true,
|
|
230
233
|
"variables": [
|
|
231
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
234
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] },
|
|
232
235
|
{ "name": "deviceCode", "type": "singleLine", "required": true },
|
|
233
236
|
{ "name": "mccCode", "type": "mccCode", "required": true },
|
|
234
237
|
{ "name": "mccName", "type": "singleLine", "required": true },
|
|
@@ -278,7 +281,7 @@
|
|
|
278
281
|
"owner": "catalog_owned",
|
|
279
282
|
"trigger": "FLOW:KEY_NOT_CONFIRMED",
|
|
280
283
|
"blocking": true,
|
|
281
|
-
"
|
|
284
|
+
"allowedReplySet": "affirmative",
|
|
282
285
|
"inputHintType": "publicKeyConfirmationComplete",
|
|
283
286
|
"variables": [],
|
|
284
287
|
"requiredPolicyIds": ["P-KEY-PUBLIC-USER"],
|
|
@@ -316,14 +319,16 @@
|
|
|
316
319
|
{ "name": "categoryName", "type": "enum", "required": true, "values": ["签约材料", "服务资料", "应用资料"] },
|
|
317
320
|
{ "name": "currentStatus", "type": "enum", "required": true, "values": ["待补充", "部分已提供,待补充", "校验失败,需更正"] },
|
|
318
321
|
{ "name": "missingFields", "type": "enumList", "required": true, "values": ["APP名称", "首页截图", "商品页截图", "支付页截图", "服务名称", "服务描述", "服务地址", "服务单价", "请求示例JSON", "应用平台和对应资料", "iOS Bundle ID(bundleId)", "Android 应用包名(appPackage)", "Android 应用签名摘要(appSign)", "应用公钥"] },
|
|
319
|
-
{ "name": "paymentPageHint", "type": "string", "derived": true, "values": ["支付页说明:支付页是展示支付宝付款方式,等待用户去支付的页面,不是支付成功页。"] }
|
|
322
|
+
{ "name": "paymentPageHint", "type": "string", "derived": true, "values": ["支付页说明:支付页是展示支付宝付款方式,等待用户去支付的页面,不是支付成功页。"] },
|
|
323
|
+
{ "name": "serviceUrlHint", "type": "string", "derived": true, "values": ["请提供有效的 URL 地址(以 http:// 或 https:// 开头)"] },
|
|
324
|
+
{ "name": "servicePricingHint", "type": "string", "derived": true, "values": ["请提供不低于 0.01 元的有效服务单价,可输入 0.03、0.03元或 0.03 元/次。"] }
|
|
320
325
|
],
|
|
321
326
|
"requiredPolicyIds": ["P-MATERIAL-CATEGORY"],
|
|
322
327
|
"variants": {
|
|
323
328
|
"INITIAL": { "templateLines": ["当前收集类别:{{categoryName}}", "", "请在一条回复中提供:{{missingFields}}。", "{{paymentPageHint}}", "你也可以提前提供后续类别材料,我会直接接收并在对应类别复用。"] },
|
|
324
329
|
"APP_MOBILE_INITIAL": { "templateLines": ["当前收集类别:应用资料", "", "请在一条回复中选择要创建的应用平台,并提供对应资料:", "", "- iOS:回复 `IOS`,并提供 iOS Bundle ID(bundleId)。", "- Android:回复 `ANDROID`,并提供 Android 应用包名(appPackage)和 Android 应用签名摘要(appSign,不是应用公钥)。", "- iOS + Android:回复 `ALL`,并提供以上三项资料。", "", "如已准备应用公钥,也可以在同一条回复中一并提供;未准备不影响创建应用。请勿提供应用私钥。", "", "鸿蒙系统移动应用暂不支持通过 Skill 创建,请前往支付宝开放平台-控制台手动创建:https://open.alipay.com/"] },
|
|
325
330
|
"PARTIAL": { "templateLines": ["当前收集类别:{{categoryName}}", "", "还需补充:{{missingFields}}。", "{{paymentPageHint}}", "已校验字段无需重复提供;你也可以提前提供后续类别材料,我会直接接收并在对应类别复用。"] },
|
|
326
|
-
"INVALID": { "templateLines": ["当前收集类别:{{categoryName}}", "", "以下内容需要更正:{{missingFields}}。", "{{paymentPageHint}}", "已校验字段无需重复提供;你也可以提前提供后续类别材料,我会直接接收并在对应类别复用。"] }
|
|
331
|
+
"INVALID": { "templateLines": ["当前收集类别:{{categoryName}}", "", "以下内容需要更正:{{missingFields}}。", "{{serviceUrlHint}}", "{{servicePricingHint}}", "{{paymentPageHint}}", "已校验字段无需重复提供;你也可以提前提供后续类别材料,我会直接接收并在对应类别复用。"] }
|
|
327
332
|
}
|
|
328
333
|
},
|
|
329
334
|
{
|
|
@@ -341,7 +346,7 @@
|
|
|
341
346
|
],
|
|
342
347
|
"requiredPolicyIds": ["P-WRITE-CONFIRM", "P-WRITE-UNKNOWN"],
|
|
343
348
|
"variants": {
|
|
344
|
-
"DEFAULT": { "templateLines": ["
|
|
349
|
+
"DEFAULT": { "templateLines": ["将创建以下 AI 按量付费服务:", "", "服务名称:{{serviceName}}", "服务描述:{{serviceDescription}}", "服务地址:`{{serviceUrl}}`", "服务单价:{{servicePricing}} 元/次", "请求示例 JSON:", "```json", "{{serviceSchema}}", "```"] }
|
|
345
350
|
}
|
|
346
351
|
},
|
|
347
352
|
{
|
|
@@ -349,13 +354,13 @@
|
|
|
349
354
|
"owner": "catalog_owned",
|
|
350
355
|
"trigger": "external_write.ready",
|
|
351
356
|
"blocking": true,
|
|
352
|
-
"
|
|
357
|
+
"allowedReplySet": "affirmative",
|
|
353
358
|
"inputHintType": "confirm",
|
|
354
359
|
"expiresWithPrompt": true,
|
|
355
360
|
"variables": [
|
|
356
361
|
{ "name": "sessionSummary", "type": "singleLine", "required": true },
|
|
357
362
|
{ "name": "subjectSummary", "type": "singleLine", "required": true },
|
|
358
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
363
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] },
|
|
359
364
|
{ "name": "actionTypes", "type": "enumList", "required": true, "values": ["服务修改"] },
|
|
360
365
|
{ "name": "serviceId", "type": "singleLine", "required": false },
|
|
361
366
|
{ "name": "serviceName", "type": "singleLine", "required": false },
|
|
@@ -366,7 +371,7 @@
|
|
|
366
371
|
],
|
|
367
372
|
"requiredPolicyIds": ["P-WRITE-CONFIRM", "P-WRITE-UNKNOWN"],
|
|
368
373
|
"variants": {
|
|
369
|
-
"SERVICE_UPDATE_ONLY": { "templateLines": ["请确认以下支付宝操作:", "", "- 当前会话:{{sessionSummary}}", "- 操作主体:{{subjectSummary}}", "-
|
|
374
|
+
"SERVICE_UPDATE_ONLY": { "templateLines": ["请确认以下支付宝操作:", "", "- 当前会话:{{sessionSummary}}", "- 操作主体:{{subjectSummary}}", "- 产品:AI 按量付费", "- 动作:服务修改", "", "服务ID:`{{serviceId}}`", "服务名称:{{serviceName}}", "服务描述:{{serviceDescription}}", "服务地址:`{{serviceUrl}}`", "服务单价:{{servicePricing}} 元/次", "请求示例 JSON:", "```json", "{{serviceSchema}}", "```", "", "本次只执行上述服务修改;签约、应用创建、公钥设置和应用提审不包含在本确认中。"] }
|
|
370
375
|
}
|
|
371
376
|
},
|
|
372
377
|
{
|
|
@@ -376,7 +381,7 @@
|
|
|
376
381
|
"blocking": false,
|
|
377
382
|
"allowedReplies": [],
|
|
378
383
|
"variables": [
|
|
379
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
384
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] },
|
|
380
385
|
{ "name": "processResultTitle", "type": "enum", "required": true, "values": ["支付产品-产品开通已完成", "流程进展"] },
|
|
381
386
|
{ "name": "integrationResult", "type": "enum", "required": true, "values": ["不在本轮执行范围", "已完成", "部分完成,沙箱配置待完成", "部分完成,人工待验证", "未完成", "结果未知"] },
|
|
382
387
|
{ "name": "sandboxConfigState", "type": "enum", "required": false, "values": ["READY", "CREATE_PENDING", "VERIFY_PENDING"] },
|
|
@@ -444,7 +449,7 @@
|
|
|
444
449
|
"blocking": false,
|
|
445
450
|
"allowedReplies": [],
|
|
446
451
|
"variables": [
|
|
447
|
-
{ "name": "productName", "type": "enum", "required": true, "values": ["按量付费", "
|
|
452
|
+
{ "name": "productName", "type": "enum", "required": true, "values": ["AI 按量付费", "AI 网页应用收款", "AI 移动应用收款"] },
|
|
448
453
|
{ "name": "configPath", "type": "existingPath", "required": true },
|
|
449
454
|
{ "name": "environmentRows", "type": "sandboxTableRows", "required": true }
|
|
450
455
|
],
|
|
@@ -490,8 +495,8 @@
|
|
|
490
495
|
"variables": [],
|
|
491
496
|
"requiredPolicyIds": ["P-A2M-SANDBOX", "P-SENSITIVE-STATE"],
|
|
492
497
|
"variants": {
|
|
493
|
-
"DEFAULT": { "templateLines": ["快速沙箱环境配置已准备完成。", "", "- 当前环境仅供测试,不涉及真实资金。", "- 完整配置已写入本地文件;不要在项目日志、对话总结或公共代码仓库中打印或提交密钥和沙箱账号。", "- 迁移配置时从受限权限的本地文件读取,不通过对话传递密钥原文。", "- 正式上线前使用同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并按开发语言确认私钥格式;格式不匹配时只使用支付宝官方密钥工具转换。", "- 沙箱网关为 https://openapi-sandbox.dl.alipaydev.com/gateway.do,生产网关为 https://openapi.alipay.com/gateway.do;禁止在沙箱配置中提前使用生产网关。", "- 按量付费沙箱 `serviceId` 固定为 `api_mock_service_id`,生产前必须替换为服务市场实际 `serviceId`。"] },
|
|
494
|
-
"WINDOWS": { "templateLines": ["Windows 沙箱本地配置已准备完成。", "", "- 当前环境仅供测试,不涉及真实资金。", "- 不要在项目日志、对话总结或公共代码仓库中打印或提交密钥和沙箱账号。", "- 本轮提供的沙箱密钥和账号只用于当前项目配置;Agent 不得在回复中复述。", "- 生产环境应用私钥和密码切勿暴露给 Agent。", "- 正式上线前使用同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并按开发语言确认私钥格式;格式不匹配时只使用支付宝官方密钥工具转换。", "- 沙箱网关为 https://openapi-sandbox.dl.alipaydev.com/gateway.do,生产网关为 https://openapi.alipay.com/gateway.do;禁止在沙箱配置中提前使用生产网关。", "- 按量付费沙箱 `serviceId` 固定为 `api_mock_service_id`,生产前必须替换为服务市场实际 `serviceId`。"] }
|
|
498
|
+
"DEFAULT": { "templateLines": ["快速沙箱环境配置已准备完成。", "", "- 当前环境仅供测试,不涉及真实资金。", "- 完整配置已写入本地文件;不要在项目日志、对话总结或公共代码仓库中打印或提交密钥和沙箱账号。", "- 迁移配置时从受限权限的本地文件读取,不通过对话传递密钥原文。", "- 正式上线前使用同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并按开发语言确认私钥格式;格式不匹配时只使用支付宝官方密钥工具转换。", "- 沙箱网关为 https://openapi-sandbox.dl.alipaydev.com/gateway.do,生产网关为 https://openapi.alipay.com/gateway.do;禁止在沙箱配置中提前使用生产网关。", "- AI 按量付费沙箱 `serviceId` 固定为 `api_mock_service_id`,生产前必须替换为服务市场实际 `serviceId`。"] },
|
|
499
|
+
"WINDOWS": { "templateLines": ["Windows 沙箱本地配置已准备完成。", "", "- 当前环境仅供测试,不涉及真实资金。", "- 不要在项目日志、对话总结或公共代码仓库中打印或提交密钥和沙箱账号。", "- 本轮提供的沙箱密钥和账号只用于当前项目配置;Agent 不得在回复中复述。", "- 生产环境应用私钥和密码切勿暴露给 Agent。", "- 正式上线前使用同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并按开发语言确认私钥格式;格式不匹配时只使用支付宝官方密钥工具转换。", "- 沙箱网关为 https://openapi-sandbox.dl.alipaydev.com/gateway.do,生产网关为 https://openapi.alipay.com/gateway.do;禁止在沙箱配置中提前使用生产网关。", "- AI 按量付费沙箱 `serviceId` 固定为 `api_mock_service_id`,生产前必须替换为服务市场实际 `serviceId`。"] }
|
|
495
500
|
}
|
|
496
501
|
},
|
|
497
502
|
{
|
|
@@ -503,7 +508,7 @@
|
|
|
503
508
|
"variables": [],
|
|
504
509
|
"requiredPolicyIds": ["P-A2M-SANDBOX", "P-A2M-SUCCESS"],
|
|
505
510
|
"variants": {
|
|
506
|
-
"DEFAULT": { "templateLines": ["
|
|
511
|
+
"DEFAULT": { "templateLines": ["开始执行 AI 按量付费沙箱服务端联调。", "", "我将连续验证 `402 Payment-Needed`、沙箱收银、`Payment-Proof` 重试和资源交付,完成后输出实际结论;这里不需要额外确认。"] }
|
|
507
512
|
}
|
|
508
513
|
},
|
|
509
514
|
{
|
|
@@ -518,8 +523,8 @@
|
|
|
518
523
|
],
|
|
519
524
|
"requiredPolicyIds": ["P-A2M-SUCCESS", "P-SENSITIVE-STATE"],
|
|
520
525
|
"variants": {
|
|
521
|
-
"PASSED": { "templateLines": ["按量付费沙箱服务端联调通过。", "", "通过证据:{{evidenceSummary}}"] },
|
|
522
|
-
"FAILED": { "templateLines": ["按量付费沙箱服务端联调未通过。", "", "实际证据:{{evidenceSummary}}", "", "恢复动作:{{recoveryAction}}"] }
|
|
526
|
+
"PASSED": { "templateLines": ["AI 按量付费沙箱服务端联调通过。", "", "通过证据:{{evidenceSummary}}"] },
|
|
527
|
+
"FAILED": { "templateLines": ["AI 按量付费沙箱服务端联调未通过。", "", "实际证据:{{evidenceSummary}}", "", "恢复动作:{{recoveryAction}}"] }
|
|
523
528
|
}
|
|
524
529
|
},
|
|
525
530
|
{
|
|
@@ -536,7 +541,7 @@
|
|
|
536
541
|
],
|
|
537
542
|
"requiredPolicyIds": ["P-SANDBOX-CREDENTIAL-EXCEPTION"],
|
|
538
543
|
"variants": {
|
|
539
|
-
"FULL": { "templateLines": ["
|
|
544
|
+
"FULL": { "templateLines": ["可选:体验 AI 按量付费沙箱付款", "", "付款链接(复制到网页浏览器打开):{{paymentUrl}}", "沙箱买家账号:{{buyerAccount}}", "登录密码:{{buyerLoginPassword}}", "支付密码:{{buyerPayPassword}}"] }
|
|
540
545
|
}
|
|
541
546
|
},
|
|
542
547
|
{
|
|
@@ -555,7 +560,7 @@
|
|
|
555
560
|
],
|
|
556
561
|
"requiredPolicyIds": ["P-SANDBOX-CREDENTIAL-EXCEPTION"],
|
|
557
562
|
"variants": {
|
|
558
|
-
"DEFAULT": { "templateLines": ["
|
|
563
|
+
"DEFAULT": { "templateLines": ["AI 网页应用收款沙箱付款指引", "", "1. 启动服务:`{{startCommand}}`", "2. 在浏览器打开:{{paymentUrl}}", "3. 在沙箱收银台二选一:使用沙箱买家账号登录,或仅在 Android 沙箱支付宝中扫描收银台页面二维码。", "4. 沙箱买家账号:{{buyerAccount}}", "5. 登录密码:{{buyerLoginPassword}}", "6. 支付密码:{{buyerPayPassword}}", "7. {{resultPageInstruction}}", "", "沙箱测试环境不稳定,可能出现跳转到支付宝收银台页面后报错,如:504 Gateway Time-out;输入完测试买家账号后展示系统繁忙;输入完测试买家支付密码后展示系统繁忙。您可以回到支付页重新发起支付以完成沙箱测试。", "", "前台页面和同步回跳参数不是支付成功依据,最终以验签通过的异步通知或交易查询为准。用户暂不付款只记为待体验,不得表述为沙箱测试通过。"] }
|
|
559
564
|
}
|
|
560
565
|
},
|
|
561
566
|
{
|
|
@@ -583,7 +588,7 @@
|
|
|
583
588
|
],
|
|
584
589
|
"requiredPolicyIds": ["P-SENSITIVE-STATE"],
|
|
585
590
|
"variants": {
|
|
586
|
-
"DEFAULT": { "templateLines": ["
|
|
591
|
+
"DEFAULT": { "templateLines": ["AI 网页应用收款沙箱付款指引", "", "1. 启动服务:`{{startCommand}}`", "2. 在浏览器打开:{{paymentUrl}}", "3. 在沙箱收银台使用支付宝开放平台控制台中的沙箱买家账号登录,或仅在 Android 沙箱支付宝中扫描收银台页面二维码。", "4. 登录密码和支付密码请直接从本机保存的信息或支付宝开放平台控制台取得,无需再次提供给 Agent。", "5. {{resultPageInstruction}}", "", "沙箱测试环境不稳定,可能出现跳转到支付宝收银台页面后报错,如:504 Gateway Time-out;输入完测试买家账号后展示系统繁忙;输入完测试买家支付密码后展示系统繁忙。您可以回到支付页重新发起支付以完成沙箱测试。", "", "前台页面和同步回跳参数不是支付成功依据,最终以验签通过的异步通知或交易查询为准。用户暂不付款只记为待体验,不得表述为沙箱测试通过。"] }
|
|
587
592
|
}
|
|
588
593
|
},
|
|
589
594
|
{
|
|
@@ -597,9 +602,9 @@
|
|
|
597
602
|
],
|
|
598
603
|
"requiredPolicyIds": ["P-SENSITIVE-STATE"],
|
|
599
604
|
"variants": {
|
|
600
|
-
"AIPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入客户端、日志或公共仓库。", "- `Payment-Proof` 必须调用 `alipay.aipay.agent.payment.verify` 验证;无效或过期凭证拒绝服务,结果不明时不得要求用户重复付款。", "- 资源交付后必须调用 `alipay.aipay.agent.fulfillment.confirm`;履约确认失败必须可重试且保持幂等。", "- 沙箱配置仅用于开发调试;正式上线前必须替换为同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并将 `api_mock_service_id` 替换为真实 `serviceId`。`serviceId` 获取方式:支付宝扫码登录支付宝 AI 付站点 → 控制台 → 服务管理 → 复制审核已通过的服务 ID:https://aipay.alipay.com/?from=alipay-aipay-skill", "- 收款商户 PID/2088
|
|
601
|
-
"WEBPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入客户端、日志或公共仓库。", "- 同步回跳和前台结果不作为支付成功依据;必须以验签通过的异步通知或交易查询为准。", "- 异步通知必须先验签、校验关键字段、幂等处理并返回 `success`;支付结果不明时不得要求用户重复付款。", "- 沙箱配置仅用于开发调试;正式上线前必须替换为同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥。", "-
|
|
602
|
-
"APPPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入 APP 客户端、日志或公共仓库。", "- 客户端支付结果不作为成功依据;必须以验签通过的异步通知或服务端交易查询为准。", "- 异步通知必须先验签、校验关键字段、幂等处理并返回 `success`;支付结果不明时不得要求用户重复付款。", "-
|
|
605
|
+
"AIPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入客户端、日志或公共仓库。", "- `Payment-Proof` 必须调用 `alipay.aipay.agent.payment.verify` 验证;无效或过期凭证拒绝服务,结果不明时不得要求用户重复付款。", "- 资源交付后必须调用 `alipay.aipay.agent.fulfillment.confirm`;履约确认失败必须可重试且保持幂等。", "- 沙箱配置仅用于开发调试;正式上线前必须替换为同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥,并将 `api_mock_service_id` 替换为真实 `serviceId`。`serviceId` 获取方式:支付宝扫码登录支付宝 AI 付站点 → 控制台 → 服务管理 → 复制审核已通过的服务 ID:https://aipay.alipay.com/?from=alipay-aipay-skill", "- 收款商户 PID/2088 用于 AI 按量付费 `seller_id` 和 `seller_unique_id`,不由 Agent 猜测。获取方式:支付宝扫码登录支付宝商家平台 → 点击头像 → 复制账户名下方 2088 开头的商家 ID:https://b.alipay.com/page/portal/home", "- 生产环境必须严格校验本地订单、金额与资源关系;AI 按量付费不使用 AI 网页应用收款/AI 移动应用收款的 `notify_url`,正式收款依赖 `Payment-Proof` 验付和异步履约回执确认。", "- 上线前必须完成人工代码审查;Java 使用 `PKCS#8` 私钥,非 Java 使用 `PKCS#1` 私钥,格式不匹配时只用支付宝官方密钥工具转换。", "", "补充说明:", "- 若忘记代码开发过程中获取的沙箱配置,可以试试对 Agent 说:“沙箱测试买家账号和密码是什么?”。", "- 当前沙箱版支付宝【仅支持 Android 端】,可自行前往网页浏览器打开链接,扫码下载。下载地址:https://mdn.alipayobjects.com/sandboxsys/afts/img/_itHRrdOD9oAAAAAAAAAAAAADgSLAQBr/original", "", "当前验收口径:{{acceptanceSummary}}"] },
|
|
606
|
+
"WEBPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入客户端、日志或公共仓库。", "- 同步回跳和前台结果不作为支付成功依据;必须以验签通过的异步通知或交易查询为准。", "- 异步通知必须先验签、校验关键字段、幂等处理并返回 `success`;支付结果不明时不得要求用户重复付款。", "- 沙箱配置仅用于开发调试;正式上线前必须替换为同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥。", "- AI 网页应用收款生产上线必须配置公网 HTTPS `notify_url`,完成验签、幂等、关键字段校验、成功回写和补偿查询;localhost、局域网地址或其他不可公网访问的地址只能标记为人工待验证。", "- 本地生产参数验收可暂缓公网通知联调;未完成公网 HTTPS `notify_url` 联调时,只能表述为“本地正式验收 / 本地生产参数验收,公网异步通知待补齐”,不能表述为生产就绪。", "- Java 使用 `PKCS#8` 私钥,非 Java 使用 `PKCS#1` 私钥,格式不匹配时只用支付宝官方密钥工具转换。", "", "补充说明:", "- 若忘记代码开发过程中获取的沙箱配置,可以试试对 Agent 说:“沙箱测试买家账号和密码是什么?”。", "- 当前沙箱版支付宝【仅支持 Android 端】,可自行前往网页浏览器打开链接,扫码下载。下载地址:https://mdn.alipayobjects.com/sandboxsys/afts/img/_itHRrdOD9oAAAAAAAAAAAAADgSLAQBr/original", "", "当前验收口径:{{acceptanceSummary}}"] },
|
|
607
|
+
"APPPAY": { "templateLines": ["代码开发安全与上线提醒", "", "- 私钥只保存在商家服务端,禁止写入 APP 客户端、日志或公共仓库。", "- 客户端支付结果不作为成功依据;必须以验签通过的异步通知或服务端交易查询为准。", "- 异步通知必须先验签、校验关键字段、幂等处理并返回 `success`;支付结果不明时不得要求用户重复付款。", "- AI 移动应用收款生产上线必须配置公网 HTTPS `notify_url`,完成验签、幂等、关键字段校验、成功回写和补偿查询;localhost、局域网地址或其他不可公网访问的地址只能标记为人工待验证。", "- 本地生产参数验收可暂缓公网通知联调;未完成公网 HTTPS `notify_url` 联调时,只能表述为“本地正式验收 / 本地生产参数验收,公网异步通知待补齐”,不能表述为生产就绪。", "- Java 使用 `PKCS#8` 私钥,非 Java 使用 `PKCS#1` 私钥,格式不匹配时只用支付宝官方密钥工具转换。", "- 沙箱配置仅用于开发调试;正式上线前必须替换为同一套生产 `appId`、应用公钥、应用私钥和支付宝公钥。", "- 本轮代码开发覆盖商家服务端支付能力;APP 客户端还需接入支付宝客户端 SDK,使用服务端返回的 `orderStr` 调起支付,并完成客户端支付结果展示与服务端异步通知/交易查询的联动测试。若 APP 尚未接入,可以试试继续对 Agent 说:“给我的 APP 接支付宝客户端 SDK,我要做服务端和客户端的联调”(请确保此时你已经有一个开发完毕的 APP)。", "", "补充说明:", "- 若忘记代码开发过程中获取的沙箱配置,可以试试对 Agent 说:“沙箱测试买家账号和密码是什么?”。", "- 当前沙箱版支付宝【仅支持 Android 端】,可自行前往网页浏览器打开链接,扫码下载;或试试让 Agent 帮你解析该地址包含的二维码并下载沙箱版支付宝,下载地址:https://mdn.alipayobjects.com/sandboxsys/afts/img/_itHRrdOD9oAAAAAAAAAAAAADgSLAQBr/original", "- 【友情提醒】如果你当前还没有开发 APP,可以试着让 Agent 帮你安装手机客户端模拟器、开发 APP、接入支付宝客户端 SDK 并安装沙箱版支付宝供测试使用。", "", "当前验收口径:{{acceptanceSummary}}"] }
|
|
603
608
|
}
|
|
604
609
|
},
|
|
605
610
|
{
|
|
@@ -612,7 +617,7 @@
|
|
|
612
617
|
{ "name": "overallResult", "type": "enum", "required": true, "values": ["通过", "部分通过", "未通过"] },
|
|
613
618
|
{ "name": "failedItems", "type": "singleLine", "required": true },
|
|
614
619
|
{ "name": "manualItems", "type": "singleLine", "required": true },
|
|
615
|
-
{ "name": "sandboxResult", "type": "enum", "required": false, "values": ["按量付费沙箱服务端联调通过", "按量付费沙箱服务端联调未通过"] },
|
|
620
|
+
{ "name": "sandboxResult", "type": "enum", "required": false, "values": ["AI 按量付费沙箱服务端联调通过", "AI 按量付费沙箱服务端联调未通过"] },
|
|
616
621
|
{ "name": "webpayExperienceResult", "type": "enum", "required": false, "values": ["已提供浏览器付款入口和操作指引,实际付款及结果验证仍以用户完成情况为准", "未提供浏览器付款入口或完整操作指引,需先补齐", "已提供浏览器付款入口和操作指引;用户已完成一笔沙箱付款,结果只按实际核验证据记录"] },
|
|
617
622
|
{ "name": "sandboxConfigState", "type": "enum", "required": true, "values": ["READY", "CREATE_PENDING", "VERIFY_PENDING"] },
|
|
618
623
|
{ "name": "blockingDefectState", "type": "enum", "required": true, "values": ["NONE", "PRESENT"] },
|
|
@@ -621,17 +626,17 @@
|
|
|
621
626
|
],
|
|
622
627
|
"requiredPolicyIds": [],
|
|
623
628
|
"variants": {
|
|
624
|
-
"AIPAY_PASSED": { "templateLines": ["按量付费代码开发校验通过。", "", "{{nextFlowReminder}}"] },
|
|
625
|
-
"AIPAY_INCOMPLETE": { "templateLines": ["按量付费代码开发校验:{{overallResult}}。", "", "未完成项:{{failedItems}}", "人工待验证:{{manualItems}}", "", "{{nextFlowReminder}}"] },
|
|
626
|
-
"WEBPAY_PASSED": { "templateLines": ["
|
|
627
|
-
"WEBPAY_INCOMPLETE": { "templateLines": ["
|
|
629
|
+
"AIPAY_PASSED": { "templateLines": ["AI 按量付费代码开发校验通过。", "", "{{nextFlowReminder}}"] },
|
|
630
|
+
"AIPAY_INCOMPLETE": { "templateLines": ["AI 按量付费代码开发校验:{{overallResult}}。", "", "未完成项:{{failedItems}}", "人工待验证:{{manualItems}}", "", "{{nextFlowReminder}}"] },
|
|
631
|
+
"WEBPAY_PASSED": { "templateLines": ["AI 网页应用收款代码开发校验通过。", "", "{{nextFlowReminder}}"] },
|
|
632
|
+
"WEBPAY_INCOMPLETE": { "templateLines": ["AI 网页应用收款代码开发校验:{{overallResult}}。", "", "未完成项:{{failedItems}}", "人工待验证:{{manualItems}}", "", "{{nextFlowReminder}}"] },
|
|
628
633
|
"APPPAY_PASSED": {
|
|
629
|
-
"maintenanceTodo": "TODO: 后续确定
|
|
630
|
-
"templateLines": ["
|
|
634
|
+
"maintenanceTodo": "TODO: 后续确定 AI 移动应用收款沙箱测试的对客引导动作后,在本变体补充;同步 integration flow、checklist 和测试。",
|
|
635
|
+
"templateLines": ["AI 移动应用收款代码开发校验通过。", "", "{{nextFlowReminder}}"]
|
|
631
636
|
},
|
|
632
637
|
"APPPAY_INCOMPLETE": {
|
|
633
|
-
"maintenanceTodo": "TODO: 后续确定
|
|
634
|
-
"templateLines": ["
|
|
638
|
+
"maintenanceTodo": "TODO: 后续确定 AI 移动应用收款沙箱测试的对客引导动作后,在本变体补充;同步 integration flow、checklist 和测试。",
|
|
639
|
+
"templateLines": ["AI 移动应用收款代码开发校验:{{overallResult}}。", "", "未完成项:{{failedItems}}", "人工待验证:{{manualItems}}", "", "{{nextFlowReminder}}"]
|
|
635
640
|
}
|
|
636
641
|
}
|
|
637
642
|
},
|
|
@@ -640,7 +645,7 @@
|
|
|
640
645
|
"owner": "catalog_owned",
|
|
641
646
|
"trigger": "AUTH_FLOW:PENDING",
|
|
642
647
|
"blocking": true,
|
|
643
|
-
"
|
|
648
|
+
"allowedReplySet": "affirmative",
|
|
644
649
|
"inputHintType": "authorizationComplete",
|
|
645
650
|
"variables": [],
|
|
646
651
|
"requiredPolicyIds": ["P-AUTH-BEFORE-ONBOARDING"],
|
|
@@ -750,7 +755,7 @@
|
|
|
750
755
|
"allowedReplies": [],
|
|
751
756
|
"variables": [{ "name": "recoveryAction", "type": "singleLine", "required": true }],
|
|
752
757
|
"requiredPolicyIds": ["P-A2M-SUCCESS"],
|
|
753
|
-
"variants": { "DEFAULT": { "templateLines": ["按量付费本地服务尚未达到自动联调前置条件。", "", "需要处理:{{recoveryAction}}", "", "该条件未满足前不会运行自动联调,也不会把服务标记为可用。"] } }
|
|
758
|
+
"variants": { "DEFAULT": { "templateLines": ["AI 按量付费本地服务尚未达到自动联调前置条件。", "", "需要处理:{{recoveryAction}}", "", "该条件未满足前不会运行自动联调,也不会把服务标记为可用。"] } }
|
|
754
759
|
},
|
|
755
760
|
{
|
|
756
761
|
"messageId": "integration.project_path.required",
|
|
@@ -861,7 +866,7 @@
|
|
|
861
866
|
"owner": "catalog_owned",
|
|
862
867
|
"trigger": "application.harmony.manual_create",
|
|
863
868
|
"blocking": true,
|
|
864
|
-
"
|
|
869
|
+
"allowedReplySet": "affirmative",
|
|
865
870
|
"inputHintType": "complete",
|
|
866
871
|
"variables": [],
|
|
867
872
|
"requiredPolicyIds": ["P-MCP-CONTRACT-FROZEN"],
|
|
@@ -931,7 +936,7 @@
|
|
|
931
936
|
"allowedReplies": [],
|
|
932
937
|
"variables": [{ "name": "serviceName", "type": "singleLine", "required": true }],
|
|
933
938
|
"requiredPolicyIds": ["P-PARTIAL-RESULT"],
|
|
934
|
-
"variants": { "DEFAULT": { "templateLines": ["服务 `{{serviceName}}` 的创建或修改调用已返回成功,但未解析到 `serviceId`,因此服务分支尚未完成。接下来会重新查询完整服务列表,并使用本次实际提交资料与列表可见字段做唯一匹配;没有唯一结果时保持未知。在取得实际 `serviceId`
|
|
939
|
+
"variants": { "DEFAULT": { "templateLines": ["服务 `{{serviceName}}` 的创建或修改调用已返回成功,但未解析到 `serviceId`,因此服务分支尚未完成。接下来会重新查询完整服务列表,并使用本次实际提交资料与列表可见字段做唯一匹配;没有唯一结果时保持未知。在取得实际 `serviceId` 前不会宣称 AI 按量付费产品开通完成。", "", "如需自行核对服务状态或服务详情,可前往支付宝 AI 付站点,登录后进入控制台 → 服务管理查看。", "https://aipay.alipay.com/?from=alipay-aipay-skill"] } }
|
|
935
940
|
}
|
|
936
941
|
]
|
|
937
942
|
}
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"policyId": "P-WRITE-CONFIRM",
|
|
18
18
|
"scope": "onboarding.write",
|
|
19
19
|
"severity": "critical",
|
|
20
|
-
"text": "
|
|
20
|
+
"text": "签约材料完整且校验通过后直接执行签约提交,不增加额外确认点;材料缺失或校验失败时继续使用受控材料提示,禁止提交。服务创建资料完整且校验通过后展示受控创建摘要并直接执行,不增加额外确认点;服务修改执行前必须展示当前会话、脱敏主体、产品、动作和目标摘要,并取得绑定当前摘要、通过统一肯定语义判定器校验的明确确认。应用创建由用户针对当前应用候选列表明确选择新建来确认,候选重查未变化且条件字段齐备时不再追加确认;用户提供应用公钥后生成确认页不重复确认,由用户在官方页面完成公钥确认;新建应用的公钥校验成功后直接提交应用审核,不增加额外确认点。"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"policyId": "P-WRITE-UNKNOWN",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"policyId": "P-A2M-SANDBOX",
|
|
78
78
|
"scope": "integration.aipay",
|
|
79
79
|
"severity": "critical",
|
|
80
|
-
"text": "按量付费沙箱 serviceId 固定为 api_mock_service_id,SDK 使用沙箱网关;生产网关和真实 serviceId 只用于正式配置。"
|
|
80
|
+
"text": "AI 按量付费沙箱 serviceId 固定为 api_mock_service_id,SDK 使用沙箱网关;生产网关和真实 serviceId 只用于正式配置。"
|
|
81
81
|
},
|
|
82
82
|
{
|
|
83
83
|
"policyId": "P-A2M-SUCCESS",
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
"policyId": "P-SCAN-PAGE-DELIVERY-BARRIER",
|
|
120
120
|
"scope": "onboarding",
|
|
121
121
|
"severity": "critical",
|
|
122
|
-
"text": "所有 `postRenderHintType=scanReturn` 的页面消息都是交付屏障,当前包括 `auth.page` 和 `application.key.page`。脚本产生页面 stdout 后,Agent 必须先把剔除内部事实后的 stdout 作为独立对客消息送达,再执行对应 opener 和后续有限轮询;不得把后续 `auth.pending`、`application.key.pending`、`process.partial_result` 或其他 stdout
|
|
122
|
+
"text": "所有 `postRenderHintType=scanReturn` 的页面消息都是交付屏障,当前包括 `auth.page` 和 `application.key.page`。脚本产生页面 stdout 后,Agent 必须先把剔除内部事实后的 stdout 作为独立对客消息送达,再执行对应 opener 和后续有限轮询;不得把后续 `auth.pending`、`application.key.pending`、`process.partial_result` 或其他 stdout 合并在同一条对客回复中。该屏障不等待用户确认,不新增确认或其他用户操作。"
|
|
123
123
|
},
|
|
124
124
|
{
|
|
125
125
|
"policyId": "P-DETERMINISTIC-HANDOFF",
|
|
@@ -147,17 +147,17 @@
|
|
|
147
147
|
},
|
|
148
148
|
"authorizationProducts": [
|
|
149
149
|
{
|
|
150
|
-
"productName": "按量付费",
|
|
150
|
+
"productName": "AI 按量付费",
|
|
151
151
|
"salesCode": "I1080300001000160457",
|
|
152
152
|
"scope": "app:all,machine_pay:write,agmnt:write"
|
|
153
153
|
},
|
|
154
154
|
{
|
|
155
|
-
"productName": "
|
|
155
|
+
"productName": "AI 网页应用收款",
|
|
156
156
|
"salesCode": "I1080300001000041203",
|
|
157
157
|
"scope": "app:all,fast_instant_trade_pay:write"
|
|
158
158
|
},
|
|
159
159
|
{
|
|
160
|
-
"productName": "
|
|
160
|
+
"productName": "AI 移动应用收款",
|
|
161
161
|
"salesCode": "I1080300001000041313",
|
|
162
162
|
"scope": "app:all,auth_alipay_apppay:write"
|
|
163
163
|
}
|
|
@@ -29,7 +29,7 @@ printf '%s' "$MESSAGE_INPUT_JSON" | node scripts/render_customer_message.mjs pro
|
|
|
29
29
|
| 付款码 | 使用标准引导 |
|
|
30
30
|
| JSAPI支付 | 使用标准引导 |
|
|
31
31
|
|
|
32
|
-
>
|
|
32
|
+
> “网站支付”“手机网站支付”“H5支付”只是用户对网页场景的旧叫法,在本 Skill 中统一归为 **AI 网页应用收款**,不作为独立产品处理,也不使用拒绝话术。
|
|
33
33
|
|
|
34
34
|
---
|
|
35
35
|
|
|
@@ -3,14 +3,18 @@
|
|
|
3
3
|
import process from 'node:process';
|
|
4
4
|
|
|
5
5
|
import { checkCliEnvironment, isWindowsPlatform } from './platform_compat.mjs';
|
|
6
|
+
import { emitStageMetricAsync } from './telemetry.mjs';
|
|
6
7
|
|
|
7
8
|
function main() {
|
|
8
|
-
|
|
9
|
-
|
|
9
|
+
const mode = process.argv[2];
|
|
10
|
+
if (!['check', 'integration-check'].includes(mode) || process.argv.length !== 3) {
|
|
11
|
+
console.error('用法: node alipay_cli_env.mjs <check|integration-check>');
|
|
10
12
|
process.exitCode = 1;
|
|
11
13
|
return;
|
|
12
14
|
}
|
|
13
15
|
|
|
16
|
+
if (mode === 'integration-check') emitStageMetricAsync('integration.env_prepare.start');
|
|
17
|
+
|
|
14
18
|
const windows = isWindowsPlatform();
|
|
15
19
|
const missing = checkCliEnvironment({
|
|
16
20
|
requireJq: !windows,
|
|
@@ -2,10 +2,44 @@
|
|
|
2
2
|
|
|
3
3
|
set -u
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
MODE="${1:-}"
|
|
6
|
+
if [ "$MODE" != "check" ] && [ "$MODE" != "integration-check" ]; then
|
|
7
|
+
echo "用法: bash alipay_cli_env.sh <check|integration-check> [--product-type aipay|webpay|apppay]" >&2
|
|
7
8
|
exit 1
|
|
8
9
|
fi
|
|
10
|
+
shift
|
|
11
|
+
|
|
12
|
+
case "${BASH_SOURCE[0]}" in
|
|
13
|
+
*/*) SCRIPT_DIR="${BASH_SOURCE[0]%/*}" ;;
|
|
14
|
+
*) SCRIPT_DIR="." ;;
|
|
15
|
+
esac
|
|
16
|
+
# shellcheck source=/dev/null
|
|
17
|
+
source "${SCRIPT_DIR}/common.sh"
|
|
18
|
+
|
|
19
|
+
PRODUCT_TYPE=""
|
|
20
|
+
while [ "$#" -gt 0 ]; do
|
|
21
|
+
case "$1" in
|
|
22
|
+
--product-type)
|
|
23
|
+
[ "$#" -ge 2 ] || { echo "❌ 缺少参数值: $1" >&2; exit 1; }
|
|
24
|
+
PRODUCT_TYPE="$2"
|
|
25
|
+
shift 2
|
|
26
|
+
;;
|
|
27
|
+
*)
|
|
28
|
+
echo "❌ 未知参数: $1" >&2
|
|
29
|
+
exit 1
|
|
30
|
+
;;
|
|
31
|
+
esac
|
|
32
|
+
done
|
|
33
|
+
|
|
34
|
+
if [ -n "$PRODUCT_TYPE" ]; then
|
|
35
|
+
init_alipay_cli_product "$PRODUCT_TYPE" || exit 1
|
|
36
|
+
else
|
|
37
|
+
unset PRODUCT
|
|
38
|
+
fi
|
|
39
|
+
|
|
40
|
+
if [ "$MODE" = "integration-check" ]; then
|
|
41
|
+
emit_stage_metric_async "integration.env_prepare.start"
|
|
42
|
+
fi
|
|
9
43
|
|
|
10
44
|
MISSING=()
|
|
11
45
|
command -v node >/dev/null 2>&1 || MISSING+=("node")
|
|
@@ -117,3 +117,67 @@ init_alipay_cli_context() {
|
|
|
117
117
|
init_platform_id
|
|
118
118
|
export PLATFORM="${DEV_TOOL_NAME:-unknown}"
|
|
119
119
|
}
|
|
120
|
+
|
|
121
|
+
alipay_cli_product_for_type() {
|
|
122
|
+
case "${1:-}" in
|
|
123
|
+
aipay) printf 'AIPAY' ;;
|
|
124
|
+
webpay) printf 'WEBPAY' ;;
|
|
125
|
+
apppay) printf 'APPPAY' ;;
|
|
126
|
+
*) return 1 ;;
|
|
127
|
+
esac
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
alipay_product_type_for_sales_code() {
|
|
131
|
+
case "${1:-}" in
|
|
132
|
+
I1080300001000160457) printf 'aipay' ;;
|
|
133
|
+
I1080300001000041203) printf 'webpay' ;;
|
|
134
|
+
I1080300001000041313) printf 'apppay' ;;
|
|
135
|
+
*) return 1 ;;
|
|
136
|
+
esac
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
init_alipay_cli_product() {
|
|
140
|
+
local product_type="${1:-${ALIPAY_AIPAY_PRODUCT_TYPE:-}}"
|
|
141
|
+
local cli_product
|
|
142
|
+
|
|
143
|
+
cli_product="$(alipay_cli_product_for_type "$product_type")" || {
|
|
144
|
+
echo "❌ 缺少或无法识别支付宝产品上下文(仅支持 aipay|webpay|apppay)" >&2
|
|
145
|
+
return 1
|
|
146
|
+
}
|
|
147
|
+
ALIPAY_AIPAY_PRODUCT_TYPE="$product_type"
|
|
148
|
+
PRODUCT="$cli_product"
|
|
149
|
+
export ALIPAY_AIPAY_PRODUCT_TYPE PRODUCT
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
init_alipay_cli_product_from_sales_code() {
|
|
153
|
+
local product_type
|
|
154
|
+
product_type="$(alipay_product_type_for_sales_code "${1:-}")" || {
|
|
155
|
+
echo "❌ 无法从 salesCode 解析支付宝产品上下文" >&2
|
|
156
|
+
return 1
|
|
157
|
+
}
|
|
158
|
+
init_alipay_cli_product "$product_type"
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
emit_stage_metric_async() {
|
|
162
|
+
local stage="${1:-}"
|
|
163
|
+
local product_name="${2:-}"
|
|
164
|
+
local common_dir telemetry_script
|
|
165
|
+
[ -n "$stage" ] || return 0
|
|
166
|
+
common_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
167
|
+
telemetry_script="${common_dir}/telemetry.mjs"
|
|
168
|
+
[ -f "$telemetry_script" ] && command -v node >/dev/null 2>&1 || return 0
|
|
169
|
+
if [ -n "$product_name" ]; then
|
|
170
|
+
if [ "${ALIPAY_AIPAY_TEST_MODE:-0}" = "1" ]; then
|
|
171
|
+
node "$telemetry_script" stage "$stage" --product-name "$product_name"
|
|
172
|
+
else
|
|
173
|
+
node "$telemetry_script" stage "$stage" --product-name "$product_name" >/dev/null 2>&1 &
|
|
174
|
+
fi
|
|
175
|
+
else
|
|
176
|
+
if [ "${ALIPAY_AIPAY_TEST_MODE:-0}" = "1" ]; then
|
|
177
|
+
node "$telemetry_script" stage "$stage"
|
|
178
|
+
else
|
|
179
|
+
node "$telemetry_script" stage "$stage" >/dev/null 2>&1 &
|
|
180
|
+
fi
|
|
181
|
+
fi
|
|
182
|
+
return 0
|
|
183
|
+
}
|