- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-03-2016 08:37 AM
Hi All,
In REST integration, we are getting Response.getBody() with lots of fields and values respective to it. However, i would like to get some specific value from that Response.Could anyone please let me know how to get that? I tried with decode and Parse but still in log its displaying undefined.
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-03-2016 09:05 AM
Result does not appear to be an array. I'm reaching this as:
gs.log('Number=' + jsonObject.result.number);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-18-2018 05:22 AM
Its After Business rule
Yes its a typo from my end instead of copying complete rest Response, I typed only that combo
I'm able to see the summary successfully in log, but not able to set in the field 😞

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-18-2018 05:25 AM
If it's after, there's your issue. You are trying to update a field on the current record AFTER the system does the save to the record. It's a bit like holding out your train ticket after the train has left the station. You're not getting on that ride.
Instead, change it to a BEFORE business rule so you can get the value in to the current object, then the system does the save.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-18-2018 05:28 AM
Ohh WOw, that did the trick.
Now i caught right train 🙂
Thanks a lot

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-18-2018 05:34 AM
You are welcome. A common mistake. I'll cover it on today's community live stream.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-18-2018 05:14 AM
try this:
var jsonObject = JSON.parse(responseBody);
gs.info('Summary='+jsonObject.summary);
current.setValue('u_jira_sys_id',jsonObject.summary);