Fixes #1411 /claim #1411
When a tool call is blocked due to untrusted data, the error message was incorrectly displaying [object Object] instead of the actual JSON arguments.
JSON.stringify() to toolCall.custom.input in openai.ts (lines 482 and 760)For function tool calls, toolCall.function.arguments is already a string from OpenAI’s SDK. However, for custom tool calls, toolCall.custom.input is an object. When passed directly to evaluatePolicies(), the object was converted to [object Object] via JavaScript’s default string conversion.
Excellencedev
@Excellencedev
Archestra
@archestra-ai