I try to set the content as "Binary", but getting error like this "The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received undefined"
Hey knight, sorry for the delay on this. As you mentioned, the new file button stores the file meta data separately from the file data itself. Stitching them together will avoid the "The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received undefined" error.
We are looking into this, and will update everyone when we have a solution.
for (let i = 0 ; i < fileButton1.files.length; i++) {
let x = { data: fileButton1.value[i],...fileButton1.files[i] }
ApiUploadFile.trigger({additionalScope: { i: i, d: x}})
}
}
return go()
I simplified my upload button and now it is working.
In the tutorial of @knight I see this POST URI storage/v1/<bucket>/<folder>/{{fileButton1.files[i].name}}?
This should be storage/v1/object/<bucket>/<folder>/{{fileButton1.files[i].name}}
The path "object" was missing.
The is optional btw.
I also removed the runQuerySingle or any other transformers.
Just place this in the Body > Form Data > File {{ fileButton1.value }}
No need to adjust this data. It just works like this.