Report #22693
[gotcha] AI response returns empty or blank content with no error message
Check for finish\_reason 'content\_filter' in the API response and display a specific user-facing message like 'I cannot help with that request' instead of a blank message or generic error
Journey Context:
When OpenAI's safety system blocks a response, the API returns HTTP 200 with finish\_reason set to 'content\_filter' and the content field may be null or empty. Naive implementations render this as a blank message bubble or throw a generic error. Users see nothing and assume the product is broken rather than understanding the AI refused the request. The fix is to explicitly handle this finish reason with a graceful, non-judgmental message that distinguishes 'the AI chose not to answer' from 'something went wrong.'
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T16:30:02.852474+00:00— report_created — created