Documentation ¶
Index ¶
- type App
- func (app *App) IotApiGetAllSimType() *IotApiGetAllSimTypeResult
- func (app *App) IotApiQueryOrderedPkgInfo(simId string) *IotApiQueryOrderedPkgInfoResult
- func (app *App) IotApiQuerySimPkgInfo(simId string, sd int) *IotApiQuerySimPkgInfoResult
- func (app *App) IotApiQueryUserBalance() *IotApiQueryUserBalanceResult
- func (app *App) IotApiQueryUserPkgInfo() *IotApiQueryUserPkgInfoResult
- func (app *App) IotApiRechargeSim(notMustParams ...Params) *IotApiRechargeSimResult
- func (app *App) NewParamsWith(params ...Params) Params
- type IotApiGetAllSimTypeResponse
- type IotApiGetAllSimTypeResult
- type IotApiQueryOrderedPkgInfoResponse
- type IotApiQueryOrderedPkgInfoResult
- type IotApiQuerySimPkgInfoResponse
- type IotApiQuerySimPkgInfoResult
- type IotApiQueryUserBalanceResponse
- type IotApiQueryUserBalanceResult
- type IotApiQueryUserPkgInfoResponse
- type IotApiQueryUserPkgInfoResult
- type IotApiRechargeSimResponse
- type IotApiRechargeSimResult
- type Params
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct { AppID string ApiKey string ZapLog *zap.Logger // 日志服务 Db *gorm.DB // 关系数据库服务 RDb *redis.Client // 缓存数据库服务 MDb *mongo.Client // 非关系数据库服务 }
func (*App) IotApiGetAllSimType ¶
func (app *App) IotApiGetAllSimType() *IotApiGetAllSimTypeResult
IotApiGetAllSimType 卡类型列表查询 https://www.showdoc.com.cn/916774523755909/4858492092033167
func (*App) IotApiQueryOrderedPkgInfo ¶
func (app *App) IotApiQueryOrderedPkgInfo(simId string) *IotApiQueryOrderedPkgInfoResult
IotApiQueryOrderedPkgInfo 查询流量卡已订购流量包 https://www.showdoc.com.cn/916774523755909/5092045889939625
func (*App) IotApiQuerySimPkgInfo ¶
func (app *App) IotApiQuerySimPkgInfo(simId string, sd int) *IotApiQuerySimPkgInfoResult
IotApiQuerySimPkgInfo 流量卡可用流量包查询 https://www.showdoc.com.cn/916774523755909/4880284631482420
func (*App) IotApiQueryUserBalance ¶
func (app *App) IotApiQueryUserBalance() *IotApiQueryUserBalanceResult
IotApiQueryUserBalance 余额查询 https://www.showdoc.com.cn/916774523755909/4857910459512420
func (*App) IotApiQueryUserPkgInfo ¶
func (app *App) IotApiQueryUserPkgInfo() *IotApiQueryUserPkgInfoResult
IotApiQueryUserPkgInfo 账户可用流量包查询 https://www.showdoc.com.cn/916774523755909/4850094776758927
func (*App) IotApiRechargeSim ¶
func (app *App) IotApiRechargeSim(notMustParams ...Params) *IotApiRechargeSimResult
IotApiRechargeSim 单卡流量充值 https://www.showdoc.com.cn/916774523755909/4880284631482420
func (*App) NewParamsWith ¶
type IotApiGetAllSimTypeResult ¶
type IotApiGetAllSimTypeResult struct { Result IotApiGetAllSimTypeResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiGetAllSimTypeResult ¶
func NewIotApiGetAllSimTypeResult(result IotApiGetAllSimTypeResponse, body []byte, err error) *IotApiGetAllSimTypeResult
type IotApiQueryOrderedPkgInfoResponse ¶
type IotApiQueryOrderedPkgInfoResponse struct { Code int `json:"code"` Istest int `json:"istest"` Data []struct { Name string `json:"name"` // 流量包名字 PkgId int64 `json:"pkgId"` // 流量包ID Traffic int `json:"traffic"` // 流量大小,单位:MB Ntraffic float64 `json:"ntraffic"` // 已用量,单位:MB Starttime int `json:"starttime"` // 流量生效起始时间时间戳 Endtime int `json:"endtime"` // 流量生效结束时间时间戳 Addtime int `json:"addtime"` // 订购时间时间戳 } `json:"data"` Msg string `json:"msg"` }
type IotApiQueryOrderedPkgInfoResult ¶
type IotApiQueryOrderedPkgInfoResult struct { Result IotApiQueryOrderedPkgInfoResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiQueryOrderedPkgInfoResult ¶
func NewIotApiQueryOrderedPkgInfoResult(result IotApiQueryOrderedPkgInfoResponse, body []byte, err error) *IotApiQueryOrderedPkgInfoResult
type IotApiQuerySimPkgInfoResponse ¶
type IotApiQuerySimPkgInfoResponse struct { Code int `json:"code"` Istest int `json:"istest"` Data []struct { PkgId int `json:"pkgId"` // 流量包ID PkgName string `json:"pkgName"` // 流量包名字 Price float64 `json:"price"` // 流量包成本价格,单位: 元 Sprice float64 `json:"sprice"` // 流量包零售价格,单位: 元 Traffic int `json:"traffic"` // 流量包大小,单位: MB Type int `json:"type"` // 流量包类型,1:叠加包 2:单月套餐 3:季度套餐 4:半年套餐 5:全年套餐 6:每月套餐 (3个月) 7:每月套餐(6个月) 8:每月套餐(12个月) 0:N天套餐 Isdm int `json:"isdm"` // 是否依赖主套餐,此字段只有套餐类型为叠加包时有效; 1:依赖主套餐 0:独立 Isnm int `json:"isnm"` // 是否支持次月生效,此字段只有套餐类型为独立叠加包时有效; 1:支持 0:不支持 Istest int `json:"istest"` // 是否为体验包; 1:是 0:否 Isimm int `json:"isimm"` // 订购后是否立即叠加生效; 1:是 0:否 Stime string `json:"stime"` // 套餐的生效起始日期 Etime string `json:"etime"` // 套餐的生效结束日期 Daynum int `json:"daynum"` // 当type=0时,表示套餐有效天数;当type=8 且 daynum>0 时,表示套餐的有效年数 } `json:"data"` Msg string `json:"msg"` }
type IotApiQuerySimPkgInfoResult ¶
type IotApiQuerySimPkgInfoResult struct { Result IotApiQuerySimPkgInfoResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiQuerySimPkgInfoResult ¶
func NewIotApiQuerySimPkgInfoResult(result IotApiQuerySimPkgInfoResponse, body []byte, err error) *IotApiQuerySimPkgInfoResult
type IotApiQueryUserBalanceResult ¶
type IotApiQueryUserBalanceResult struct { Result IotApiQueryUserBalanceResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiQueryUserBalanceResult ¶
func NewIotApiQueryUserBalanceResult(result IotApiQueryUserBalanceResponse, body []byte, err error) *IotApiQueryUserBalanceResult
type IotApiQueryUserPkgInfoResponse ¶
type IotApiQueryUserPkgInfoResponse struct { Code int `json:"code"` Data []struct { Type int `json:"type"` PkgId int64 `json:"pkgId"` PkgName string `json:"pkgName"` Price float64 `json:"price"` Sprice float64 `json:"sprice"` Traffic int `json:"traffic"` Caltype int `json:"caltype"` SimType int `json:"simType"` Isdm int `json:"isdm"` Isnm int `json:"isnm"` Istest int `json:"istest"` Isimm int `json:"isimm"` Daynum int `json:"daynum"` } `json:"data"` Msg string `json:"msg"` }
type IotApiQueryUserPkgInfoResult ¶
type IotApiQueryUserPkgInfoResult struct { Result IotApiQueryUserPkgInfoResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiQueryUserPkgInfoResult ¶
func NewIotApiQueryUserPkgInfoResult(result IotApiQueryUserPkgInfoResponse, body []byte, err error) *IotApiQueryUserPkgInfoResult
type IotApiRechargeSimResult ¶
type IotApiRechargeSimResult struct { Result IotApiRechargeSimResponse // 结果 Body []byte // 内容 Err error // 错误 }
func NewIotApiRechargeSimResult ¶
func NewIotApiRechargeSimResult(result IotApiRechargeSimResponse, body []byte, err error) *IotApiRechargeSimResult
Click to show internal directories.
Click to hide internal directories.