fix(billing): 默认关闭 OpenAI 长上下文计费

This commit is contained in:
benjamin
2026-07-13 23:32:16 +08:00
parent f63d168ae0
commit e9fb5983cd
19 changed files with 182 additions and 73 deletions
@@ -1303,6 +1303,10 @@ func (h *AccountHandler) ApplyOAuthCredentials(c *gin.Context) {
response.ErrorFrom(c, infraerrors.BadRequest("NOT_OAUTH", "cannot apply oauth credentials to non-OAuth account"))
return
}
if err := service.ValidateOpenAILongContextBillingExtra(existing.Platform, req.Extra); err != nil {
response.ErrorFrom(c, err)
return
}
updatedAccount, err := h.adminService.UpdateAccount(ctx, accountID, &service.UpdateAccountInput{
Type: req.Type,