Here is the code
const endpoint = "https://www.stack-inference.com/run_deployed_flow?flow_id=64b1aa0eeb1096a9b84e20ef&org=e55254da-2736-41bb-9549-798937b4a981";
const headers = {
Authorization: 'Bearer 769ecdad-dd21-48fe-988b-78e188440e34',
"Content-Type": "application/json"
};
const data = {
"in-0": workflow.questionaskedbyuser
};
try {
const response = await axios.post(endpoint, data, { headers });
workflow.ApiResponse = response.data["out-0"];
} catch (error) {
throw new Error(`stack-error: ${error}`);
}
I deployed stackai onto botpress, i was expecting an output from stackai so that i can use it in my botpress, but it's not sending me the output, either it's null or undefined.