60 lines
1.8 KiB
Go
60 lines
1.8 KiB
Go
package imconfiginternal
|
|
|
|
import "github.com/gogf/gf/v2/frame/g"
|
|
|
|
type TenantReq struct {
|
|
g.Meta `path:"/internal/im-config/tenants/by-code/{code}" method:"get" tags:"IM内部配置" summary:"按编码获取IM租户"`
|
|
Code string `json:"code" in:"path" dc:"租户编码"`
|
|
}
|
|
|
|
type TenantByIDReq struct {
|
|
g.Meta `path:"/internal/im-config/tenants/by-id/{id}" method:"get" tags:"IM内部配置" summary:"按ID获取IM租户"`
|
|
Id int64 `json:"id" in:"path" dc:"租户ID"`
|
|
}
|
|
|
|
type TenantListReq struct {
|
|
g.Meta `path:"/internal/im-config/tenants" method:"get" tags:"IM内部配置" summary:"获取IM租户列表"`
|
|
State string `json:"state" dc:"状态"`
|
|
Limit int `json:"limit" dc:"数量"`
|
|
}
|
|
|
|
type TenantRes struct {
|
|
*TenantModel
|
|
}
|
|
|
|
type TenantListRes struct {
|
|
Items []*TenantModel `json:"items" dc:"租户列表"`
|
|
}
|
|
|
|
type TenantModel struct {
|
|
ID int64 `json:"id"`
|
|
Code string `json:"code"`
|
|
Name string `json:"name"`
|
|
TenantDesc *string `json:"tenant_desc,omitempty"`
|
|
DBName string `json:"db_name"`
|
|
DBDSN string `json:"db_dsn"`
|
|
State int `json:"state"`
|
|
CreatedAt string `json:"created_at"`
|
|
CreatedBy int64 `json:"created_by"`
|
|
UpdatedAt string `json:"updated_at"`
|
|
UpdatedBy int64 `json:"updated_by"`
|
|
}
|
|
|
|
type RegistrationSmsReq struct {
|
|
g.Meta `path:"/internal/im-config/registration/sms" method:"get" tags:"IM内部配置" summary:"获取注册短信开关"`
|
|
}
|
|
|
|
type RegistrationSmsRes struct {
|
|
Enabled bool `json:"enabled" dc:"是否开启"`
|
|
}
|
|
|
|
type ThirdPartyReq struct {
|
|
g.Meta `path:"/internal/im-config/third-party/{group}" method:"get" tags:"IM内部配置" summary:"获取第三方配置"`
|
|
Group string `json:"group" in:"path" dc:"配置组"`
|
|
Keys string `json:"keys" dc:"配置键,逗号分隔"`
|
|
}
|
|
|
|
type ThirdPartyRes struct {
|
|
Values map[string]string `json:"values" dc:"配置值"`
|
|
}
|