Insomnia upload pic and post data at same time

Viewed 24151

I'm having problem posting binary data and regular data at the same time.

How I can test it with Insomnia? Insomnia offers only URL Encoded for data and Binary File for file. I cannot send both at the same time.

What should I do to test uploading data and binary file at the same time with one request?

2 Answers

you could use multipart form from insomnia with this you could send data and file at the same request

enter image description here

  1. Choose Multipart Form enter image description here

  2. Enter the name of the param (ex. image) and for the value, at the end you have a dropdown, choose File enter image description here

BONUS:

If you want to upload multiple files, you just need to put the same name of the param. enter image description here

Related