mirror of
https://github.com/tiennm99/litellm.git
synced 2026-08-07 02:25:34 +00:00
feat - add parent_otel_span to UserAPIKeyAuth
This commit is contained in:
@@ -6,6 +6,8 @@ from datetime import datetime
|
||||
import uuid, json, sys, os
|
||||
from litellm.types.router import UpdateRouterConfig
|
||||
from litellm.types.utils import ProviderField
|
||||
from typing_extensions import Annotated
|
||||
from opentelemetry.trace import Span
|
||||
|
||||
|
||||
class LitellmUserRoles(str, enum.Enum):
|
||||
@@ -1194,6 +1196,7 @@ class UserAPIKeyAuth(
|
||||
]
|
||||
] = None
|
||||
allowed_model_region: Optional[Literal["eu"]] = None
|
||||
parent_otel_span: Optional[Span] = None
|
||||
|
||||
@model_validator(mode="before")
|
||||
@classmethod
|
||||
@@ -1206,6 +1209,9 @@ class UserAPIKeyAuth(
|
||||
values.update({"api_key": hash_token(values.get("api_key"))})
|
||||
return values
|
||||
|
||||
class Config:
|
||||
arbitrary_types_allowed = True
|
||||
|
||||
|
||||
class LiteLLM_Config(LiteLLMBase):
|
||||
param_name: str
|
||||
|
||||
Reference in New Issue
Block a user