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
↓ 2 callers
Function
mantleRequestURL
(info *relaycommon.RelayInfo)
relay/channel/aws/mantle.go:24
↓ 2 callers
Function
mapEncoding
(responseFormat string)
relay/channel/volcengine/tts.go:125
↓ 2 callers
Function
markAnnouncementsAsRead
()
web/src/hooks/use-notifications.ts:126
↓ 2 callers
Method
markHit
()
router/plugin-router.go:36
↓ 2 callers
Function
markOAuthPopup
( storage: OAuthModeStorage | null | undefined, provider: string, state: string, intent: 'bind' | 'ver
web/src/features/auth/lib/oauth-callback-mode.ts:86
↓ 2 callers
Method
markUnchecked
markUnchecked records every instance as unable to read the answer.
relay/requestplugin/reply.go:245
↓ 2 callers
Function
marketplaceBuiltInVersion
( installed?: TaskPluginListItem )
web/src/features/task-plugins/lib/marketplace.ts:423
↓ 2 callers
Function
marshalChatAnnotations
(annotations []any)
relaykit/relayconvert/internal/claude_messages/citations.go:53
↓ 2 callers
Function
marshalGroundingAnnotations
(annotations []any)
relaykit/relayconvert/internal/gemini_chat/grounding.go:324
↓ 2 callers
Function
maskHostTail
maskHostTail returns the tail parts of a domain/host that should be preserved. It keeps 2 parts for likely country-code TLDs (e.g., co.uk, com.cn), ot
relaykit/relayconvert/kitutil/mask.go:30
↓ 2 callers
Function
matchAdvancedCustomIncomingPath
(configuredPath string, requestPath string)
relaykit/dto/channel_settings.go:438
↓ 2 callers
Function
matchAdvancedCustomRouteModelRule
(rule string, model string)
relaykit/dto/channel_settings.go:426
↓ 2 callers
Function
maxInlineFileBytes
()
relay/channel/task/jsplugin/adaptor.go:461
↓ 2 callers
Function
maxTokenQuota
()
controller/token.go:47
↓ 2 callers
Function
maybeResetUserSubscriptionWithPlanTx
(tx *gorm.DB, sub *UserSubscription, plan *SubscriptionPlan, now int64)
model/subscription.go:1279
↓ 2 callers
Function
mediaInput
(value, name)
plugins/tasks/xai/plugin.js:164
↓ 2 callers
Function
mediaRef
(index int)
relay/requestplugin/attachments.go:294
↓ 2 callers
Function
memoryEmailVerificationRateLimiter
(c *gin.Context)
middleware/email-verification-rate-limit.go:42
↓ 2 callers
Method
mergeFinalValue
(block *responsesClaudeStreamBlock, finalValue string, estimatedInputTokens int)
relaykit/relayconvert/internal/oai_responses/to_claude_messages_stream_resp.go:319
↓ 2 callers
Function
mergeGeminiTokenDetails
mergeGeminiTokenDetails overlays per-modality counts the same way as the scalar counts: every stream frame carries a cumulative snapshot, so a modalit
relaykit/dto/usage_merge.go:274
↓ 2 callers
Function
mergeInputTokenDetails
(current *InputTokenDetails, incoming InputTokenDetails)
relaykit/dto/usage_merge.go:295
↓ 2 callers
Function
mergeModelBucket
(modelBuckets map[string]map[int64]counters, modelName string, bucketTs int64, value counters)
pkg/perf_metrics/metrics.go:361
↓ 2 callers
Function
mergeModelMappingPairs
( current: string, pairs: readonly ModelMappingPair[] )
web/src/features/channels/lib/model-mapping-rules.ts:112
↓ 2 callers
Function
mergeToolSurchargeItems
(items []ToolSurchargeItem)
service/text_quota.go:122
↓ 2 callers
Function
mergedHotBuckets
()
pkg/perf_metrics/metrics_test.go:176
↓ 2 callers
Method
messageOutput
(status string)
relaykit/relayconvert/internal/oai_chat/to_oai_responses_stream_resp.go:860
↓ 2 callers
Function
messageText
(value: unknown)
web/src/lib/server-error-message.ts:144
↓ 2 callers
Function
metricMean
( metrics: InferenceMetric[], name: string )
web/src/features/channels/lib/inference-status.ts:75
↓ 2 callers
Function
migrateTokenControllerTestDB
(t *testing.T, db *gorm.DB)
controller/token_test.go:107
↓ 2 callers
Function
minInt
(a int, b int)
service/rankings.go:591
↓ 2 callers
Function
modelPriceNotConfiguredError
(c *gin.Context, modelName string, userId int)
relay/helper/price.go:28
↓ 2 callers
Function
modelPricingDisplay
( entry: Pick<ModelPricingEntry, 'model_name' | 'effective' | 'usage_schema'> & Partial< Pick<
web/src/features/model-pricing/pricing.ts:71
↓ 2 callers
Function
modelRequestSucceeded
(c *gin.Context)
middleware/model-rate-limit.go:167
↓ 2 callers
Function
modelURL
(ctx, project, location, model, action)
plugins/tasks/vertex-ai/plugin.js:335
↓ 2 callers
Function
moderate
(config, input)
plugins/tasks/content-moderation/plugin.js:252
↓ 2 callers
Function
moderationNotice
(data)
plugins/tasks/xai/plugin.js:333
↓ 2 callers
Function
multipartMemoryLimit
multipartMemoryLimit returns the configured multipart memory limit in bytes
common/gin.go:487
↓ 2 callers
Function
nativeBody
(ctx)
plugins/tasks/jimeng/plugin.js:120
↓ 2 callers
Function
nativeRequest
(ctx)
plugins/tasks/alibaba/plugin.js:399
↓ 2 callers
Method
needsRefundLocked
()
service/billing_session.go:138
↓ 2 callers
Function
newAPIGateway
newAPIGateway emulates the upstream New API instance a type-60 channel points at: it answers only on the plugin's prefixed native routes, requires the
relay/channel/task/jsplugin/adaptor_test.go:2701
↓ 2 callers
Function
newAwsStreamResponse
(request *http.Request, body io.ReadCloser)
relay/channel/aws/relay_aws_test.go:140
↓ 2 callers
Function
newCallMedia
(request *requestMedia, view []byte, media []inlineMedia, form *formBody)
relay/requestplugin/attachments.go:290
↓ 2 callers
Function
newEpayRSAKeyPairForTest
newEpayRSAKeyPairForTest returns a throwaway key pair as single-line Base64 text, the format Epay merchant consoles show.
controller/payment_webhook_availability_test.go:312
↓ 2 callers
Function
newFakeUpstream
(t *testing.T)
router/provider_plugin_relay_test.go:72
↓ 2 callers
Method
newFallbackID
()
relaykit/relayconvert/internal/gemini_chat/to_oai_chat_req.go:345
↓ 2 callers
Function
newGeminiChatBillingUsage
(metadata *GeminiUsageMetadata, estimated bool)
relaykit/dto/billing_usage.go:210
↓ 2 callers
Function
newGeminiStreamResponse
(candidates []dto.GeminiChatCandidate, usage *dto.Usage, info convmeta.Meta)
relaykit/relayconvert/internal/oai_chat/to_gemini_chat_resp.go:476
↓ 2 callers
Function
newGormAdapter
(db *gorm.DB)
service/authz/adapter.go:18
↓ 2 callers
Function
newJSONStateNode
(value any, depth int, budget *jsonStateBudget)
pkg/jsplugin/json_state.go:99
↓ 2 callers
Function
newKeywordList
(text string, hash [sha256.Size]byte)
pkg/jsplugin/keywords.go:52
↓ 2 callers
Function
newLoginSession
(userID int, authVersion int64, loginMethod, ip, userAgent string)
service/auth_session.go:104
↓ 2 callers
Function
newMemoryStorage
(data []byte)
common/body_storage.go:76
↓ 2 callers
Function
newMultipartFileContext
(t *testing.T, field, filename, contentType string, content []byte)
relay/channel/task/jsplugin/adaptor_test.go:267
↓ 2 callers
Function
newNodeSyncRegistry
()
service/node_sync.go:52
↓ 2 callers
Function
newOpenAIBillingUsage
(source string, usage *Usage)
relaykit/dto/billing_usage.go:66
↓ 2 callers
Function
newPassThroughBody
(t *testing.T, payload []byte)
relay/channel/api_request_getbody_test.go:442
↓ 2 callers
Function
newPlanOf
newPlanOf is the plan of instances, in their order.
relay/requestplugin/plan.go:136
↓ 2 callers
Function
newPluginRouterTestWithProxies
( t *testing.T, plugins []*jsplugin.LoadedPlugin, handlers pluginRouteHandlers, trustedProxies []string, )
router/plugin_router_test.go:1017
↓ 2 callers
Function
newProtectedFetchHTTPClientWithDialer
(resolver ssrfResolver, dialContext func(ctx context.Context, network, address string) (net.Conn, error), getP
service/protected_fetch_client.go:62
↓ 2 callers
Function
newRelayHTTPClient
(transport http.RoundTripper)
service/http_client.go:132
↓ 2 callers
Function
newRelayHTTPTransport
()
service/http_client.go:79
↓ 2 callers
Function
newReportError
newReportError is the error a client received, as the record shows it.
relay/requestplugin/report.go:325
↓ 2 callers
Function
newReportQueue
(records int, maxBytes int64, workers int)
relay/requestplugin/report.go:461
↓ 2 callers
Function
newResponseStreamStateFromSpec
(from types.RelayFormat, target types.RelayFormat, options ResponseStreamOptions, spec ResponseConverterSpec)
relaykit/relayconvert/response_registry.go:579
↓ 2 callers
Function
newResponsesWSRequestRunner
(c *gin.Context)
controller/responses_websocket.go:76
↓ 2 callers
Function
newRevokeServer
(t *testing.T)
controller/provider_plugin_test.go:55
↓ 2 callers
Method
newRuntime
(ctx context.Context)
pkg/jsplugin/engine.go:873
↓ 2 callers
Method
newStreamConverter
newStreamConverter converts the stream of an upstream request whose convertResponse would read state as ctx.state.
relay/channel/providerplugin/stream.go:69
↓ 2 callers
Function
newTaskAPIRequest
(c *gin.Context, fullRequestURL string, requestBody io.Reader)
relay/channel/api_request.go:642
↓ 2 callers
Function
newTaskArtifactAccessLimiter
(limits system_setting.TaskArtifactAccessLimits)
middleware/task_artifact_access.go:45
↓ 2 callers
Function
newTestTLSCertificate
()
common/email_test.go:215
↓ 2 callers
Method
newline
newline ends the current line unless the text is empty or ends one.
relay/requestplugin/extract.go:59
↓ 2 callers
Method
next
()
web/src/features/pricing/lib/billing-expression/parser.ts:81
↓ 2 callers
Method
next
next reads one message as convertStreamEvent gets it: event is the :event-type header, or :exception-type or :error-code for an exception or an error,
relay/channel/providerplugin/eventstream.go:35
↓ 2 callers
Function
nextRequestBody
nextRequestBody is the body and content type of a chained request: its body with $file markers filled in, its form, its client file, or none.
relay/channel/providerplugin/chain.go:92
↓ 2 callers
Function
nextTaskPluginBaseUrl
( currentValue: string | undefined, previousDefault: string | undefined, nextDefault: string | undefined
web/src/features/channels/lib/task-plugin-base-url.ts:85
↓ 2 callers
Function
noAvailableChannelMessage
noAvailableChannelMessage explains a 503 for a task-plugin-claimed model. The response tells the caller the model is plugin-claimed without naming the
middleware/distributor.go:145
↓ 2 callers
Function
nodeSyncState
( node: NodeSyncNode, topics: string[] )
web/src/features/system-info/lib/node-sync.ts:55
↓ 2 callers
Function
nonnegativePriceLiteral
(node: ExpressionNode)
web/src/features/pricing/lib/billing-expression/display.ts:83
↓ 2 callers
Function
normalizeAccessTokenName
normalizeAccessTokenName returns the trimmed name, or false when it is empty or longer than the 64-character column.
controller/access_token.go:53
↓ 2 callers
Function
normalizeAdvancedCustomRouteModels
( models: string[] | undefined )
web/src/features/channels/lib/advanced-custom.ts:840
↓ 2 callers
Function
normalizeBaseUrl
(value: string | undefined)
web/src/features/channels/lib/channel-form.ts:903
↓ 2 callers
Function
normalizeChannelModelMapping
(channel *model.Channel)
controller/channel_upstream_update.go:155
↓ 2 callers
Function
normalizeChannelTestMode
(value?: string)
web/src/features/system-settings/request-policies/channel-health-section.tsx:145
↓ 2 callers
Function
normalizeClaudeEffort
(effort Effort, capabilities claudeCapabilities)
relaykit/relayconvert/reasoning/claude.go:456
↓ 2 callers
Function
normalizeClickHouseDSN
(dsn string)
model/main.go:127
↓ 2 callers
Function
normalizeCondition
( condition: Record<string, unknown> = {} )
web/src/features/channels/components/dialogs/param-override-editor-dialog.tsx:495
↓ 2 callers
Function
normalizeCondition
( cond: Partial<RequestCondition> | null | undefined )
web/src/features/pricing/lib/billing-expr.ts:728
↓ 2 callers
Function
normalizeGeminiSchemaTypeAndNullable
(schema map[string]interface{})
relaykit/relayconvert/internal/shared/gemini/schema.go:172
↓ 2 callers
Function
normalizeHttp2ConnectionShards
( value: number | undefined | null )
web/src/features/channels/lib/channel-form.ts:98
↓ 2 callers
Function
normalizeLookupValues
(values []string)
model/model_meta.go:430
↓ 2 callers
Function
normalizeMetaBaseURL
normalizeMetaBaseURL admits an absolute http(s) URL that a channel can adopt verbatim as its base URL: no credentials, query, or fragment, an ASCII lo
pkg/jsplugin/registry.go:2430
↓ 2 callers
Function
normalizeModelList
(models: unknown[] = [])
web/src/features/channels/lib/upstream-update-utils.ts:19
↓ 2 callers
Function
normalizeOperation
( operation: Record<string, unknown> = {} )
web/src/features/channels/components/dialogs/param-override-editor-dialog.tsx:511
↓ 2 callers
Function
normalizePlanType
(value: unknown)
web/src/features/channels/components/dialogs/codex-usage-dialog.tsx:239
↓ 2 callers
Function
normalizePluginConfig
normalizePluginConfig validates the plugin config in the channel's settings and stores it as the schema reads it: declared properties only, defaults l
controller/channel.go:563
↓ 2 callers
Function
normalizePluginSourceUrl
(input: string)
web/src/features/task-plugins/lib/plugin-url.ts:38
↓ 2 callers
Function
normalizeReason
(reason string)
pkg/wsmanager/wsmanager.go:234
↓ 2 callers
Function
normalizeRequestPluginInstances
normalizeRequestPluginInstances checks an instance list and returns it as it is saved: ids filled in, names trimmed and configs validated. An enabled
controller/request_plugin.go:92
← previous
next →
4,301–4,400 of 15,409, ranked by callers