Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/QuantumNous/new-api
/ functions
Functions
10,934 in github.com/QuantumNous/new-api
⨍
Functions
10,934
◇
Types & classes
1,622
↓ 5 callers
Function
getDynamicPriceUnitLabelKey
( entry: DynamicPriceEntry )
web/src/features/pricing/lib/dynamic-price.ts:109
↓ 5 callers
Function
getMessageContent
(message: Message)
web/src/features/playground/lib/message/message-utils.ts:49
↓ 5 callers
Function
getSavedChartPreferences
()
web/src/features/dashboard/lib/filters.ts:94
↓ 5 callers
Function
getTaskQuota
(t *testing.T, id int64)
service/task_billing_test.go:496
↓ 5 callers
Function
getTokenCacheKey
(key string)
model/token_cache.go:12
↓ 5 callers
Function
getUserAvatarFallback
(name: string)
web/src/lib/avatar.ts:43
↓ 5 callers
Function
getUserAvatarStyle
(name: string)
web/src/lib/avatar.ts:31
↓ 5 callers
Function
insertOriginOwnedTask
(t *testing.T, taskID string, userID, channelID int, platform constant.TaskPlatform)
middleware/task_plugin_origin_task_test.go:55
↓ 5 callers
Function
invalidateTokenCacheForMutation
invalidateTokenCacheForMutation is called before a token metadata mutation writes to the database: it raises the fence and drops the cached hash so no
model/token_cache.go:38
↓ 5 callers
Function
isContentSizedColumn
(columnId: string)
web/src/components/data-table/core/content-sized-columns.ts:19
↓ 5 callers
Function
isJsonObjectValue
(value: unknown)
web/src/features/channels/lib/channel-form.ts:113
↓ 5 callers
Function
isPaymentComplianceConfirmed
()
controller/payment_webhook_availability.go:10
↓ 5 callers
Function
isRecord
(value: unknown)
web/src/lib/auth-session.ts:88
↓ 5 callers
Function
isUnconfiguredTaskUsageModel
(model: PricingModel)
web/src/features/pricing/lib/dynamic-price.ts:142
↓ 5 callers
Function
logsAppender
(logs *[]string)
controller/plugin_protocol_test.go:1544
↓ 5 callers
Method
makeChunk
(delta dto.ChatCompletionsStreamResponseChoiceDelta, finishReason *string)
relaykit/relayconvert/internal/oai_responses/to_oai_chat_stream_resp.go:519
↓ 5 callers
Function
mergeModelNames
(base []string, appended []string)
controller/channel_upstream_update.go:108
↓ 5 callers
Function
mustRawMessage
(t *testing.T, value any)
relaykit/relayconvert/request_registry_test.go:698
↓ 5 callers
Function
newFakeSMTPServer
(t *testing.T)
common/email_test.go:35
↓ 5 callers
Function
newHTTPClientWithPolicyAndTLS
newHTTPClientWithPolicyAndTLS is a test seam that builds a never-used transport stack with the given policy and TLS config (for httptest certificate t
service/http_client.go:373
↓ 5 callers
Function
newTaskSubmitContext
(t *testing.T, originalModel, mapping string)
relay/relay_task_test.go:58
↓ 5 callers
Function
newTokenAutoGroupsAuthenticatedContext
(t *testing.T, method string, target string, body any, userID int)
controller/token_auto_groups_test.go:67
↓ 5 callers
Function
normalizeVisualTier
( tier: Partial<VisualTier> = {} )
web/src/features/pricing/lib/tier-expr.ts:61
↓ 5 callers
Function
parseAdvancedCustomConfig
( value: string | undefined )
web/src/features/channels/lib/advanced-custom.ts:531
↓ 5 callers
Function
parseLooseValue
(valueText: string)
web/src/features/channels/components/dialogs/param-override-editor-dialog.tsx:464
↓ 5 callers
Function
parseOptionalJson
(value: string | undefined)
web/src/features/channels/lib/channel-form.ts:108
↓ 5 callers
Function
parseRatioMap
(value: string)
web/src/features/system-settings/models/group-ratio-visual-editor.tsx:120
↓ 5 callers
Function
parseUsableMap
(value: string)
web/src/features/system-settings/models/group-ratio-visual-editor.tsx:127
↓ 5 callers
Function
pinnedTaskPluginChannelTypes
(c *gin.Context, expected string)
service/channel_select.go:200
↓ 5 callers
Function
presentTaskSubmission
(c *gin.Context, outcome *taskSubmissionOutcome)
controller/relay.go:766
↓ 5 callers
Function
preserveToolPrices
(t *testing.T)
setting/operation_setting/tools_price_test.go:11
↓ 5 callers
Function
requestClientIP
(router http.Handler, remoteAddr string, forwardedFor string)
middleware/trusted_proxies_test.go:13
↓ 5 callers
Function
requireOptionMissing
(t *testing.T, db *gorm.DB, key string)
model/frontend_option_migration_test.go:37
↓ 5 callers
Function
resolveAuth
(meta pluginruntime.AuthMeta, apiKey, proxy string)
relay/channel/task/jsplugin/auth.go:22
↓ 5 callers
Function
rowMetrics
(row: FlowQuotaDataItem)
web/src/features/dashboard/lib/flow.ts:156
↓ 5 callers
Function
sanitizeAuthRedirect
( value: unknown, origin: string )
web/src/features/auth/lib/auth-redirect.ts:46
↓ 5 callers
Function
sanitizeFetchModelsError
(err error, key string)
controller/channel_upstream_update.go:285
↓ 5 callers
Function
sankeyDatumValue
( datum: Record<string, unknown>, key: string )
web/src/features/dashboard/lib/flow.ts:1041
↓ 5 callers
Function
seedSubscriptionResetPlan
(t *testing.T, plan *SubscriptionPlan)
model/subscription_reset_test.go:12
↓ 5 callers
Function
setupAuthFlowControllerTest
(t *testing.T)
controller/auth_flow_test.go:51
↓ 5 callers
Function
setupTokenAutoGroupsControllerTest
(t *testing.T)
controller/token_auto_groups_test.go:41
↓ 5 callers
Function
startHTTP2TLSServer
(t *testing.T, handler http.Handler)
service/http_client_transport_test.go:99
↓ 5 callers
Function
stringMetaField
(object map[string]any, name string)
pkg/jsplugin/registry.go:1641
↓ 5 callers
Function
stringifyAdvancedCustomConfig
( config: AdvancedCustomConfig )
web/src/features/channels/lib/advanced-custom.ts:546
↓ 5 callers
Function
syncTaskPluginsOnceContext
(ctx context.Context)
controller/task_plugin.go:609
↓ 5 callers
Function
taskHasPluginExecution
(task *model.Task)
controller/task.go:208
↓ 5 callers
Function
taskMatrixRowLabel
( combination: Record<string, string> )
web/src/features/pricing/lib/task-expr.ts:135
↓ 5 callers
Function
taskPluginDebugStatus
(status string)
controller/task_plugin_debug.go:258
↓ 5 callers
Function
testTLSClientConfig
(t *testing.T, server *httptest.Server)
service/http_client_transport_test.go:91
↓ 5 callers
Function
textRegistryChatResponse
()
relaykit/relayconvert/response_registry_test.go:615
↓ 5 callers
Function
toNumberOrNull
(value: unknown)
web/src/features/system-settings/models/model-pricing-core.ts:153
↓ 5 callers
Function
trimmed
(value)
plugins/tasks/vidu/plugin.js:45
↓ 5 callers
Function
trimmed
(value)
plugins/tasks/hailuo/plugin.js:50
↓ 5 callers
Function
trimmed
(value)
plugins/tasks/kling/plugin.js:49
↓ 5 callers
Function
tryParseRequestRuleExpr
( expr: string )
web/src/features/pricing/lib/billing-expr.ts:862
↓ 5 callers
Function
tryParseTaskVisualConfig
( expression: string | null | undefined, schema: BillingUsageSchema )
web/src/features/pricing/lib/task-expr.ts:444
↓ 5 callers
Function
updateChannel
( id: number, data: Partial<Channel> )
web/src/features/channels/api.ts:140
↓ 5 callers
Function
updateUserCache
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:80
↓ 5 callers
Function
usageNumber
(value any, allowNumericString bool)
relay/channel/task/jsplugin/adaptor.go:1349
↓ 5 callers
Function
useBranch
()
web/src/components/ai-elements/branch.tsx:49
↓ 5 callers
Function
useLogsViewScope
()
web/src/features/usage-logs/components/usage-logs-provider.tsx:104
↓ 5 callers
Function
usePricingData
(enabled = true)
web/src/features/pricing/hooks/use-pricing-data.ts:26
↓ 5 callers
Function
validateAdvancedCustomConfig
( config: AdvancedCustomConfig | null )
web/src/features/channels/lib/advanced-custom.ts:587
↓ 5 callers
Function
writeUserCache
(user *UserBase, includeQuota bool)
model/user_auth_cache.go:48
↓ 4 callers
Method
AddAll
(other map[K]V)
types/rw_map.go:46
↓ 4 callers
Method
AddPolicy
(_ string, ptype string, rule []string)
service/authz/adapter.go:57
↓ 4 callers
Function
AdminResetUserSubscriptionsByPlan
(userId int, planId int, advanceResetTime bool)
model/subscription.go:1091
↓ 4 callers
Function
ApiSuccessI18n
ApiSuccessI18n returns a translated success message based on the user's language preference
common/gin.go:232
↓ 4 callers
Method
AppendRequestConversion
AppendRequestConversion records a hop in the request format chain.
relaykit/relayconvert/convmeta/meta.go:45
↓ 4 callers
Function
AppendTaskPluginIdentityFilter
(c *gin.Context, pluginKey string)
service/channel_select.go:27
↓ 4 callers
Method
ApplyOtherRatiosToFloat
(value float64)
types/price_data.go:84
↓ 4 callers
Function
CallID
(item map[string]any)
relaykit/relayconvert/internal/oai_responses/to_oai_chat_req.go:505
↓ 4 callers
Function
ClaimExternalAuthAssertion
ClaimExternalAuthAssertion records a signed provider assertion as consumed. The assertion is HMACed before storage and the unique token_hash index mak
model/auth_flow.go:124
↓ 4 callers
Method
ConvOptions
ConvOptions returns the request-scoped conversion options snapshot. Must never return nil.
relaykit/relayconvert/convmeta/meta.go:49
↓ 4 callers
Function
ConvertRequestByID
(c *gin.Context, info *relaycommon.RelayInfo, converter string, request any)
service/request_converter.go:30
↓ 4 callers
Method
ConvertToOpenAIVideo
(originTask *model.Task)
relay/channel/adapter.go:93
↓ 4 callers
Function
CountUserSubscriptionsByPlan
(userId int, planId int)
model/subscription.go:413
↓ 4 callers
Function
CovertMjpActionToModelName
(mjAction string)
service/midjourney.go:26
↓ 4 callers
Function
CreateUserSubscriptionFromPlanTx
(tx *gorm.DB, userId int, plan *SubscriptionPlan, source string)
model/subscription.go:484
↓ 4 callers
Method
DecodePayload
(v any)
model/system_task.go:408
↓ 4 callers
Function
DecreaseTokenQuota
(id int, key string, quota int)
model/token.go:408
↓ 4 callers
Function
DecrementDiskFiles
DecrementDiskFiles 减少磁盘文件计数
common/disk_cache_config.go:115
↓ 4 callers
Function
DeleteTaskPluginVersion
(c *gin.Context)
controller/task_plugin.go:358
↓ 4 callers
Function
DoDownloadRequest
(originUrl string, reason ...string)
service/download.go:52
↓ 4 callers
Function
DoWorkerRequest
DoWorkerRequest 通过Worker发送请求
service/download.go:24
↓ 4 callers
Function
ErrOptionWithNoRecordErrorLog
()
relaykit/types/error.go:387
↓ 4 callers
Function
ExtendWriteDeadline
ExtendWriteDeadline pushes the connection write deadline forward before each stream write. Best-effort: writers that don't support deadlines (e.g. htt
relay/helper/stream_scanner.go:70
↓ 4 callers
Method
FillUserById
()
model/user.go:1014
↓ 4 callers
Method
FullKey
(key string)
pkg/cachex/hybrid_cache.go:55
↓ 4 callers
Function
GeminiTextGenerationHandler
(c *gin.Context, info *relaycommon.RelayInfo, resp *http.Response)
relay/channel/gemini/relay-gemini-native.go:20
↓ 4 callers
Function
GenerateHMAC
(data string)
common/crypto.go:17
↓ 4 callers
Function
GenerateHMACWithKey
(key []byte, data string)
common/crypto.go:11
↓ 4 callers
Function
GenerateRandomCharsKey
(length int)
common/utils.go:231
↓ 4 callers
Function
GenerateStopResponse
(id string, createAt int64, model string, finishReason string)
relay/helper/common.go:202
↓ 4 callers
Function
GetBillingExpr
(model string)
setting/billing_setting/tiered_billing.go:52
↓ 4 callers
Method
GetByModel
GetByModel returns the deterministic effective plugin metadata used for a model-level host concern such as billing. When multiple providers expose the
pkg/jsplugin/routing.go:413
↓ 4 callers
Function
GetChannelAffinityUsageCacheStats
(ruleName, usingGroup, keyFp string)
service/channel_affinity.go:790
↓ 4 callers
Function
GetCheckinSetting
GetCheckinSetting 获取签到配置
setting/operation_setting/checkin_setting.go:25
↓ 4 callers
Function
GetContextKeyInt
(c *gin.Context, key constant.ContextKey)
common/gin.go:169
↓ 4 callers
Function
GetCustomOAuthProviderById
GetCustomOAuthProviderById returns a custom OAuth provider by ID
model/custom_oauth_provider.go:88
← previous
next →
801–900 of 10,934, ranked by callers