Flow Designer, Rest Step, Connection Alias

Daniel Peel
Mega Sage

It is possible yet, without code... to define a connection that supports DEV and PROD and at runtime, pick which it needs to run... 

 

I know I can do a 

gs.getProperty('instance_name')

and code the return to include that so I can pick the right connection alias... was just wondering what no-code way exists, if any, to define the connection... and perhaps some child aliases (I know these exist too, but can't call them without code, that I know of) to hold the different system connections... and have the action know which to pull based on the instance it was running on.  

currently in upgrade to UTAH so that's the target version for the question

2 REPLIES 2

Sandeep Rajput
Tera Patron
Tera Patron

@Daniel Peel You can choose to create a custom action in flow designer which may have all the connection string fed through a custom table/property, and based on the current instance URL it may choose to return a connection which suitable for that instance. This is going to be a one time effort for defining the action, once defined it can be used across different the instances and configurations related to connections can be handled via the custom table/property. 

I'm already building a custom action... you can not call an action from another action, nor know what other actions exist.  I'm building an action that will be a rest call using a imported OpenAPI file.  I would like the Action to be self contained... I built the credential and connection alias... and defining child alias that target different systems... it would be nice if I could define something the rest step could use that would look at the instance and pick the right one... so I wouldn't need to be build 2 different actions or script it... trying to make it more user friendly, less dev heavy... 

What you've described wouldn't solve the need of picking the correct connection inside the action... it would rely on and require the user to have knowledge of the other actions.  I would like someone to be able to pick this action, put it in a flow, pass the payload and have it do it's job of making the rest call... 

I know I can code it in... I'm just trying to ensure the clones and other changes don't cause the action to call the wrong system... I do this already in scripted rest apis I just wondered if I was missing some no scripted way to do that on the Rest Step configuration.