MCPcopy Create free account

hub / github.com/BerriAI/litellm / functions

Functions202,479 in github.com/BerriAI/litellm

↓ 8 callersFunctionassert_counted_with_deepseek
(counted: int, expected: Callable[[Callable[[str], int]], int])
tests/integration/_support/deepseek_tokens.py:31
↓ 8 callersFunctionassert_each_value_arrives_once
( events: Sequence[Mapping[str, JsonValue]], expected: Sequence[Mapping[str, JsonValue]] )
tests/integration/streaming/faked_responses_case.py:309
↓ 8 callersFunctionassert_gone
(candidate: Gateway, team: str, users: Sequence[str], key: str)
tests/integration/_support/scim.py:170
↓ 8 callersFunctionassert_hop_stripped
( record: HopRecord, expected_order_one: list[JsonValue], expected_order_two: list[JsonValue] )
tests/integration/routing/test_fallback_hop_foreign_encrypted_reasoning.py:637
↓ 8 callersFunctionassert_identity
(attrs: Mapping[str, object], expected: Mapping[str, object])
tests/integration/observability/_langfuse_otel_metadata_support.py:353
↓ 8 callersFunctionassert_marker_seen
Sensitivity control: the marker must be reported by each sweep at the expected location.
tests/integration/security/_sweeps.py:618
↓ 8 callersFunctionassert_model_parity
(baseline: BaseModel, candidate: BaseModel)
tests/rust-python-harness/shared/parity/compare.py:42
↓ 8 callersFunctionassert_no_provider_call
(gateway: Gateway, *identities: str)
tests/integration/compatibility/_status_code_audit.py:166
↓ 8 callersMethodassert_no_writes
(self)
tests/unit/proxy/management_endpoints/test_mcp_management_endpoints.py:9178
↓ 8 callersFunctionassert_parity
(baseline: Execution, candidate: Execution, baseline_user_agent: str)
tests/rust-python-harness/shared/parity/compare.py:77
↓ 8 callersFunctionassert_same_origin
Verify ``candidate_url`` shares scheme, host, and port with ``expected_url``. Use when an upstream API returns a URL meant for follow-up requests
litellm/litellm_core_utils/url_utils.py:406
↓ 8 callersFunctionassert_serving
(gateway: Gateway, model: str, key: str, status: int, error_type: str = "auth_error")
tests/integration/authorization/test_warmed_policy.py:295
↓ 8 callersFunctionassert_user_can_access_vector_store_id
Resolve a managed vector store id and enforce ownership if it exists. Unknown ids are treated as provider-native ids and are not rejected he
litellm/proxy/vector_store_endpoints/utils.py:336
↓ 8 callersMethodassign_unique_short_prefix
Resolve and cache a collision-free short tool prefix on ``server``. Called at registration time for every MCP server entering the reg
litellm/proxy/mcp_server/mcp_server_manager.py:5711
↓ 8 callersFunctionassistant_text
An ASSISTANT text block (SPECULATIVE stage) closed with `stop_reason`.
tests/integration/_support/bedrock_realtime_peer.py:129
↓ 8 callersMethodassume_role
(self, *, RoleArn: str, RoleSessionName: str)
tests/unit/proxy/auth/test_rds_iam_token.py:91
↓ 8 callersMethodasync_anthropic_sse_wrapper
Async version of anthropic_sse_wrapper. Convert AnthropicStreamWrapper dict chunks to Server-Sent Events format.
litellm/llms/anthropic/messages/adapters/streaming_iterator.py:1389
↓ 8 callersMethodasync_delete_cache
(self, key)
tests/unit/proxy/auth/test_login_utils.py:1415
↓ 8 callersMethodasync_delete_secret
Delete a secret from the in-memory store.
tests/unit/secret_managers/test_custom_secret_manager.py:72
↓ 8 callersMethodasync_health_check
(self)
litellm/integrations/galileo.py:141
↓ 8 callersMethodasync_health_check
Health check for SQS by sending a small test message to the configured queue.
litellm/integrations/sqs.py:317
↓ 8 callersMethodasync_increment_cache
( self, key: str, value: float, parent_otel_span: Span | None = None,
litellm/proxy/common_utils/user_api_key_cache.py:465
↓ 8 callersMethodasync_key_updated_hook
Post /key/update processing hook Handles the following: - Renaming the key's secret in the secret manager when the alias cha
litellm/proxy/hooks/key_management_event_hooks.py:105
↓ 8 callersMethodasync_log_batch_line_items
(self, payload: StandardBatchLineItemsPayload)
tests/unit/batches/test_batch_line_items.py:109
↓ 8 callersMethodasync_moderation_hook
During-call hook to sanitize user prompts in parallel with LLM call.
litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.py:806
↓ 8 callersFunctionasync_openai_client
(candidate: Gateway, key: str)
tests/integration/authorization/_hidden_alias_budget.py:308
↓ 8 callersFunctionasync_post_call_failure_deployment_hook
Notify CustomLogger callbacks that a deployment attempt failed. Unlike its pre-call/post-success siblings, this wraps each callback call
litellm/utils.py:1901
↓ 8 callersMethodasync_post_call_streaming_hook
Allow user to modify outgoing streaming data -> per chunk Covers: 1. /chat/completions
litellm/proxy/utils.py:4764
↓ 8 callersMethodasync_post_call_streaming_iterator_hook
Process streaming response chunks and check for blocked content. For BLOCK action: Raises HTTPException immediately when blocked con
litellm/proxy/guardrails/guardrail_hooks/litellm_content_filter/content_filter.py:2239
↓ 8 callersMethodasync_post_call_streaming_iterator_hook
(self, **kwargs)
tests/unit/proxy/utils/proxy_logging/test_streaming_hooks.py:445
↓ 8 callersFunctionasync_post_call_success_deployment_hook
Allow modifying / reviewing the response just after it's received from the deployment.
litellm/utils.py:1865
↓ 8 callersMethodasync_post_mcp_tool_call_hook
(self, kwargs, response_obj, start_time, end_time)
tests/unit/litellm_core_utils/test_litellm_logging.py:205
↓ 8 callersMethodasync_pre_call_deployment_hook
( self, kwargs: dict[str, Any], call_type: CallTypes | None )
litellm/integrations/compression_interception/handler.py:137
↓ 8 callersMethodasync_pre_call_hook
Pre-call hook to scan user prompts before sending to LLM. Raises HTTPException if content should be blocked.
litellm/proxy/guardrails/guardrail_hooks/azure/text_moderation.py:222
↓ 8 callersMethodasync_pre_call_hook
(self, data: dict, **kwargs)
tests/unit/integrations/test_custom_guardrail.py:1538
↓ 8 callersMethodasync_realtime
Establish bidirectional streaming connection with Bedrock Nova Sonic. Args: model: Model ID (e.g., 'amazon.nova-sonic-v1
litellm/llms/bedrock/realtime/handler.py:562
↓ 8 callersMethodasync_realtime
( self, model: str, websocket: _ProxyClientWebSocket, logging_obj: LiteLLMLogg
litellm/llms/azure/realtime/handler.py:200
↓ 8 callersMethodasync_responses_websocket
Handles Responses API WebSocket mode. For providers with native websocket support (OpenAI, Azure): - Opens a persistent WebS
litellm/llms/custom_httpx/llm_http_handler.py:7231
↓ 8 callersMethodasync_send_batch
(self)
litellm/integrations/generic_api/generic_api_callback.py:357
↓ 8 callersMethodasync_set_cache
(self, key: str, value: str, ttl: float | None = None)
litellm/proxy/mcp_server/outbound_credentials/dual_cache_token_backend.py:31
↓ 8 callersMethodasync_set_cache
(self, key, value, **kwargs)
tests/unit/test_scheduler.py:53
↓ 8 callersMethodasync_should_run_agentic_loop
(self, *args: object, **kwargs: object)
tests/unit/rust_bridge/test_detectors.py:444
↓ 8 callersMethodauth_flow
(self, request)
tests/unit/proxy/mcp_server/test_mcp_debug.py:355
↓ 8 callersFunctionauthenticated
(call: MessagesCall, api_base: String)
litellm-rust/crates/inference-messages/tests/messages/host.rs:254
↓ 8 callersFunctionauthorize_member_auto_router_dependencies
( *, config: RequestComplexityRouterConfig, default_model: str | None, user_api_key_dict: User
litellm/proxy/management_helpers/auto_router_permissions.py:187
↓ 8 callersMethodavector_store_create
(self, model: str | None, **kwargs: object)
litellm/router_rust/invoke/endpoints.py:2171
↓ 8 callersMethodawait_tool
Poll tools/list until `server_id` serves a tool matching `needle`, and return its fully-qualified name. Fails at poll_timeout. /v1/mc
tests/e2e/mcp/mcp_client.py:338
↓ 8 callersMethodbatch
(&self)
litellm-rust/crates/redis-client/src/client.rs:174
↓ 8 callersFunctionbatch_model_name
(base: str)
tests/e2e/batches/capabilities.py:20
↓ 8 callersFunctionbedrock_model_accepts_cache_points
Whether Converse ``cachePoint`` blocks may be sent to this model. OpenAI-family models only support implicit caching and never accept explic
litellm/llms/bedrock/common_utils.py:1631
↓ 8 callersFunctionbedrock_model_id_and_region
Model-id and region parsing shared by every Bedrock route.
litellm-rust/crates/auth-aws/src/aws.rs:663
↓ 8 callersFunctionbedrock_proxy_route
This is the v1 passthrough for Bedrock. V2 is handled by the `/bedrock/v2` endpoint. [Docs](https://docs.litellm.ai/docs/pass_through/bed
litellm/proxy/pass_through_endpoints/llm_passthrough_endpoints.py:1606
↓ 8 callersFunctionbill_first_round_on_failure
( dispatch: Awaitable[_DispatchResult], *, logging_obj: object, response: object, stream: bool )
litellm/litellm_core_utils/chat_completion_agentic_loop.py:55
↓ 8 callersFunctionbilled_for_every_round
The final round's response carrying the usage and cost of both rounds, so the one logged row bills the request. Costs are summed per round rather
litellm/responses/mcp/round_billing.py:143
↓ 8 callersFunctionbody
(response: httpx.Response)
tests/integration/_support/scim.py:99
↓ 8 callersFunctionbuildUpdatedComplexityRouterConfig
( storedConfig: unknown, value: ComplexityRouterConfigValue, customTechnicalKeywords?: string[], keywo
ui/litellm-dashboard/src/components/edit_auto_router/edit_auto_router_modal.tsx:194
↓ 8 callersMethodbuild_debug_headers
Build masked debug response headers. Parameters ---------- inbound_headers : dict Raw headers received f
litellm/proxy/mcp_server/mcp_debug.py:263
↓ 8 callersFunctionbuild_discovery
( *, configured: tuple[str, ...], revision: str, transport: MCPTransport, authorized_opera
litellm/proxy/mcp_server/capabilities.py:98
↓ 8 callersFunctionbuild_mantle_native_messages_url
(api_base: str | None, litellm_params: Mapping[str, object])
litellm/llms/bedrock_mantle/messages/transformation.py:27
↓ 8 callersFunctionbuild_model_usage_transaction
(payload: SpendLogsPayload)
litellm/proxy/db/model_usage_rollup.py:98
↓ 8 callersFunctionbuild_synthetic_mcp_request
A synthetic FastAPI ``Request`` carrying the MCP connection's HTTP headers. The MCP protocol transports do not hand a per-call ``Request`` to the
litellm/proxy/mcp_server/utils.py:1046
↓ 8 callersFunctionbuiltin
(key: str)
tests/unit/test_router/core/test_gaps_l8400_pricing.py:28
↓ 8 callersFunctionbyok_credential_cache_key
(user_id: str, server_id: str)
litellm/proxy/mcp_server/byok_credential_cache.py:23
↓ 8 callersFunctionc
(t)
litellm/proxy/_experimental/out/_next/static/chunks/0tx19jeq-wskb.js:1
↓ 8 callersFunctionc
litellm/proxy/_experimental/out/_next/static/chunks/1f2vcab0yti03.js:53
↓ 8 callersFunctioncache_scope
( caller_key_hash: str, deployment_id: str, provider_key: str, model: str, anthropic_versi
litellm/llms/anthropic/prompt_cache_prediction.py:468
↓ 8 callersFunctioncalculate_cache_writing_cost
Bill cache writes per lifetime: Anthropic reports 5m and 1h counts, OpenAI reports 30m and 12h counts. Writes no lifetime count covers, such
litellm/litellm_core_utils/llm_cost_calc/utils.py:1014
↓ 8 callersFunctioncall
(s)
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 8 callersFunctioncall
(account: str | None)
tests/unit/test_router/test_router.py:19985
↓ 8 callersFunctioncallback
()
tests/unit/litellm_core_utils/test_logging_worker.py:27
↓ 8 callersFunctioncaller_model_verdict
``denied`` when an allowlist or a per-model budget refuses ``model`` for the caller, which only an admin or the next budget window changes; ``deni
litellm/llms/anthropic/messages/caller_model_checks.py:89
↓ 8 callersFunctioncan_project_access_model
Returns True if the project can access a specific model. Raises ProxyException if access is denied.
litellm/proxy/auth/auth_checks.py:5885
↓ 8 callersMethodcan_user_make_model_call
( model_params: Deployment, user_api_key_dict: UserAPIKeyAuth, prisma_client: PrismaCl
litellm/proxy/management_endpoints/model_management_endpoints.py:2833
↓ 8 callersMethodcan_user_set_aws_session_tags
( litellm_params: GenericLiteLLMParams | None, user_api_key_dict: UserAPIKeyAuth, exis
litellm/proxy/management_endpoints/model_management_endpoints.py:2710
↓ 8 callersFunctioncapture_baseline_parameters
( kwargs: Mapping[str, object], *, include_extra_body: bool = True )
litellm/router_strategy/auto_router/baseline_request.py:102
↓ 8 callersFunctioncarry_forward_resolved_oauth_endpoints
Keep the last known good OAuth endpoints when a rebuild's re-discovery comes back empty. A rebuild wholesale-replaces the registry entry, so with
litellm/proxy/mcp_server/mcp_server_manager.py:868
↓ 8 callersFunctionchat_completion_tool_call_from_dict
( tool_call: Mapping[str, Any], )
litellm/types/utils.py:1480
↓ 8 callersFunctionchat_messages
(marker: str)
tests/integration/routing/_reasoning_effort_levels_support.py:261
↓ 8 callersFunctionchat_response
(content: str)
tests/unit/proxy/batches_endpoints/test_litellm_executed_batches.py:78
↓ 8 callersFunctionchat_statuses
( candidate: Gateway, model: str, key: str, count: int, extra: Mapping[str, JsonValue] = NO_EXTRA )
tests/integration/authorization/_hidden_alias_budget.py:167
↓ 8 callersFunctioncheck_allowed_extension
( filename: str | None, allowed_extensions: tuple[str, ...] | None, )
litellm/proxy/openai_files_endpoints/general_upload_validation.py:99
↓ 8 callersMethodcheck_available_usage
For a given model, get its available tpm Params: - model: str, the name of the model in the router model_list - prio
litellm/proxy/hooks/dynamic_rate_limiter.py:90
↓ 8 callersFunctioncheck_upload_file_size
( file_source: bytes | BinaryIO, max_file_size_mb: int | None, )
litellm/proxy/openai_files_endpoints/general_upload_validation.py:78
↓ 8 callersFunctionchoices
(response: httpx.Response)
tests/integration/caching/response_cache_case.py:375
↓ 8 callersFunctionci
(t,e,r)
litellm/proxy/_experimental/out/_next/static/chunks/0cz1d0mv5g_q7.js:1
↓ 8 callersFunctionclean_endpoint_data
Keep only the explicitly approved, JSON-safe diagnostic fields for display to users.
litellm/proxy/health_check.py:216
↓ 8 callersMethodcleanup_expired_keys
Main entry point for deleting expired UI session keys. Uses PodLockManager to ensure only one pod runs cleanup in multi-pod deploymen
litellm/proxy/common_utils/expired_ui_session_key_cleanup_manager.py:50
↓ 8 callersFunctioncli
(port: u16, args: &[&str])
litellm-rust/crates/redis-testing/src/exec.rs:25
↓ 8 callersFunctionclickTeamId
(page: PlaywrightPage, teamId: string)
tests/e2e/ui/helpers/navigation.ts:95
↓ 8 callersMethodclose
(self)
tests/unit/llms/bedrock/realtime/test_bedrock_realtime_handler.py:141
↓ 8 callersFunctionclose_after_upstream_handshake_refusal
(websocket: _ClientWebSocket, status_code: int)
litellm/litellm_core_utils/realtime_errors.py:62
↓ 8 callersMethodcoalesced
Reseed a cold spend counter from the DB and warm the cache, coalesced via a per-counter lock so concurrent callers (read path
litellm/proxy/db/spend_counter_reseed.py:218
↓ 8 callersFunctioncoerce_top_k
(value: Any, default: int = 5)
litellm/proxy/mcp_server/tool_search.py:134
↓ 8 callersMethodcollect_until
( self, stop_type: str, *, timeout: float )
tests/e2e/llm_translation/realtime/realtime_client.py:400
↓ 8 callersFunctioncollected_item
(request: pytest.FixtureRequest, name: str)
tests/code_coverage_tests/test_e2e_metadata.py:64
↓ 8 callersFunctioncommit_staged_json
Move a staged file into place, replacing whatever is there in one step
litellm/litellm_core_utils/private_json.py:54
↓ 8 callersMethodcompletion
(self, *args: object, **kwargs: object)
tests/unit/responses/litellm_completion_transformation/test_anthropic_responses_bridge.py:1042
↓ 8 callersFunctioncompress
Compress a list of messages by replacing low-relevance content with stubs. Messages below ``compression_trigger`` tokens pass through unchan
litellm/compression/compress.py:354
↓ 8 callersFunctionconfig_file
(directory: Path, upstream: str, protocol: str | None = None)
tests/integration/mcp/test_pagination.py:34
↓ 8 callersMethodconfigure
( &self, version: &Version, _settings: &Settings, home: &Path, )
litellm-rust/crates/testkit/tests/session.rs:13
← previousnext →9,101–9,200 of 202,479, ranked by callers