I need to create a simple REST application.
I`ve created an app:.png)
Also here is a dispatcher class:
Class Lab3.helloWorld Extends %CSP.REST
{
Parameter Authentication = 0;
Parameter HandleCorsRequest = 0;
XData UrlMap [ XMLNamespace = "https://www.intersystems.com/urlmap" ]
{
<Routes>
<Route Url="/hello" Method="GET" Call="Hello" />
</Routes>
}
ClassMethod Hello() As %Status
{
Do ##class(%REST.Impl).%SetContentType("application/json")
If '##class(%REST.Impl).%CheckAccepts("application/json") Do ##class(%REST.Impl).%ReportRESTError(.(1).jpg)
(2).jpg)

.jpg)


