Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/QuantumNous/new-api
/ functions
Functions
15,409 in github.com/QuantumNous/new-api
⨍
Functions
15,409
◇
Types & classes
2,241
↓ 3 callers
Function
normalizeLocale
(locale string)
controller/model_sync.go:30
↓ 3 callers
Function
normalizeOpenAIUsage
normalizeOpenAIUsage maps the OpenAI Images usage shape (input_tokens / output_tokens / input_tokens_details / output_tokens_details) onto the canonic
relay/channel/openai/relay_image.go:101
↓ 3 callers
Function
normalizeRatio
(value: unknown)
web/src/features/system-settings/models/group-ratio-visual-editor.tsx:131
↓ 3 callers
Function
normalizeResetCreditStatus
(value: unknown)
web/src/features/channels/components/dialogs/codex-usage-dialog.tsx:254
↓ 3 callers
Function
normalizeVisualTier
(tier: Partial<VisualTier> = {})
web/src/features/pricing/lib/tier-expr.ts:74
↓ 3 callers
Function
omniVideo
(body)
plugins/tasks/vertex-ai/plugin.js:218
↓ 3 callers
Function
onSubmit
(values: OAuthFormValues)
web/src/features/system-settings/auth/oauth-section.tsx:299
↓ 3 callers
Function
onePagePDF
onePagePDF is a PDF whose one page shows text in Helvetica.
plugins/request_plugins_test.go:1151
↓ 3 callers
Function
openAIBillingUsageFromUsage
(usage *dto.Usage)
relaykit/relayconvert/internal/oai_chat/to_gemini_chat_resp.go:547
↓ 3 callers
Function
openOAuthPopup
( options: OAuthPopupOptions )
web/src/features/auth/lib/oauth-popup.ts:51
↓ 3 callers
Function
optionalString
(s string)
service/waffo_pancake.go:150
↓ 3 callers
Function
outboundResolution
(req, model)
plugins/tasks/hailuo/plugin.js:223
↓ 3 callers
Method
pages
pages writes objects 1 to 3: the catalog, the page tree and one page whose contents are object 4 and whose font F1 is object 5.
relay/requestplugin/pdf_test.go:85
↓ 3 callers
Function
parseAuthClaims
(raw, expectedUse string, key []byte)
service/auth_token.go:183
↓ 3 callers
Function
parseCodexOAuthKey
(raw string)
service/codex_credential_refresh.go:31
↓ 3 callers
Function
parseConditionValue
( condition: Pick<ParamOverrideCondition, 'mode' | 'value_text'> )
web/src/features/channels/components/dialogs/param-override-editor-dialog.tsx:478
↓ 3 callers
Function
parseGroupsList
(groups: string)
web/src/features/channels/lib/channel-utils.ts:240
↓ 3 callers
Function
parseMediaRef
parseMediaRef returns N of "[media:N]".
relay/requestplugin/attachments.go:299
↓ 3 callers
Function
parseNumberDraft
(value: string)
web/src/features/system-settings/models/draft-number-input.tsx:38
↓ 3 callers
Function
parseOpenAIModelIDs
(body []byte)
controller/channel_upstream_update.go:268
↓ 3 callers
Function
parsePluginMetaPreview
(source: string)
web/src/features/task-plugins/lib/plugin-meta-preview.ts:340
↓ 3 callers
Function
parseSidebarModulesAdmin
( value: string | null | undefined )
web/src/features/system-settings/maintenance/config.ts:185
↓ 3 callers
Function
parseSystemVersion
( value: string | null | undefined )
web/src/features/system-update/releases.ts:47
↓ 3 callers
Function
parseThinkTags
(content: string)
web/src/features/playground/lib/message/message-reasoning-utils.ts:29
↓ 3 callers
Function
parseVisualBillingDocument
( source: string )
web/src/features/pricing/lib/billing-expression/visual.ts:219
↓ 3 callers
Function
passkeyDomainAssertion
Reuse the existing software authenticator, replacing the domain-bound bytes and recomputing the signature exactly as a browser/authenticator would.
controller/passkey_test.go:111
↓ 3 callers
Function
patchClaudeMessageDeltaUsageData
(data string, usage *dto.ClaudeUsage)
relay/channel/claude/relay-claude.go:81
↓ 3 callers
Function
permissionMatrixToScopes
( matrix: AdminPermissionMatrix )
web/src/lib/admin-permissions.ts:119
↓ 3 callers
Function
plainObject
plainObject builds a JavaScript object, not a host map, so a hook may return it or keep it.
pkg/jsplugin/media.go:79
↓ 3 callers
Function
pluginIconMediaType
( fileName: string )
web/src/features/task-plugins/lib/plugin-icon-file.ts:31
↓ 3 callers
Function
pluginIconUrl
(key: string, version?: string)
web/src/features/task-plugins/lib/plugin-icon.ts:29
↓ 3 callers
Function
pluginJSONDepth
(raw json.RawMessage)
relay/plugin_protocol.go:328
↓ 3 callers
Function
pluginLoginChannelID
(c *gin.Context)
controller/provider_plugin.go:42
↓ 3 callers
Function
pluginLoginIdentity
pluginLoginIdentity is the administrator session a login flow belongs to: a browser session, or a scoped access token with its own session.
controller/provider_plugin.go:33
↓ 3 callers
Function
pluginName
pluginName is the plugin name a log shows, in every locale it has.
relay/requestplugin/record.go:24
↓ 3 callers
Function
positiveInt
(value any)
relay/channel/task/jsplugin/adaptor.go:2262
↓ 3 callers
Function
positiveIntegerSchema
(message: string)
web/src/features/system-settings/utils/numeric-field.ts:27
↓ 3 callers
Function
postTaskPluginUpload
(t *testing.T, payload map[string]any)
controller/task_plugin_test.go:1465
↓ 3 callers
Function
previewPriorityDrop
( channels: Channel[], drop: PriorityDrop, desc: boolean )
web/src/features/channels/lib/channel-priority-order.ts:44
↓ 3 callers
Function
priceLineKey
(group: PriceGroup, line: PriceLine)
web/src/features/system-settings/models/price-change-diff.tsx:146
↓ 3 callers
Function
pricingDisplayFallbackKey
( expression: string, schema: BillingUsageSchema | null | undefined )
web/src/features/pricing/lib/task-price-display.ts:118
↓ 3 callers
Function
pricingRows
(options: PricingOptions)
web/src/features/model-pricing/pricing.ts:168
↓ 3 callers
Function
processChartData
( data: QuotaDataItem[], timeGranularity: TimeGranularity = 'day', t?: TFunction, chartCornerRadius?:
web/src/features/dashboard/lib/charts.ts:70
↓ 3 callers
Function
propertyName
(node)
web/scripts/oxlint/intl-locale.mjs:42
↓ 3 callers
Function
publishCommittedUserAuthVersion
publishCommittedUserAuthVersion records the durable lower bound used to reject an arbitrarily delayed cache fill after a committed security change. It
model/user_auth_cache.go:160
↓ 3 callers
Function
pushJSON
(texts, value)
plugins/tasks/request-filter/plugin.js:139
↓ 3 callers
Function
quotaReminderDue
quotaReminderDue reports whether a charge that moved a balance (wallet or subscription) from before to after earns a low-balance reminder. The site an
service/quota.go:539
↓ 3 callers
Function
randomInRange
( rand: () => number, min: number, max: number )
web/src/features/pricing/lib/seed.ts:48
↓ 3 callers
Function
rankingShare
(value int64, total int64)
service/rankings.go:556
↓ 3 callers
Function
rawMapValue
(value map[string]any, key string)
relaykit/relayconvert/internal/toolconv/decode.go:1114
↓ 3 callers
Function
rawOrNull
(raw json.RawMessage)
pkg/jsplugin/provider.go:290
↓ 3 callers
Function
read
(start, length)
plugins/tasks/xai/plugin.js:615
↓ 3 callers
Function
readCgroupUint
readCgroupUint 读取只含一个无符号整数的 cgroup 文件。
common/container_usage.go:150
↓ 3 callers
Function
readConstInitializer
(variable: SyntaxNode)
web/src/features/task-plugins/lib/plugin-meta-preview.ts:77
↓ 3 callers
Function
readModelPricingMaps
(db *gorm.DB)
model/model_pricing_config.go:99
↓ 3 callers
Function
readTokenTierChain
(node: ExpressionNode)
web/src/features/pricing/lib/billing-expression/display.ts:185
↓ 3 callers
Method
reader
()
relay/requestplugin/attachments.go:197
↓ 3 callers
Function
realtimeDone
realtimeDone is the response.done of resp_1 with one message item.
relay/requestplugin/socket_test.go:89
↓ 3 callers
Function
reasoningDiagnostic
reasoningDiagnostic describes a best-effort resolution between reasoning controls that is not tied to a single provider's field layout. The target for
relaykit/relayconvert/reasoning/intent.go:140
↓ 3 callers
Method
reasoningID
()
relaykit/relayconvert/internal/oai_chat/to_oai_responses_stream_resp.go:856
↓ 3 callers
Function
recalcQuotaFromRatios
recalcQuotaFromRatios 根据 adjustedRatios 重新计算 quota。 公式: baseQuota × ∏(ratio) — 其中 baseQuota 是不含 OtherRatios 的基础额度。
relay/relay_task.go:449
↓ 3 callers
Function
recordLoginAudit
recordLoginAudit 记录登录成功审计日志(对所有用户启用,仅记录成功,不记录失败)。
controller/user.go:129
↓ 3 callers
Function
recordPollFailure
(ctx context.Context, adaptor TaskPollingAdaptor, task *model.Task, fromStatus model.TaskStatus, class string,
service/task_polling.go:863
↓ 3 callers
Function
recordValue
(value: unknown)
web/src/features/dashboard/lib/flow.ts:1028
↓ 3 callers
Function
refreshAuthentication
()
web/src/lib/auth-session.ts:335
↓ 3 callers
Function
register
(payload: RegisterPayload)
web/src/features/auth/api.ts:250
↓ 3 callers
Method
register
(source string, options Options, factory bool)
pkg/jsplugin/registry.go:476
↓ 3 callers
Function
registerChannelRoutes
(apiRouter *gin.RouterGroup)
router/channel-router.go:40
↓ 3 callers
Function
registerModelTestPlugin
(t *testing.T, source, key string)
model/channel_plugin_credential_test.go:49
↓ 3 callers
Function
registeredSyncTopics
(sync: NodeSync, topics?: string[])
web/src/features/system-info/lib/node-sync.ts:48
↓ 3 callers
Function
rejectInvalidCreditedQuota
(c *gin.Context, userId int, quota decimal.Decimal)
controller/topup.go:267
↓ 3 callers
Function
rejectTaskPluginRoutingConflict
rejectTaskPluginRoutingConflict answers the request and returns true when the plugin about to serve key fails to compile or does not fit the live rout
controller/task_plugin.go:836
↓ 3 callers
Method
rejected
rejected reports an upstream rejection of the credential: a 401, or a non-2xx response credentialRejected accepts. The body it reads stays readable fo
relay/channel/providerplugin/adaptor.go:752
↓ 3 callers
Function
relaxNoticeDelivery
(t *testing.T, onNotice func(title string))
service/provider_plugin_test.go:527
↓ 3 callers
Function
rememberPasskeyRPID
(rpID?: string)
web/src/features/auth/passkey/assertion.ts:39
↓ 3 callers
Method
rememberUsage
(usage *dto.Usage)
relaykit/relayconvert/response_registry.go:667
↓ 3 callers
Function
removeTrailingSlash
(value: string)
web/src/features/system-settings/integrations/utils.ts:19
↓ 3 callers
Function
renderChildren
( nodes: ParsedNode[], fadeRun?: FadeRun )
web/src/components/ai-elements/response-renderer.tsx:62
↓ 3 callers
Function
renderQuotaCompat
(rawQuota: number, digits = 4)
web/src/features/dashboard/lib/charts.ts:53
↓ 3 callers
Method
renew
renew refreshes the request's credential, or drops its token and exchanges the key again, after the upstream rejected it.
relay/channel/providerplugin/adaptor.go:639
↓ 3 callers
Function
reportFailedTasks
reportFailedTasks reports tasks failed in one bulk update with reason.
service/task_polling.go:82
↓ 3 callers
Function
reportFinalTask
reportFinalTask reports a task once, after its final state is stored and settled. A task no instance may report costs nothing.
service/task_polling.go:75
↓ 3 callers
Function
requestAccessTokenLookup
(c *gin.Context)
middleware/auth.go:280
↓ 3 callers
Function
requestPasskeyAssertion
( begin: (rpID?: string) => Promise<PasskeyOptionsPayload>, signal?: AbortSignal, selection: PasskeySele
web/src/features/auth/passkey/assertion.ts:48
↓ 3 callers
Function
requestPluginConfigDefaults
( schema: RequestPluginConfigShape | undefined )
web/src/features/task-plugins/lib/request-plugins.ts:200
↓ 3 callers
Function
requestPluginModelValueShape
( field: RequestPluginConfigField )
web/src/features/task-plugins/lib/request-plugins.ts:113
↓ 3 callers
Function
requestRuleNumber
(node ast.Node)
pkg/billingexpr/compile.go:87
↓ 3 callers
Function
requestSettings
(req, action, model)
plugins/tasks/vidu/plugin.js:242
↓ 3 callers
Function
requestTarget
requestTarget reads the path or url member of a request result: path replaces the route's upstream path on its origin, url the whole address.
pkg/jsplugin/provider.go:808
↓ 3 callers
Function
resolution
(size)
plugins/tasks/vertex-ai/plugin.js:302
↓ 3 callers
Function
resolveAuthentication
()
web/src/lib/auth-session.ts:373
↓ 3 callers
Function
resolveChannelSortOptions
(idSort bool, sortOptions []ChannelSortOptions)
model/channel.go:138
↓ 3 callers
Function
resolveChannelTestUserID
(c *gin.Context)
controller/channel-test.go:85
↓ 3 callers
Function
resolvePluginMetaPreview
( plugin: MarketplacePlugin | undefined, version: MarketplaceIndexVersion | undefined, source: PluginMet
web/src/features/task-plugins/lib/plugin-meta-preview.ts:488
↓ 3 callers
Function
resolveVisibleStages
( role: FlowRole, visibleStages?: FlowNodeKind[] )
web/src/features/dashboard/lib/flow.ts:264
↓ 3 callers
Method
respond
respond primes the conversion and answers the client: the event stream, or the chunks or body of a non-streaming client. An error before the first out
relay/channel/providerplugin/stream.go:99
↓ 3 callers
Method
responseEvent
(eventType string)
relay/plugin_protocol.go:967
↓ 3 callers
Function
responseStreamResults
(state *ResponseStreamState, values []any, usage *dto.Usage, diagnostics []types.ConversionDiagnostic)
relaykit/relayconvert/response_registry.go:706
↓ 3 callers
Function
responsesCallID
(item map[string]any)
relaykit/relayconvert/internal/oai_responses/to_oai_chat_req.go:581
↓ 3 callers
Function
responsesCustomToolChoice
responsesCustomToolChoice rewrites a Responses {"type":"custom"} tool choice into a named function choice when that custom tool was sent as a function
relaykit/relayconvert/internal/toolconv/encode.go:406
← previous
next →
2,801–2,900 of 15,409, ranked by callers