Use Cases
Native Action Use Cases
Variables Use Case
4 min
variables support turbine orchestrators by allowing them to collect data, store it, and use it in downstream actions using the create variables and update variables native actions allows orchestrators to create and/or update variables without writing code, add the variable, and apply properties from the playbook scenario vanessa is an analyst who wants to use the get emails action in turbine to retrieve email data her co worker max has also created a playbook to get email results; however, max had more time and used jsonata in the transform data native action, under the advanced transformation feature, to get the results he wanted vanessa needs a faster, simpler way to get microsoft emails to pass downstream into her playbook using the create variables native action gives vanessa the ability to produce the same outcome, but easier and quicker steps vanessa starts by creating a minutely cron trigger in her playbook next, she visits the swimlane content page to use the microsoft graphapi get emails component for the fastest configuration tip the cron trigger helps automate the process, ensuring that the playbook runs at a set interval from the swimlane content home page, enter microsoft graphapi get emails into the search bar the component opens with an overview vanessa clicks the install button to start the import process the window displays a breakdown of the component's playbooks, connectors, and assets however, vanessa notices that she needs to import three connectors first microsoft graphapi, sos network activity events p1, and jsonata vanessa installs the necessary connectors and then creates the microsoft graph api asset next, she adds the get emails action to her playbook on the inputs tab of the get emails action, vanessa enters her email address in the outputs tab, she promotes the entire object result, allowing her to access all email data downstream in the playbook vanessa now needs to create variables to store specific parts of the email data she adds a new action in the success flow vanessa adds the create variables native action to the success flow and clicks configure she clicks add variable and selects object as the property type she names the object object header and then clicks the + icon to add a playbook property value she selects response headers from the get emails action output, as she wants to pass the header information along for later use vanessa clicks add variable again, selecting json body from the property drawer to store the email content this ensures that she captures both the header and body of the email for future actions vanessa realizes she needs to modify some of the variables to do this, she adds another success flow action, selecting update variables from the list of native actions clicking select variable to update , she chooses object header in the action window, she clicks the + icon and selects the get emails action again, this time choosing the date sub property from the response headers once satisfied, vanessa clicks apply to save the update she then adds a broadcast message action to her playbook, configuring it to send a message to a specific slack channel with the email results error handling vanessa also wants to ensure that if the email retrieval fails, an error message is logged, and her team is notified to do this, she adds an on failure action to her playbook add an on failure flow by clicking the plus icon on the get emails action select the log message action to log the failure details add a send message action to notify the team in slack of the error, including details of the failure for debugging conclusion her work is complete! the playbook executes by retrieving emails and forwarding the response header dates and json body from the retrieved emails to the slack channel she provided quick and easy, vanessa did not have to spend extra time entering complex json expressions to get the data she needed additionally, she ensured her playbook handles errors gracefully by logging and notifying her team in case of failures