From 2dac75a22359cb16e5deea7e0a32f60e59347ae5 Mon Sep 17 00:00:00 2001 From: cthomas Date: Thu, 11 Dec 2025 16:29:05 -0800 Subject: [PATCH] fix: remove project id before proxying (#6750) --- letta/server/rest_api/routers/v1/anthropic.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/letta/server/rest_api/routers/v1/anthropic.py b/letta/server/rest_api/routers/v1/anthropic.py index b3399451..a25d12c0 100644 --- a/letta/server/rest_api/routers/v1/anthropic.py +++ b/letta/server/rest_api/routers/v1/anthropic.py @@ -323,7 +323,8 @@ async def anthropic_messages_proxy( request_data = json.loads(body) is_streaming = request_data.get("stream", False) model_name = request_data.get("model") - project_id = request_data.get("project_id") + # Extract and remove project_id (internal use only, not for Anthropic API) + project_id = request_data.pop("project_id", None) logger.debug(f"[Anthropic Proxy] Request is streaming: {is_streaming}") logger.debug(f"[Anthropic Proxy] Model: {model_name}") logger.debug(f"[Anthropic Proxy] Project ID: {project_id}")