java http协议接口测试_java soa接口测试,可以使用http协议调用

post调用url:“接口url”+/rpc

post调用参数body:

{

"ver": "接口版本号",

"soa":{"req":"123"},    //123取值随意?

"iface":"接口调用依赖方法",

"method":"接口调用方法名",

"args":{"arg0":"参数0","arg1":"参数1","arg2":"参数2"}

}

例如:请求url:http://vpcb-lpdinfra-stream-1.vm.elenet.me:8989/rpc

body:

{ "ver":"1.0",

"soa":{"req":"123"},

"iface":"me.ele.lpdinfra.prediction.service.PredictionService",

"method":"restaurant_make_order_time",

"args":{"arg2":"\"stable\"","arg1":"{\"code\":[\"WIND\"],\"temperature\":11.11}","arg0":"{\"tracking_id\":\"100000000331770936\",\"eleme_order_id\":\"100000000331770936\",\"platform_id\":\"4\",\"restaurant_id\":\"482571\",\"dish_num\":1,\"dish_info\":[{\"entity_id\":142547763,\"quantity\":1,\"category_id\":1,\"dish_name\":\"番茄炒蛋\",\"price\":1.0}],\"merchant_location\":{\"longitude\":\"121.47831425\",\"latitude\":\"31.27576153\"},\"customer_location\":{\"longitude\":\"121.47831425\",\"latitude\":\"31.27576153\"},\"created_at\":1472809544,\"confirmed_at\":1472809545,\"dishes_total_price\":0.0,\"food_boxes_total_price\":2.0,\"delivery_total_price\":2.0,\"pay_amount\":0.0,\"city_id\":\"1\"}"}

}

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值