# Json Custom Parsing Assist

**URL:** <https://forum.inductiveautomation.com/t/json-custom-parsing-assist/70006>\
**Category:** Ignition\
**Tags:** scripting\
**Created:** [February 17, 2023, 3:31pm UTC](https://forum.inductiveautomation.com/t/json-custom-parsing-assist/70006 "2023-02-17T15:31:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Frantz\_Miles](https://avatars.discourse-cdn.com/v4/letter/f/898d66/32.png) [@Frantz\_Miles](https://forum.inductiveautomation.com/u/Frantz_Miles)\
**Post date:** [February 17, 2023, 3:31pm UTC](https://forum.inductiveautomation.com/t/json-custom-parsing-assist/70006/1 "2023-02-17T15:31:05Z")

</div>

Hi There,

I need some guidance as to whether the following is even possible. - We have a system where we get the following JSON message:  
{  
"type" : "DeviceCommand",  
"sessionId" : "86a624c5-fa85-4e82-8c5b-0c09774139a3",  
"controllerId" : "PLC\_NAME",  
"devices" : [ {  
"moduleType" : "Custom",  
"deviceId" : "g\_ASOUTBOUNDPORT220READY",  
"command" : ""  
} ]  
}

The INTENT of the message is to request the current value of "g\_ASOUTBOUNDPORT220READY" from "PLC\_NAME" (which can be any of a number of PLC's connected to Ignition)

The EXPECTED response message we need to generate SHOULD look like:  
{  
"type" : "DeviceStatus",  
"sessionId" : "86a624c5-fa85-4e82-8c5b-0c09774139a3",  
"controllerId" : "PLC\_NAME",  
"devices" : [ {  
"moduleType" : "Custom",  
"deviceId" : "g\_ASOUTBOUNDPORT220READY",  
"command" : "TRUE"  
} ]  
}

Thank You for any feedback

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [February 17, 2023, 3:35pm UTC](https://forum.inductiveautomation.com/t/json-custom-parsing-assist/70006/2 "2023-02-17T15:35:55Z")

</div>

> [@Frantz\_Miles](#):
>
> we get the following JSON message

How is this message delivered? Are you using the WebDev module to handle an incoming API request? WebDev will handle json for you, converting to/from jython dictionaries and lists.

---

<div class="post-metadata">

**Author:** ![Frantz\_Miles](https://avatars.discourse-cdn.com/v4/letter/f/898d66/32.png) [@Frantz\_Miles](https://forum.inductiveautomation.com/u/Frantz_Miles)\
**Post date:** [March 13, 2023, 3:52pm UTC](https://forum.inductiveautomation.com/t/json-custom-parsing-assist/70006/3 "2023-03-13T15:52:29Z")

</div>

Hi Phil,

We were actually doing this using CirrusLink MQTT and connection to an AMQ (Apache) server that acts like the broker. So the "interfacing" was done via that. - THere was some scripting around "message received / populate response / send the response" items.

However we have since started looking at the WebDev module (still learning) and are busy exploring this. - We are at this moment still thinking to "subscribe" to the AMQ topics and process replies to the relevant "return topic".
