diff --git a/doc/api/transfercastile.api b/doc/api/transfercastile.api index d1ff4cb..3cb496f 100644 --- a/doc/api/transfercastile.api +++ b/doc/api/transfercastile.api @@ -44,8 +44,8 @@ type TransferCastileToGameListResp { } type UserCastileBalanceResp { - TotalCastile int `json:total_castile` //总数 - TransferAmount int `json:transfer_amount` //已转回游戏内的数量 - TotalBalance int `json:total_balance` //castile当前余额 + TotalCastile int `json:"total_castile"` //总数 + TransferAmount int `json:"transfer_amount"` //已转回游戏内的数量 + TotalBalance int `json:"total_balance"` //castile当前余额 } diff --git a/doc/swagger/nova.json b/doc/swagger/nova.json index 33bad16..f70ed84 100644 --- a/doc/swagger/nova.json +++ b/doc/swagger/nova.json @@ -895,6 +895,28 @@ ] } }, + "/gapi/transfercastile/v1/getBalance": { + "post": { + "summary": "查询castile代币余额", + "operationId": "GetCastileBalance", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/UserCastileBalanceResp" + } + } + }, + "tags": [ + "transfercastile" + ], + "security": [ + { + "apiKey": [] + } + ] + } + }, "/gapi/transfercastile/v1/list": { "post": { "summary": "获取提取castile到游戏的记录", @@ -2068,6 +2090,32 @@ "email" ] }, + "UserCastileBalanceResp": { + "type": "object", + "properties": { + "total_castile": { + "type": "integer", + "format": "int32", + "description": "总数" + }, + "transfer_amount": { + "type": "integer", + "format": "int32", + "description": "已转回游戏内的数量" + }, + "total_balance": { + "type": "integer", + "format": "int32", + "description": "castile当前余额" + } + }, + "title": "UserCastileBalanceResp", + "required": [ + "total_castile", + "transfer_amount", + "total_balance" + ] + }, "UserNft": { "type": "object", "properties": { diff --git a/internal/types/types.go b/internal/types/types.go index 9a973f6..4e42ab5 100644 --- a/internal/types/types.go +++ b/internal/types/types.go @@ -277,9 +277,9 @@ type UnlockChapterReq struct { } type UserCastileBalanceResp struct { - TotalCastile int `json:total_castile` //总数 - TransferAmount int `json:transfer_amount` //已转回游戏内的数量 - TotalBalance int `json:total_balance` //castile当前余额 + TotalCastile int `json:"total_castile"` //总数 + TransferAmount int `json:"transfer_amount"` //已转回游戏内的数量 + TotalBalance int `json:"total_balance"` //castile当前余额 } type UserNft struct {