修改回调接口解析参数的方式

This commit is contained in:
2026-09-20 21:15:35 +08:00
parent 57e0854a0e
commit ae94c1dc00
2 changed files with 29 additions and 7 deletions
+5
View File
@@ -454,6 +454,11 @@ curl -X POST "https://{接口域名}/enterprise/api/receipt/getPaymentReceipt" \
| oil_price | 是 | number/null | 油品原价(分) |
| actual_oil_price | 是 | number/null | 油品实际价格 |
**⚠️ 推送用 `multipart/form-data`,不是 JSON 请求体**:业务参数放在表单字段 `params` 里(JSON 字符串)。
- PHP:`php://input` 在这种 Content-Type 下恒为空,必须取 `$_POST['params']` 再 `json_decode`
- Java(Spring):用 `@RequestParam("params") String params`,`@RequestBody` 取不到
**接入方需返回**:`{"code":"100","msg":"Success"}`
> 测试环境可用 **7.23** 模拟一笔平安消费来联调本回调。