swagger.json 5.49 KB
Newer Older
wangp's avatar
wangp committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147
{
    "swagger": "2.0",
    "info": {
        "title": "beego Test API",
        "description": "beego has a very cool tools to autogenerate documents for your API",
        "version": "1.0.0",
        "termsOfService": "http://beego.me/",
        "contact": {
            "email": "astaxie@gmail.com"
        },
        "license": {
            "name": "Apache 2.0",
            "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
        }
    },
    "basePath": "/api",
    "paths": {
        "/index/unified_order": {
            "post": {
                "tags": [
                    "index"
                ],
                "description": "拉卡拉统一支付",
                "operationId": "PayController.",
                "parameters": [
                    {
                        "in": "body",
                        "name": "data",
                        "description": "输入项",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/model.PlaceAnOrderParamInput"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": ""
                    }
                }
            }
        }
    },
    "definitions": {
        "model.PlaceAnOrderParamInput": {
            "title": "PlaceAnOrderParamInput",
            "type": "object",
            "properties": {
                "app_id": {
                    "description": "wxAppId source code 2 小程序支付时必传、同时小程序支付必须关联了商户号支付",
                    "type": "string"
                },
                "attach_info": {
                    "description": "附加信息",
                    "type": "string"
                },
                "customer": {
                    "description": "顾客信息",
                    "type": "string"
                },
                "dynamic_id": {
                    "description": "顾客手机条码的内容",
                    "type": "string"
                },
                "goods_des": {
                    "description": "商品描述",
                    "type": "string"
                },
                "goods_detail": {
                    "description": "商品详情",
                    "type": "string"
                },
                "goods_price": {
                    "description": "商品金额,个位为分",
                    "type": "number",
                    "format": "double"
                },
                "is_serve": {
                    "description": "0直连模式  1服务商模式",
                    "type": "integer",
                    "format": "int32"
                },
                "notice_url": {
                    "description": "客户端回调的url",
                    "type": "string"
                },
                "open_id": {
                    "description": "此参数 支付类型是 JS API 的时候 必传",
                    "type": "string"
                },
                "operator": {
                    "description": "操作员",
                    "type": "string"
                },
                "pay_type": {
                    "description": "1: 微信,2: 支付宝, 3: 拉卡拉 4: 收钱吧",
                    "type": "integer",
                    "format": "int64"
                },
                "platform_info": {
                    "description": "平台信息",
                    "type": "string"
                },
                "platform_type": {
                    "description": "平台类型 1: saas  2: shop 3: shop mobile 4: 收银台",
                    "type": "integer",
                    "format": "int32"
                },
                "quit_url": {
                    "description": "返回按钮 可用于用户付款中途退出并返回到该参数指定的商户网站地址, 支付方式为 支付宝手机网站时 必传(尽量传)",
                    "type": "string"
                },
                "return_url": {
                    "description": "用户在完成支付后,会根据商户在请求支付API中传入的前台回跳地址return_url自动跳转return_url地址页面(必传)",
                    "type": "string"
                },
                "source_code": {
                    "description": "1: 微信 Native  2:微信小程序  3:微信内支付 4:h5 跳微信 5:支付宝(web)-扫码或登录支付宝账户  6:alipay(mobile) 7:alipay(app) 9: B2C 10:bk支付宝web 11:bk 支付宝手机",
                    "type": "integer",
                    "format": "int32"
                },
                "store_sn": {
                    "description": "商户门店编号",
                    "type": "string"
                },
                "sub_mchid": {
                    "description": "通过进件接口申请的支付商户号、这是由微信生成并下发的",
                    "type": "string"
                },
                "wap_name": {
                    "description": "WAP网站名称, 支付方式为微信MWEB时 必传",
                    "type": "string"
                },
                "wap_url": {
                    "description": "WAP网站URL地址, 支付方式为微信MWEB时 必传",
                    "type": "string"
                }
            }
        }
    },
    "tags": [
        {
            "name": "index",
            "description": "拉卡拉统一支付\n"
        }
    ]
}