Umbraco 13.3.2 : Umbraco Api Controller error 500 while using custom routes
Hello everyone,
I am encountering an issue while using custom routes with UmbracoApiController.
This is an example of my code:
[Route("api/version")]
public class ExampleController: UmbracoApiController
{
[HttpGet]
public object GetExampleVersionInfo() => Content($"ModelVersion: {GetModelVersion()});
}
I currently solved this by using SurfaceControllers but it is not ideal in my opinion.
I wanted to ask you if this is an issue related to UmbracoApiControllers or I am missing something.
Thank you in advance
Umbraco 13.3.2 : Umbraco Api Controller error 500 while using custom routes
Hello everyone, I am encountering an issue while using custom routes with UmbracoApiController. This is an example of my code:
I currently solved this by using SurfaceControllers but it is not ideal in my opinion. I wanted to ask you if this is an issue related to UmbracoApiControllers or I am missing something. Thank you in advance
I'm not sure what GetModelVersion does, but you are missing a double quote at the end of GetExampleVersionInfo.
Should be more like this perhaps?
is working on a reply...