Troubleshooting Empty Array Display but displayed ...
# 🤝help
h
I'm working on adding a feature to a chatbot that displays available slots at a barbershop. Initially, I tried displaying these slots using a single choice element, but that approach was unsuccessful. Now, I'm fetching the slots from an API and storing them in an array called
workflow.slots
. While the results are visible in the console, they don't appear in the chat interface—instead, I just see "Available Slots[]", indicating the array is empty at the time of display. I've attempted to manage the asynchronous nature of the API call with
await
, but I was not successful. Can you help me troubleshoot why the array might be empty in the chat, even though it populates correctly in the console? Attached you can find my console log, my code and an overview of the chatbot flow. https://cdn.discordapp.com/attachments/1236381882560675901/1236381883651195011/Chatbotflow.png?ex=6637cddb&is=66367c5b&hm=b3aa08243fdcf43bc2ee2bef6f446c46b6c5d508dc7fc889d3b875bf3096ef2b&