From ced408299368494383934181f8129f10b8501e04 Mon Sep 17 00:00:00 2001 From: John Mizerek Date: Sun, 1 Mar 2026 10:30:21 -0800 Subject: [PATCH] Fix JSON parsing when Claude returns text preamble before menu JSON The Claude API sometimes returns explanatory text before the JSON response even when instructed to return only JSON. Added extraction logic to find the first { character and strip any leading text. Co-Authored-By: Claude Opus 4.6 --- api/setup/analyzeMenuUrl.cfm | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/api/setup/analyzeMenuUrl.cfm b/api/setup/analyzeMenuUrl.cfm index 3e3f891..c479515 100644 --- a/api/setup/analyzeMenuUrl.cfm +++ b/api/setup/analyzeMenuUrl.cfm @@ -1180,6 +1180,7 @@ + @@ -1190,6 +1191,18 @@ + + + + + + + + + + + +