I want my controllers in the omod to return json, how can I best do it.
You could take a look at these examples: https://github.com/openmrs/openmrs-module-appframework/blob/230081bd2875e14bb936b9d86c1227118caebeea/omod/src/main/java/org/openmrs/module/appframework/web/AppFrameworkController.java
Thank you @dkayiwa But when i try to access the url, it gives me this error
A user context must first be passed to setUserContext()…use Context.openSession() (and closeSession() to prevent memory leaks!) I have tried open the session by using Context.openSession(), but still throws me the same error