I am trying to find out if it is possible to decode the Azure access token in IRIS. Has anyone ever tried this before? I need to decode the token to extract the "Scope" details in order to verify the scope to make sure client is permitted to do the request they have done.

If you could point me to any information, that'd be great. 

Thank you.



0 7 54
Hello! I have a question how to parse Library.ListOfObjects to JSON

I send post data like this from client using rest and want parse "templates", after save "codeForm","codeName" in database

    "whoIs": "",
    "templates": [{
            "codeForm": "FORM_FIOGROUP",
            "codeName": "operationDate",
            "orderNumber": "1",
            "codeFormat": "YYYY-MM-DD",
            "header": "DATE",
            "dbfFormatType": "Date",
            "dbfFormatLength": "8",
            "valueFrom": "Payment"
        }, {
            "codeForm": "FORM_FIOGROUP",
0 4 70


I am creating an import tool to convert a client's JSON data into IRIS classes.   The sample file is over half a gig.   I am copying the data into an instance of %Stream.FileCharacter;.    My first few attempts worked fine.   However I started getting an error thrown when I try to create a DynamicAbstractObject using the  %FromJSON method.     See the code below.   The error code given is not in the documentation, at least not the doc that I was searching.   

0 3 98

I had a challenge recently where I was asked to parse and iterate JSON to find a patient that has a forename = "Bill" and try to make the function that iterates through the code re-usable.

Being working in Healthcare there isn't much experience or demand for parsing JSON, as most of my work is HL7.

I took this on using the documentation and worked out a way to parse the JSON (see posts below for code and source data).

0 6 104
Chris Stewart · Feb 18, 2021 2m read
Basic JSON Compare

Hi Dev Community

I thought i would share a little method I knocked together to traverse and compare 2 JSON objects for basic equivilance.   I'm currently working on some data migration, and wanted a basic sanity check to validate that the JSON output is basically equivliant between the old and new, excluding a few things like timestamps.  

It's a basic little recurvsive method, that will bubble up any differences over a nested structure.   It's very low tech, as that's all I need it to do, but I thought it might be useful for others?

0 5 150

Hello fellow community members,

I would like to offer my services as an Intersystems Professional and am available to work on projects. 

I have more than a decade experience into  Intersystems stack of technologies including IRIS, Ensemble, Healthshare, Healthconnect, Cache Objectscript, Mumps, Zen, Analytics etc. with companies spread over US and UK  involved in multiple domains.

0 0 120
Mike Yackanich · Jan 11, 2021
How to use HS.JSON.Path

Has anyone used the ##class(HS.JSON.Path).%Evaluate() classmethod interrogate JSON and return a specific object value? I need to extract the MessageHeader.destination.endpoint value from a FHIR bundle and can't seem to get that XPath-like method to work.

0 2 59

There are couple of options to do this.

1. You can extend your class &JSON.Adaptor, it will do it for you with inbuilt logicaldtodisplay methods

2. Create another request class and do your transformations

3. Before calling the json convert to stream methods, transform the object's field with a ZDT.



I have an extremely simple example where there is a class with 3 properties

0 1 111


We are working with a vendor who only accepts JSON as payload. We are currently still on Cache/HealthShare, not IRIS. Since we have to send Continuity of Care Documents, this raises issues with Long Strings (some CCDs can be quite large and in addition to that, they have to be b64-encoded which increases their size even more).

My question is: if we were to go on IRIS and use %JSON.Adapter, storing the encoded Stream in an object's Stream property, would calling %JSONExport() on this object produce the desired JSON? Or would we have to call %JSONExportToStream()?

0 3 154

QEWD is assumed by most people to only integrate with IRIS (or Cache) via a connection through IRIS's high-performance C interface.  This requires QEWD (and its Node.js environment) to be installed and configured on the same machine as IRIS.

I'm frequently asked if QEWD can run on a separate server (or servers), and access IRIS (or Cache) over a network connection.  The answer is yes it can, but the information on how to set it up in this way has been admittedly a bit tricky to discover.

0 0 68

What is the best way to create an HL7 message from JSON input file?

We have JSON file available with data required for building the HL7 message . I am trying to use a standard file/FTP Business service to pick up the file and convert the input %FileCharacterStream into a dynamic Object and use the stand JSON features to read /process the data and build the HL7 message. 

Is there any other better way to do this? or any standard built-in functionality available in HealthShare? 

Thanks you for your help


0 2 147
Sabit Issakhan · Nov 26, 2020
Set null


How to set null in variable? 

I need to create JSON like below:



"Code": null



0 3 120

Hey Intersystems Community,

I have a Problem with the Session Handling in .csp.

I wrote all my Web Services in .csp-Pages and do the work for example in the OnPreHttp Method for to get some data.

After that the Web Service response is in JSON.

I call These Web Services via fetch in my react Single Page application, also Many request parallel. The react App is Rolled out as index.html.
Everything Works Fine with the session Handling via Cookie.

0 3 127

Let's imagine if you would like to write some real web application, for instance, some simple clone of medium.com. Such sort of application can be written using any different language on the backend side, or with any framework on the frontend side. So many ways to do the same application, and you can look at this project. Which offers a bunch of frontends and backends realizations for exactly the same application. And you can easily mix them, any chosen frontend should work with any backend.

Let me introduce the same application realization for InterSystems IRIS on a backend side.

0 0 245

Doing a new project with %JSON.Adaptor, unexpectedly realized that %JSON.Adaptor does not support export to native JSON. %JSONExport just outputs directly to the current device, and there are two more methods %JSONExportToString, and %JSONExportToStream.

In conjunction with generating REST from swagger specification, where any generated method accepts as a result %DynamicObject, which is good. 

I have multiple places in my REST where I have to return JSON for an object, but I have to modify the result a bit, just extend it with some other way.

1 6 222

Hello Intersystems-Community,

I build an API and there I use $order to get the Data from my Globals.
When I first time use that API it's get an error (504 Gateway-Timout > 60 Sec.).

After 2 reloads it works with a loading time of 2 Sec.! Sounds for me like the $order is cached and it works faster. Is it true $order will be cached?

When it works, I only get the error at the next day. So it's very hard to reproduce that error. Is it possible to delete the cache for $order?



0 8 174


How do I generate JSON strings instead of integers, as follows:

{ "MyProperty":"1"}

all we seem to be able to generate is 

{ "MyProperty":1}

Its for an api that requires the former and as the former is valid JSON I'm surprised I am having so much trouble.

(Obviously I'm new, please be kind :D

0 7 179
This is a coding example working on Caché 2018.1.3 and IRIS 2020.2 
It will not be kept in sync with new versions 
It is also NOT serviced by InterSystems Support !

This  an example of a customized SystemFunction extension (ZZISJSON) in Caché & IRIS
This time it is  to be included in %ZLANGF00.mac

A JSON string is mostly imported from a file or over REST.
You rely on a clean and compatible structure. This is the check.

0 0 206