- 18 Oct 2024
-
DarkLight
-
PDF
Cloud Managed Network (Meraki) - Workflows
- Updated on 18 Oct 2024
-
DarkLight
-
PDF
Next, we will build a workflow which will utilize the transformation just built, create a new Meraki network, query the network ID from the response, and then claim the devices and associate them with the new Meraki network.
Workflow Video
Step 1
From Automation Studio, select Create a Workflow from the Quick Start menu.
Step 2
Name the workflow Lab – Meraki – XX and click Create.
Step 3
A fresh workflow canvas opens. For our use-case, we would like to build our workflow horizontally, so we will click and drag the START and END termination tasks so they are aligned horizontally on our canvas.
Step 4
We are ready to begin adding tasks from our Task Palette. The first task we need is a Transformation task. Search for the Transformation task and then click and drag the task onto the canvas.
Step 5
Add the following tasks to the right of the Transformation task; Child Job, Query, and a second Child Job task.
Step 6
Next, we need to connect the tasks with transitions to form the workflow. This is done by first clicking the START task, which will highlight the task with a dashed border. Click within the dashed border and begin dragging the transition towards the Transformation task. When the transition snaps to the Transition task, release the mouse button.
Step 7
Repeat this process to add transitions between the remaining tasks.
Note: The default transition is a Success transition. If you would like to add an Error or Failure transition, press and hold the E or F key on your keyboard as you are adding the transition. If you would like to change an existing transition, right click on the transition and a popup will open. From the popup, you can choose to change the transition type or to delete the transition.
Workflow Video - Part 2
Step 8
We are ready to begin configuring the tasks. Double click the Transformation task to open the configuration window.
Step 9
From the Transformation dropdown, select the Lab – Meraki – XX transformation. Once selected, the summary will automatically update.
Step 10
For the formData variable, select Job as the Variable Source and enter formData for the Job Variable.
Step 11
Close the configuration window.
Step 12
Double click the first Child Job task to open the configuration window.
Step 13
Update the summary to Create Network.
Step 14
From the workflow dropdown, select Create Network – Meraki - REST. This is one of the pre-built workflows we installed earlier in the training.
Step 15
For the adapterId variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and merakiAdapter as the Task Variable.
Step 16
For the networkName variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and networkName as the Task Variable.
Step 17
For the timeZone variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and timeZone as the Task Variable.
Step 18
For the tags variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and tags as the Task Variable.
Step 19
For the productTypes variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and productTypes as the Task Variable.
Step 20
For the notes variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and notes as the Task Variable.
Step 21
And for the organizationName variable, select Task as the Variable Source. Select Lab – Meraki – XX for the Previous Task and organizationName as the Task Variable.
Step 22
Close the configuration window.
Step 23
Double click the Query task to open the configuration window.
Step 24
Update the Summary to Query Network ID.
Step 25
For the pass_on_null variable, select Static for the Variable Source and False as the Value.
Step 26
For the query variable, select Static for the Variable Source and enter createNetworkSuccess.response.id for the Value.
Step 27
For the object variable, select Task for the Variable Source and then select Create Network for the Previous Task and job_details for the Task Variable.
Step 28
Close the configuration window.
Step 29
Double click the second Child Job task to open the configuration window.
Step 30
Update the Summary to Claim Devices.
Step 31
From the workflow dropdown, select Claim Network Devices – Meraki - REST. This is also one of the pre-built workflows we installed earlier in the training.
Step 32
For the networkId variable, select Task as the Variable Source. Select Query Network ID as the Previous Task and return_data for the Task Variable.
Step 33
For the adapterId variable, select Task as the Variable Source. Select Lab – Meraki – XX as the Previous Task and merakiAdapter for the Task Variable.
Step 34
For the serials variable, select Task as the Variable Source. Select Lab – Meraki – XX as the Previous Task and serials for the Task Variable.
Close the configuration window.
Step 35
Our workflow is complete. Click Save. A green check mark appears in the upper right corner signaling that the workflow has passed validation and that all resources needed to run the workflow are present.