Protocol Documentation

Table of Contents

auth.proto

Top

授权中心

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

Auth

授权中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

base.proto

Top

通用

设计中

Empty

空返回

IdReq

IdReq 通用Id参数

FieldTypeLabelDescription
id int64

数据ID

ListReq

ListReq 通用列表参数

FieldTypeLabelDescription
cond string

条件

page int64

页码

limit int64

页数

Map

Map 通用

FieldTypeLabelDescription
data Map.DataEntry repeated

数据

Map.DataEntry

FieldTypeLabelDescription
key string

value string

cms.proto

Top

内容中心

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

cms

商品中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

file.proto

Top

文件中心

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

file

商品中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

order.proto

Top

订单中心

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

order

商品中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

pay.proto

Top

支付中心

设计中

GenResp

生成支付单返回值

FieldTypeLabelDescription
payment_no string

支付单号

order_no string

订单号

pay_type payType repeated

支持的支付方式列表

OrderGenReq

生成支付单

FieldTypeLabelDescription
uid string

用户ID

order_no string

订单编号

title string

订单标题

price uint64

支付价格

notify_url string

通知链接

remarks string

订单备注

timestamp uint64

时间戳 秒

sign string

签名

PaymentInfoReq

支付信息

FieldTypeLabelDescription
payment_no string

支付单号

pay_type string

支付方式

pay_password string

支付密码

RefundReq

FieldTypeLabelDescription
payment_no string

支付单号

order_no string

订单号

refund_price string

退款金额

remarks string

备注

timestamp uint64

时间戳

sign uint64

签名

payType

支付方式

FieldTypeLabelDescription
id uint64

数据ID

name string

名称

tag string

标识

icon string

图标

sort uint64

排序

remarks string

备注

status uint64

状态

pay

商品中心

Method NameRequest TypeResponse TypeDescription
Gen OrderGenReq GenResp

生成订单信息

PaymentInfo PaymentInfoReq .base.Map

获取支付参数

Refund RefundReq .base.Empty

申请退款

product.proto

Top

商品中心

设计中

AttrItem

Attr详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

name string

属性名

desc string

属性描述

key string

AttrKey

is_important bool

是否重要属性 0否 1是

is_required bool

是否必填 0否 1是

is_custom bool

是否自定义添加 0否 1是

form_type string

form类型 input, select, checkbox

form_optional string

form类型 input时,默认值,select, checkbox时,可选范围项

custom_label string

自定义标签

sort int64

排序

status int64

状态

AttrListResp

Attr列表

FieldTypeLabelDescription
items AttrItem repeated

列表

total int64

总数

CategoryItem

Category 详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

pid int64

父ID

name string

分类名称

desc string

分类描述

pic_url string

分类图片

sort int64

排序

custom_label string

自定义标签

is_leaf int64

是否为叶子分类

status int64

状态 1:enable, 0:disable

CategoryListResp

Category 列表

FieldTypeLabelDescription
items CategoryItem repeated

列表

total int64

总数

GroupItem

Group 详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

group_type string

分组类型 base基础属性, sale销售属性, categ类别属性

name string

分组名称

desc string

分组描述

custom_label string

自定义标签

sort int64

排序

status int64

状态

items AttrItem repeated

属性列表

GroupListResp

Group 列表

FieldTypeLabelDescription
items GroupItem repeated

列表

total int64

总数

ProductAttr

FieldTypeLabelDescription
attr_id int64

属性ID

value string

属性值

ProductAttrGroup

FieldTypeLabelDescription
group_id int64

分组ID

group_name string

分组名称

attrs ProductAttr repeated

销售属性

ProductItem

Product 详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

category_id int64

分类ID

name string

商品名称

in_stock int64

库存

sales int64

已售数量

cover_url string

封面图

video_url string

介绍视频

is_recommend bool

是否推荐

price_fee int64

售价,整数方式保存

market_price_fee int64

市场价,整数方式保存

custom_label int64

自定义标签

content_type string

详情类型 容类型:html json

content string

详情

cate_attrs ProductAttr repeated

类目属性

sale_group ProductAttrGroup repeated

销售属性

sku ProductSku repeated

销售规格

sort int64

排序

status int64

状态 1:enable, 0:disable

ProductListResp

Product 列表

FieldTypeLabelDescription
items ProductItem repeated

列表

total int64

总数

ProductSku

FieldTypeLabelDescription
id int64

数据ID,创建时传0

spec_no string

attrs md5后的字符串

attrs ProductAttr repeated

销售属性值{attr_id}:{attr_value},{attr_id}:{attr_value} 多个销售属性值逗号分隔

cover_url string

商品介绍主图 多个图片逗号分隔

in_stock int64

库存

sales int64

销量

custom_label string

自定义标签

price_fee int64

售价,整数方式保存

consign_price int64

市场价,整数方式保存

market_price_fee int64

成本价,整数方式保存

status int64

状态 1:enable, 0:disable

Product

商品中心

Method NameRequest TypeResponse TypeDescription
AttrList .base.ListReq AttrListResp

Attr 列表

AttrDetail .base.IdReq AttrItem

Attr 详情

AttrUpdateOrCreate AttrItem .base.Empty

Attr 更新或创建

AttrDelete .base.IdReq .base.Empty

Attr 删除

GroupList .base.ListReq GroupListResp

Group 列表

GroupDetail .base.IdReq GroupItem

Group 详情

GroupUpdateOrCreate GroupItem .base.Empty

Group 更新或创建

GroupDelete .base.IdReq .base.Empty

Group 删除

CategoryList .base.ListReq CategoryListResp

Category 列表

CategoryDetail .base.IdReq CategoryItem

Category 详情

CategoryUpdateOrCreate CategoryItem .base.Empty

Category 更新或创建

CategoryDelete .base.IdReq .base.Empty

Category 删除

ProductList .base.ListReq ProductListResp

Product 列表

ProductDetail .base.IdReq ProductItem

Product 详情

ProductUpdateOrCreate ProductItem .base.Empty

Product 更新或创建

ProductDelete .base.IdReq .base.Empty

Product 删除

sms.proto

Top

短信服务

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

sms

商品中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

user.proto

Top

用户中心

设计中

AppItem

APP详情

FieldTypeLabelDescription
id int64

数据ID,创建时传0

identity string

权限标识

name string

APP名

key string

AppKey

remark string

备注

status int64

状态

created_at string

创建时间

updated_at string

更新时间

AppListResp

APP列表

FieldTypeLabelDescription
items AppItem repeated

列表

total int64

总数

AppResetResp

APP重置返回

FieldTypeLabelDescription
key string

AppKey

secret string

AppSecret

user

商品中心

Method NameRequest TypeResponse TypeDescription
AppList .base.ListReq AppListResp

APP列表

AppDetail .base.IdReq AppItem

APP详情

AppUpdateOrCreate AppItem .base.Empty

APP更新或创建

AppDelete .base.IdReq .base.Empty

APP删除

AppReset .base.IdReq AppResetResp

APP重置Secret

Scalar Value Types

.proto TypeNotesC++JavaPythonGoC#PHPRuby
double double double float float64 double float Float
float float float float float32 float float Float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int int32 int integer Bignum or Fixnum (as required)
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long int64 long integer/string Bignum
uint32 Uses variable-length encoding. uint32 int int/long uint32 uint integer Bignum or Fixnum (as required)
uint64 Uses variable-length encoding. uint64 long int/long uint64 ulong integer/string Bignum or Fixnum (as required)
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int int32 int integer Bignum or Fixnum (as required)
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long int64 long integer/string Bignum
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int uint32 uint integer Bignum or Fixnum (as required)
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long uint64 ulong integer/string Bignum
sfixed32 Always four bytes. int32 int int int32 int integer Bignum or Fixnum (as required)
sfixed64 Always eight bytes. int64 long int/long int64 long integer/string Bignum
bool bool boolean boolean bool bool boolean TrueClass/FalseClass
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode string string string String (UTF-8)
bytes May contain any arbitrary sequence of bytes. string ByteString str []byte ByteString string String (ASCII-8BIT)