feat: make new message create type field optional [LET-4116] (#4319)

feat: make new message create type field optional
This commit is contained in:
cthomas
2025-08-29 15:22:34 -07:00
committed by GitHub
parent 35103b3a9f
commit bfd6030f72
3 changed files with 14 additions and 26 deletions

View File

@@ -29,7 +29,6 @@ from letta.schemas.letta_message_content import (
create_letta_user_message_content_union_schema,
)
from letta.schemas.letta_ping import create_letta_ping_schema
from letta.schemas.message import create_message_create_union_schema
from letta.server.constants import REST_DEFAULT_PORT
from letta.server.db import db_registry
@@ -66,7 +65,6 @@ def generate_openapi_schema(app: FastAPI):
letta_docs["paths"] = {k: v for k, v in letta_docs["paths"].items() if not k.startswith("/openai")}
letta_docs["info"]["title"] = "Letta API"
letta_docs["components"]["schemas"]["LettaMessageUnion"] = create_letta_message_union_schema()
letta_docs["components"]["schemas"]["MessageCreateUnion"] = create_message_create_union_schema()
letta_docs["components"]["schemas"]["LettaMessageContentUnion"] = create_letta_message_content_union_schema()
letta_docs["components"]["schemas"]["LettaAssistantMessageContentUnion"] = create_letta_assistant_message_content_union_schema()
letta_docs["components"]["schemas"]["LettaUserMessageContentUnion"] = create_letta_user_message_content_union_schema()