企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
[TOC] ## 充值押金 * 请求地址: `/user_topup/save` * 请求方式: post * 请求参数: | 字段名 | 字段类型 | 字段长度 | 必填 | 字段说明 | | --- | --- | --- | --- | --- | | `type` | int | 11 | `是` | 充值类型 | | `mode` | int | 11 | `是` | 支付方式 | >[info] 充值类型 0余额 1 押金 > 支付方式 0微信 1 支付宝 * 成功返回: ```json { "code": 0, "data": {//微信支付需要参数 "appid": "", "partnerid": "", "prepayid": "", "noncestr": "", "timestamp": , "package": "", "sign": "" } } ``` * 失败返回: 其他错误信息 ## 充值押金(返回) ~~~[api] post:/user_topup/save *int:type=1# 充值类型 0 余额 1押金 *int:mode=0# 支付方式 0 微信 1 支付宝 <<< success //微信支付返回 { "code": 0, "data": {//微信支付需要参数 "id":"11", "appid": "", "partnerid": "", "prepayid": "", "noncestr": "", "timestamp": , "package": "", "sign": "" } } <<< success //支付宝支付返回 { "code": 0, "data": { "result": "alipay_sdk=alipay-sdk-php-20161101&app_id=2018032202428621&biz_content=%7B%22body%22%3A%22%E8%B6%85%E7%A5%9E%E5%AE%BF-%E6%8A%BC%E9%87%91%E5%85%85%E5%80%BC%22%2C%22subject%22%3A%22%E6%8A%BC%E9%87%91%E5%85%85%E5%80%BC%22%2C%22out_trade_no%22%3A%22ABvZGW15232662389501%22%2C%22timeout_express%22%3A%2230m%22%2C%22total_amount%22%3A%220.01%22%2C%22product_code%22%3A%22QUICK_MSECURITY_PAY%22%2C%22passback_params%22%3A%22%22%7D&charset=utf-8&format=JSON&method=alipay.trade.app.pay&notify_url=http%3A%2F%2Flocalhost%3A8003%2Fuser%2Falipay%2FdepositNotice&sign_type=RSA2&timestamp=2018-04-09+17%3A30%3A38&version=1.0&sign=D6rPLpz0%2Ft3ric%2FreSVsxBfol9iV4Zt9PXhAgJpLH0PgjVlm4Z9OifyM8RM0koF8EtY61I06pw7jedhEBiaH8cVTiPeYNnTkaSmxyOZ9P3BPQ%2BAi6yGNQorW%2B3S6f0WvTN%2FkZxVfaho7Hd7XBTYyN60ZeJPdy25NAFixP%2F%2FDKUBLHQCyer%2FWAlwLVo2UIOWLKkTU4GVppBQ8jkBYxmp%2Fh2zreJ3gXzOGAtwXc16NC9fiqLex2V69dcJ7hh9jNNlvRVQ1c0UrHs%2B2Ijcs7nUL%2FyIj4FthpgyLJPFrLcMEFfYjhGYVq6uk%2FHD%2BpOuPs6Vhs3UM1mDPE60AOQDczuu99g%3D%3D", "id": "58" } } <<< error { "code": -1, "msg": "不支持该方式支付" } ~~~ ## 查询支付结果 ~~~[api] get:/user_topup/read *int:id=0#支付参数中的id <<< success { "code": 0, "data": { "status": 0,//支付状态 0 未支付 1支付成功 2 支付失败 "sum":0//充值的金额 } } ~~~