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
↓ 4 callers
Function
_key
(client: McpClient, resources: ResourceManager, *, mcp_servers: list[str] | None)
tests/e2e/mcp/test_mcp_key_access_e2e.py:29
↓ 4 callers
Method
_key
(which: CountKey, model_name: str, group: str)
litellm/router_rust/invoke/endpoints.py:789
↓ 4 callers
Method
_key_granting
(agent_ids: list[str], agent_id: str | None)
tests/unit/proxy/agent_endpoints/auth/test_agent_permission_handler.py:322
↓ 4 callers
Function
_key_hash
(key: str)
tests/integration/routing/test_responses_websocket_turn_admission.py:91
↓ 4 callers
Function
_key_info_everywhere
( client: ManagementClient, key: str, settled: Callable[[KeyInfo], bool] )
tests/e2e/management/test_key_lifecycle_e2e.py:127
↓ 4 callers
Method
_key_or_team_declares_toolsets
Whether the key or its team GRANTS any toolset, resolvable or not. A declared toolset is a lower-level restriction even when it resolves to no
litellm/proxy/mcp_server/auth/user_api_key_auth_mcp.py:3219
↓ 4 callers
Function
_key_row
(metadata: Mapping[str, object])
tests/unit/proxy/common_utils/test_check_responses_cost.py:2076
↓ 4 callers
Function
_key_spend
(parity_database: str)
tests/integration/database/test_spendlogs_ledger_parity.py:1295
↓ 4 callers
Function
_key_spend_select
()
litellm/repositories/daily_activity_sql.py:294
↓ 4 callers
Function
_key_state_rows
(key: str)
tests/integration/management/test_project_lifecycle.py:81
↓ 4 callers
Function
_keyless_rag_query
( general_settings: Mapping[str, object], user_vector_stores: list[str] | None, team_vector_stores
tests/unit/proxy/auth/test_auth_checks_object_access_and_lookup.py:2165
↓ 4 callers
Method
_keys
(self)
litellm/litellm_core_utils/hidden_params.py:50
↓ 4 callers
Method
_keysets
Attribute-key sets, one per recorded data point of `metric_name`.
tests/unit/integrations/test_opentelemetry.py:6414
↓ 4 callers
Method
_keyword_matches
r""" Check if a keyword matches in text. Single-word keywords use regex word boundaries to avoid false positives, e.g. "api"
litellm/router_strategy/complexity_router/complexity_router.py:1740
↓ 4 callers
Method
_keyword_to_regex_pattern
Convert a keyword into a safe regex pattern. Escape all regex metacharacters to prevent malformed patterns from user/templat
litellm/proxy/guardrails/guardrail_hooks/litellm_content_filter/content_filter.py:1612
↓ 4 callers
Function
_kwargs_with_guardrail
Build the kwargs / model_call_details shape that the OTEL integration consumes. ``litellm_params.metadata`` is the SAME dict that the proxy's
tests/unit/integrations/test_otel_guardrail_violation_spans.py:120
↓ 4 callers
Function
_kwargs_with_v3_rate_limit_headers
(additional_headers: dict)
tests/unit/integrations/test_prometheus_rate_limit_labels.py:346
↓ 4 callers
Function
_landed
(rig: Rig, expected: Mapping[str, str])
tests/integration/observability/test_otel_conversation_id.py:676
↓ 4 callers
Function
_lazy_loaded
(app: "FastAPI")
litellm/proxy/_lazy_features.py:506
↓ 4 callers
Function
_leaf_instance
(leaf: type, sample: Mapping[str, object])
tests/unit/types/test_litellm_params.py:619
↓ 4 callers
Function
_leave_an_invalid_index
(database_url: str, name: str, table: str, column: str)
tests/integration/database/migrations/test_request_log_indexes.py:426
↓ 4 callers
Function
_legacy_route_request
(path: str, query_params: Mapping[str, str])
tests/unit/proxy/auth/test_route_checks.py:5016
↓ 4 callers
Function
_legacy_spend_queue_proxy_with_one_seeded_row
( gateway: Gateway, tmp_path: Path, pool_limit: int, cancel_timeout_seconds: int = 5, sett
tests/integration/spend/test_shutdown_flush.py:415
↓ 4 callers
Function
_legacy_stream_chunk
( model: str, *, content: str | None = None, tool_calls: tuple[ChatCompletionDeltaToolCall, ..
tests/unit/litellm_core_utils/test_streaming_chunk_builder_utils.py:2040
↓ 4 callers
Function
_lifecycle_round
One upstream Responses round as a provider streams it: its own id, indexes from 0, numbering from 0.
tests/unit/responses/mcp/test_mcp_streaming_iterator.py:454
↓ 4 callers
Method
_limit_outbound_concurrency
(self, mcp_server: MCPServer)
litellm/proxy/mcp_server/mcp_server_manager.py:6417
↓ 4 callers
Function
_limited_key
( client: QuotaClient, resources: ResourceManager, *, rpm_limit: int | None = None, tpm_li
tests/e2e/quota_management/ratelimit/test_rate_limit_e2e.py:128
↓ 4 callers
Function
_limiter
(fakes: FakeRateLimits)
tests/unit/caching/test_request_redis_batch_post_call.py:101
↓ 4 callers
Function
_limits_sent
(body: Mapping[str, JsonValue])
tests/integration/providers/test_gemini_default_output_budget_wire.py:72
↓ 4 callers
Function
_line
(event: Mapping[str, object])
tests/e2e_harness/codex/test_codex_run.py:31
↓ 4 callers
Method
_link
(self, item: _Link)
litellm/llms/vertex_ai/audio_transcription/realtime_backend.py:340
↓ 4 callers
Function
_lint_section
(config_name: str)
tests/unit/test_ruff_strict_gate.py:52
↓ 4 callers
Function
_list_hashes
(gateway_client, caller_cleartext: str, query: str)
tests/integration/management/test_key_list.py:74
↓ 4 callers
Function
_list_keys_capture_helper_kwargs
(user_api_key_dict, **list_kwargs)
tests/unit/proxy/management_endpoints/test_key_management_endpoints.py:17763
↓ 4 callers
Function
_list_mcp_tools
List all available MCP tools. Args: user_api_key_auth: User authentication info for access control mcp_auth_header: Optional
litellm/proxy/mcp_server/operations.py:1698
↓ 4 callers
Function
_list_models
(monkeypatch: pytest.MonkeyPatch, owner: LiteLLM_UserTable, token: UserAPIKeyAuth)
tests/unit/proxy/auth/test_personal_key_team_model_access.py:261
↓ 4 callers
Method
_list_partitions
( self, prisma_client: "PrismaClient", timeout_ms: int )
litellm/proxy/db/db_transaction_queue/spend_logs_partition_manager.py:245
↓ 4 callers
Method
_list_response
(self, purpose: str | None, listing: bytes | None = None, status_code: int = 200)
tests/unit/llms/bedrock/files/test_bedrock_files_transformation.py:3669
↓ 4 callers
Function
_list_system
(text: str)
tests/integration/providers/test_ollama_prompt_tools_wire.py:1418
↓ 4 callers
Function
_list_tools_with_listing
( _mcp_request_ctx: Callable[..., ServerRequestContext], listing: AggregateToolListing, params: Pa
tests/unit/proxy/mcp_server/test_mcp_server_tool_calls_and_headers.py:10539
↓ 4 callers
Function
_listed
()
tests/integration/database/test_chunked_in_lists.py:92
↓ 4 callers
Function
_lit8679_priced_logging_obj
(deployment_id: str, litellm_call_id: str)
tests/unit/litellm_core_utils/test_litellm_logging.py:11747
↓ 4 callers
Function
_litellm_key_from_request
Return the LiteLLM API key presented on the request, or ``None``. Accepts the key from ``x-litellm-api-key`` (what MCP clients such as Claude Des
litellm/proxy/mcp_server/bridge_token_flow.py:36
↓ 4 callers
Method
_live
(self, key: str)
tests/unit/proxy/hooks/test_max_budget_per_session_limiter.py:283
↓ 4 callers
Function
_live_router_and_db
Drive the endpoints against a real ProxyConfig so the router refresh actually runs.
tests/unit/proxy/management_endpoints/search_endpoints/test_search_tool_management.py:988
↓ 4 callers
Function
_live_token
(hashed: str)
tests/integration/management/test_team_delete_large_membership.py:116
↓ 4 callers
Function
_llama_3
(scenario: Scenario, api_base: str)
tests/integration/providers/test_huggingface_tokenizer_downloads_wire.py:62
↓ 4 callers
Function
_llm_body
(route: str, model: str)
tests/integration/authorization/test_rag_team_provider_credentials.py:1336
↓ 4 callers
Function
_llm_spans_through_markers
(destination: Wire, markers: tuple[str, ...])
tests/integration/observability/_openinference_support.py:649
↓ 4 callers
Method
_load_alerting_settings
Initialize alerting settings
litellm/proxy/proxy_server.py:7744
↓ 4 callers
Function
_load_instance_from_remote_storage
Load custom logger instance from S3 or GCS URL. Expected format: - s3://bucket-name/path/to/module.instance_name - gcs://bucket-name
litellm/proxy/types_utils/utils.py:75
↓ 4 callers
Function
_load_oci_config
Load OCI config from the profile named by ``OCI_CONFIG_PROFILE`` env var, falling back to ``[DEFAULT]``. Lets CI/local runs target a specific prof
tests/integration/test_oci_integration.py:41
↓ 4 callers
Function
_load_report
(repository: ConfigRepository, settings: ROISettings)
litellm/proxy/management_endpoints/roi_calculator_endpoints.py:188
↓ 4 callers
Method
_load_requirements
Load pinned requirements from a file or from the repo defaults.
tests/code_coverage_tests/check_licenses.py:357
↓ 4 callers
Function
_load_root_cost_map
()
tests/unit/litellm_core_utils/test_get_model_cost_map.py:36
↓ 4 callers
Method
_load_yaml_file
Load and parse a YAML file
litellm/proxy/proxy_server.py:6013
↓ 4 callers
Function
_local_count
(gateway: Gateway, model: str)
tests/integration/providers/test_huggingface_tokenizer_downloads_wire.py:66
↓ 4 callers
Method
_locate_message_texts_slice
Map one message's text segments to their (offset, length) slice in the flat `texts` list built by the guardrail translation handler.
litellm/proxy/guardrails/guardrail_hooks/bedrock_guardrails.py:648
↓ 4 callers
Function
_lock_timeout_error
()
tests/unit/proxy/db/test_db_spend_update_writer.py:557
↓ 4 callers
Function
_log_after
(owned: OwnedProxy, offset: int)
tests/integration/authorization/test_websocket_rejection_logging.py:100
↓ 4 callers
Method
_log_async_event
(self, kwargs, response_obj=None, start_time=0.0, end_time=0.0)
litellm/integrations/posthog.py:146
↓ 4 callers
Method
_log_json_data_on_gcs
Helper function to make POST request to GCS Bucket in the specified bucket.
litellm/integrations/gcs_bucket/gcs_bucket_base.py:264
↓ 4 callers
Method
_log_migration_lock_holders
Best-effort log of the sessions holding locks on the tables a timed-out migration touches.
litellm-proxy-extras/litellm_proxy_extras/utils.py:1283
↓ 4 callers
Function
_log_refused_pick
A refused pick is logged to the request's logging object (`_async_get_available_deployment`).
litellm/router_rust/core.py:4251
↓ 4 callers
Function
_log_stream
(endpoint: str, sse: bytes, request_data: dict | None = None)
tests/unit/llms/vllm/passthrough/test_vllm_passthrough_transformation.py:80
↓ 4 callers
Method
_log_stream_failure_and_raise
(self, e: Exception)
litellm/litellm_core_utils/streaming_handler.py:2734
↓ 4 callers
Function
_logged_call
(text: str = "Hello, how are you?")
tests/unit/proxy/guardrails/guardrail_hooks/akto/test_akto.py:1895
↓ 4 callers
Method
_logged_call
(**overrides)
tests/unit/proxy/guardrails/guardrail_hooks/test_singulr.py:943
↓ 4 callers
Function
_logged_response
(text: str = "Fine, thanks")
tests/unit/proxy/guardrails/guardrail_hooks/akto/test_akto.py:1905
↓ 4 callers
Function
_logging_obj
()
tests/unit/proxy/pass_through_endpoints/test_streaming_handler.py:82
↓ 4 callers
Function
_logging_obj
()
tests/unit/llms/vertex_ai/files/test_vertex_ai_files_streaming.py:467
↓ 4 callers
Function
_logging_obj
(model: str, call_type: str = "acompletion", logged: bool = False)
tests/unit/test_router/core/streaming_helpers.py:56
↓ 4 callers
Function
_login_id
(device_code: str)
tests/unit/proxy/anthropic_endpoints/test_gateway_endpoints.py:272
↓ 4 callers
Function
_lookup
(settings: Mapping[str, JsonValue], path: str)
litellm/proxy/client/cli/commands/claude_settings.py:436
↓ 4 callers
Function
_lookup_model_info_or_none
(model: str, custom_llm_provider: str | None)
litellm/cost_calculator.py:2954
↓ 4 callers
Function
_lookup_tool
(result: str = "found")
tests/integration/mcp/test_mcp_accounting_guardrails.py:375
↓ 4 callers
Function
_lookups
(seen: SimpleQueue[tuple[int, str]])
tests/integration/spend/test_daily_activity_key_metadata_query_timeout.py:400
↓ 4 callers
Function
_low_entropy_text
(length: int)
tests/unit/proxy/middleware/test_request_body_decompression_middleware.py:79
↓ 4 callers
Function
_m2m_server
(**overrides)
tests/unit/proxy/mcp_server/test_oauth2_token_cache.py:445
↓ 4 callers
Function
_make_agent
( agent_id, agent_name, static_headers=None, extra_headers=None, url="http://0.0.0.0:9999"
tests/unit/proxy/agent_endpoints/test_agent_header_isolation.py:25
↓ 4 callers
Method
_make_agent
(self, agent_id: str, url: str | None = None)
tests/unit/proxy/agent_endpoints/test_endpoints.py:944
↓ 4 callers
Function
_make_agent_record
(agent_id: str, agent_name: str)
tests/unit/proxy/management_endpoints/test_access_group_endpoints.py:72
↓ 4 callers
Function
_make_ambiguity_prisma
Mock prisma client whose MCP server table holds _SHARED_ALIAS_DB_SERVERS and whose object permission row (if any) stores the given mcp_tool_permis
tests/unit/proxy/management_helpers/test_object_permission_utils.py:1542
↓ 4 callers
Function
_make_arize_logger
Create an ``arize`` callback backed by an in-memory exporter. ArizeLogger._init_tracing creates its own TracerProvider, so we pass the export
tests/unit/integrations/arize/test_arize_otel_coexistence.py:53
↓ 4 callers
Function
_make_batch_response
Create a mock LiteLLMBatch response from a provider.
tests/unit/proxy/test_batch_x_litellm_model_encoding.py:41
↓ 4 callers
Function
_make_chunk
(content: Optional[str])
tests/unit/litellm_core_utils/test_streaming_handler.py:3585
↓ 4 callers
Function
_make_chunk
Create a minimal streaming chunk with the given delta and finish_reason.
tests/unit/llms/anthropic/messages/adapters/test_streaming_iterator_tool_args.py:33
↓ 4 callers
Function
_make_compact_handler_call
Drive (async_)compact_response_api_handler with a fully mocked provider config + client, returning the kwargs the client.post was called with.
tests/unit/llms/custom_httpx/test_llm_http_handler.py:2380
↓ 4 callers
Method
_make_config
(self)
tests/unit/llms/oci/chat/test_oci_chat_transformation.py:956
↓ 4 callers
Function
_make_db_mcp_server
(server_id: str, updated_at: datetime)
tests/unit/proxy/mcp_server/test_mcp_server_tool_calls_and_headers.py:5571
↓ 4 callers
Function
_make_db_model
Helper to create a mock DB model record.
tests/unit/proxy/test_update_llm_router_resilience.py:19
↓ 4 callers
Function
_make_dict_logging_obj
Build a Logging instance configured for a non-streaming dict result.
tests/unit/litellm_core_utils/test_litellm_logging.py:6770
↓ 4 callers
Method
_make_disable_auto_response_message
Return a session.update that disables VAD auto-response.
litellm/litellm_core_utils/realtime_streaming.py:1539
↓ 4 callers
Function
_make_failed_request_standard_logging_payload
()
tests/unit/proxy/spend_tracking/test_spend_tracking_utils.py:5728
↓ 4 callers
Function
_make_failure_logging_obj
()
tests/unit/test_router/test_router.py:12459
↓ 4 callers
Function
_make_frames
(n: int)
tests/unit/llms/sagemaker/test_sagemaker_chat_transformation.py:66
↓ 4 callers
Function
_make_function_call_item
Build a mock ResponseFunctionToolCall.
tests/unit/llms/anthropic/messages/responses_adapters/test_responses_adapters_transformation.py:1394
↓ 4 callers
Method
_make_gigachat_response
(self, data: list[dict])
tests/unit/llms/gigachat/embedding/test_gigachat_embedding_transformation.py:172
↓ 4 callers
Function
_make_guardrail
(name="g1", should_run=True, response=None)
tests/unit/proxy/utils/proxy_logging/test_during_call_hook.py:24
↓ 4 callers
Function
_make_guardrail
(name="g", should_run=True, override=None)
tests/unit/proxy/utils/proxy_logging/test_post_call_success_hook.py:25
← previous
next →
18,201–18,300 of 202,479, ranked by callers