
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-03-2023 09:13 AM - edited 08-03-2023 09:15 AM
ver. Tokyo
Hello, I'm currently wrestling with extracting values from a complex object within a subflow. Using Jira Spoke, and a webhook setup, when a JIRA issue is updated the data from that update is being pushed (integration) to our SN instance. It's a relatively straightforward JSON object value extraction operation. Until I ran into a couple Array.Objects in the data.
In the JSON this is what I see:
jira:issue_updated{
"timestamp": 1691044740524,
"webhookEvent": "theHook",
"issue_event_type_name": "issue_updated",
"user": {
"self": "https://some.url.com",
"name": "Bob",
"key": "bob",
"emailAddress": "bob@some.org",
"active": true,
"timeZone": "America/West"
},
"issue": {
"id": "15525",
"self": "self",
"key": "123456",
"fields": {
"customfield_10630": null,
"customfield_10510": null,
"customfield_10631": null,
"customfield_12800": null,
"customfield_11700": {
"self": "https://some.url.com/rest/api/2/customFieldOption/13600",
"value": "Consolidated",
"id": "13600",
"disabled": false
},
"fixVersions": [
{
"self": "https://some.url.com/",
"id": "22",
"description": "RWR",
"name": "RWR",
"archived": false,
"released": false
}
],
~
~
~
}
}
}
The subflow inputs for the array.object is like so:
The data pill view:
The update record view:
The functions added to the variable:
The runtime value:
u_release=[unnamed]
I've tried various methods to pull this value but none have worked thus far. If anyone else has experience with this some insight would be greatly appreciated.
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-05-2023 10:57 AM
Ok, here's what worked for me. I decided to create a Flow Action to process the JSON payload in an attempt to extract that value from the Array.Object in question.
// Used as a workaround to the Flow/Array.Object value extraction issue we ran into
// inputs: the JSON payload
// JSON Parser step: use the JSON payload to Generate Target
/** Script step **/
// Input Variables
// Name | Value
// - fixedversion: step 1 > root > issue > fields > fixVersions (Array.Object)
// - payload: Inputs > payload
// Script
function execute(inputs, outputs) {
var parsedJSON = JSON.parse(inputs.payload)
var parsedJSONFix = parsedJSON.issue.fields.fixVersions;
outputs.fixver = parsedJSONFix[0].name.toString();
})(inputs, outputs);
// Output Variables
// - fixver | fixver | String
// Outputs
// IssueID > 1 - JSON Parser step > root > issue > id
// IssueType > 1 - JSON Parser step > root > issue > fields > name
// Release > 2 - Script step > fixver (Our extracted Array.Object value)
// ccbstatus > 1 - JSON Parser step > root > issue > fields > customfield_10120
// expedite status > 1 - JSON Parser step > root > issue > fields > customfield_12002 > value
// link > 1 - JSON Parser step > root > self
// Minor Version > 1 - JSON Parser step > root > issue > fields > customfield_10104
// Description > 1 - JSON Parser step > root > issue > fields > summary
// Orig Behavior > 1 - JSON Parser step > root > issue > fields > customfield_10161
// New Behavior > 1 - JSON Parser step > root > issue > fields > customfield_10162
// FixVersion > 2 - Script step > fixver (Our extracted Array.Object value)
Parse the JSON object to get a JS object.
Descend into the object to find our Array.Object.
Dot walk to our needed value.
Output that value.
And there you go. Your mileage may vary.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-05-2023 10:57 AM
Ok, here's what worked for me. I decided to create a Flow Action to process the JSON payload in an attempt to extract that value from the Array.Object in question.
// Used as a workaround to the Flow/Array.Object value extraction issue we ran into
// inputs: the JSON payload
// JSON Parser step: use the JSON payload to Generate Target
/** Script step **/
// Input Variables
// Name | Value
// - fixedversion: step 1 > root > issue > fields > fixVersions (Array.Object)
// - payload: Inputs > payload
// Script
function execute(inputs, outputs) {
var parsedJSON = JSON.parse(inputs.payload)
var parsedJSONFix = parsedJSON.issue.fields.fixVersions;
outputs.fixver = parsedJSONFix[0].name.toString();
})(inputs, outputs);
// Output Variables
// - fixver | fixver | String
// Outputs
// IssueID > 1 - JSON Parser step > root > issue > id
// IssueType > 1 - JSON Parser step > root > issue > fields > name
// Release > 2 - Script step > fixver (Our extracted Array.Object value)
// ccbstatus > 1 - JSON Parser step > root > issue > fields > customfield_10120
// expedite status > 1 - JSON Parser step > root > issue > fields > customfield_12002 > value
// link > 1 - JSON Parser step > root > self
// Minor Version > 1 - JSON Parser step > root > issue > fields > customfield_10104
// Description > 1 - JSON Parser step > root > issue > fields > summary
// Orig Behavior > 1 - JSON Parser step > root > issue > fields > customfield_10161
// New Behavior > 1 - JSON Parser step > root > issue > fields > customfield_10162
// FixVersion > 2 - Script step > fixver (Our extracted Array.Object value)
Parse the JSON object to get a JS object.
Descend into the object to find our Array.Object.
Dot walk to our needed value.
Output that value.
And there you go. Your mileage may vary.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 09:24 PM - edited 05-22-2025 09:39 PM
This is a perfect example showing how poor Flow Design is. Imagine implementing a code-less application approach and intentionally leaving out, which should of been the very first thing to consider, was the passing of objects between flows, subflows and actions. Cleary showing that whoever was making technical design decisions behind Flow designer, was not a good developer and has cause nothing but PAIN for actual seasoned developers.
Or was it their intention to force actual proper developers out of the SN platform?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2024 01:33 PM
Hoping you can help me... I am trying to retrieve the fix version from the jira issue into a new field I created on the task.
I have followed your steps about the Flow Action:
Here's my action:
If this is correct above what do I need to do in my webhook to get the fix version into the task