Forum Discussion
Hi adithyaram93
Im responding to this cos no one else has - but it's been quite a while since I attached a file to a REST request in ReadyAPI! - but I do remember itgave me a headache!
The error you're getting quite often occurs when the endpoint you're hitting doesn't like either the data (in the file) youre sending or it doesnt like the Content-Type header value on your request or both.
I know you said you need to attach a file to a REST request and so followed the youtube vid - but have you confirmed what Content-Type header value the listening endpoint is expecting? have you confirmed whether the header value is multipart/form-data or multipart/mixed (for attached files) or application/json for embedded files?
Your listening endpoint will be expecting a specific Content-Type header value and if you send the wrong one, you'll get the sort of error response you've been seeing.
Cheers,
rich