https://discord.gg/botpress logo
Hello there, does anyone has some
# 💻developers
j
Hello there, does anyone has some experience with the FileAPI? I'm trying to run (copy/paste) the example from the documentation and getting and error const file = await client.createAndUploadFile({ name: 'test.txt', content: 'This is a test file', }) console.info("File url:", file.url) An error occured while running Execute Code card: client.createAndUploadFile is not a function
I'm Running the code from the web studio editor. Inside of "execute code" card
b
@jolly-businessperson-95032 did you enable the BP client from your chatbot settings?
the gear icon in the left-hand menu
j
yup
does the example above works for you?
b
I'm running into an error with this code but not the same one
stupid question - after enabling the client - did you refresh?
if so, can you try deleting the execute code card and creating a fresh one?
j
I've been stuck with this for 2 or 3 days. I can retry whatever is necesary. I'll reload the browser, re-create the node, and run //state/reset
b
then try in a new workflow/bot/workspace, if needed
j
same results 😦
I'll create a new workflow soon
b
hmm
j
2 Views