Hello,
I'm currently working on replacing a curl script to make a call directly from the webmethods server integration.
the actual curl is :
-location 'https://monsite.fr/api/files/v1/sftp/etl/fichier' --form 'file=@'$fileName
I first retrieved my file in Bytes with the command "pub.file:getFile" then i use the "pub.client:http" service :
-url => "https://monsite.fr/api/files/v1/sftp/etl/fichier"
-method => "POST"
-loadAs => "bytes"
-data/bytes => object bytes (my file)
-headers/content-type => multipart/form-data
the result is : "{"timestamp":"2025-10-20","status":500,"error":"Internal Server Error","message":"Failed to parse multipart servlet request","path":"/files/v1/sftp/etl/fichier"}
it is same result if i let the value data/bytes empty, It's the same if i use stream, etc.
I'd like to know how to transmit my file so that it's properly processed.
I dont udnerstand how it works and how i am able to do the job.
Please Help me !
-------------------------------------------
------------------------------
Geoffrey MOULIN
------------------------------