WebSearch tool appends raw API Error: Output blocked by content filtering policy to already-successful responses

Open 💬 2 comments Opened Jul 2, 2026 by danrosg

When using the WebSearch tool for narrow, fact-based queries (e.g., confirming a short quoted fragment), the tool sometimes generates a complete, useful answer and then appends a raw backend error string as a trailing line:

API Error: Output blocked by content filtering policy

Example: querying for the line following a specific short lyric fragment returned:

"The chorus line in Pink Floyd's 'Money' goes 'Money, it's a crime. Share it fairly but don't take a slice of my pie.'" API Error: Output blocked by content filtering policy

The answer was already delivered in full before the error line appeared — the filtering trigger fired redundantly, after the fact, on content that had already been returned. This is different from a deliberate refusal message (which reads as a normal sentence explaining why the tool won't do something); this string is an unhandled internal error code (API Error: ...) leaking directly into user-facing output. A 400-style error code is meant for service-to-service communication, not for display to a human end user.

Suggested fix: Either suppress/retry silently when the filter trips after a response has already been generated, or replace the raw error string with a plain-language message consistent with the tool's other refusal phrasing.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗