Reputation: 182
I have an azure function app (abc.azurewebsites.net) and have a function named Function1 defined in it. (abc.azurewebsites.net/api/Function1?code=def==)
Is there a way in which, I can define this Function1 as default and all the incoming requests to abc.azurewebsites.net gets routed to my Function1?
Thanks.
Upvotes: 0
Views: 507
Reputation: 14334
You could use proxy to get this.
Follow this tutorial, and the Route template
should be /
, and then you should change your function authLevel
to anonymous
like this.
1.Set the application setting add HELLO_HOST
(any parameter same as the backend url) with value <YourBackendApp>.azurewebsites.net
.
2.Create the proxy.
3.Set your function to anonymous
then your function don't need API keys code to call it.
Then below my test result, it's a HTTP trigger function with query string &name=<yourname>
.
Upvotes: 1