public static class GetCategoriesCRUDFunction
{
[FunctionName("CategoriesFunction")]
public static async Task<HttpResponseMessage> Run([HttpTrigger(AuthorizationLevel.Function, "get", Route = "{website}")]HttpRequestMessage request, TraceWriter log) // is this how to set up a route or do I need to do attribute routing?
{
IService service = new Service();
var categories = await service.GetCategories(website); // how do I get this website parameter from the querystring - do I need to use something like httpcontext?
return request.CreateResponse(HttpStatusCode.OK, categories);
}
}