white-mechanic-95574
02/22/2025, 4:50 AMwhite-mechanic-95574
02/22/2025, 4:50 AMwhite-mechanic-95574
02/22/2025, 4:51 AMwooden-beard-40210
02/22/2025, 7:42 AMwhite-nest-40686
02/22/2025, 9:27 AMworkflow.responseData filled with the all response of an axios call? or the response.data ?white-mechanic-95574
02/24/2025, 4:40 AMwhite-nest-40686
02/24/2025, 5:15 AMresponse.data.content, or the path to content, in workflow.responseData.white-mechanic-95574
02/25/2025, 4:02 AMwhite-nest-40686
02/25/2025, 5:27 AMcontent, so it'd be response.data.choices[0].contentwhite-mechanic-95574
02/26/2025, 3:34 AMwhite-nest-40686
02/26/2025, 5:59 AMwhite-mechanic-95574
02/26/2025, 5:59 PMwhite-nest-40686
02/27/2025, 12:09 PMts
const fetchCompanyData = JSON.parse(workflow.fetchCompanyData.response.data)
console.log("fetchCompanyData: ", fetchCompanyData)
workflow.responseData = fetchCompanyData.choices[0].contentwhite-mechanic-95574
03/01/2025, 3:36 AM[414dd65b3d] [bot-action] [flow:SummarizeFlow] [node:Standard5] [card:"Extract and Log Company Data from Workflow Response"]: Error executing action "inline-card:"Extract and Log Company Data from Workflow Response".js" in flow:SummarizeFlow:node:Standard5
[Error, "[object Object]" is not valid JSON
Transpiled Code:
003 async function __ROOT__() {
004 var __defProp = Object.defineProperty;
005 var __name = (target, value) => __defProp(target, "name", {
006 value,
007 configurable: true
008 });
009 async function __ROOT__() {
> 010 const fetchCompanyData = JSON.parse(workflow.fetchCompanyData.response.data);
^^^^^^^^^^
011 console.log("fetchCompanyData: ", fetchCompanyData);
012 workflow.responseData = fetchCompanyData.choices[0].content;
013 }
014 __name(__ROOT__, "__ROOT__");
015 ;
> 016 return await __ROOT__();
^^^^^^^^^^
017 ;
> 018 }; return await __ROOT__();
^^^^^^^^^^
]white-mechanic-95574
03/01/2025, 3:37 AMwhite-mechanic-95574
03/05/2025, 3:16 AMwhite-nest-40686
03/05/2025, 5:30 AMwhite-mechanic-95574
03/07/2025, 4:01 AMwhite-nest-40686
03/07/2025, 7:13 AMwhite-mechanic-95574
03/08/2025, 5:14 PMwhite-nest-40686
03/15/2025, 11:22 PMworkflow.fetchCompanyData.response.data contains the response of axios call to your API then it has not choices because these are in workflow.sessionSummary
I think you must pass workflow.fetchCompanyData.response.data to Generte content without JSON.parse() and after generation text get workflow.sessionSummary.choices[0].content