# 查询余额 ## 描述 >此功能允许运营商在游戏提供商的钱包中获取最新会员余额。 > 请求方式( Host-> BCWIN):post > 编码方式:application/x-www-form-urlencoded > BCWIN响应的数据格式是: application/json ## 网址 > {bcwinapi}/api/game/getbalance ## 请求参数 | 名称 | 类型 | 必要 | 描述 | | -------- | -------- | ------------ | -------- | | cert | int32 | Y | 安全代码 | | extension1 |string | Y | 代理 ID | | users | string(500) | Y | 用逗号(,)分隔的一系列用户名。没有users参数返回代理所有玩家分数 | ## 示例 - URL: - http://127.0.0.1:8000/api/game/getbalance - HTTP Method - POST - 表单数据 > Content-Type: application/x-www-form-urlencoded ``` cert:v8VMKKzlPpD0te4rX99Hgefs3PQrBFWJKiuUqg6Y extension1:adminweb user:test1 ``` ## 返回结果 | 名称 | 类型 | 描述 | | -------- | -------- | -------- | | status |int32| 状态代码,类型是int32_t | | extension1 | dstring | 代理帐号 | | etotalscore | double | 查询总分 | | users| array | 查询的玩家,只有查询指定玩家才有 | |users.user| string | 玩家账号 | |users.curscore| double | 玩家当前分数 | ## 成功的结果 ```CPP { "extension1": "agent", "status": 1, "totalscore": "200000000",  "users": [         {             "user": "test1",             "curscore": "100000000"         },         {             "user": "test2",             "curscore": "100000000"         }     ] } { "extension1": "admin", "status": 1,     "totalscore": "0",     "users": [] } ``` ## 查无资料的结果 ``` { "extension1": "admin", "status": 1,     "totalscore": "0",     "users": [] } ``` ## 失败的结果 ``` {"status": 1003} ```