1 Star 0 Fork 0

fastbird/快手api

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
convert_list_request.go 967 Bytes
一键复制 编辑 原始数据 按行查看 历史
zz8304 提交于 2个月前 . new function
package tool
import (
"net/url"
"strconv"
)
// ConvertListRequest 获取可用的转化目标 API Request
type ConvertListRequest struct {
// AdvertiserID 广告主ID
AdvertiserID uint64 `json:"advertiser_id,omitempty"`
// Type 转化目标类型; 1:JS布玛 2:Xpath 3:应用-SDK 7:应用-API
Type int `json:"type,omitempty"`
// Page 页码
Page int `json:"page,omitempty"`
// PageSize 每页行数
PageSize int `json:"page_size,omitempty"`
}
// Url implement GetRequest interface
func (r ConvertListRequest) Url() string {
return "v1/tool/convert/list"
}
// Encode implement GetRequest interface
func (r ConvertListRequest) Encode() string {
values := &url.Values{}
values.Set("advertiser_id", strconv.FormatUint(r.AdvertiserID, 10))
values.Set("type", strconv.Itoa(r.Type))
if r.Page > 0 {
values.Set("page", strconv.Itoa(r.Page))
}
if r.PageSize > 0 {
values.Set("page_size", strconv.Itoa(r.PageSize))
}
return values.Encode()
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/fastbird_rta/kwai-marketing-api.git
git@gitee.com:fastbird_rta/kwai-marketing-api.git
fastbird_rta
kwai-marketing-api
快手api
39b604fa7cb0

搜索帮助