MCPcopy Create free account

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

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

↓ 2 callersMethodInsert
()
model/redemption.go:188
↓ 2 callersMethodInsert
Insert 创建新的供应商记录
model/vendor_meta.go:29
↓ 2 callersMethodInsertWithContext
InsertWithContext creates the row. omitColumns are left out of the INSERT (for example "data" when the submit route discards the upstream snapshot) wh
model/task.go:525
↓ 2 callersMethodInsertWithTx
InsertWithTx inserts a new user within an existing transaction. This is used for OAuth registration where user creation and binding need to be atomic.
model/user.go:740
↓ 2 callersFunctionInspectStreamResponse
InspectStreamResponse avoids treating a single Gemini streaming chunk as a complete grounding document. Gemini grounding chunk indexes and segment off
relaykit/relayconvert/internal/toolconv/response.go:51
↓ 2 callersFunctionInvalidateCache
InvalidateCache clears the compiled-expression cache. Called when billing rules are updated.
pkg/billingexpr/compile.go:366
↓ 2 callersFunctionInvalidateExposedDataCache
()
setting/ratio_setting/exposed_cache.go:24
↓ 2 callersFunctionIsAdmin
(userId int)
model/user.go:1215
↓ 2 callersFunctionIsAdvancedCustomChannel
IsAdvancedCustomChannel includes named channels backed by route presets.
constant/channel.go:239
↓ 2 callersFunctionIsAdvancedCustomConverterAllowed
(converter string)
relaykit/dto/channel_settings.go:466
↓ 2 callersFunctionIsChannelEnabledForGroupModel
(group string, modelName string, channelID int)
model/channel_satisfy.go:10
↓ 2 callersFunctionIsCustomProvider
IsCustomProvider checks if a provider is a custom provider
oauth/registry.go:102
↓ 2 callersMethodIsFinished
()
relaykit/dto/openai_response.go:157
↓ 2 callersFunctionIsGitHubIdAlreadyTaken
(githubId string)
model/user.go:1172
↓ 2 callersMethodIsIPAccessAllowed
IsIPAccessAllowed 检查IP是否允许访问
common/ssrf_protection.go:251
↓ 2 callersFunctionIsImageGenerationModel
(modelName string)
common/model.go:44
↓ 2 callersFunctionIsModelNameDuplicated
(id int, name string)
model/model_meta.go:252
↓ 2 callersFunctionIsOpenAIGPT5Model
IsOpenAIGPT5Model identifies the GPT-5 family, independently of request capabilities.
relaykit/dto/openai_request.go:318
↓ 2 callersFunctionIsOpenAIReasoningOModel
(modelName string)
relaykit/dto/openai_request.go:311
↓ 2 callersFunctionIsPrefillGroupNameDuplicated
IsPrefillGroupNameDuplicated 检查组名称是否重复(排除自身 ID)
model/prefill_group.go:98
↓ 2 callersFunctionIsProviderRegistered
IsProviderRegistered checks if a provider is registered
oauth/registry.go:94
↓ 2 callersFunctionIsProviderUserIdTaken
IsProviderUserIdTaken checks if a provider user ID is already bound to any user
model/user_oauth_binding.go:57
↓ 2 callersFunctionIsRunningInContainer
IsRunningInContainer detects if the application is running inside a container
common/utils.go:97
↓ 2 callersFunctionIsSlugTaken
IsSlugTaken checks if a slug is already taken by another provider Returns true on DB errors (fail-closed) to prevent slug conflicts
model/custom_oauth_provider.go:155
↓ 2 callersMethodIsSuccess
()
dto/task.go:30
↓ 2 callersFunctionIsSupported
IsSupported checks if a language code is supported
i18n/i18n.go:214
↓ 2 callersMethodIsURL
()
relaykit/types/file_source.go:14
↓ 2 callersMethodIsUserIDTaken
IsUserIDTaken checks if the provider user ID is already associated with an account
oauth/provider.go:26
↓ 2 callersFunctionIsWeChatIdAlreadyTaken
(wechatId string)
model/user.go:1168
↓ 2 callersFunctionJSONString
(raw json.RawMessage)
relaykit/relayconvert/internal/oai_responses/to_oai_chat_req.go:714
↓ 2 callersMethodJSValue
()
pkg/jsplugin/routing.go:395
↓ 2 callersMethodListDeployments
ListDeployments retrieves a list of deployments with optional filtering
pkg/ionet/deployment.go:56
↓ 2 callersFunctionListSystemTasks
(filter SystemTaskFilter, offset, limit int)
model/system_task.go:219
↓ 2 callersFunctionListWaffoPancakeCatalog
ListWaffoPancakeCatalog queries Pancake's GraphQL `stores` for the merchant's stores + onetime products. A successful call also proves the supplied cr
service/waffo_pancake.go:442
↓ 2 callersFunctionLoadTaskArtifactStoreConfig
LoadTaskArtifactStoreConfig reads and validates startup-only configuration. S3 mode is deliberately disabled until a storage implementation is shipped
setting/system_setting/task_artifact_store.go:54
↓ 2 callersFunctionLoadToolPricesFromJSONString
LoadToolPricesFromJSONString replaces the complete operator price map. Invalid legacy entries are ignored individually so valid sibling overrides surv
setting/operation_setting/tools.go:199
↓ 2 callersFunctionLogJson
LogJson 仅供测试使用 only for test
logger/logger.go:179
↓ 2 callersFunctionLogSystemError
LogSystemError reports an internal converter failure through its dedicated hook, keeping it distinct from malformed request-data diagnostics.
relaykit/relayconvert/kitutil/log.go:55
↓ 2 callersFunctionManageUser
ManageUser Only admin user can do this
controller/user.go:1094
↓ 2 callersMethodMarkIncomplete
(reason string)
relay/common/stream_status.go:119
↓ 2 callersFunctionMarkSystemTaskLeaseExpired
(taskID string)
model/system_task.go:504
↓ 2 callersFunctionMaskEmail
MaskEmail masks a user email to prevent PII leakage in logs Returns "***masked***" if email is empty, otherwise shows only the domain part
common/str.go:120
↓ 2 callersMethodMaskSensitiveErrorWithStatusCode
(upstreamURLs ...string)
relaykit/types/error.go:167
↓ 2 callersFunctionMaskSensitiveInfo
MaskSensitiveInfo moved to the conversion kit (kitutil) because the types package error formatting depends on it; host callers keep this name.
common/str.go:138
↓ 2 callersMethodMatchPattern
()
pkg/cachex/namespace.go:32
↓ 2 callersFunctionMaxBodyBytes
MaxBodyBytes is MAX_REQUEST_BODY_MB in bytes, 128 MB when unset: the limit a client body is read with, which a patched body keeps as well.
pkg/requestpatch/patch.go:290
↓ 2 callersMethodMergeAdmin
(values map[string]any)
model/log_other.go:105
↓ 2 callersFunctionMidjourneyErrorWithStatusCodeWrapper
(code int, desc string, statusCode int)
service/error.go:28
↓ 2 callersFunctionMigrateLegacyGitHubBindingWithTx
MigrateLegacyGitHubBindingWithTx rewrites a login-name GitHub binding to the numeric account ID once the login flow has confirmed the account. It repo
model/account_security.go:157
↓ 2 callersFunctionModelPricingVersion
(values PricingValues)
model/model_pricing_config.go:81
↓ 2 callersFunctionNew
(ctx context.Context, r *redis.Client)
common/limiter/limiter.go:27
↓ 2 callersFunctionNewBase64FileSource
(base64Data string, mimeType string)
relaykit/types/file_source.go:127
↓ 2 callersFunctionNewClaudeToChatStreamState
()
relaykit/relayconvert/response_compat.go:54
↓ 2 callersFunctionNewClientWithConfig
NewClientWithConfig creates a new IO.NET API client with custom configuration
pkg/ionet/client.go:84
↓ 2 callersFunctionNewConfigManager
()
setting/config/config.go:21
↓ 2 callersFunctionNewDiskCachedData
(diskPath string, mimeType string, size int64)
relaykit/types/file_source.go:171
↓ 2 callersFunctionNewEnterpriseClient
NewEnterpriseClient creates a new IO.NET API client targeting the enterprise API base URL.
pkg/ionet/client.go:74
↓ 2 callersFunctionNewJSONState
(limit int)
pkg/jsplugin/json_state.go:252
↓ 2 callersFunctionNewMemoryCachedData
(base64Data string, mimeType string, size int64)
relaykit/types/file_source.go:162
↓ 2 callersFunctionNewMessage
(msgType MsgType, flag MsgTypeFlagBits)
relay/channel/volcengine/protocols.go:245
↓ 2 callersFunctionNewRealtime
NewRealtime starts the request plugins of a Realtime session on its channel. toClient and toTarget write one event to the client and to the upstream.
relay/requestplugin/socket.go:228
↓ 2 callersFunctionNewReplayableBodyReader
NewReplayableBodyReader returns a request body over storage with its own cursor. Closing the body, as net/http does, never closes the storage.
common/body_storage.go:438
↓ 2 callersFunctionNormalizeAccessTokenScopeList
NormalizeAccessTokenScopeList trims, de-duplicates and sorts scope keys. It only checks the shape; grantability is checked against the scope catalog.
service/security_verification.go:134
↓ 2 callersFunctionNormalizeAccessTokenScopes
NormalizeAccessTokenScopes validates a requested grant against the catalog the user sees and returns it trimmed, de-duplicated and sorted.
service/access_token_scope.go:174
↓ 2 callersFunctionNormalizeBackupCode
NormalizeBackupCode 标准化备用码格式
common/totp.go:101
↓ 2 callersFunctionNormalizeBillingPreference
NormalizeBillingPreference clamps the billing preference to valid values.
common/str.go:109
↓ 2 callersFunctionNormalizeCacheCreationSplit
(totalTokens int, tokens5m int, tokens1h int)
relaykit/relayconvert/response_compat.go:34
↓ 2 callersFunctionNormalizeChannelGroupFilter
(group string)
model/channel.go:147
↓ 2 callersFunctionNormalizeChannelTestConcurrency
(concurrency int)
setting/operation_setting/monitor_setting.go:65
↓ 2 callersFunctionNormalizePasskeyRPID
(value string, configuredOrigins ...string)
setting/system_setting/passkey.go:57
↓ 2 callersFunctionNormalizeRoutePath
NormalizeRoutePath validates the canonical path syntax used by plugin route declarations. A trailing slash is allowed and remains significant.
pkg/jsplugin/routing.go:793
↓ 2 callersFunctionObjectValue
(value any, fallbackKey string)
relaykit/relayconvert/internal/oai_responses/req_helpers.go:195
↓ 2 callersFunctionOpenAIFinishReasonToClaudeStopReason
(finishReason string)
relaykit/reasonmap/reasonmap.go:31
↓ 2 callersFunctionPROFILE_BY_NAME
(name: string)
web/src/features/pricing/lib/mock-stats.ts:229
↓ 2 callersFunctionPanicRecover
PanicRecover is the server-wide panic recovery. Gin logs the panic stack through common.ErrorLogWriter so it reaches the current log file.
middleware/recover.go:33
↓ 2 callersFunctionParseClaudeModelSuffix
ParseClaudeModelSuffix folds the naked claude-* aliases (-thinking, -nothinking, -thinking-<budget>, and effort tails such as -high) into an Intent. a
relaykit/relayconvert/reasoning/suffix.go:143
↓ 2 callersFunctionParseExprVersion
ParseExprVersion extracts the version tag and body from an expression string. Format: "v1:tier(...)" → version=1, body="tier(...)". No prefix defaults
pkg/billingexpr/compile.go:29
↓ 2 callersFunctionParseLegacyModelSuffix
ParseLegacyModelSuffix parses the old naked aliases only for positively matched GPT/o-series, Claude, and Gemini model families. The provider prefix b
setting/reasoning/suffix.go:35
↓ 2 callersMethodParseMediaContent
()
relaykit/dto/claude.go:110
↓ 2 callersFunctionParseOAuthKey
(raw string)
relay/channel/codex/oauth_key.go:21
↓ 2 callersFunctionParsePasskeyRPIDs
(value string, configuredOrigins ...string)
setting/system_setting/passkey.go:99
↓ 2 callersFunctionParseProxyURLStrict
ParseProxyURLStrict validates and normalizes a proxy URL for persistence.
common/proxy_url.go:12
↓ 2 callersFunctionParseTaskPluginDisabledFactoryKeys
(raw string)
setting/task_plugin.go:86
↓ 2 callersFunctionParseThinkingModifier
ParseThinkingModifier maps an explicit @thinking value onto a portable Intent. on/adaptive/off and integer budgets (including -1) are accepted; values
relaykit/relayconvert/reasoning/suffix.go:87
↓ 2 callersFunctionPaymentReturnURL
(suffix string)
service/return_path.go:9
↓ 2 callersFunctionPermissionsForRole
PermissionsForRole returns the permissions whose DefaultRoles include roleKey.
service/authz/registry.go:56
↓ 2 callersMethodPersist
(ctx context.Context, task *model.Task, artifact types.TaskArtifact, content io.Reader)
service/task_artifact_store.go:29
↓ 2 callersFunctionPluginBalanceUSD
PluginBalanceUSD is a balance result in USD for the balance column: USD as it is, CNY at the exchange-rate setting. ok is false for another currency,
service/provider_plugin_balance.go:17
↓ 2 callersFunctionPluginBillingExprKey
(pluginKey, model string)
setting/billing_setting/tiered_billing.go:86
↓ 2 callersFunctionPluginFetcher
PluginFetcher returns the utils.fetch of a plugin's hooks on a channel: the base URL host and the plugin's allowedHosts only, through the channel prox
service/provider_plugin.go:61
↓ 2 callersFunctionPluginModelListKey
PluginModelListKey returns the key line the model list request of a channel uses: its first enabled key that is a static key or a credential of the pl
service/provider_plugin.go:598
↓ 2 callersMethodPluginValue
PluginValue returns the state as a hook argument: nil when it is absent or null, otherwise its JSON text for the hook to receive parsed.
relay/plugin_protocol.go:107
↓ 2 callersFunctionPostWssConsumeQuota
(ctx *gin.Context, relayInfo *relaycommon.RelayInfo, modelName string, usage *dto.RealtimeUsage, extraContent
service/quota.go:159
↓ 2 callersMethodPreConsume
PreConsume 从该资金来源预扣 amount 额度
service/funding_source.go:19
↓ 2 callersFunctionPreConsumeTokenQuota
(relayInfo *relaycommon.RelayInfo, quota int)
service/quota.go:408
↓ 2 callersFunctionPrepareRequestBilling
PrepareRequestBilling estimates and reserves one request's charge. Transports provide the current request body through BodyStorage or BillingRequestIn
relay/request_billing.go:21
↓ 2 callersMethodPresentationLoss
PresentationLoss builds a warning-severity diagnostic for this definition.
relaykit/relayconvert/convmeta/websearch.go:93
↓ 2 callersFunctionPreviewVendorOperation
(operation VendorOperation)
model/vendor_management.go:197
↓ 2 callersFunctionProcessStreamResponse
(streamResponse dto.ChatCompletionsStreamResponse, responseTextBuilder *strings.Builder, toolCount *int)
relay/channel/openai/helper.go:123
↓ 2 callersMethodPurge
()
pkg/cachex/hybrid_cache.go:159
← previousnext →3,301–3,400 of 15,409, ranked by callers