MCPcopy Create free account

hub / github.com/BerriAI/litellm / functions

Functions68,141 in github.com/BerriAI/litellm

↓ 32 callersMethodget_model_info
( self, model: str, api_base: Optional[str] = None, api_key: Optional[str] = N
litellm/llms/ollama/common_utils.py:219
↓ 32 callersFunctionn
()
litellm/proxy/_experimental/out/_next/static/chunks/101az3fsw7lje.js:1
↓ 32 callersMethodnotify
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0n.a~e5dwfnkn.js:1
↓ 32 callersFunctionuser_api_key_auth
(request: Request, api_key: str)
tests/proxy_unit_tests/test_configs/custom_auth.py:9
↓ 32 callersFunctionuuid4
Return a UUID4 using the selected backend.
litellm/_uuid.py:13
↓ 32 callersFunctionvalidate_trusted_redirect_uri
Accept ``redirect_uri`` when it is (a) same-origin with the proxy's own request origin, (b) loopback, (c) listed in the ``MCP_TRUSTED_REDIRECT
litellm/proxy/_experimental/mcp_server/oauth_utils.py:486
↓ 31 callersFunction_make_user_api_key_dict
( user_id: str = "user-123", team_id: str = "team-abc", user_email: str = "user@example.com",
tests/test_litellm/proxy/guardrails/test_mcp_jwt_signer.py:27
↓ 31 callersFunctiona$
(t,e,r)
litellm/proxy/_experimental/out/_next/static/chunks/0ys10755n8os_.js:1
↓ 31 callersFunctiongenerate_mock_mcp_server_config_record
Generate a mock MCP server record from config.yaml
tests/test_litellm/proxy/management_endpoints/test_mcp_management_endpoints.py:57
↓ 31 callersMethodget_deployment_by_model_group_name
Returns -> Deployment or None Raise Exception -> if model found in invalid format Optimized with O(1) index lookup instead
litellm/router.py:8267
↓ 31 callersFunctionget_user_object
- Check if user id in proxy User Table - if valid, return LiteLLM_UserTable object with defined limits - if not, then raise an error
litellm/proxy/auth/auth_checks.py:1580
↓ 31 callersMethodis_llm_api_route
Helper to checks if provided route is an OpenAI route Returns: - True: if route is an OpenAI route - False:
litellm/proxy/auth/route_checks.py:347
↓ 31 callersMethodmodel_dump
(self_inner)
tests/llm_translation/test_openai.py:324
↓ 31 callersFunctionr
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0.4.bbjx7y007.js:1
↓ 31 callersMethodset_cache
(self, key, value, **kwargs)
litellm/caching/s3_cache.py:63
↓ 31 callersMethodupdate_request_status
(self, litellm_call_id: str, status: Literal["success", "fail"])
litellm/proxy/utils.py:603
↓ 31 callersMethodvalueOf
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 30 callersFunctionW
({accessToken:e,token:a,userRole:n,userID:s,keys:o,premiumUser:i})
litellm/proxy/_experimental/out/_next/static/chunks/0~0su3wi_7f6-.js:1
↓ 30 callersFunctionX
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/15hm8gokjq2uu.js:1
↓ 30 callersFunction_make_mock_response
( content: str, prompt_tokens: int = 50, completion_tokens: int = 100, )
tests/test_litellm/llms/anthropic/experimental_pass_through/context_management/test_compact.py:69
↓ 30 callersFunctionencode
Return a urlsafe-base64 managed ID string (trailing ``=`` stripped).
litellm/proxy/pass_through_endpoints/managed_id_codec.py:40
↓ 30 callersFunctionrewrite_response_ids
Mint managed IDs for raw provider values listed in ``BUILTIN_OUTPUT_ID_FIELD_MAP`` and swap them into *body*. Returns the same *body* ob
litellm/proxy/pass_through_endpoints/managed_id_rewriter.py:680
↓ 30 callersMethodtransform_image_generation_request
Transform the image generation request to Gemini format For Gemini 2.5 Flash Image Preview, use the standard Gemini format with resp
litellm/llms/gemini/image_generation/transformation.py:110
↓ 30 callersMethodtransform_request
( self, model: str, messages: List[AllMessageValues], optional_params: dict,
litellm/llms/bedrock/chat/converse_transformation.py:1614
↓ 29 callersFunctionG
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 29 callersFunctionZ
({filters:e})
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 29 callersMethodaclose
(self)
tests/test_litellm/proxy/test_proxy_server.py:5415
↓ 29 callersMethodasync_log_success_event
(self, kwargs, response_obj, start_time, end_time)
tests/test_litellm/integrations/arize/test_arize_utils.py:385
↓ 29 callersMethodasync_set_cache
(self, *args, **kwargs)
tests/test_litellm/proxy/auth/test_resolvers_store.py:28
↓ 29 callersMethodcheck_and_fix_namespace
Make sure each key starts with the given namespace
litellm/caching/redis_cache.py:354
↓ 29 callersMethodclient
(self)
tests/test_litellm/proxy/test_proxy_server.py:8314
↓ 29 callersMethodfind_many
( self, where: Optional[Dict[str, Any]] = None, skip: Optional[int] = None, ta
tests/test_litellm/repositories/test_repositories.py:64
↓ 29 callersMethodget_error_information
( original_exception: Optional[Exception], traceback_str: Optional[str] = None, )
litellm/litellm_core_utils/litellm_logging.py:4858
↓ 29 callersFunctioninitialize
( model=None, alias=None, api_base=None, api_version=None, debug=False, detailed_debug
litellm/proxy/proxy_server.py:6370
↓ 29 callersMethodmap_openai_params
( self, non_default_params: dict, optional_params: dict, model: str, d
litellm/llms/anthropic/chat/transformation.py:1358
↓ 29 callersMethodrun
()
litellm/proxy/_experimental/out/_next/static/chunks/0ivj_wax-joap.js:1
↓ 29 callersMethodtoString
()
litellm/proxy/_experimental/out/_next/static/chunks/0.4.bbjx7y007.js:1
↓ 29 callersFunctiontoken_counter
The same as `litellm.litellm_core_utils.token_counter`. Kept for backwards compatibility.
litellm/utils.py:2090
↓ 29 callersFunctiontp
(t)
litellm/proxy/_experimental/out/_next/static/chunks/03~yq9q893hmn.js:1
↓ 29 callersMethodtransform_image_generation_response
Transform the image generation response to the litellm image response
litellm/llms/fal_ai/image_generation/transformation.py:70
↓ 29 callersMethodupdate
(e,t,s)
litellm/proxy/_experimental/out/_next/static/chunks/16.oisvgwzo8s.js:7
↓ 29 callersFunctionw
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 28 callersFunctionMn
(t,e,r,n)
litellm/proxy/_experimental/out/_next/static/chunks/03~yq9q893hmn.js:1
↓ 28 callersFunctionV
()
litellm/proxy/_experimental/out/_next/static/chunks/01_xjyxcb1uco.js:1
↓ 28 callersMethod__init__
( self, message, model, llm_provider, litellm_debug_info: Optional[str
litellm/exceptions.py:331
↓ 28 callersFunction_user_auth
(user_id: str = "user-a", team_id: str = "team-a")
tests/test_litellm/proxy/memory/test_memory_endpoints.py:209
↓ 28 callersMethodbackend_to_client_send_messages
(self)
litellm/litellm_core_utils/realtime_streaming.py:932
↓ 28 callersMethodclose
(self)
litellm/llms/custom_httpx/http_handler.py:1105
↓ 28 callersFunctiondecode
Decode *managed_id*. Returns ``None`` for anything that is not a passthrough managed ID — raw OpenAI IDs, unified-endpoint IDs, garbage,
litellm/proxy/pass_through_endpoints/managed_id_codec.py:48
↓ 28 callersMethoddiscard
Pseudo-destructor to be invoked to clean up global data structures when router is no longer used. For now, unhook router's callbacks
litellm/router.py:716
↓ 28 callersFunctione
(t)
litellm/proxy/_experimental/out/_next/static/chunks/0.4.bbjx7y007.js:1
↓ 28 callersFunctionea
()
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 28 callersFunctionet
(t,e)
litellm/proxy/_experimental/out/_next/static/chunks/03~yq9q893hmn.js:1
↓ 28 callersMethodexists
(self, *names: str)
litellm/proxy/_experimental/mcp_server/outbound_credentials/redis_distributed_lock.py:43
↓ 28 callersMethodflush
Flush the logging queue. Waits until every enqueued task has completed. ``queue.join()`` blocks on the queue's unfinished-task counte
litellm/litellm_core_utils/logging_worker.py:360
↓ 28 callersMethodget_base_completion_call_args
Must return the base completion call args
tests/llm_translation/base_llm_unit_tests.py:82
↓ 28 callersMethodget_provider_chat_config
Returns the provider config for a given provider. Uses O(1) dictionary lookup for fast provider resolution. Python classes t
litellm/utils.py:7718
↓ 28 callersFunctionget_utc_datetime
()
litellm/utils.py:4728
↓ 28 callersFunctionprint_verbose
Prints the given `print_statement` to the console if `litellm.set_verbose` is True. Also logs the `print_statement` at the debug level using
litellm/proxy/utils.py:182
↓ 28 callersFunctionresolveLogoSrc
(value: string | null | undefined, root: string = serverRootPath)
ui/litellm-dashboard/src/lib/assetPaths.ts:23
↓ 28 callersMethodtransform_rerank_response
( self, model: str, raw_response: httpx.Response, model_response: RerankRespon
litellm/llms/voyage/rerank/transformation.py:79
↓ 28 callersFunctionunique_marker
A short unique token per call/run, so concurrent runs and the shared response cache never collide on prompts, tags, or customer ids.
tests/e2e/e2e_config.py:31
↓ 28 callersFunctionupdate_team
Use `/team/member_add` AND `/team/member/delete` to add/remove new team members You can now update team budget / rate limits via /team/updat
litellm/proxy/management_endpoints/team_endpoints.py:1566
↓ 28 callersFunctionuseComponent
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 27 callersFunctionD
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/0rdv7_7_95b-1.js:1
↓ 27 callersFunctionU
({accessToken:e,userRole:y,userID:v})
litellm/proxy/_experimental/out/_next/static/chunks/01_xjyxcb1uco.js:1
↓ 27 callersFunctionY
()
litellm/proxy/_experimental/out/_next/static/chunks/15hm8gokjq2uu.js:13
↓ 27 callersFunction_make_access_group_record
( access_group_id: str = "ag-123", access_group_name: str = "test-group", description: str | None
tests/test_litellm/proxy/management_endpoints/test_access_group_endpoints.py:27
↓ 27 callersMethod_normalize_otel_endpoint
Normalize the endpoint URL for a specific OpenTelemetry signal type. The OTLP exporters expect endpoints to use signal-specific path
litellm/integrations/opentelemetry.py:2983
↓ 27 callersMethodacquire_lock
Attempt to acquire the lock for a specific cron job using Redis. Uses the SET command with NX and EX options to ensure atomicity.
litellm/proxy/db/db_transaction_queue/pod_lock_manager.py:42
↓ 27 callersMethodapply_guardrail
Validate tool calls against the blocking service (fail-open).
litellm/integrations/rubrik.py:167
↓ 27 callersMethodasync_service_success_hook
Arize is used mainly for LLM I/O tracing, sending router+caching metrics adds bloat to arize logs
litellm/integrations/arize/arize.py:116
↓ 27 callersMethodcall_cato_guardrail
( self, data: dict, hook: str, key_alias: Optional[str], user_email: O
litellm/proxy/guardrails/guardrail_hooks/cato_networks/cato_networks.py:223
↓ 27 callersFunctione
()
litellm/proxy/_experimental/out/_next/static/chunks/0ys10755n8os_.js:1
↓ 27 callersFunctione1
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 27 callersFunctioned
({organizationId:e,onClose:t,accessToken:s,is_org_admin:i,is_proxy_admin:r,userModels:n,editOrg:o})
litellm/proxy/_experimental/out/_next/static/chunks/0c2apcdkbqq0o.js:1
↓ 27 callersMethodget_deployment
Returns -> Deployment or None Raise Exception -> if model found in invalid format
litellm/router.py:8233
↓ 27 callersFunctionget_end_user_id_from_request_body
(request_body: dict, request_headers: Optional[dict] = None)
litellm/proxy/auth/auth_utils.py:1128
↓ 27 callersFunctionget_logging_payload
(kwargs, response_obj, start_time, end_time)
litellm/proxy/spend_tracking/spend_tracking_utils.py:227
↓ 27 callersFunctionget_server_prefix
Return the prefix for a server. When the short-prefix mode is enabled (``LITELLM_USE_SHORT_MCP_TOOL_PREFIX``) a three-character base62 ID is
litellm/proxy/_experimental/mcp_server/utils.py:263
↓ 27 callersMethodload
(self)
litellm/proxy/proxy_cli.py:455
↓ 27 callersMethodpre_call_hook
( self, user_api_key_dict: UserAPIKeyAuth, data: None, call_type: CallTypesLit
litellm/proxy/utils.py:1317
↓ 27 callersMethodregister
(s,o=!0)
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 27 callersFunctionreserve_budget_for_request
( request_body: dict, route: str, llm_router: Optional[Router], valid_token: Optional[UserAPIK
litellm/proxy/spend_tracking/budget_reservation.py:57
↓ 27 callersFunctionresponses_api_bridge_check
( model: str, custom_llm_provider: str, web_search_options: Optional[OpenAIWebSearchOptions] = Non
litellm/main.py:963
↓ 27 callersMethodset_cache
(self, key, value, **kwargs)
tests/test_litellm/proxy/test_redis_auth_cache_flag.py:35
↓ 27 callersFunctionstr_to_bool
Converts a string to a boolean if it's a recognized boolean string. Returns None if the string is not a recognized boolean value. :param
litellm/secret_managers/main.py:85
↓ 27 callersFunctiont6
(e,t,s,r,a)
litellm/proxy/_experimental/out/_next/static/chunks/16.oisvgwzo8s.js:4
↓ 27 callersFunctiontd
(e)
litellm/proxy/_experimental/out/_next/static/chunks/04jvxoid~vpxj.js:1
↓ 27 callersFunctiontest
()
tests/local_testing/test_router.py:1213
↓ 27 callersFunctiontk
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/0c4pfjjue0uc-.js:1
↓ 27 callersMethodtoRgbString
()
litellm/proxy/_experimental/out/_next/static/chunks/0.4.bbjx7y007.js:1
↓ 27 callersMethodtoValue
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 27 callersFunctiontoken_counter
Count the number of tokens in a given text using a specified model. Args: model (str): The name of the model to use for tokenization. De
litellm/litellm_core_utils/token_counter.py:341
↓ 27 callersMethodtransform_image_edit_request
(self, *args, **kwargs)
tests/test_litellm/images/test_image_edit_utils.py:38
↓ 26 callersFunction_build_router
(routing_strategy="simple-shuffle", routing_groups=None)
tests/test_litellm/router_strategy/test_router_routing_groups.py:53
↓ 26 callersFunction_make_trusted_request
Build a request-like object whose same-origin is ``base_url``. ``get_request_base_url`` defers to ``request.base_url`` unless the caller is a
tests/test_litellm/proxy/_experimental/mcp_server/test_byok_oauth_endpoints.py:1145
↓ 26 callersMethod_map_tool_helper
( self, tool: ChatCompletionToolParam, )
litellm/llms/anthropic/chat/transformation.py:618
↓ 26 callersFunction_safe_get_request_headers
[Non-Blocking] Safely get the request headers. Caches the result on request.state to avoid re-creating dict(request.headers) per call. W
litellm/proxy/common_utils/http_parsing_utils.py:177
↓ 26 callersFunction_safe_response
(url: str = CHAT_URL)
tests/test_litellm/proxy/guardrails/guardrail_hooks/_cisco_ai_defense_test_utils.py:81
← previousnext →401–500 of 68,141, ranked by callers