MCPcopy Create free account

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

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

↓ 3 callersFunctiontaskModelName
taskModelName 从 BillingContext 或 Properties 中获取模型名称。
service/task_billing.go:257
↓ 3 callersFunctiontaskPluginControllerModelSource
taskPluginControllerModelSource is a task plugin with one model; two plugins whose model names differ only in case conflict.
controller/task_plugin_test.go:64
↓ 3 callersFunctiontaskPluginHookDetail
(err error)
middleware/task_plugin.go:1747
↓ 3 callersFunctiontaskPluginOptionsHasKey
(t *testing.T, key string)
controller/task_plugin_test.go:203
↓ 3 callersFunctiontaskPluginProtocolRendererContext
( request pluginruntime.ProtocolRequestContext, pinned pluginruntime.PinnedEndpoint, task *model.Task, art
controller/plugin_protocol.go:1177
↓ 3 callersFunctiontaskPluginRoutingDebugReason
(message string)
pkg/jsplugin/registry.go:454
↓ 3 callersFunctiontaskPluginSkippedRoutes
taskPluginSkippedRoutes lists, as "METHOD /path", the declared top-level routes the gateway does not register for the plugin version serving key; the
controller/task_plugin.go:461
↓ 3 callersFunctiontaskSubmissionAPIError
taskSubmissionAPIError adapts a task error for the shared relay error paths. TaskError.Error is nil for many local rejections, so fall back to the mes
controller/relay.go:974
↓ 3 callersFunctionterminalTestGeminiChunk
(text string, finishReason string, toolCall bool)
relaykit/relayconvert/terminal_stream_test.go:333
↓ 3 callersFunctiontextContent
(text string)
relay/requestplugin/pdf_test.go:101
↓ 3 callersFunctiontextFormat
textFormat is the format the host reads text from for a file of mime and filename: text, docx or pdf; "" for any other file.
relay/requestplugin/attachments.go:103
↓ 3 callersFunctiontextRequestViaResponses
(c *gin.Context, info *relaycommon.RelayInfo, adaptor channel.Adaptor, request any)
relay/chat_completions_via_responses.go:76
↓ 3 callersFunctionthrownAt
thrownAt is the frame an Error was thrown from, as " at fn (file:line:col)", for host logs; it is empty for thrown values that are not Errors and for
pluginkit/engine.go:630
↓ 3 callersFunctiontimeCondition
(overrides: Partial<TimeCondition> = {})
web/src/features/pricing/lib/__tests__/time-rule-expr.test.ts:33
↓ 3 callersFunctiontoBoolean
(value: unknown, fallback: boolean)
web/src/features/system-settings/maintenance/config.ts:88
↓ 3 callersFunctiontoInputValue
(date?: Date)
web/src/features/usage-logs/components/compact-date-time-range-picker.tsx:40
↓ 3 callersMethodtoMap
()
model/log_other.go:154
↓ 3 callersFunctiontoastPluginChange
( title: string, issues: ModelPricingIssue[] | null | undefined )
web/src/features/task-plugins/lib/plugin-change-toast.tsx:29
↓ 3 callersMethodtouchEntry
touchEntry returns the key's bucket, creating it on demand, and marks it as the most recently active key. The caller must hold the mutex.
common/rate-limit.go:135
↓ 3 callersMethodtransformHookContext
transformHookContext is the ctx argument of a stage, reply or report hook.
pluginkit/transform.go:365
↓ 3 callersFunctiontrimmed
(value)
plugins/tasks/google/plugin.js:49
↓ 3 callersFunctiontruncateRunes
(text string, limit int)
pluginkit/provider.go:1462
↓ 3 callersFunctiontryParseTaskMatrixConfig
( expression: string | null | undefined, schema: BillingUsageSchema )
web/src/features/pricing/lib/task-expr.ts:191
↓ 3 callersFunctiontryParseTimeCondition
(expr: string)
web/src/features/pricing/lib/billing-expr.ts:402
↓ 3 callersFunctiontryRealtimeFetch
tryRealtimeFetch 尝试从上游实时拉取 Gemini/Vertex 任务状态。 仅当渠道类型为 Gemini 或 Vertex 时触发;其他渠道或出错时返回 nil。 当非 OpenAI Video API 时,还会构建自定义格式的响应体。
relay/relay_task.go:561
↓ 3 callersFunctionuniqueChannelIDs
(channelIDs []int)
pkg/wsmanager/wsmanager.go:218
↓ 3 callersFunctionunmarshalJSONString
(data string, v any)
pluginkit/json.go:22
↓ 3 callersFunctionunwrapStoredValue
(value: unknown)
web/src/features/playground/lib/storage/storage.ts:83
↓ 3 callersFunctionupdateRow
(index: number, patch: Partial<MarketplaceSource>)
web/src/features/task-plugins/components/marketplace-sources-dialog.tsx:92
↓ 3 callersMethodupdateUsageState
()
model/twofa.go:65
↓ 3 callersFunctionupdateVideoSingleTask
(ctx context.Context, adaptor TaskPollingAdaptor, ch *model.Channel, taskId string, taskM map[string]*model.Ta
service/task_polling.go:556
↓ 3 callersFunctionusageNumber
(value any)
relay/channel/task/jsplugin/adaptor.go:1832
↓ 3 callersFunctionuseApiInfo
()
web/src/features/dashboard/hooks/use-status-data.ts:40
↓ 3 callersFunctionuseCanBindTaskPlugins
Whether the user may read the plugin options, which only binding needs.
web/src/features/channels/hooks/use-task-plugin-option.ts:35
↓ 3 callersFunctionuseCarouselApi
()
web/src/components/ai-elements/inline-citation.tsx:115
↓ 3 callersFunctionuseChannelUpstreamUpdates
(refresh: () => Promise<void>)
web/src/features/channels/hooks/use-channel-upstream-updates.ts:52
↓ 3 callersFunctionuseInvalidateOnSuccess
()
web/src/features/system-settings/auth/custom-oauth/hooks/use-custom-oauth-mutations.ts:33
↓ 3 callersFunctionuseSettingsForm
({ onSubmit, compareValues, defaultValues, ...formOptions }: SettingsFormOptions<T>)
web/src/features/system-settings/hooks/use-settings-form.ts:185
↓ 3 callersFunctionuseSidebarConfig
(navGroups: NavGroup[])
web/src/hooks/use-sidebar-config.ts:279
↓ 3 callersFunctionuseSidebarView
()
web/src/hooks/use-sidebar-view.ts:52
↓ 3 callersFunctionuseStatusData
( enabledKey: string, dataKey: string )
web/src/features/dashboard/hooks/use-status-data.ts:26
↓ 3 callersFunctionuseSystemOptions
(enabled = true)
web/src/features/system-settings/hooks/use-system-options.ts:25
↓ 3 callersFunctionuseTopNavLinks
()
web/src/hooks/use-top-nav-links.ts:46
↓ 3 callersFunctionuseTurnstile
()
web/src/features/auth/hooks/use-turnstile.ts:28
↓ 3 callersFunctionuseWebPreview
()
web/src/components/ai-elements/web-preview.tsx:57
↓ 3 callersFunctionuserAuthFenceTTLSeconds
A pending fence only covers the interval between publishing the next version and the surrounding database transaction reaching a decision. Its TTL mus
model/user_auth_cache.go:42
↓ 3 callersFunctionusesKling4
(ctx, req)
plugins/tasks/kling/plugin.js:295
↓ 3 callersFunctionvalidateCreditedQuota
(quota decimal.Decimal)
controller/topup.go:247
↓ 3 callersFunctionvalidateH3Content
(items)
plugins/tasks/hailuo/plugin.js:360
↓ 3 callersFunctionvalidateJsonString
( value: string, options: JsonValidationOptions = {} )
web/src/features/system-settings/models/utils.ts:145
↓ 3 callersFunctionvalidateKlingDuration
(value)
plugins/tasks/kling/plugin.js:224
↓ 3 callersFunctionvalidateTurnstile
()
web/src/features/auth/hooks/use-turnstile.ts:40
↓ 3 callersFunctionvalidateUsageNumberLimit
(number float64, limit int)
relay/channel/task/jsplugin/adaptor.go:1822
↓ 3 callersFunctionvalidateVendorMetadata
(tx *gorm.DB, vendor *Vendor)
model/vendor_management.go:52
↓ 3 callersFunctionverify
( input: VerificationInput, operation: VerificationOperation, passwordEncryptionEnabled: boolean, sign
web/src/features/auth/secure-verification/api.ts:202
↓ 3 callersFunctionverifySecurityProof
(raw string, identity AuthIdentity, binding VerificationBinding)
service/auth_token.go:162
↓ 3 callersFunctionviaGateway
(ctx)
plugins/tasks/google/plugin.js:60
↓ 3 callersFunctionviaGateway
(ctx)
plugins/tasks/hailuo/plugin.js:216
↓ 3 callersFunctionvideoModel
(identity)
plugins/tasks/xai/plugin.js:146
↓ 3 callersFunctionvideoProfile
(ctx)
plugins/tasks/doubao/plugin.js:426
↓ 3 callersFunctionvideoRequest
(action, source, identity)
plugins/tasks/xai/plugin.js:271
↓ 3 callersFunctionvideoSize
(value)
plugins/tasks/alibaba/plugin.js:825
↓ 3 callersFunctionvideoURL
(body)
plugins/tasks/alibaba/plugin.js:1295
↓ 3 callersFunctionvideoURL
(data)
plugins/tasks/xai/plugin.js:340
↓ 3 callersFunctionwarnLegacyProxyURLOnce
(config *proxyURLConfig)
service/http_client.go:181
↓ 3 callersFunctionwechatLoginByCode
(code: string)
web/src/features/auth/api.ts:227
↓ 3 callersFunctionwithClient
(children: React.ReactNode)
web/src/features/usage-logs/components/__tests__/request-plugin-record.test.tsx:147
↓ 3 callersFunctionwithNormalizedEmailLock
withNormalizedEmailLock serializes concurrent writers that target the same normalized email inside tx, so a "check then write" sequence cannot be race
model/user.go:371
↓ 3 callersFunctionwithTieredBillingConfig
(t *testing.T, modes map[string]string, exprs map[string]string)
controller/model_list_test.go:99
↓ 3 callersMethodwriteClient
(kind int, message []byte)
relay/responses_websocket.go:871
↓ 3 callersFunctionwriteDashboardAuthError
(c *gin.Context, err error)
middleware/auth.go:385
↓ 3 callersFunctionwriteStoredValue
(baseKey: string, data: T)
web/src/features/playground/lib/storage/storage.ts:95
↓ 3 callersFunctionwriteTaskPluginProtocolEvent
(c *gin.Context, event dto.PluginResponsesStreamEvent)
controller/plugin_protocol.go:1219
↓ 3 callersFunctionwriteTestCgroupFile
(t *testing.T, path string, content string)
common/system_monitor_test.go:23
↓ 3 callersFunctionwriteVideoDataURL
(c *gin.Context, dataURL string)
controller/video_proxy.go:679
↓ 3 callersMethodxref
xref writes a cross-reference stream of rows as object number and returns its offset. encode, when set, encodes the rows.
relay/requestplugin/pdf_test.go:47
↓ 3 callersFunctionzeroPluginResponsesUsage
()
relay/plugin_protocol.go:1030
↓ 2 callersFunctionASCIIFold
ASCIIFold is the exported form of asciiFold for consumers outside this package.
pluginkit/model_fold.go:24
↓ 2 callersFunctionAccessTokenRouteRule
AccessTokenRouteRule returns the rule for "METHOD /full/path".
middleware/access_token_routes.go:341
↓ 2 callersFunctionAccessTokenScopeGranted
(scopes []string, scope string)
service/access_token_scope.go:212
↓ 2 callersFunctionAccessTokenVerificationScope
AccessTokenVerificationScope returns the token scope a PAT needs for a verification scope and whether the scope is listed at all.
service/access_token_scope.go:246
↓ 2 callersFunctionActivateTaskPlugin
(c *gin.Context)
controller/task_plugin.go:665
↓ 2 callersFunctionAdjustUserQuota
(userID, operatorRole int, mode string, value int)
model/user_quota_adjustment.go:25
↓ 2 callersMethodAllow
(ctx context.Context, key string, opts ...Option)
common/limiter/limiter.go:43
↓ 2 callersFunctionApiErrorI18n
ApiErrorI18n returns a translated error message based on the user's language preference key is the i18n message key, args is optional template data
common/gin.go:335
↓ 2 callersFunctionAppendResponseModelLogInfo
(relayInfo *relaycommon.RelayInfo, other *model.LogOther)
service/log_info_generate.go:140
↓ 2 callersFunctionAppendTaskPluginAuditInfo
AppendTaskPluginAuditInfo writes role-separated, credential-free plugin provenance into a usage log.
service/task_plugin_audit.go:54
↓ 2 callersFunctionApplyGeminiThinkingConfigChecked
(geminiRequest *dto.GeminiChatRequest, info convmeta.Meta, oaiRequest ...dto.GeneralOpenAIRequest)
relaykit/relayconvert/request_compat.go:32
↓ 2 callersFunctionApplyMetadataSync
(updates []MetadataSyncUpdate, upstreamVendors map[string]Vendor)
model/model_metadata_sync.go:158
↓ 2 callersMethodApplyOtherRatiosToDecimal
(value decimal.Decimal)
types/price_data.go:97
↓ 2 callersFunctionApplyVendorOperation
(operation VendorOperation)
model/vendor_management.go:201
↓ 2 callersFunctionAsParamOverrideReturnError
(err error)
relay/common/override.go:125
↓ 2 callersFunctionAttachHostedResponse
(format types.RelayFormat, response any, set HostedResponseSet, options *convmeta.Options)
relaykit/relayconvert/internal/toolconv/response_artifacts.go:76
↓ 2 callersFunctionAudioCompletionRatio2JSONString
()
setting/ratio_setting/model_ratio.go:676
↓ 2 callersFunctionAudioRatio2JSONString
()
setting/ratio_setting/model_ratio.go:668
↓ 2 callersFunctionAutomaticDisableKeywordsToString
()
setting/operation_setting/operation_setting.go:18
↓ 2 callersFunctionAutomaticDisableStatusCodesToString
()
setting/operation_setting/status_code_ranges.go:40
↓ 2 callersMethodBalanceRoute
BalanceRoute returns the explicitly configured channel-management balance route.
relaykit/dto/channel_settings.go:315
↓ 2 callersFunctionBatchDeleteChannels
(ids []int)
model/channel.go:540
↓ 2 callersFunctionBatchDeleteRedemptions
BatchDeleteRedemptions soft-deletes the selected codes in one statement.
model/redemption.go:243
← previousnext →3,001–3,100 of 15,592, ranked by callers