Forum Discussion

Joydeep's avatar
Joydeep
New Contributor
5 years ago

Trying to send a file , not an attachment, using REST API call, the api accepts a filestream object

The File is PDF file, Programatically the Body wil look like this  body = [file:FileObj, name:'file']   The test step looks like this [Soap help 1.png]   The same step in postman can be done a...
  • richie's avatar
    5 years ago
    Hi Joydeep,

    I had a similar issue about 6 months ago where i use the form-data type in Postman and used the equivalent in ReadyAPI! and i remember it being quite fiddly to get it to work.

    I'll have to dig the post i submitted out, but in the meantime if you look at your screenshots, we cant actually determine anything from the detail youve provided which could help diagnose the issue.

    Consider the postman pic....youve blanked the full URI, not just the server. We would need to know all the uri/template and query parameters as well as headers before we could really help. From a security perspective as long as you dont supply the auth details along with the servername....thats all you need to hide, but (depending on the issue and especially this formdata issue) we'd need to understand the full URI (so full URL excepting the server).

    Whilst i find the post (that explains what i was doing wrong) i raised and until you give us a bit more info, i think i remember setting up the formdata parms as query parms in ReadyAPI! and i think i used the 'Post Querystring' checkbox.....but i'm stretching my memory a bit here!

    Cheers,

    Rich