Files
openclaw/extensions
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-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-22 11:58:33 -07:00
2026-03-23 14:32:10 +00:00
2026-03-23 14:32:10 +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-23 14:32:10 +00:00
2026-03-22 11:58:33 -07:00
2026-03-22 17:51:29 -07:00