Hello. 

I'm trying to POST a JSON on an URL. 

But the body request arrive empty on the web service : 

[DEBUG] # 2022-05-05 15:04:32,966 # scopes founds : api
[DEBUG] # 2022-05-05 15:04:32,971 # PatientController:PostSignaletic object null

Here is the code, i tried a TONS of ways to do it but i'm still in trouble ... 

0 14
0 109

Given I have a property 

Class All.AllBooks Extends %Library.Persistent
{

Property ID As %Integer;

Property Title As User.Book;

}

 

In the class method

ClassMethod GetABookById(id As %Integer) As %Status
{

SET MyBooks = ##class(All.Allbooks).%OpenId(id)

SET obj = {

     "ID" : (MyBooks.%Id())

     "Title" : (MyBooks.Title)

}

WRITE obj.%ToJSON()

Quit 1
}

 

How do Access the foreign key in JSON() data

 

0 7
0 117