MCPcopy Create free account

hub / github.com/BerriAI/litellm / functions

Functions71,069 in github.com/BerriAI/litellm

↓ 17 callersMethoddelete_many
(self, where)
tests/test_litellm/proxy/_experimental/mcp_server/test_mcp_env_vars.py:930
↓ 17 callersFunctionec
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 17 callersFunctionef
(e)
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 17 callersFunctioneh
(e,r)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 17 callersFunctionemit_vcr_diagnostic_log
(terminalreporter)
tests/_vcr_conftest_common.py:107
↓ 17 callersMethodenqueue
Add a coroutine to the logging queue. Hot path: never blocks, aggressively clears queue if full.
litellm/litellm_core_utils/logging_worker.py:135
↓ 17 callersMethodexchange
(self, subject_token, server, config, *, tenant_id="")
tests/test_litellm/proxy/_experimental/mcp_server/outbound_credentials/test_resolver.py:178
↓ 17 callersMethodexecute_steps
Execute pipeline steps sequentially with conditional actions. Args: steps: Ordered list of pipeline steps mo
litellm/proxy/policy_engine/pipeline_executor.py:37
↓ 17 callersMethodfrom_env
Read config from the environment, falling back to defaults. An invalid value warns and uses the default rather than failing startup.
litellm-rust/crates/ai-gateway/src/io/realtime_pool.rs:122
↓ 17 callersMethodgetStore
()
litellm/proxy/_experimental/out/_next/static/chunks/0ivj_wax-joap.js:1
↓ 17 callersMethodget_auth_header
Resolve Anthropic credentials and return the appropriate auth header dict. Checks ANTHROPIC_API_KEY first (-> x-api-key or Bearer depending o
litellm/llms/anthropic/common_utils.py:740
↓ 17 callersFunctionget_budget_reset_time
Get the budget reset time based on the configured timezone. Falls back to UTC if not specified.
litellm/proxy/common_utils/timezone_utils.py:18
↓ 17 callersMethodget_complete_url
( self, api_base: Optional[str], litellm_params: dict, )
litellm/llms/bedrock_mantle/responses/transformation.py:60
↓ 17 callersMethodget_deployment_credentials_with_provider
Get API credentials and provider info from a model name in model_list. Useful for passthrough endpoints (files, batches, etc.) that n
litellm/router.py:8318
↓ 17 callersFunctionget_key_model_rpm_limit
Get the model rpm limit for a given api key. Priority order (returns first found): 1. Key metadata (model_rpm_limit) 2. Key model_ma
litellm/proxy/auth/auth_utils.py:832
↓ 17 callersMethodget_provider_anthropic_messages_config
( model: str, provider: LlmProviders, )
litellm/utils.py:8002
↓ 17 callersMethodget_runtime_endpoint
( self, api_base: Optional[str], aws_bedrock_runtime_endpoint: Optional[str],
litellm/llms/bedrock/base_aws_llm.py:1260
↓ 17 callersFunctionisAdminRole
(role: string)
ui/litellm-dashboard/src/utils/roles.ts:18
↓ 17 callersMethodisServer
()
litellm/proxy/_experimental/out/_next/static/chunks/15.9ylrtxojbj.js:1
↓ 17 callersFunctionmake_client
(**overrides)
tests/test_litellm/integrations/gitlab/test_gitlab_client.py:76
↓ 17 callersMethodmap_cohere_rerank_params
( self, non_default_params: dict, model: str, drop_params: bool, query
litellm/llms/voyage/rerank/transformation.py:29
↓ 17 callersMethodmap_ocr_params
Map OCR parameters to provider-specific parameters.
litellm/llms/base_llm/ocr/transformation.py:113
↓ 17 callersFunctionmodel_dump_with_preserved_fields
Serialize a Pydantic model to a dictionary while preserving specific fields even if they are None. Fields listed in _PRESERVED_NONE_FIEL
litellm/proxy/utils.py:6189
↓ 17 callersMethodon
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/0piozaeodiue..js:7
↓ 17 callersMethodpre_call_tool_check
Run pre-call checks and guardrail hooks for an MCP tool call. Returns a dict that may contain: - "arguments": hook-modified
litellm/proxy/_experimental/mcp_server/mcp_server_manager.py:3298
↓ 17 callersFunctionredact_string
Scrub known secret/credential patterns from *value* and return the result.
litellm/litellm_core_utils/secret_redaction.py:81
↓ 17 callersMethodremove
(self, *label_values)
tests/test_litellm/integrations/test_prometheus_end_user_cardinality.py:85
↓ 17 callersFunctionresolve_and_validate_end_user_id
Optionally drop end-user ids that don't resolve to a known DB row. Default: pass-through. LiteLLM's documented pattern is that the `user` fie
litellm/proxy/auth/auth_checks.py:1159
↓ 17 callersFunctionresolve_llm_provider_for_rate_limit
Resolve ``(model, llm_provider)`` for a request being rejected by an internal proxy-side rate-limit hook. These hooks fire from ``async_
litellm/proxy/hooks/rate_limiter_utils.py:15
↓ 17 callersMethodretrieve
(e,t={},s)
litellm/proxy/_experimental/out/_next/static/chunks/0piozaeodiue..js:7
↓ 17 callersMethodrun_with_session
Open a session, run the provided coroutine, and clean up.
litellm/experimental_mcp_client/client.py:385
↓ 17 callersFunctionsend_llm_exception_alert
Only runs if router.slack_alerting_logger is set Sends a Slack / MS Teams alert for the LLM API call failure. Only if router.slack_alerting_l
litellm/router_utils/handle_error.py:23
↓ 17 callersFunctionsetup_proxy_logging_object
(monkeypatch, llm_router: Router)
tests/test_litellm/proxy/openai_files_endpoint/test_files_endpoint.py:75
↓ 17 callersFunctionshould_use_polling_for_request
Determine if polling via cache should be used for a request. Args: background_mode: Whether background=true was set in the request
litellm/proxy/response_polling/polling_handler.py:251
↓ 17 callersMethodtransform_request
( self, model: str, messages: List[AllMessageValues], optional_params: dict,
litellm/llms/bedrock/chat/invoke_transformations/anthropic_claude3_transformation.py:127
↓ 17 callersMethodtransform_responses_api_request
Transform the request for Manus API. Manus requires: - `task_mode: "agent"` in the request body - `agent_profile` ex
litellm/llms/manus/responses/transformation.py:123
↓ 17 callersFunctiontx
(e)
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 17 callersMethodvalidate_environment
( self, headers: dict, model: str, messages: list[Any], optional_param
litellm/llms/gdc/chat/transformation.py:174
↓ 16 callersFunctionC
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 16 callersFunction_async_return
(value)
tests/test_litellm/proxy/guardrails/guardrail_hooks/test_repelloai.py:1135
↓ 16 callersFunction_coerce_user_id_to_str
Return a usable end-user identifier string, or None if the value isn't one. Always drops non-string structured values (dict/list/tuple/set) becau
litellm/proxy/auth/auth_utils.py:1109
↓ 16 callersFunction_config
()
tests/test_litellm/llms/fastcrw/search/test_transformation.py:10
↓ 16 callersMethod_create_anthropic_response_logging_payload
Create the standard logging object for Anthropic passthrough handles streaming and non-streaming responses
litellm/proxy/pass_through_endpoints/llm_provider_handlers/anthropic_passthrough_logging_handler.py:224
↓ 16 callersMethod_decode_responses_api_response_id
Decode the responses_api_response_id Returns: DecodedResponseId: Structured tuple with custom_llm_provider, model_id, an
litellm/responses/utils.py:421
↓ 16 callersMethod_get_optional_params
(self, vendor: OCIVendors, optional_params: dict, model: str = "")
litellm/llms/oci/chat/transformation.py:457
↓ 16 callersMethod_get_span_processor
(self, dynamic_headers: Optional[dict] = None)
litellm/integrations/opentelemetry.py:2750
↓ 16 callersFunction_greptile_comment
( body: str, updated_at: str = "2026-05-10T00:00:00Z", login: str = "greptile-apps[bot]", )
tests/test_litellm/test_github_close_low_quality_prs.py:35
↓ 16 callersFunction_invalidate_model_cost_lowercase_map
Invalidate the case-insensitive lookup map for model_cost. Call this whenever litellm.model_cost is modified to ensure the map is rebuilt. Al
litellm/utils.py:4902
↓ 16 callersFunction_is_user_org_admin_for_team
Check if user is an org admin for the team's organization. Returns True if: - The team belongs to an organization, AND - The user ha
litellm/proxy/management_endpoints/common_utils.py:114
↓ 16 callersFunction_make_router
()
tests/test_litellm/router_strategy/adaptive_router/test_adaptive_router.py:21
↓ 16 callersMethod_process_chunk
Process a single chunk of data from the stream
litellm/responses/streaming_iterator.py:116
↓ 16 callersFunction_resolve_jwt_to_virtual_key
Returns: - ``UserAPIKeyAuth``: a resolved virtual key (cache hit or DB hit). The caller may use this directly; JWT policy has been
litellm/proxy/auth/user_api_key_auth.py:828
↓ 16 callersFunction_router_with_two_deployments
(blocked_flags)
tests/test_litellm/test_router.py:4909
↓ 16 callersFunction_run_dispatch
(wrapper: CustomStreamWrapper, chunk)
tests/test_litellm/litellm_core_utils/test_streaming_handler.py:1914
↓ 16 callersFunction_server
(**kwargs)
tests/test_litellm/proxy/_experimental/mcp_server/outbound_credentials/test_adapter.py:33
↓ 16 callersMethod_sign_request
Sign a request for Bedrock or Sagemaker Returns: Tuple[dict, Optional[str]]: A tuple containing the headers and the json
litellm/llms/bedrock/base_aws_llm.py:1442
↓ 16 callersMethod_to_ns
(self, dt)
litellm/integrations/opentelemetry.py:2657
↓ 16 callersMethod_transform_chat_completion_usage_to_responses_usage
( chat_completion_response: Union[ModelResponse, Usage], )
litellm/responses/litellm_completion_transformation/transformation.py:1967
↓ 16 callersMethod_transform_messages
(self, messages: List[AllMessageValues], model: str)
litellm/llms/openai/openai.py:208
↓ 16 callersFunction_u
(name: str)
tests/test_litellm/proxy/_experimental/mcp_server/test_mcp_env_vars.py:21
↓ 16 callersFunction_user_api_key_auth_builder
( request: Request, api_key: str, azure_api_key_header: str, anthropic_api_key_header: Optiona
litellm/proxy/auth/user_api_key_auth.py:1034
↓ 16 callersMethodaiter_lines
(self)
tests/test_litellm/sandbox/test_e2b_sandbox.py:31
↓ 16 callersMethodapply_guardrail
Apply Bedrock guardrail to a batch of texts for testing purposes. This method allows users to test Bedrock guardrails without making
litellm/proxy/guardrails/guardrail_hooks/bedrock_guardrails.py:1616
↓ 16 callersMethodapply_guardrail
(self, inputs, request_data, **kwargs)
tests/test_litellm/integrations/test_custom_guardrail.py:1166
↓ 16 callersFunctionas_str
(value: object)
litellm/integrations/otel/model/utils.py:12
↓ 16 callersFunctionassert_bfl_polling_url
Validate that a polling URL points to a BFL-controlled host. BFL returns polling URLs on subdomains like ``gateway.bfl.ai`` that differ from
litellm/llms/black_forest_labs/common_utils.py:28
↓ 16 callersMethodasync_get_available_deployment
( self, model: str, messages: Optional[list[dict[str, str]]] = None, input: Op
litellm/router_strategy/lar1_routing.py:89
↓ 16 callersMethodasync_get_cache
( self, key, litellm_parent_otel_span: Union[Span, None], local_only: bool = F
litellm/proxy/utils.py:230
↓ 16 callersMethodasync_pre_call_deployment_hook
(self, kwargs: dict[str, Any], call_type: CallTypes | None)
litellm/integrations/code_interpreter_interception/handler.py:186
↓ 16 callersMethodasync_pre_call_hook
Pre-call hook to sanitize user prompts.
litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.py:465
↓ 16 callersMethodatext_completion
( self, model: str, prompt: str, is_retry: Optional[bool] = False, is_
litellm/router.py:3958
↓ 16 callersMethodatranscription
Example Usage: ``` from litellm import Router client = Router(model_list = [ { "model_na
litellm/router.py:3647
↓ 16 callersFunctioncall_with_db_reconnect_retry
Run a Prisma read coroutine with one transport-reconnect-and-retry. The canonical "self-heal a transient DB transport blip" wrapper used by `
litellm/proxy/db/exception_handler.py:254
↓ 16 callersMethodcheck_and_create_cache
Receives - messages: List of dict - messages in the openai format Returns - messages - List[dict] - filtered list of
litellm/llms/vertex_ai/context_caching/vertex_ai_context_caching.py:276
↓ 16 callersFunctiondate
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 16 callersMethoddelete_cache
(self, key)
litellm/caching/disk_cache.py:90
↓ 16 callersMethoddelete_key
(self, key: str)
tests/e2e/budgets/budget_client.py:193
↓ 16 callersFunctioneP
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 16 callersFunctioneX
(e,t,n)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 16 callersFunctionej
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 16 callersFunctionextract_file_data
Extracts and processes file data from various input formats. Args: file_data: Can be a tuple of (filename, content, [content_type],
litellm/litellm_core_utils/prompt_templates/common_utils.py:747
↓ 16 callersMethodgenerate_key
( self, *, models: list[str] | None = None, max_budget: float | None = None,
tests/e2e/budgets/budget_client.py:164
↓ 16 callersMethodget_api_key
Return the API key for this provider.
tests/test_litellm/interactions/base_interactions_test.py:29
↓ 16 callersFunctionget_attachment_registry
Get the global AttachmentRegistry singleton. Returns: The global AttachmentRegistry instance
litellm/proxy/policy_engine/attachment_registry.py:463
↓ 16 callersFunctionget_azure_ad_token
Get Azure AD token from various authentication methods. This function tries different methods to obtain an Azure AD token: 1. From an ex
litellm/llms/azure/common_utils.py:253
↓ 16 callersMethodget_levo_config
Retrieves the Levo configuration based on environment variables. Returns: LevoConfig: Configuration object containing Le
litellm/integrations/levo/levo.py:41
↓ 16 callersFunctionget_management_object_ttl
In-memory TTL for management-object cache writes (keys, teams, users, budgets, ...). Honors ``general_settings.user_api_key_cache_ttl``, whi
litellm/proxy/common_utils/user_api_key_cache.py:153
↓ 16 callersFunctionget_standard_logging_object_payload
( kwargs: Optional[dict], init_response_obj: Union[Any, BaseModel, dict], start_time: dt_object,
litellm/litellm_core_utils/litellm_logging.py:5183
↓ 16 callersMethodget_team_id
(self, token: dict, default_value: Optional[str])
litellm/proxy/auth/handle_jwt.py:351
↓ 16 callersMethodhasKey
(s)
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 16 callersFunctionhash_password
Hash a password using scrypt with a random salt.
litellm/proxy/utils.py:5050
↓ 16 callersFunctioninitialize_pass_through_endpoints
1. Create a global list of pass-through endpoints (db + config) 2. Clear all existing pass-through endpoints from the FastAPI app routes
litellm/proxy/pass_through_endpoints/pass_through_endpoints.py:2712
↓ 16 callersFunctioninitialize_standard_callback_dynamic_params
Initialize the standard callback dynamic params from the kwargs checks supported request callback params in kwargs and sets the correspondin
litellm/litellm_core_utils/initialize_dynamic_callback_params.py:87
↓ 16 callersFunctioninstall_live_call_probe
Activate the live-call socket probe for non-VCR-marked tests. Call this from inside the per-test autouse ``_vcr_outcome_gate`` fixture *befor
tests/_vcr_conftest_common.py:1845
↓ 16 callersFunctionis_cached_message
Returns true, if message is marked as needing to be cached. Used for anthropic/gemini context caching. Follows the anthropic format {"c
litellm/utils.py:7185
↓ 16 callersFunctioniter_message_text
Yield every text fragment from ``messages`` AND ``input``. Walks every role (user, assistant, system, …) — guardrails inspect the entire conv
litellm/proxy/guardrails/_content_utils.py:88
↓ 16 callersFunctionkt
(t)
litellm/proxy/_experimental/out/_next/static/chunks/03~yq9q893hmn.js:1
↓ 16 callersMethodload_local_model_cost_map
Load the local backup model cost map bundled with the package.
litellm/litellm_core_utils/get_model_cost_map.py:51
↓ 16 callersMethodmake_bedrock_api_request
( self, source: Literal["INPUT", "OUTPUT"], messages: Optional[List[AllMessageValues]]
litellm/proxy/guardrails/guardrail_hooks/bedrock_guardrails.py:632
↓ 16 callersFunctionmake_ui_spend_logs_mock_prisma
Create a MockPrismaClient for /spend/logs/ui endpoint tests. Args: mock_spend_logs: List of mock spend log dicts. filter_fn:
tests/test_litellm/proxy/spend_tracking/test_spend_management_endpoints.py:148
← previousnext →901–1,000 of 71,069, ranked by callers