Title
[Bug]: @openclaw/feishu bitable write tools emit invalid JSON Schema (empty patternProperties sub-schema) — breaks Anthropic via AWS Bedrock
Bug type
Schema validation error
Summary
Three bitable write tools in @openclaw/feishu use Type.Record(Type.String(), Type.Any()) which serializes to patternProperties: { "^.*$": {} } (empty sub-schema). This is rejected by AWS Bedrock's strict JSON Schema draft 2020-12 validation, causing all LLM calls to fail when these tools are in the tool list.
Affected tools
feishu_bitable_create_record — fields parameter
feishu_bitable_update_record — fields parameter
feishu_bitable_create_field — property parameter
Steps to reproduce
- Install
@openclaw/[email protected]
- Configure an Anthropic provider that routes through AWS Bedrock (e.g., a corporate proxy)
- Send any message to an agent that has these tools enabled
- Every LLM call fails with schema validation error
Expected behavior
Tools should emit valid JSON Schema that passes strict validation. Type.Any() should serialize to {} with at minimum "type": "object" or equivalent non-empty schema.
Actual behavior
tools.N.custom.input_schema: JSON schema is invalid
The Anthropic Messages API (via Bedrock) rejects the entire request because patternProperties: { "^.*$": {} } contains an empty sub-schema {}.
Root cause
In dist/api.js:
fields: Type.Record(Type.String(), Type.Any(), { description: "..." })
Serializes to:
{
"type": "object",
"patternProperties": {
"^.*$": {}
}
}
The empty {} is invalid under strict JSON Schema validation (Bedrock enforces draft 2020-12).
Workaround
Add these tools to tools.deny in agent config:
"tools": {
"deny": ["feishu_bitable_create_record", "feishu_bitable_update_record", "feishu_bitable_create_field"]
}
Suggested fix
Replace Type.Any() with a non-empty schema, for example:
Type.Record(Type.String(), Type.Unknown())
// or explicitly:
Type.Record(Type.String(), Type.Union([Type.String(), Type.Number(), Type.Boolean(), Type.Array(Type.Any()), Type.Object({})]))
Or apply schema sanitization in the tool registration phase to replace empty {} sub-schemas with { "type": "object" } or similar.
Environment
- OpenClaw: 2026.6.8
- @openclaw/feishu: 2026.6.8
- Provider: Anthropic (via AWS Bedrock corporate proxy)
- OS: macOS (ARM64)
Impact
P0 for affected users — all agent communication is blocked (not just bitable functionality). The invalid schema in any tool causes the entire tool list to be rejected by the provider.
Notes
- The Anthropic direct API appears to tolerate empty sub-schemas, so this only manifests when routing through Bedrock or other strict validators.
- OpenClaw's tool schema normalization covers Gemini, DeepSeek, and OpenAI but has no sanitization pass for Anthropic-bound schemas.
- Previous version (5.27) had internal normalization that masked this issue; 6.8 apparently removed or changed that behavior.
Title
[Bug]: @openclaw/feishu bitable write tools emit invalid JSON Schema (empty
patternPropertiessub-schema) — breaks Anthropic via AWS BedrockBug type
Schema validation error
Summary
Three bitable write tools in
@openclaw/feishuuseType.Record(Type.String(), Type.Any())which serializes topatternProperties: { "^.*$": {} }(empty sub-schema). This is rejected by AWS Bedrock's strict JSON Schema draft 2020-12 validation, causing all LLM calls to fail when these tools are in the tool list.Affected tools
feishu_bitable_create_record—fieldsparameterfeishu_bitable_update_record—fieldsparameterfeishu_bitable_create_field—propertyparameterSteps to reproduce
@openclaw/[email protected]Expected behavior
Tools should emit valid JSON Schema that passes strict validation.
Type.Any()should serialize to{}with at minimum"type": "object"or equivalent non-empty schema.Actual behavior
The Anthropic Messages API (via Bedrock) rejects the entire request because
patternProperties: { "^.*$": {} }contains an empty sub-schema{}.Root cause
In
dist/api.js:Serializes to:
{ "type": "object", "patternProperties": { "^.*$": {} } }The empty
{}is invalid under strict JSON Schema validation (Bedrock enforces draft 2020-12).Workaround
Add these tools to
tools.denyin agent config:Suggested fix
Replace
Type.Any()with a non-empty schema, for example:Or apply schema sanitization in the tool registration phase to replace empty
{}sub-schemas with{ "type": "object" }or similar.Environment
Impact
P0 for affected users — all agent communication is blocked (not just bitable functionality). The invalid schema in any tool causes the entire tool list to be rejected by the provider.
Notes