I think there are two things you need to investigate here. First, you need to parse your HTTP request, as represented by your Data variable. This is not in the format of a JSON string, though the body of the message may be. If your body is in JSON, then you need to extract it from the request using http.parseRequest. Check out this help page: https://help.interfaceware.com/v6/creating-web-services

I am assuming that you are embedding batch HL7 messages in a web service request. If that is the case, once you extract them, you need to split them up before applying the VMD to them through hl7.parse. Please refer to the documentation I linked to above to understand how to do that: https://help.interfaceware.com/v6/hl7-split-up-batch-file.

Please contact your account manager if you would like access to the Iguana training series.

Hope this helps.

Casey Trauer,
Director, Client Education