Since you are in the Product-context, it isn't purely REST (Can be a hot topic ;) ) to do GetAllProducts. Just change it to Get(). Otherwise you would have to do some custom routing (unless Umbraco does something special for you here...).
Never mind, it seems like Umbraco has setup some routing to do this...
Web API - routing not working
Umbraco v6.1
I've created the following controller, but when accessing http://domain/Umbraco/Api/GetAllProducts I just get a 404.
Any idea what I'm doing wrong?
hello Michael
hmm i think your missing the controller name :)
like /Umbraco/Api/[YourControllerName]/[Method]
Hi Kasper.
I think I've tried all possible combinations... can't get anything else than an 404 error... :o/
hello Agien :)
have you tried to see what the URL is ? :)
Hello,
I had the same problem, turns out you need to include the "Api" part of your controller.
So the Url would be ~/Umbraco/Api/ProductsApi/GetAllProducts
Also it seems you can't use the RESTful setup because it doesn't support the Get/Get(id) methods at the same time.
Since you are in the Product-context, it isn't purely REST (Can be a hot topic ;) ) to do GetAllProducts. Just change it to Get(). Otherwise you would have to do some custom routing (unless Umbraco does something special for you here...).
Never mind, it seems like Umbraco has setup some routing to do this...
is working on a reply...