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.
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.
I am writing an API that sends over a very large JSON object.
The code I'm using to get the data is actually used in our production system today for the use of writing a report.
However when I call the code using the API (using SoapUI) I am getting 'Error getting response; java.net.SocketTimeoutException: Read timed out'
The web applications settings have a session timeout setting at 15 minutes, but this is timing out within just a few minutes, so I know it's not hitting this mark.
I am looking for an implementation strategy to create/update organizations in a local ISC based FHIR server. Thoase organizations do have a certain dependancy to one another. For Organization resources the "partOf" property symbolizes that. It is planned, that a Interoperability Production (supporting FHIR Server) receives a bundle which contains a batch export of all organizations of a customer (Hospital). The task is to bring those data into the FHIR server create and/or update organization.
How to clone dynamic objects more efficiently than using a serialization/desserialization approach (eg. Set objectB = {}.%FromJSON(objectA.%ToJSON()) ) ?
Why %DynamicObject could not extend %RegisteredObject and its %ConstructClone method (if not inherit it)?
As it says in documentation %ZEN.Auxiliary.jsonProvider been deprecated. We been using it's functions like %ConvertJSONToObject, WriteJSONFromObject etc. Is there any replacement?
I want to call the REST endpoint and return the list of objects. I`ve created the method but it displays an error: <METHOD DOES NOT EXIST>GetAllPersons+10^Lab3.RestClient.1 *Count,%ZEN.proxyObject
I'm trying to make a REST API call in JSON format. When using the example in the class reference documentation the getJSON method in the %Net.Http class throws the error <METHOD DOES NOT EXIST> on a %Clone() method in the %LIbrary.DynamicObject class. I even changed the parameter to a JSON string to no avail. The code will then fail on the %Compose method (examples below). My workaround is to use the %Net.HttpRequest functionality. Is there another workaround to this?
Class pbarton.test Extends (%RegisteredObject, %JSON.Adaptor)
{
Property Version As %String;
}
The Version property could be either a string or a number in the JSON source data. If it's a string, importing it will succeed. If it's a number, importing fails.
I am playing around with trying to make an Epic REST API call from an operation, and from what I understood because the request has to be sent as POST, I need to send the request as JSON. However when I try taking the request and running %ToJSON against it for the payload to be created I am getting an error...
I've extended the a class %JSON.Adaptor in my class definition and it contains the xData block MimeType of application/json. I got the error while compiling. Why this error occurs and how to resolve it
Thank you very much for reading the doubt and above all thank you very much for answering.
Given the following use case:
If we have a Destination Service that through a HTTP GET by REST gives us a certain JSON response, where it should be noted that it is a list of objects where each object in the list does NOT have a key:
We recently had an issue where we weren't able to parse a JSON HTTP request, but the issue went by unnoticed. We also did not have a trace of what the raw HTTP request was that we couldn't parse. I'm looking at improving our this by: Tracing the raw request using $$$TRACE
Raising an alert which will hit our Ens.Alert router which will compose and send an email
I have created a FHIR endpoint and send the FHIR resource to FHIR Interoperability production class which is HS.FHIRServer.Interop.Service through the the created endpoint(/r4). I can able to see/get the HS.SDA3.QuickStream(It use CacheTemp.HS.Stream temporary global) on the fly(In between the process). I'm unable to get the FHIR resource from the QuickStream once the process completed. Is this HS.SDA3.QuickStream is wiped out from the system once process completed?
Hi all, I am trying to compile my swagger class file with swagger JSON which is a valid JSON as I created it and verified from swagger.io 2.0 spec. But getting below error. I am not very clear with the error message. Please help me resolve the same.
ObjectScript error: <CLASS DOES NOT EXIST>removeprj+7^%occClass *SwaggerClass
> ERROR #5091: An error has occurred while removing projection SwaggerClass:Reference.
> ERROR #5030: An error occurred while compiling class 'SwaggerClass'
I have an issue where a Windows Reserved word, in my case CON, is causing an error when used as part of a JSON Get operation. In this case CON is the user identifier (the full identifier is CON.SURNAME) of a person and I am trying to read the employee record using a web service provided by the payroll system.
Is there a way I can get around this, some sort of encoding that would enable the inclusion of this identifier. I can't just change the identifier has it is used extensively across systems.