Cue 语音文档

懂的人自然懂


v2.4.5

<p>[TOC]</p> <h1>游客通知(新版)</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">action: guestex</td> <td style="text-align: left;">主题: user.track</td> </tr> </tbody> </table> <pre><code>type UTGuest struct { Action string `json:"guestex"` Platform string `json:"platform"` // android/ios LangCode string `json:"lang_code"` // zh-CN Model string `json:"model"` // XiaomiMi-4c AppVersion string `json:"app_version"` // 1.1.8 (100001) SystemVersion string `json:"system_version"` // SDK 24 Channel string `json:"channel"` // 渠道 appstore/google play/360/baidu/... Udid string `json:"udid"` // 设备唯一ID VestId int `json:"vest_id"` // 马甲包ID Ip string `json:"ip"` Time int `json:"time"` }</code></pre> <h1>靓号库结构</h1> <pre><code>type EUNoState int // const ( EUNoS_Idle EUNoState = 1 // 闲置中 EUNoS_Shop = 2 // 上架中 EUNoS_Sell = 3 // 已出售 EUNoS_Recy = 4 // 已回收 ) type UniqueNo struct { Id int64 `json:"id"` No string `json:"no" xorm:"notnull index varchar(16)"` // 靓号 Lv int64 `json:"lv" xorm:"notnull default 0"` // 靓号等级 Digit int64 `json:"digit" xorm:"notnull default 0"` // 靓号位数 CobTyp string `json:"cob_typ" xorm:"notnull varchar(16)"` // 靓号组合类型(ABACCCCC ... ) State EUNoState `json:"state" xorm:"notnull default 1"` // 状态 Price int32 `json:"price" xorm:"notnull default 0"` // 上架价格 Belong int64 `json:"belong" xorm:"notnull default 0"` // 归属者uid InitNo int64 `json:"init_no" xorm:"notnull default 0"` // 归属者原始号 DealAt int64 `json:"dealAt" xorm:"notnull default 0"` // 交易时间 RecyAt int64 `json:"recyAt" xorm:"notnull default 0"` // 回收时间 UpdatedAt int64 `json:"updated" xorm:"updated"` // 更新时间 CreatedAt int64 `json:"created" xorm:"created"` // 生成时间 CondCols []string `json:"-" xorm:"-"` CondOmit []string `json:"-" xorm:"-"` } // func (this *UniqueNo) TableName() string { return "unique_no" }</code></pre> <h1>[APP]靓号标记</h1> <p><em>影响以下接口</em></p> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/web/(getProfile)</td> <td style="text-align: left;">-</td> </tr> <tr> <td style="text-align: left;">/user/(getUserFull)</td> <td style="text-align: left;">-</td> </tr> <tr> <td style="text-align: left;">/user/(getUserSelf)</td> <td style="text-align: left;">-</td> </tr> <tr> <td style="text-align: left;">account/login</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 更新一下结构: type UserSelf struct { Id string `json:"id"` No string `json:"no"` UNo int `json:"uno"` // 1: 靓号 [新增] ... }</code></pre> <h1>[APP]靓号商城列表</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/item/uniqueNoList</td> <td style="text-align: left;">支持查询</td> </tr> </tbody> </table> <pre><code>// 入参 conds string // 包含的子数字 [可选] // 出参 struct { List proto.TUniqueNoItems `json:"list"` // 这是个数组(已按位数排序),结构如下: } type UniqueNo struct { No string `json:"no"` // 靓号 Lv int64 `json:"lv"` // 靓号等级 Digit int64 `json:"digit"` // 靓号位数 Price int32 `json:"price"` // 上架价格 UpdatedAt int64 `json:"updated"` // 更新时间 }</code></pre> <h1>[APP]靓号商城购买</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/item/uniqueNoBuy</td> <td style="text-align: left;"></td> </tr> </tbody> </table> <pre><code>// 入参 no string // 购买的靓号 // 出参 </code></pre> <h1>[后台]靓号上架</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/up</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 入参 id int64 // price int // 价格(金币) // 出参 service.NewError(400, "UNIQUE_NO_ALREADY BELONG") 当收到此错误信息时 表示 此靓号已经老用户占用, 且系统已经进行此靓号与老用户之间的关系绑定, 靓号状态更新为 已交易状态. 页面操作时可以给予一定友好提示.</code></pre> <h1>[后台]靓号下架</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/down</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 入参 id int64 // // 出参 </code></pre> <h1>[后台]靓号发放</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/send</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 入参 id int64 // sendTo int64 // 送给谁 userId // 出参 </code></pre> <h1>[后台]靓号回收</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/recy</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 入参 id int64 // // 出参 </code></pre> <h1>[后台]靓号修改价格</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/edit</td> <td style="text-align: left;">-</td> </tr> </tbody> </table> <pre><code>// 入参 id int64 // price int // 价格(金币) // 出参 </code></pre> <h1>[后台]靓号添加</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/sys/uniqueNo/insert</td> <td style="text-align: left;">详细阅读</td> </tr> </tbody> </table> <p><strong>这个接口比较特殊,大概有以下几种场景:</strong></p> <ul> <li>添加一个清白的靓号,需要赋值 no lv digit cob_type</li> <li>添加一个待回收的靓号, 需要赋值 no lv digit cob_type state=3 belong init_no(如果不知道老no,可以不用赋值)</li> <li>不允许直接添加一个已回收 或者 已上架 的靓号.</li> </ul> <pre><code>// 入参 no := md.Get("no").String() lv := md.Get("lv").Int64() digit := md.Get("digit").Int64() cob_typ := md.Get("cob_typ").String() state := md.Get("state").Int32() belong := md.Get("belong").Int64() init_no := md.Get("init_no").Int64() // 出参 返回 主键id</code></pre> <h1>[APP]新版横幅</h1> <table> <thead> <tr> <th style="text-align: left;">推送ID</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">-508</td> </tr> </tbody> </table> <pre><code>type SimpleTLUser struct { Id string `json:"id"` Name string `json:"name"` CC string `json:"cc"` No int `json:"no,omitempty"` Age int `json:"age,omitempty"` Gender int `json:"gender,omitempty"` VipLvl int `json:"viplvl,omitempty"` Photo map[string]string `json:"photo,omitempty"` PhotoUrl string `json:"photo_url"` } // 新版横幅公告信息 type GlobalBannerInfo struct { MainType int `json:"main_type"` // 主类型 1礼物 2游戏 SubType int `json:"sub_type"` // 子类型 游戏类型 1猜拳 2大转盘 3ludo GameIcon string `json:"game_icon"` // 游戏图标 WinIcon string `json:"win_icon"` // 游戏赢分小图标 FromUser *proto.SimpleTLUser `json:"from_user"` ToUser *proto.SimpleTLUser `json:"to_user"` Gift *proto.Gift `json:"gift"` RoomId int `json:"room_id"` Amount int `json:"amount"` // 数量 }</code></pre> <h1>炸金花H5游戏-信息[新增]</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/web/game/bombFlower/info</td> <td style="text-align: left;">尽量兼容别人的协议</td> </tr> </tbody> </table> <pre><code class="language-go">// 入参 uid int64 round int64 // 返回 { Select map[string]int `json:"select"` // 当前的选中 Countdown int `json:"countdown"` // 当前的倒计时 Avatar string `json:"avatar"` // 头像 (小图) Nick string `json:"nick"` // 昵称 Coin int `json:"gold"` // 现有金币数 Round int64 `json:"round"` // 当前的轮数 (别人的协议是 string 类型) TimeUnix int64 `json:"time"` // 当前时间戳 (别人的协议是 string 类型) Profit int64 `json:"profit"` // 当日收益 Result string `json:"result,omitempty"` // 指定局的结果 BoutInfo biz.FlowerBout `json:"bout_info"` // 指定游戏对局信息 ResultList []string `json:"resultList"` // 最近10次的结果列表 WinCoin int64 `json:"winGold,omitempty"` // 指定局收益 } // FlowerBout 对局信息 type FlowerBout struct { Bout int64 `json:"bout"` // 第几局 OverAt int64 `json:"over_at"` // 结束时间 Player [3]*Chair `json:"player"` // 三张椅子 WinChair string `json:"win_chair"` // 赢的椅子名称 } // Chair 椅子信息 type Chair struct { ChairName string `json:"chair_name"` // 椅子名称 HandCards *Cards `json:"hand_cards"` // 椅子的牌 Pattern int `json:"pattern"` // 椅子牌型 } // Cards 牌组 type Cards struct { Data []*Card `json:"data"` } // Card 牌信息 type Card struct { CardType int `json:"card_type"` // 牌类型 1方块 2梅花 3红桃 4黑桃 CardPoint int `json:"card_point"` // 牌值大小 }</code></pre> <h1>炸金花H5游戏-下注[新增]</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/web/game/bombFlower/choice</td> <td style="text-align: left;">尽量兼容别人的协议</td> </tr> </tbody> </table> <pre><code class="language-go">// 入参 uid int64 choice string // 选择的椅子名称 012 gold int // 下注金额 round int64 // 游戏局数ID // 出参 &amp;struct { Coin int `json:"coin"` // 用户剩余金币数量 }</code></pre> <h1>炸金花H5游戏-所有下注信息[新增]</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/web/game/bombFlower/bill</td> <td style="text-align: left;">尽量兼容别人的协议</td> </tr> </tbody> </table> <pre><code class="language-go">// 入参 token string round int64 // 游戏局数ID // 出参 &amp;struct { Select [3][2]int `json:"select"` // 当前的选中 00 A所有 01 A自己 10 B所有 11 B自己 20 C所有 21 C自己 }</code></pre> <h1>炸金花H5游戏-排行榜[新增]</h1> <table> <thead> <tr> <th style="text-align: left;">接口名</th> <th style="text-align: left;">备注</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">/v1/web/game/bombFlower/rank</td> <td style="text-align: left;">尽量兼容别人的协议</td> </tr> </tbody> </table> <pre><code class="language-go">// 入参 token string // 出参 &amp;struct { DayRank []FlowerTopItem `json:"day_rank"` WeekRank []FlowerTopItem `json:"week_rank"` }</code></pre>

页面列表

ITEM_HTML