Hi, seeking help with creating JSON file within BE workflow. The goal is to get data from specific table in my DB and create a JSON file from it that I can then send in API request. API call is to OpenAI so I can store JSON file in Vector Stores.
Hey @filip.youneverwalkalo - do you know how to upload a file to your app using the API connector and base64?
If so, you can put this in a server side action (your JSON) and save it as a yourfile.json file in your app!
function stringToBase64(str) { return btoa(unescape(encodeURIComponent(str))); } let myString = {{your text input}}; let base64String = stringToBase64(myString); return base64String;
Good luck!
Note for anyone else out there, this can also create .txt files for LLMs