axios - same code in two different cards one work ...
# 🤝help
a
the card code was different, both content and url, in debuging made 2nd card the same. in the php script... // Retrieve the JSON payload from the POST request $input = file_get_contents('php://input'); // Decode the JSON payload $data = json_decode($input, true); 2nd time $input is null. execute cards... // Define the email content /// Define the email content const aContent = { Authorization: env.flyofficeKey, chatAction: 'bookingrequest', for: 'peter@xxxxxx.co.nz', date: '2024-05-26' } // Send the email using Axios const webhookUrl = 'http://xxxx.co.nz/chatbotxx/Chatbot.php' const response = await axios.post(webhookUrl, aContent) const result = response.data // Save the result to a variable or store it in the workflow or turn variables as needed workflow.webhookResult = result
a
Hey @adorable-area-26614 please send me a reportId @square-energy-41150
s
# Sending a Problem Report Here's how to send the Botpress Team a problem report: 1. In the Botpress Cloud Studio, locate the "Help" icon in the bottom left corner of the screen. 2. Click "Report a problem" and follow the steps on the screen. 3. Copy the Report ID to your clipboard and provide it to a member of the Botpress Team on Discord.
message has been deleted
a
Hi Ermek, I found the problem—it seems I somehow corrupted the card in the node. When I deleted the node and replaced it with a copy of one that was working successfully, everything burst into life. I think the corruption may have occurred when I cut and pasted text/script from a note app that automatically placed single quotation marks at the beginning and end of each line.
a
@adorable-area-26614 interesting. Thank you for letting us know
5 Views