Workflow Examples

In this section, sample workflows have been explained that can aid you in getting started quickly and becoming more efficient.

Search tweets by keywords and post it on Slack

This workflow searches your Twitter tweets using specified keywords or # tags and sends them to a specific Slack channel.

To set up this integration, you will need to use the following:

Add and configure Twitter - Search Tweets action

  1. Add Twitter connector to the canvas and connect it to the Start icon.

  2. Next, double-click the Twitter connector icon, select the Search Tweets action from the Select Action drop down list, and select the Twitter account you want to use to execute the action.

  3. Once this is done, click Next.

  4. In the configuration page that appears, enter values for the input fields as per the instructions given below:

    • Search Keyword: Enter the keyword by which you want to search the tweets.

    • Count: Specify the maximum number of results you want to retrieve per page. The default value of this field is 15.

    Once you have entered all the details, click on Next, Test the action, and click Done. This will take you back to the canvas.

Add and configure Slack - chatPostMessage action

  1. Add Slack connector to your canvas, and connect it with the previous action.

  2. Next, double-click the Slack connector icon, select the chatPostMessage action from the Select Action drop down list, and select the Slack account you want to use to execute the action.

    Once this is done, click Next .

  3. Configure this action and enter a value in the fields as per the instructions given below:

    • channel: Enter the ID of the channel on which you want to post the message.

    • text: Add the output key, say {{$a6.statuses[0].text}} , listed under the array output on the left-side of the configuration window as an input for this field.

  4. Once you have entered all the details, click on Next, Test the action, and click Done to return to the canvas. Connect this action to the Stop icon and SAVE the action.

    Now, whenever you execute this workflow, it will search Twitter for the tweets containing specified hashtags and will post the tweets matching the criteria on the specified Slack channel.

Get a note from Evernote and email it using Gmail

This workflow retrieves a note from Evernote and sends its details (title and content) to a recipient using Gmail. To set up this workflow, you will need to use:

Add and configure Evernote - Get Note action

  1. Add Evernote connector to the canvas and connect it to the Start icon

  2. Next, double-click the Evernote connector icon, select the Get Note action from the Select Action drop down list, and select the Evernote account you want to use to execute the action.

  3. Once this is done, click Next.

  4. In the action configuration form that appears next, provide the details as given below:

    • Notebook ID: Select/specify the ID of the notebook from which you want to retrieve the note.

    • Note ID: Select the ID of the note from which you want to retrieve the note.

    • Include Content: Specify if you want to include the note content details along with the note. By default the value for this field is set to ‘true’.

    • Include Resources Recognition: Specify if you want to include resource recognition details along with the note. By default the value for this field is set to ‘true’.

    • Include Resources Alternative Data: Specify if you want to include resource alternative data along with the note. By default the value for this field is set to ‘true’.

  5. Once you have entered these details, click the Next button, Test the application, and click the Done button. This will take you back to the canvas.

Add and configure Gmail - Send an Email action

  1. Add Gmail connector to the canvas and connect it to the previous action.

  2. Next, double-click the Gmail connector icon, select the Send an Email action from the Select Action drop down list, and select the Gmail account you want to use to execute the action.

    Once this is done, click Next.

    In the action configuration form that appears next, provide the details as given below:

    • To: Enter the email ID of the recipient you want to send the shortened URL to. You can also add multiple email IDs by using a comma separator or a new line separator.

    • Cc: Enter the recipient’s email address if you want to send them a copy of the mail.

    • Bcc: Enter the recipient’s email address whom you want to send a blind copy of this mail.

    • Subject: Enter a suitable subject for the email.

    • Body: Add the output key, say {{$a7.url}}, available under Shorten URL output on the left-side of the configuration window as an input for this field.

    Once you have entered all the details, click the Next button, Test the action, and click the Done button to return to the canvas. Connect this action to the Stop icon and Save the workflow.

    This workflow will fetch you the specified note and send the contents of the note to the specified recipient(s) in an email using Gmail.

Shorten URL and send it using Gmail

This workflow shortens a long URL with Google shortener and sends it to a Gmail account.
To set up this workflow, you will need to use:

Add and configure Google URL shortener - Shorten URL action

  1. Add Google URL shortener application and connect it to the Start icon.

  2. Next, double-click the Google URL Shortener connector icon, select the Shorten URL action from the Select Action drop down list, and select the Google URL Shortener account you want to use to execute the action.

    Once this is done, click Next.

    In the action configuration form that appears next, provide the details by entering the long URL you want to shorten in the Long URL field.

    Once you have entered these details, click Next, Test the action, and click Done.

Add and configure Gmail - Send an Email action

  1. Add Gmail connector to the canvas and connect it to the previous action.

  2. Next, double-click the Gmail connector icon, select the Send an Email action from the Select Action drop down list, and select the Gmail account you want to use to execute the action.

    Once this is done, click Next.

  3. In the action configuration form that appears next, provide the details as given below:

    • To: Enter the email ID of the recipient you want to send the shortened URL to. You can also add multiple email IDs by using a comma separator or a new line separator.

    • Subject: Enter a suitable subject for the email.

    • Body: Add the output key, say {{$a7.url}}, available under Shorten URL output on the left-side of the configuration window as an input for this field.

    Once you have entered all the details, click the Next button, Test the action, and click Done. This will take you back to canvas.

    Now connect the Gmail connector icon with the Stop icon, and Save the workflow.

    Now when you execute the workflow, it will shorten a long URL and send it to the specified email address.

Get Cisco Webex Teams space messages and email them

This workflow fetches all the messages of a particular space in Cisco Webex Teams and sends them to the specified recipient’s email address.

To set up this workflow, you will need Cisco Webex Teams application, JSON to HTML action, and Send an Email action.

Add and configure Cisco Webex Teams - Get Space Messages action

  1. Add Cisco Webex Teams connector to your canvas and use the Get Space Messages action to retrieve the list of all the messages of a particular space.

  2. Double-click the Cisco Webex Teams connector icon, select the Get Space Messages action from the Select Action drop down list, and select the Cisco Webex Teams account you want to use to execute the action.

    Once this is done, click Next.

  3. In the action configuration form that appears next, provide the details as given below:

    • Space ID: Select the ID of the space (from the dropdown options) whose messages you want to fetch. You can optionally enter the Space ID manually.

    • Fetch Messages before Date (Optional): Specify a date if you want to get messages posted before that date.

    • Fetch Messages before Message (Optional): Specify a message ID if you want to get messages sent before that message.

    • Number of Messages to be included (Optional): Enter the maximum number of items you want to get in the response.

  4. Once you enter the required values in the fields, Click the Next button, Test the action, and click Done to return to the workflow canvas.

    Since the output of the Get Space Messages action contains raw JSON data, it is recommended that you use JSON to HTML action to convert JSON into HTML before sending it via email. This will improve the readability of the output.

Add and configure JSON to HTML operation

This action converts any JSON data into HTML format.

  1. To implement this, add this operation to your canvas, and connect it with Cisco Webex Teams application.

  2. Configure JSON to HTML operation, and enter values in the fields as per the instructions given below:

    • JSON Data: Use the output of Cisco Webex Teams - Get Space Messages operation as the input value for this field (e.g. {{$a0}}).

    • Jade template (Optional): Provide a Jade template, if required.

  3. Once you enter the required details, click Next, Test the operation, and click on Done to return to integration canvas.

Add and configure Send an Email action

The Send an Email action sends an email to the specified email address. Let’s add this to our canvas, connect it with JSON to HTML operation, and configure it.

  1. Enter values in the configuration form input fields as per the instructions given below:

    • To: Enter the email address of the recipient.

    • Cc (Optional): Enter the email address of the recipients you want to mark the copy to.

    • Bcc (Optional): Enter email address of the recipients you want to mark a blind copy to.

    • ReplyTo (Optional): Enter the email ID on which user can send the reply.

  2. Once you enter the required details, click Next, Test the operation, and click on Done to return to integration canvas.

Save and test the workflow

Now that your connector and both the applications have been configured, SAVE your workflow.

Click Test to manually execute the workflow.

As soon as the workflow starts its execution, you will see real-time indicators showing the progress of the workflow. Once the execution is completed, you will receive an email that contains all the messages of the specified Cisco Webex Teams space in the HTML format.

Post new PagerDuty incident details to Cisco Webex Teams space and Slack

This workflow fetches the details of any new incident created in your PagerDuty account and sends the details of the incident to a Cisco Webex Teams space as well as a Slack channel.

To set up this workflow, you will need to use the following:

Set up PagerDuty - Incident Triggered trigger

  1. Configure the Start icon by double-clicking on it and select the PagerDuty connector from the list of trigger service icons that appear.

  2. The PagerDuty trigger configuration window will appear on the screen. Provide values for the input fields as per the instructions given below:

    • Trigger Label: Enter a suitable name for the trigger.

    • Select Trigger: Select New Incident trigger from the options available in the drop-down list. This instructs the webMethods.io Integration to trigger the workflow whenever a new incident is added in a particular service in your PagerDuty account.

    • Authorize PagerDuty: In order to use this trigger, you will have to first create PagerDuty account. Click the + button, and create your account using either Default Authorization option or service access token (i.e., Or option). If you have already created an account, select it from the drop-down list.

    • Service ID: Select/specify the ID of the service for which the trigger is to be set. In PagerDuty, the service ID could be found in the URL of the service. For example, if https://example.pagerduty.com/services/P4OPRHG is the service URL, then P4OPRHG will be the service ID.

    Once you have entered all the details, click on Save. You will be redirected to the Test trigger window where you can test the trigger with real-time data to use it to configure the rest of the workflow or skip testing and use mock data to configure the rest of the workflow.

  3. After this, click on Done to return to the canvas.

Add and configure Cisco Webex Teams - Post New Message action

  1. Add Cisco Webex Teams connector to the canvas and connect it with the Start icon (which now displays PagerDuty connector icon).

  2. Next, double-click the Cisco Webex Teams connector icon, select the Post New Message action from the Select Action drop down list, and select the Cisco Webex Teams account you want to use to execute the action.

    Once this is done, click Next.

  3. In the action configuration form that appears next, provide the details as given below:

    • Space ID: Select/specify the ID of the space on which you want to post the message.

    • Message: Specify the message that you want to post in the space. In this case, we will enter a custom message, along with the output of the PagerDuty trigger.

    Once you have entered all the details, click on Next. You will be redirected to the Test action window where you can test the action. After this, click on Done to return to the canvas.

Add and configure Slack - chatPostMessage action

  1. Add Slack connector to your canvas, and connect it with the Start icon (which now displays PagerDuty icon).

  2. Next, double-click the Slack connector icon, select the chatPostMessage action from the Select Action drop down list, and select the Slack account you want to use to execute the action.

    Once this is done, click Next .

  3. In the action configuration form that appears next, provide the details as given below:

    • channel: Enter the ID of the channel on which you want to post the message.

    • text: Specify the message that you want to send to the channel. In this case, we will enter a custom message, along with the output of the PagerDuty trigger.

    For this example tutorial, no details need to be entered in the other fields.

  4. Once you have entered all the details, click on Next.

    You will be redirected to the Test action window where you can test the action.

    After this, click on Done to return to the canvas and connect the Cisco Webex Teams and Slack connector icons to the Stop icon.

    Now, whenever a new incident is triggered in the specified service in PagerDuty, this workflow will send the incident details to the specified Cisco Webex Teams space and Slack channel.

Post new Marketo lead details to Cisco Webex Teams space

This workflow fetches the details of any new lead created in Marketo and sends the name of the lead to a space in Cisco Webex Teams.

To set up this workflow, you will need to use the following:

Set up Marketo - New Lead trigger

  1. Hover on the Start icon, and click on the Settings icon. Select Marketo from the list of triggers that appear. Enter values in the fields as per the instructions given below:

    • Select Trigger: Select New Lead trigger from the options available in the drop-down list. This instructs the webMethods.io Integration to trigger the workflow whenever a new lead is created in a particular list of your Marketo account.

    • Connect to Marketo: In order to use this trigger, you will have to first create a Marketo account. Click the + button, and create your account using either Default Authorization option or service access token (i.e., Or option). If you have already created an account, select it from the drop-down list.

  2. Once you have entered all the details, Save the trigger. After this, you will be directed to the Test trigger window, where you can check whether the trigger has been configured properly by clicking on the Test button.

  3. Once the trigger gets tested successfully, click on Done to return to the canvas.

Add and configure Cisco Webex Teams - Post New Message action

  1. Add Cisco Webex Teams connector to your canvas. Then, double-click the Cisco Webex Teams connector icon, select the Post New Message action from the Select Action drop down list, and select the Cisco Webex Teams account you want to use to execute the action.

  2. Once this is done, click Next.

  3. In the action configuration form that appears next, provide the details as given below:

    • Space ID: Select/specify the name/ID of the space to which you want to post the message.

    • Message: Specify the message that you want to send to space. In this case, we will enter a custom message, along with the output of Marketo trigger, under Trigger Data New Lead given in the left-side of the configuration window.

  4. Once you have entered all the details, click on Next, optionally Test the action, and click Done. This will take you back to canvas.

  5. Next, connect this action to the Stop icon and save the workflow.

    Now, whenever a new lead is created in your Marketo account, this workflow will send the lead name to the specified Cisco Webex Teams space in the custom message.

Change state of Nest thermostat every day at 6 PM

This workflow sets the room state of the structure of Nest thermostat from away to home every day at a defined time. To set up this workflow, you will need to use:

Set up Clock trigger

  1. Hover on the Start icon and click on the Settings icon. Select the Clock trigger from the list of trigger services. Configure the Clock trigger as per the instructions given below:

    • Trigger Label: Enter a suitable name for the trigger.

    • Trigger type: Select the Repeat From option from the drop-down list. This instructs the trigger to repeat at regular intervals, starting from the specified date and time.

    • Date: Select the date from which you want to start the repeat trigger.

    • Time: Enter the time from which you want to start the repeat trigger. For the purpose of this workflow, we will set it to 6 PM. (18:00)

    • Timezone: Select the timezone for the trigger start time.

    • Runs on every: Select the trigger interval. The trigger will be fired off every time after the interval specified here. Since we need to get the temperature every day, select 1 Day from the drop-down list.

    This trigger will fire off the workflow every day at 6 PM. Once you have entered all the details, save the trigger and click Done. This will take you back to the canvas.

Add and configure Nest - Set State of Structure action

  1. Add Nest connector to the canvas and connect it to the Clock trigger.

  2. Next, double-click the Nest connector icon, select the Set State of Structure action from the Select Action drop down list, and select the Nest account you want to use to execute the action.

  3. Once this is done, click Next.

  4. In the action configuration form that appears next, provide the details as given below:

    Set State: Set the state to home. This action will ensure that the state is changed to home when the clock triggers off at a specified time.

  5. Once you have entered all the details, click the Next button, Test the action, and click the Done button to return to the canvas. Connect this action to the Stop icon and Save the workflow.

    Now, every day at 6 PM, this integration will be triggered. As a result, it will set the state of your Nest thermostat from away to home.