For partners that build or integrate commercially available applications and service solutions with the Oracle Cloud Platform
For partners that provide implementation or managed services around Oracle Cloud Applications
What are the widgets available to upload the file from the local directory in VBCS? I could not find the option in drag and drop widgets pallet.
How to initiate the request of content-type multiform data from VBCS to OMC 19A, and send the file as form data parameter in the body of the request.
Can we also use the drop-down widget in VBCS, and how to add the additional widgets which are available in OJET but they are not available in VBCS.
Your suggestions would be a great help to me.
The first part of creating a file picker is covered in this article:
https://blogs.oracle.com/groundside/uploading-and-reading-a-text-file-in-visual-builder
Your use case then differs that rather than reading the file locally in JavaScript you want to pass the same file object to a REST endpoint. However, it would be the same file object that gets passed as the body of the POST request.
I am able upload file to VBCS and get the file object and print it. Sent the same in the rest request body but the body is not printed in logs.
However, the file object created by VBCS request when compared to postman request does not have file path parameter.
VBCS rest call fails
Please find attached screenshots.
I'll ping you internally to address this - it will just be a matter of getting the body payload set up correctly
Also have a look at https://docs.oracle.com/en/cloud/paas/app-builder-cloud/visual-builder-developer/call-rest-action.html. "If you have set "contentType" to "multipart/form-data", the Action will interpret your request "body" object as the form parts"
In the "Call Rest Action" you will need to set Content type = "multipart/form-data" . Also, if you simply map the filepicker selected file to filepath param in the "Call Rest action", it will be added as an additional form-data part with name "file".
Hi
Assigned the file object to filePath as well, ContentType equals multipart/form-data and fileType equals csv. Still, the rest request failed.
The first part of creating a file picker is covered in this article:
https://blogs.oracle.com/groundside/uploading-and-reading-a-text-file-in-visual-builder
Your use case then differs that rather than reading the file locally in JavaScript you want to pass the same file object to a REST endpoint. However, it would be the same file object that gets passed as the body of the POST request.