MCPcopy Create free account

hub / github.com/QuantumNous/new-api / functions

Functions15,592 in github.com/QuantumNous/new-api

↓ 5 callersFunctiontokenAuditParams
(c *gin.Context)
controller/audit.go:187
↓ 5 callersFunctiontriggerRefresh
()
web/src/features/redemption-codes/components/redemptions-provider.tsx:47
↓ 5 callersFunctiontrimmed
(value)
plugins/tasks/jimeng/plugin.js:54
↓ 5 callersFunctiontryParseRequestRuleExpr
( expr: string )
web/src/features/pricing/lib/billing-expr.ts:588
↓ 5 callersFunctionupdateChannel
( id: number, data: Partial<Channel> )
web/src/features/channels/api.ts:261
↓ 5 callersFunctionupdateUserCache
updateUserCache refreshes non-quota user cache fields. Quota is maintained by atomic quota delta paths and must not be overwritten by stale user snaps
model/user_cache.go:92
↓ 5 callersFunctionuseAuthRedirect
()
web/src/features/auth/hooks/use-auth-redirect.ts:36
↓ 5 callersFunctionuseBranch
()
web/src/components/ai-elements/branch.tsx:49
↓ 5 callersFunctionuseCommonLogsColumns
( isAdmin: boolean, isRoot: boolean, showBillingSource = false )
web/src/features/usage-logs/components/columns/common-logs-columns.tsx:352
↓ 5 callersFunctionuseScheduledChannelDatabase
useScheduledChannelDatabase isolates these locked-update tests on each real dialect selected through TEST_TASK_DB_DIALECT and the standard test DSNs.
model/channel_plugin_credential_test.go:290
↓ 5 callersFunctionvalidateAdvancedCustomConfig
( config: AdvancedCustomConfig | null )
web/src/features/channels/lib/advanced-custom.ts:623
↓ 5 callersFunctionvalidateOptionValue
(key string, value string)
model/option.go:239
↓ 5 callersFunctionvalueMap
(value any)
controller/ratio_sync.go:94
↓ 5 callersFunctionviaGateway
(ctx)
plugins/tasks/vertex-ai/plugin.js:128
↓ 5 callersFunctionvisualNodeId
()
web/src/features/pricing/lib/billing-expression/visual.ts:79
↓ 5 callersFunctionwriteAccountStatusError
writeAccountStatusError responds with a web console message under a non-200 status.
controller/secure_verification.go:140
↓ 5 callersFunctionwriteChat
(w http.ResponseWriter, request capturedRequest)
router/provider_plugin_relay_test.go:100
↓ 5 callersFunctionwriteUserCache
(user *UserBase, includeQuota bool)
model/user_auth_cache.go:48
↓ 4 callersMethodAddAll
(other map[K]V)
types/rw_map.go:46
↓ 4 callersMethodAddPolicy
(_ string, ptype string, rule []string)
service/authz/adapter.go:79
↓ 4 callersFunctionAddToken
(c *gin.Context)
controller/token.go:299
↓ 4 callersFunctionAdminResetUserSubscriptionsByPlan
(userId int, planId int, advanceResetTime bool)
model/subscription.go:1109
↓ 4 callersMethodAppendRequestConversion
AppendRequestConversion records a hop in the request format chain.
relaykit/relayconvert/convmeta/meta.go:60
↓ 4 callersFunctionAppendUsedChannel
AppendUsedChannel records an attempted channel in the request's channel trail, which the retry log and the consume log's admin_info both read.
service/channel_select.go:423
↓ 4 callersMethodApply
Apply accepts a bounded batch of set, append and appendText operations. Failure invalidates the stream: callers must discard the state rather than con
pluginkit/json_state.go:259
↓ 4 callersFunctionApplyToOpenAIResponses
ApplyToOpenAIResponses writes the portable portion of an intent directly to a Responses request. The JSON-excluded state retains exact provider-native
relaykit/relayconvert/reasoning/intent.go:480
↓ 4 callersFunctionBodyStorageCleanup
BodyStorageCleanup 请求体存储清理中间件 在请求处理完成后自动清理磁盘/内存缓存
middleware/body_cleanup.go:11
↓ 4 callersFunctionBuildTaskArtifactContentURL
BuildTaskArtifactContentURL returns an absolute, long-lived capability URL. TaskPublicAddress wins when configured; ServerAddress is the only fallback
service/task_artifact_access.go:98
↓ 4 callersFunctionCacheUpdateChannelKey
CacheUpdateChannelKey publishes a new key for a cached channel. The cached channel is replaced by a copy, so a request holding the previous one keeps
model/channel_plugin_credential.go:201
↓ 4 callersMethodCacheWrite12hTokens
CacheWrite12hTokens returns the 12-hour subset of the cache writes, bounded by CacheCreationTokensTotal so it never bills more writes than reported.
relaykit/dto/openai_response.go:348
↓ 4 callersMethodCallConvertRequest
CallConvertRequest runs convertRequest(ctx, {body, model, stream}), or convertRequest(ctx, {form, model, stream}) for a multipart client request.
pluginkit/provider.go:664
↓ 4 callersMethodCallConvertStreamEvent
CallConvertStreamEvent runs convertStreamEvent(ctx, {event?, data}) on the stream of the route at hookCtx.Path, {dataBase64} for a binary frame, or wi
pluginkit/provider.go:1272
↓ 4 callersFunctionCallID
(item map[string]any)
relaykit/relayconvert/internal/oai_responses/to_oai_chat_req.go:589
↓ 4 callersMethodCallPrepareRequest
CallPrepareRequest runs prepareRequest(ctx, req).
pluginkit/provider.go:495
↓ 4 callersMethodCallReply
CallReply runs the reply hook with tctx.Stage "reply" on outputs and checks the result: each mask names an output of the call and lies within its text
pluginkit/transform.go:556
↓ 4 callersMethodCallRequestDescriptor
CallRequestDescriptor runs a request-building hook. A plugin that preserves JSON order has its descriptor decoded from the JSON.stringify text of the
pluginkit/task.go:93
↓ 4 callersMethodCallScheduled
CallScheduled runs scheduled(ctx). The caller checks the stored credential line's size and applies the result while holding the channel lock.
pluginkit/provider.go:368
↓ 4 callersFunctionCatalog
Catalog returns a copy of the registered resource definitions.
service/authz/registry.go:29
↓ 4 callersFunctionClassifyRelayOutcome
ClassifyRelayOutcome decides whether one finished relay counts as a health sample. Business rejections and cancellations during generation are not sam
pkg/perf_metrics/outcome.go:26
↓ 4 callersFunctionClaudeData
(c *gin.Context, resp dto.ClaudeResponse)
relay/helper/common.go:214
↓ 4 callersFunctionCleanupBodyStorage
CleanupBodyStorage 清理请求体存储(应在请求结束时调用)
common/gin.go:110
↓ 4 callersFunctionClearRefreshCookie
(c *gin.Context)
service/auth_session.go:346
↓ 4 callersFunctionCloseActiveWebSocketsForChannel
(channelID int, reason string)
service/ws_close.go:7
↓ 4 callersFunctionCloseChannel
(channelID int, reason string)
pkg/wsmanager/wsmanager.go:89
↓ 4 callersFunctionContentPartToFileSource
(part map[string]any)
relaykit/relayconvert/internal/oai_responses/req_helpers.go:241
↓ 4 callersMethodConvertOpenAIResponsesRequest
(c *gin.Context, info *relaycommon.RelayInfo, request dto.OpenAIResponsesRequest)
relay/channel/advancedcustom/adaptor.go:111
↓ 4 callersFunctionConvertStreamResponse
(c context.Context, info convmeta.Meta, target types.RelayFormat, response any)
relaykit/relayconvert/response_registry.go:272
↓ 4 callersFunctionCountUserSubscriptionsByPlan
(userId int, planId int)
model/subscription.go:425
↓ 4 callersFunctionCovertMjpActionToModelName
(mjAction string)
service/midjourney.go:25
↓ 4 callersFunctionCreateUserSubscriptionFromPlanTx
(tx *gorm.DB, userId int, plan *SubscriptionPlan, source string)
model/subscription.go:496
↓ 4 callersFunctionDecreaseTokenQuota
(id int, key string, quota int)
model/token.go:413
↓ 4 callersFunctionDecrementDiskFiles
DecrementDiskFiles 减少磁盘文件计数
common/disk_cache_config.go:115
↓ 4 callersFunctionDeleteJSONMember
DeleteJSONMember removes every copy of the member at path. A client body may repeat a key, and most upstream parsers read the last copy, so a survivin
relay/common/relay_info.go:1165
↓ 4 callersFunctionDeleteModelMetadata
DeleteModelMetadata optionally removes exact model names from every channel. Channel removal requires exact-match metadata records. Pricing removal cl
model/model_meta.go:285
↓ 4 callersFunctionDoDownloadRequest
(originUrl string, reason ...string)
service/download.go:52
↓ 4 callersMethodDoRequest
(c *gin.Context, info *relaycommon.RelayInfo, requestBody io.Reader)
relay/channel/aws/adaptor.go:139
↓ 4 callersFunctionDoWorkerRequest
DoWorkerRequest 通过Worker发送请求
service/download.go:24
↓ 4 callersMethodEffectiveRPID
EffectiveRPID preserves the existing default and port handling for settings created before explicit Passkey domains were introduced.
setting/system_setting/passkey.go:41
↓ 4 callersMethodEnabled
()
service/task_artifact_store.go:27
↓ 4 callersFunctionEnqueueSystemTask
EnqueueSystemTask creates an on-demand task of the given type. The returned bool is true only when a new pending row was created; false means an activ
service/system_task.go:202
↓ 4 callersFunctionExprVersion
ExprVersion returns the version of a cached expression. Returns DefaultExprVersion if the expression hasn't been compiled yet or is empty.
pkg/billingexpr/compile.go:242
↓ 4 callersMethodFinalize
(state *ResponseStreamState)
relaykit/relayconvert/response_compat.go:73
↓ 4 callersFunctionFindUserAccessTokenByHash
(hash string)
model/user_access_token.go:85
↓ 4 callersFunctionFinishEmailBinding
(identity AuthIdentity, token, newCode, oldCode string)
service/email_binding.go:129
↓ 4 callersFunctionFinishTwoFASetup
(identity AuthIdentity, flowToken, code string)
service/twofa.go:43
↓ 4 callersMethodFlush
()
router/plugin-router.go:560
↓ 4 callersMethodFullKey
(key string)
pkg/cachex/hybrid_cache.go:55
↓ 4 callersFunctionGenerateSystemTaskID
()
model/system_task.go:94
↓ 4 callersFunctionGenerateVerificationCode
(length int)
common/verification.go:27
↓ 4 callersFunctionGetAdvancedCustomPreset
GetAdvancedCustomPreset returns fresh defaults.
common/advanced_custom_presets.go:9
↓ 4 callersFunctionGetChannelAffinityUsageCacheStats
(ruleName, usingGroup, keyFp string)
service/channel_affinity.go:809
↓ 4 callersMethodGetChannelType
()
relaykit/relayconvert/convmeta/meta.go:27
↓ 4 callersFunctionGetCheckinSetting
GetCheckinSetting 获取签到配置
setting/operation_setting/checkin_setting.go:25
↓ 4 callersFunctionGetCustomOAuthProviderById
GetCustomOAuthProviderById returns a custom OAuth provider by ID
model/custom_oauth_provider.go:90
↓ 4 callersFunctionGetDiscordSettings
()
setting/system_setting/discord.go:19
↓ 4 callersFunctionGetDiskCacheThresholdBytes
GetDiskCacheThresholdBytes 获取磁盘缓存阈值(字节)
common/disk_cache_config.go:51
↓ 4 callersMethodGetEffectiveDisplayName
GetEffectiveDisplayName returns the admin-configured display name, or the literal "OIDC" when none has been set. Centralizing this fallback keeps the
setting/system_setting/oidc.go:36
↓ 4 callersFunctionGetEnabledModels
()
model/ability.go:62
↓ 4 callersFunctionGetEnvOrDefaultBool
(env string, defaultValue bool)
common/env.go:27
↓ 4 callersMethodGetFullKey
()
model/token.go:80
↓ 4 callersFunctionGetGroupRatio
(name string)
setting/ratio_setting/group_ratio.go:79
↓ 4 callersFunctionGetLatestSyncRevisions
GetLatestSyncRevisions returns the id of the newest sync task of every topic that has one. A node reads it before its startup loads, before it knows w
model/system_sync_task.go:83
↓ 4 callersFunctionGetLogSetting
()
setting/operation_setting/log_setting.go:31
↓ 4 callersFunctionGetOpenAIError
GetOpenAIError 从动态错误类型中提取OpenAIError结构
relaykit/dto/openai_response.go:636
↓ 4 callersFunctionGetOptions
(c *gin.Context)
controller/option.go:84
↓ 4 callersMethodGetPage
()
common/page_info.go:29
↓ 4 callersMethodGetPreConsumedQuota
GetPreConsumedQuota 返回实际预扣的额度值(信任用户可能为 0)。
relay/common/billing.go:20
↓ 4 callersFunctionGetProvider
GetProvider returns the OAuth provider for the given name
oauth/registry.go:63
↓ 4 callersMethodGetProviderId
GetProviderId returns the provider ID for binding purposes
oauth/generic.go:316
↓ 4 callersMethodGetSetting
()
model/user_cache.go:50
↓ 4 callersFunctionGetTimestamp
()
relaykit/relayconvert/kitutil/value.go:50
↓ 4 callersFunctionGetToolPrice
GetToolPrice is a convenience wrapper when no model name is needed.
setting/operation_setting/tools.go:279
↓ 4 callersFunctionGetUniqueUserByEmail
(email string)
model/user.go:1157
↓ 4 callersFunctionGetUnusedBackupCodeCount
GetUnusedBackupCodeCount 获取未使用的备用码数量
model/twofa.go:231
↓ 4 callersFunctionGetUserAutoGroup
GetUserAutoGroup 根据用户分组获取自动分组设置
service/group.go:57
↓ 4 callersFunctionGetUserSetting
GetUserSetting gets setting from Redis first, falls back to DB if needed
model/user.go:1319
↓ 4 callersFunctionGetVendors
GetVendors 返回当前定价接口使用到的供应商信息
model/pricing.go:108
↓ 4 callersFunctionHandleStreamResponseData
(c *gin.Context, info *relaycommon.RelayInfo, claudeInfo *ClaudeResponseInfo, data string)
relay/channel/claude/relay-claude.go:89
↓ 4 callersMethodHasIcon
HasIcon reports whether this version ships a logo.
model/task_plugin.go:103
↓ 4 callersMethodHasOtherRatio
(key string)
types/price_data.go:62
← previousnext →1,601–1,700 of 15,592, ranked by callers