From c13b4c55141beb4fc45982c736437c474d54972a Mon Sep 17 00:00:00 2001 From: Ishaan Jaffer Date: Sat, 20 Dec 2025 14:36:59 +0530 Subject: [PATCH] test_aaapass_through_endpoint_pass_through_keys_langfuse --- tests/local_testing/test_pass_through_endpoints.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/local_testing/test_pass_through_endpoints.py b/tests/local_testing/test_pass_through_endpoints.py index 1c6a7f2c5d8..132834c4023 100644 --- a/tests/local_testing/test_pass_through_endpoints.py +++ b/tests/local_testing/test_pass_through_endpoints.py @@ -443,10 +443,14 @@ async def test_aaapass_through_endpoint_pass_through_keys_langfuse( } # Make a request to the pass-through endpoint + # For langfuse custom_auth_parser, the Authorization header must be valid base64 + # Format: base64(public_key:secret_key) where public_key is the LiteLLM API key + import base64 + auth_token = base64.b64encode(f"{mock_api_key}:anything".encode()).decode() response = client.post( "/api/public/ingestion", json=_json_data, - headers={"Authorization": "Basic test-base64-auth-token-123"}, + headers={"Authorization": f"Basic {auth_token}"}, ) print("JSON response: ", _json_data)