Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/BerriAI/litellm
/ functions
Functions
202,479 in github.com/BerriAI/litellm
⨍
Functions
202,479
◇
Types & classes
26,341
↳
Endpoints
5,595
↓ 9 callers
Function
_langfuse_key
A model registered for this run plus a key on a team whose Langfuse callback is `creds`.
tests/e2e/logging/test_otel_v2_langfuse_generation_output_e2e.py:103
↓ 9 callers
Function
_ledger
migration name -> (finished, rolled back) for the newest ledger row of each migration.
tests/integration/database/migrations/test_request_log_indexes.py:241
↓ 9 callers
Function
_legacy_operation_context
(ctx: ServerRequestContext, *, trace: bool)
litellm/proxy/mcp_server/server.py:917
↓ 9 callers
Function
_legacy_row
A row exactly as the pre-fix code would have written it: plain ``urlsafe_b64encode`` of the raw payload, no encryption.
tests/unit/proxy/mcp_server/test_db_credentials.py:71
↓ 9 callers
Method
_listenForAbort
(e)
litellm/proxy/_experimental/out/_next/static/chunks/2hk8n3azev--d.js:11
↓ 9 callers
Function
_live_logging_object
( start_time: datetime.datetime, end_time: datetime.datetime, metered_usage: RealtimeMeteredUsage
tests/unit/test_cost_calculator.py:10205
↓ 9 callers
Function
_live_scan_guardrail
( seen: Dict[str, Any], *, guardrail_name: str = "gr-post", buffer_until_moderated: bool | Non
tests/unit/proxy/utils/proxy_logging/test_guardrail_pipeline.py:3997
↓ 9 callers
Function
_llm
( cell_id: str, tier: Tier, subject_endpoint: LlmEndpoint = "chat_completions" )
tests/e2e_harness/coverage_registry/test_collector.py:33
↓ 9 callers
Function
_load
(name: str)
tests/unit/router_strategy/adaptive_router/test_signals.py:18
↓ 9 callers
Method
_load_credentials
( self, optional_params: dict, # mutable-ok: the implementation pops the aws_* keys out of th
litellm/llms/bedrock/embed/embedding.py:84
↓ 9 callers
Function
_locked_spend_logs
(database_url: str)
tests/integration/spend/test_daily_activity_key_metadata_query_timeout.py:368
↓ 9 callers
Function
_log_success
( limiter: PROXY_VirtualKeyModelMaxBudgetLimiter, event: dict[str, object], response_obj: object = None )
tests/unit/proxy/hooks/test_model_max_budget_limiter.py:94
↓ 9 callers
Function
_logged_kwargs
()
tests/unit/proxy/guardrails/guardrail_hooks/test_model_armor.py:4997
↓ 9 callers
Method
_logged_response
(request_data: dict[str, object])
tests/unit/integrations/test_custom_guardrail.py:3345
↓ 9 callers
Function
_logger
(client: FakeIngestClient, **params: object)
tests/unit/integrations/zerobus/test_zerobus_logger.py:41
↓ 9 callers
Method
_logging_obj
(self, call_type: str, litellm_metadata: dict | None = None)
tests/unit/litellm_core_utils/test_litellm_logging.py:8370
↓ 9 callers
Method
_login
(self, vault, base_url="https://test.example.com")
tests/unit/proxy/client/cli/test_auth_commands.py:1245
↓ 9 callers
Function
_make_app
()
tests/unit/proxy/management_endpoints/test_workflow_management_endpoints.py:115
↓ 9 callers
Function
_make_auth
( mcp_servers: Optional[List[str]] = None, mcp_tool_permissions: Optional[Dict[str, List[str]]] = None
tests/unit/proxy/mcp_server/test_mcp_toolset_scope.py:18
↓ 9 callers
Method
_make_auth
(self, org_id=None, team_id=None)
tests/unit/proxy/mcp_server/auth/test_user_api_key_auth_mcp.py:5469
↓ 9 callers
Function
_make_backend
()
tests/unit/llms/base_llm/files/test_azure_blob_storage_backend.py:44
↓ 9 callers
Function
_make_batch_db_record
Create a mock batch database record.
tests/unit/enterprise/proxy/test_file_deletion_blocking.py:45
↓ 9 callers
Method
_make_cache_key
Create cache key for session iteration counter. Uses Redis hash-tag pattern {session_iterations:<session_id>} so all keys fo
litellm/proxy/hooks/max_iterations_limiter.py:176
↓ 9 callers
Function
_make_capture_logger
(name: str)
tests/unit/test_logging.py:494
↓ 9 callers
Function
_make_chat_request_mock
()
tests/unit/proxy/test_litellm_pre_call_utils.py:7539
↓ 9 callers
Function
_make_ctx
(base_url)
tests/unit/proxy/client/cli/test_up_commands.py:239
↓ 9 callers
Function
_make_error_chunk
(error_type: str, code: str, message: str = "err")
tests/unit/responses/test_streaming_iterator_error_events.py:74
↓ 9 callers
Method
_make_filter
(self)
tests/unit/proxy/mcp_server/test_semantic_tool_filter.py:1403
↓ 9 callers
Function
_make_guardrail
(guardrail_id: str, name: str = "g")
tests/unit/proxy/guardrails/test_guardrail_registry.py:299
↓ 9 callers
Function
_make_guardrail
Build a guardrail; construction defaults still exercise the real HTTP client.
tests/unit/proxy/guardrails/guardrail_hooks/test_airia.py:24
↓ 9 callers
Function
_make_mock_agent
(max_budget_per_session: float)
tests/unit/proxy/hooks/test_max_budget_per_session_limiter.py:31
↓ 9 callers
Function
_make_mock_response
( json_data: dict, status_code: int = 200, request_url: str | None = None, headers: dict | Non
tests/unit/llms/tinyfish/search/test_tinyfish_search_transformation.py:38
↓ 9 callers
Function
_make_org
(organization_id="org-1", members=None, models=None)
tests/unit/proxy/test_team_org_move.py:29
↓ 9 callers
Function
_make_org_admin_user
(org_id: str)
tests/unit/proxy/auth/test_route_checks.py:3040
↓ 9 callers
Function
_make_request_mock
()
tests/unit/proxy/test_pricing_field_strip.py:30
↓ 9 callers
Function
_make_retrieve_response
(original_content: str, status: int = 200)
tests/unit/proxy/guardrails/guardrail_hooks/test_headroom.py:120
↓ 9 callers
Function
_make_router
(deployments)
tests/unit/integrations/SlackAlerting/test_model_deprecation_alert.py:30
↓ 9 callers
Function
_make_search_response
()
tests/unit/integrations/websearch_interception/test_websearch_native_blocks.py:43
↓ 9 callers
Method
_make_server
( self, server_id: str, server_name: str, alias=None, name=None, )
tests/unit/proxy/mcp_server/test_mcp_server_manager.py:10594
↓ 9 callers
Function
_make_sync_iterator
( *, sse_events: list[bytes], logging_obj: LiteLLMLoggingObj, trailing_error: Optional[Excepti
tests/unit/responses/test_streaming_iterator.py:110
↓ 9 callers
Function
_make_team
(team_id="team-1", member_ids=None, organization_id=None)
tests/unit/proxy/test_team_org_move.py:49
↓ 9 callers
Function
_make_team_scoped_router
Build a Router whose model_list looks like what the proxy creates for team-scoped BYOK DB models: the internal model_name is ``<public_na
tests/unit/proxy/auth/test_auth_checks_object_access_and_lookup.py:3318
↓ 9 callers
Function
_make_transform_request
(optional_params: dict, litellm_params: dict)
tests/unit/llms/anthropic/chat/test_anthropic_chat_transformation.py:7977
↓ 9 callers
Function
_make_unified_batch_id
Create a base64-encoded unified batch ID.
tests/unit/enterprise/proxy/test_file_deletion_blocking.py:31
↓ 9 callers
Function
_make_unified_vs_id
Build a valid base64-encoded unified vector-store ID.
tests/unit/llms/test_file_search_responses.py:34
↓ 9 callers
Function
_make_user_auth
(user_id: str = "user-abc")
tests/unit/proxy/management_endpoints/test_mcp_management_endpoints.py:5678
↓ 9 callers
Function
_make_window
()
tests/unit/integrations/focus/test_mavvrik_destination.py:21
↓ 9 callers
Function
_managed_file_row
( unified_file_id: str, stored_file_id: Optional[str] = None, created_by: str = "test-user", t
tests/unit/proxy/openai_files_endpoint/test_files_endpoint.py:4954
↓ 9 callers
Method
_map_tool_choice
( self, tool_choice: str | None, parallel_tool_use: bool | None, )
litellm/llms/anthropic/chat/transformation.py:1073
↓ 9 callers
Function
_mapped_tools
()
tests/integration/providers/test_openai_responses_tool_search_wire.py:94
↓ 9 callers
Function
_marked_posts
(wire: Wire)
tests/integration/providers/test_responses_bridge_message_cache_control_wire_chaos.py:209
↓ 9 callers
Function
_marker
()
tests/integration/routing/test_model_capability_flags.py:71
↓ 9 callers
Function
_matches
(row: Mapping[str, object], where: Mapping[str, object])
tests/unit/proxy/management_helpers/test_team_roster_sync.py:85
↓ 9 callers
Function
_mcp_kwargs
(mcp_tool_call_metadata=None, **overrides)
tests/unit/integrations/arize/test_arize_utils.py:1389
↓ 9 callers
Function
_mcp_payload
(**overrides)
tests/unit/integrations/otel/test_otel_v2_logger.py:648
↓ 9 callers
Function
_merged_ptu_model_info
The model_info a patch would store, which is the stored blob updated by the patch. A PTU invariant holds over the deployment as it will exist, no
litellm/proxy/management_endpoints/model_management_endpoints.py:1056
↓ 9 callers
Method
_message_index
(self)
litellm/responses/litellm_completion_transformation/streaming_iterator.py:318
↓ 9 callers
Function
_messages
(label: str = "shared")
tests/unit/llms/vertex_ai/context_caching/test_known_cached_contents.py:47
↓ 9 callers
Function
_metadata
(duration: object, channels: int = 1)
tests/unit/proxy/pass_through_endpoints/llm_provider_handlers/test_deepgram_listen_passthrough_logging_handler.py:35
↓ 9 callers
Function
_mock_openai_embedding_route
( respx_mock: respx.MockRouter, api_base: str = "https://api.openai.com/v1" )
tests/unit/test_openai_embedding_encoding_format_default.py:20
↓ 9 callers
Function
_mock_request
(method: str)
tests/unit/proxy/auth/test_route_checks.py:480
↓ 9 callers
Function
_mock_row
Build a row-like object with real attributes (no MagicMock) for _row_to_model.
tests/unit/proxy/db/test_tool_registry_writer.py:30
↓ 9 callers
Function
_mocked_openai_chat_response
(model: str)
tests/unit/test_main.py:1188
↓ 9 callers
Function
_model_group
(gateway: Gateway, model_group: str)
tests/integration/management/test_model_hub_custom_metadata.py:21
↓ 9 callers
Function
_model_info_of
(entry: Mapping[str, object])
litellm/router_rust/surface/registry.py:549
↓ 9 callers
Function
_model_names
(payload)
tests/unit/proxy/proxy_server/test_routes_model_info.py:2085
↓ 9 callers
Function
_models
(upstream: httpx.Client)
tests/integration/management/test_team_member_lifecycle.py:149
↓ 9 callers
Function
_names
(spans: tuple[Span, ...])
tests/integration/observability/test_otel_excluded_services_matrix.py:353
↓ 9 callers
Function
_names
(results: Sequence[ToolSearchResult] | EmbeddingFailed)
tests/unit/proxy/mcp_server/test_mcp_tool_search.py:215
↓ 9 callers
Function
_namespace_tool
()
tests/integration/providers/test_responses_bridge_tool_search_undeferred_wire.py:99
↓ 9 callers
Function
_non_admin_auth
()
tests/unit/proxy/management_endpoints/test_team_endpoints.py:12806
↓ 9 callers
Function
_normalize_cli_sso_user_code
(user_code: str)
litellm/proxy/management_endpoints/ui_sso.py:311
↓ 9 callers
Function
_oauth_cred
(access_token="at-live", refresh_token=None, expires_in_seconds=None)
tests/unit/proxy/mcp_server/test_db_credentials.py:1128
↓ 9 callers
Function
_objects
(value: JsonValue)
tests/integration/spend/test_spend_log_tool_payload_content.py:80
↓ 9 callers
Function
_only_received
(wire: Wire)
tests/integration/providers/test_bedrock_converse_missing_content_wire.py:230
↓ 9 callers
Function
_only_received
(wire: Wire)
tests/integration/providers/test_bedrock_kimi_k3_cache_point_wire.py:298
↓ 9 callers
Function
_only_request
(wire: Wire, provider: Provider, stream: bool, backend: str = _BACKEND)
tests/integration/providers/test_gemini_tool_result_part_reference_wire.py:556
↓ 9 callers
Function
_only_schema
(wire: Wire)
tests/integration/providers/test_bedrock_converse_lookaround_regex_wire.py:246
↓ 9 callers
Method
_open
(self, raw_chunks: list[bytes], headers: dict[str, str], chunk_size: int = 16)
tests/unit/llms/vertex_ai/files/test_vertex_ai_files_streaming.py:879
↓ 9 callers
Function
_openai_response
(content: str | None, tool_calls: list | None = None, **message_fields: object)
tests/unit/test_tool_loop.py:30
↓ 9 callers
Method
_operator_provider
(operator_exporter, dest_exporter, scope="full")
tests/unit/integrations/otel/test_otel_v2_destinations.py:2537
↓ 9 callers
Function
_org_admins
Answer the team handlers' org-admin lookup from ``(user_id, organization_id)`` pairs instead of prisma.
tests/unit/proxy/management_endpoints/test_team_endpoints.py:144
↓ 9 callers
Function
_output_text
(observation: LangfuseObservation)
tests/e2e/logging/test_otel_v2_langfuse_generation_output_e2e.py:126
↓ 9 callers
Function
_parse_data_url
Parse data URL (base64 image). Returns: Tuple of (content_bytes, content_type, extension) or None
litellm/llms/gigachat/file_handler.py:39
↓ 9 callers
Function
_parse_ocr_request
Parse an OCR request and apply the `x-req-format` header, if any.
litellm/proxy/ocr_endpoints/endpoints.py:165
↓ 9 callers
Method
_parse_ragflow_model
Parse RAGFlow model name format: ragflow/{endpoint_type}/{id}/{model_name} Args: model: Model name in format ragflow/cha
litellm/llms/ragflow/chat/transformation.py:31
↓ 9 callers
Function
_passing_bedrock_httpx_response
A successful ApplyGuardrail response tagged with `marker` so tests can verify which chunk produced which output/usage after merging.
tests/unit/proxy/guardrails/guardrail_hooks/test_bedrock_guardrails.py:3660
↓ 9 callers
Function
_patch_proxy_server_globals_for_mcp
Non-None mocks so the helper's None-guard doesn't short-circuit.
tests/unit/proxy/mcp_server/auth/test_user_api_key_auth_mcp.py:5738
↓ 9 callers
Function
_patched_init_cache
Context manager that: 1. Replaces the module-level globals with fresh DualCache instances. 2. Patches ``litellm.Cache`` (locally imported
tests/unit/proxy/test_redis_auth_cache_flag.py:63
↓ 9 callers
Function
_patched_messages
()
tests/unit/litellm_core_utils/test_chat_completion_agentic_loop.py:281
↓ 9 callers
Function
_path
(endpoint: Endpoint)
tests/integration/providers/test_bedrock_converse_lookaround_regex_wire.py:171
↓ 9 callers
Function
_payload
(response: httpx.Response)
tests/integration/providers/test_bedrock_runtime_chat_completions_sad_wire.py:72
↓ 9 callers
Function
_payload
(**overrides: object)
tests/unit/proxy/db/test_autorouter_session_rollup.py:32
↓ 9 callers
Function
_payload
()
tests/unit/integrations/zerobus/test_zerobus_row.py:6
↓ 9 callers
Function
_payload
()
tests/unit/integrations/otel/test_otel_v2_baggage.py:28
↓ 9 callers
Function
_pdf_chat_request
()
tests/unit/proxy/guardrails/guardrail_hooks/test_bedrock_guardrails.py:6232
↓ 9 callers
Function
_peer
(frames: tuple[bytes, ...])
tests/integration/streaming/test_openai_like_stream_usage_wire.py:109
↓ 9 callers
Function
_peer
(expected_path: str, body: Mapping[str, JsonValue])
tests/integration/sdk/test_openai_sdk_client_sessions_wire.py:72
↓ 9 callers
Function
_peer
(replies: Mapping[str, Reply])
tests/integration/sdk/test_router_unsupported_params_fallback_wire.py:66
↓ 9 callers
Method
_perm
(self, *, servers=None, access_groups=None, tool_permissions=None)
tests/unit/proxy/mcp_server/auth/test_user_api_key_auth_mcp.py:10636
← previous
next →
7,601–7,700 of 202,479, ranked by callers