user_settings.go 1.1 KB

1234567891011121314151617
  1. package dto
  2. type UserSetting struct {
  3. NotifyType string `json:"notify_type,omitempty"` // QuotaWarningType 额度预警类型
  4. QuotaWarningThreshold float64 `json:"quota_warning_threshold,omitempty"` // QuotaWarningThreshold 额度预警阈值
  5. WebhookUrl string `json:"webhook_url,omitempty"` // WebhookUrl webhook地址
  6. WebhookSecret string `json:"webhook_secret,omitempty"` // WebhookSecret webhook密钥
  7. NotificationEmail string `json:"notification_email,omitempty"` // NotificationEmail 通知邮箱地址
  8. AcceptUnsetRatioModel bool `json:"accept_unset_model_ratio_model,omitempty"` // AcceptUnsetRatioModel 是否接受未设置价格的模型
  9. RecordIpLog bool `json:"record_ip_log,omitempty"` // 是否记录请求和错误日志IP
  10. SidebarModules string `json:"sidebar_modules,omitempty"` // SidebarModules 左侧边栏模块配置
  11. }
  12. var (
  13. NotifyTypeEmail = "email" // Email 邮件
  14. NotifyTypeWebhook = "webhook" // Webhook
  15. )