Where are Flow Action Inputs stored

Mark Roethof
Tera Patron
Tera Patron

Hi there,

 

Any idea in which table Flow Action Input values are stored?

 

For example:

 

MarkRoethof_1-1742899258472.png

 

So where are these values stored?

 

And yes I already saw https://www.servicenow.com/community/workflow-automation-forum/where-the-flow-designer-s-action-inpu... which does not help.

 

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

1 ACCEPTED SOLUTION

Mark Roethof
Tera Patron
Tera Patron

I thought it used to be visible, sys_variable_value or something, though somehow this changed. It's now stored in sys_hub_action_instance_v2 in the values field. Unfortunately though... that field is somehow encoded or whatever, at least not human readable 🙄

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

View solution in original post

6 REPLIES 6

Mark Roethof
Tera Patron
Tera Patron

I thought it used to be visible, sys_variable_value or something, though somehow this changed. It's now stored in sys_hub_action_instance_v2 in the values field. Unfortunately though... that field is somehow encoded or whatever, at least not human readable 🙄

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

Robert J_
Tera Contributor

This data is stored in the table you mentioned.

I use this function to decode the data in the field values:

var gr = new GlideRecord('sys_hub_action_instance_v2');
gr.queryNoDomain();
while (gr.next()) {

var json_string_subflowInputValues = JSON.parse(decompress(gr.values));
json_string_subflowInputValues.forEach(function(element) {
if (gr.action_type.name == 'Create Catalog Task' && element.name == 'ah_fields') {
....
..
}
if (gr.action_type.name == 'Ask For Approval' && element.name == 'approval_conditions') {
...
..
}
}
}
function decompress(value) {
var encoded = value.substring(this.compressed_header.length, value.length);
var cs = GlideStringUtil.base64DecodeAsBytes(encoded);
return String(GlideCompressionUtil.expandToString(cs));
}