# -*- coding: utf-8 -*- import _common class Wallet(object): def __init__(self): self.apis = [ { 'name': 'withdrawal', 'desc': '提现(game->token)', 'group': 'Wallet', 'url': 'webapp/index.php?c=Wallet&a=withdrawal', 'params': [ ['account', 0, '钱包账号'], ['token', '', 'token'], ['type', 0, '货币类型 1:金币 2:钻石'], ['amount', '', '金额'], ['net_id', '', '网络id'], ], 'response': [ _common.RspHead(), ['seq_id', '', '提现序号(errcode = 0的时候,根据序号客户端定时调用queryWithdrawalResult接口)查询状态'], ] }, { 'name': 'queryWithdrawalResult', 'desc': '查询提现结果(game->token)', 'group': 'Wallet', 'url': 'webapp/index.php?c=Wallet&a=queryWithdrawalResult', 'params': [ ['account', 0, '钱包账号'], ['token', '', 'token'], ['seq_id', 0, '提现序号'], ['net_id', '', '网络id'], ], 'response': [ _common.RspHead(errcode='当errcode!=0的时候客户端不需要再调用(停止定时器)'), ['state', 0, '0:提现序号不存在 1:提现成功 2:提现处理中 3:提现失败'], ] }, { 'name': 'queryRechargeResult', 'desc': '查询充值结果(token->game)', 'group': 'Wallet', 'url': 'webapp/index.php?c=Wallet&a=queryRechargeResult', 'params': [ ['account', 0, '钱包账号'], ['token', '', 'token'], ['txhash', 0, 'hash值'], ['net_id', '', '网络id'], ], 'response': [ _common.RspHead(), ['state', 0, '0:保留 1:充值成功 2:充值处理中 3:充值失败'], ] }, ]