How do I return files from Web API?

Please follow the below steps to create the file transferrable Web API service.

  1. Download the attached project.
  2. Open Visual Studio and create New Web API project.
  3. Create Book folder at root level in the project.
  4. Add any sample pdf, word, excel, zip (name them as sample) files into it.

For More Information Please Refer: https://www.c-sharpcorner.com/article/sending-files-from-web-api/