Hi Robert, 

thank you for your response.

I'm not trying to do JSON mapping.

The XData in my first post is for validating forms server side. We generate methods based on this XData to check if each fields are correctly completed by users. According to this doc : https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cls..., we used JSON instead of XML in XData because is easier to parse.

So my XData block is not related to new JSON mapping in IRIS.

When I moved to IRIS, I try to use %JSON.Adaptor in our class instead of Daniel Kutac adaptor (https://github.com/dkutac/cache-json-regular-vs-dynamic-object) to bind/export objects in JSON

For exemple, this class : 

Class helora.worklist.RessourceType Extends (%Persistent, %JSON.Adaptor)
{
Property code As %String;
Property description As %String(MAXLEN = "");
Index codeIdx On code [ Unique ];
XData FormValidator [ MimeType = application/json ] {
{
 "code":  { "required": true }
}
}
}

Does not compile. 

So it looks like impossible to use JSON in XData when classe extends %JSON.Adaptor.

Here's what I got

-------------- System defaults for I/O tables -------------- 
Table               Name
-----------------   ---------------
Process             RAW
Cache Terminal      UTF8
Other terminal      UTF8
File                RAW
Magtape             RAW
TCP/IP              RAW
System call         RAW
Printer             RAW

Thank you