grassylcao
ca578a9183
fix: mark card field as optional in message tool schema
...
The `createMessageToolCardSchema()` helper returned a bare `Type.Object()`
which TypeBox treats as required when merged into the parent tool schema via
`Type.Object({ card: ... })`. This caused schema validation to reject
media-only sends on Feishu and MSTeams with "must have required property
card", even though the implementation correctly treats card as optional.
Wrap the return value in `Type.Optional()` so the card field is excluded
from the JSON Schema `required` array. Fixes the catch-22 where omitting
card fails validation and including an empty card triggers the runtime
"does not support card with media" guard.
Closes #53697
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-03-24 16:53:56 -07:00
..
2026-03-24 23:33:30 +00:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-20 18:48:42 -04:00
2026-03-24 21:00:36 +00:00
2026-03-24 23:33:30 +00:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-22 20:01:25 -07:00
2026-03-23 05:06:07 -07:00
2026-03-24 16:51:36 -07:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 14:32:10 +00:00
2026-03-22 19:13:25 -07:00
2026-03-24 23:33:30 +00:00
2026-03-22 19:53:26 -07:00
2026-03-24 16:53:56 -07:00
2026-03-23 14:32:10 +00:00
2026-03-24 23:33:30 +00:00
2026-03-24 23:33:30 +00:00
2026-03-22 18:57:44 -07:00
2026-03-22 20:01:25 -07:00
2026-03-23 01:56:00 +00:00
2026-03-23 23:37:34 -05:00
2026-03-23 01:56:01 +00:00
2026-03-22 19:43:19 -07:00
2026-03-24 10:58:03 -07:00
2026-03-24 23:33:30 +00:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 17:39:30 +05:30
2026-03-23 17:05:37 +08:00
2026-03-23 15:07:24 -05:00
2026-03-22 19:13:25 -07:00
2026-03-23 09:26:34 -05:00
2026-03-23 10:57:56 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 01:56:00 +00:00
2026-03-24 23:33:30 +00:00
2026-03-23 01:56:01 +00:00
2026-03-24 23:33:30 +00:00
2026-03-23 01:56:00 +00:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 00:02:35 -07:00
2026-03-22 11:58:33 -07:00
2026-03-24 23:33:30 +00:00
2026-03-24 23:33:30 +00:00
2026-03-22 16:09:43 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 01:56:00 +00:00
2026-03-22 17:16:43 +00:00
2026-03-22 11:58:33 -07:00
2026-03-20 19:24:10 +00:00
2026-03-24 23:33:30 +00:00
2026-03-24 23:33:30 +00:00
2026-03-23 07:27:03 +00:00
2026-03-23 01:56:00 +00:00
2026-03-19 07:17:04 +00:00
2026-03-23 14:32:10 +00:00
2026-03-24 23:33:30 +00:00
2026-03-18 17:14:15 -07:00
2026-03-22 23:59:04 -07:00
2026-03-23 01:56:00 +00:00
2026-03-24 16:26:58 +00:00
2026-03-23 01:56:00 +00:00
2026-03-23 01:56:00 +00:00
2026-03-22 11:58:33 -07:00
2026-03-24 21:41:46 +00:00
2026-03-22 11:58:33 -07:00
2026-03-24 23:33:30 +00:00
2026-03-23 01:56:00 +00:00
2026-03-23 01:56:00 +00:00
2026-03-22 17:51:29 -07:00
2026-03-24 15:48:35 +00:00
2026-03-22 20:35:28 -07:00
2026-03-12 23:03:19 +00:00