# -*- coding: utf-8 -*- import _common class Shop(object): def __init__(self): self.apis = [ { 'name': 'info', 'desc': '获取商店信息', 'group': 'Shop', 'url': 'webapp/index.php?c=Shop&a=info', 'params': [ _common.ReqHead(), ['shop_id', '', '商店id'], ], 'response': [ _common.RspHead(), ['info', _common.Shop(), '商店信息'], ] }, { 'name': 'buyGoods', 'desc': '购买商品', 'group': 'Shop', 'url': 'webapp/index.php?c=Shop&a=buyGoods', 'params': [ _common.ReqHead(), ['shop_id', 0, '商店id'], ['goods_id', 0, '商品id'], ['cost_item_id', 0, '支付方式'], ], 'response': [ _common.RspHead(), ['award', _common.Award(), '奖励信息'], ['property_chg', _common.PropertyChg(), '属性变更'], ] }, { 'name': 'outsideBuy', 'desc': '购买道具(商店外购买)', 'group': 'Shop', 'url': 'webapp/index.php?c=Shop&a=outsideBuy', 'params': [ _common.ReqHead(), ['item_id', 0, '商品id'], ['item_num', 0, '购买数量'], ['cost_item_id', 0, '支付方式'], ], 'response': [ _common.RspHead(), ['award', _common.Award(), '奖励信息'], ['property_chg', _common.PropertyChg(), '属性变更'], ] }, { 'name': 'getOutsidePriceInfo', 'desc': '获取价格信息(商店外购买目前只有:英雄、英雄皮肤、枪支皮肤)', 'group': 'Shop', 'url': 'webapp/index.php?c=Shop&a=getOutsidePriceInfo', 'params': [ _common.ReqHead(), ], 'response': [ _common.RspHead(), ['!price_list', [_common.ItemPriceInfo()], '价格信息'], ] }, ]