Question

Rest sender multipart/form data

  • 14 October 2021
  • 6 replies
  • 270 views

Userlevel 2
Badge +6

Calling all IFS REST gurus…

Has anyone successfully sent multipart/form-data requests to REST endpoints using IFS standard functionality or do you need to go down the UTL_HTTP route to do this?  I seem to get parsing errors whenever i try to send the message using plsql_rest_sender_api.call_rest_endpoint2.


This topic has been closed for comments

6 replies

Userlevel 2
Badge +6

Hi Lijin

We got it working in the end using utl_http.write_raw but it was messy and took a lot of trial and error testing.  Getting the boundaries working properly is one of the most challenging bits of the process.

Regards

Chris

Userlevel 1
Badge +2

Hi @chriselliston ,

​Were you able to send the BLOB attachment to the REST endpoint?
We are also facing similar requirement. Kindly let us know if you have found any way to do this.

Thank You.
Regards,
Lijin

Userlevel 2
Badge +6

Hi Shehan

Have you got any examples?

I’ve got a simple text file working.

The blob is proving problematic though.  I’m converting to a base64 encoded clob and the file gets sent but is corrupt at the other end.

Regards

Chris

Userlevel 4
Badge +7

Hi @chriselliston,

 

I have sent a json as a blob. However if you need to send a attachment I believe that you should chunk it before send to the endpoint.

 

Best Regards

Sheha

Userlevel 2
Badge +6

Hi Shehan

Have you been able to pass a blob as an attachment in the multipart form-data request?

Regards

Chris

Userlevel 4
Badge +7

Hi @chriselliston,

 

I have done same program using UTL_HTTP. I believe that UTL_HTTP package is the most suitable one for this operation.

 

Best Regards

Shehan