dotnet / WatsonWebserver

Watson is the fastest, easiest way to build scalable RESTful web servers and services in C#.
MIT License
406 stars 83 forks source link

Dynamic file destinations? #18

Closed dbuzz111 closed 5 years ago

dbuzz111 commented 5 years ago

Hi JChristn,

I was wondering if there is a way to have dynamic file routes? For example we generate a package using $filename.$epoch.zip (profile.1553088047.zip) This file typically only exists for a short period of time etc.

Any suggestions on how to make a route like this?

Thank you ever so much!

jchristn commented 5 years ago

Hi @dbuzz111 if you are only planning to use GET, you can use content routes. .AddContentRoute("/html/", true); will expose an entire directory, making it available for GET requests. Would that work for your use case? Cheers!

jchristn commented 5 years ago

Hi @dbuzz111 please re-open the issue if needed. Assuming this will meet your need. Thanks