diff --git a/ui/desktop/openapi.json b/ui/desktop/openapi.json index 971f05dbb766..6814ace4eb2a 100644 --- a/ui/desktop/openapi.json +++ b/ui/desktop/openapi.json @@ -2332,17 +2332,16 @@ } }, "ResourceContents": { - "oneOf": [ + "anyOf": [ { "type": "object", "required": [ - "uri", - "text" + "text", + "uri" ], "properties": { "mime_type": { - "type": "string", - "nullable": true + "type": "string" }, "text": { "type": "string" @@ -2355,16 +2354,15 @@ { "type": "object", "required": [ - "uri", - "blob" + "blob", + "uri" ], "properties": { "blob": { "type": "string" }, "mime_type": { - "type": "string", - "nullable": true + "type": "string" }, "uri": { "type": "string" diff --git a/ui/desktop/src/api/types.gen.ts b/ui/desktop/src/api/types.gen.ts index 53230d066b87..6df01c7809fc 100644 --- a/ui/desktop/src/api/types.gen.ts +++ b/ui/desktop/src/api/types.gen.ts @@ -463,12 +463,12 @@ export type RedactedThinkingContent = { }; export type ResourceContents = { - mime_type?: string | null; + mime_type?: string; text: string; uri: string; } | { blob: string; - mime_type?: string | null; + mime_type?: string; uri: string; }; diff --git a/ui/desktop/src/components/BaseChat.tsx b/ui/desktop/src/components/BaseChat.tsx index c20c29de3884..769615b35712 100644 --- a/ui/desktop/src/components/BaseChat.tsx +++ b/ui/desktop/src/components/BaseChat.tsx @@ -537,7 +537,7 @@ function BaseChatContent({ recipeDetails={{ title: recipeConfig?.title, description: recipeConfig?.description, - instructions: recipeConfig?.instructions, + instructions: recipeConfig?.instructions ?? undefined, }} />