After the future removal of the classic playbook editor, your existing classic playbooks will continue to run, However, you will no longer be able to visualize or modify existing classic playbooks.
For details, see:
Use Data Preview to build, test, and edit playbooks
Use the Data preview panel on the right side of the Splunk SOAR screen to add blocks and preview their associated data. Data preview shows both sample data and real data for SOAR containers.
The data path picker configuration panel is still available to show possible data paths when using the configuration panel on the left side of the Visual Playbook Editor.
Real data views are currently available only for action and playbook block types. Sample data views are available for all block types.
Create a playbook
Perform the following tasks to create a new playbook in :
- Select the Home menu, then select Playbooks.
- Select + Playbook to create a new playbook.
- Select the type of playbook you want to create. The playbook type appears at the bottom of the configuration panel on the playbook editor canvas.
Playbook type Availability Usage Automation Always available. Can be called by analysts within Splunk SOAR, invoked automatically based on active labels, or used as sub-playbooks. Input Always available. Can only be called as sub-playbooks. Can only be run directly within the debugger. - Specify a name for the playbook.
- Playbooks in the same repository cannot have the same name. Playbooks in different repositories can have the same name.
- As a best practice, do not use personally identifiable information in the names of playbooks.
- Select Settings. In the Playbook Settings panel, select the Operates on field and specify one or more event labels that this playbook runs on. Operates on is only available for the Automation playbook type. Optionally, specify additional settings. For additional details on playbook settings, see Manage settings for a playbook in .
Playbook block limit recommendations
Try to limit your playbook to fewer than 50 individual blocks. Larger playbooks more resources and might load slowly. If needed, break large playbooks into smaller playbooks, including Input type playbooks, described in Create a new playbook in .
Preview the data
You can configure your playbook using the data from a Splunk SOAR event or container that you specify. You can see actual data from the container, event, finding, or investigation to make sure that you construct the playbook appropriately for your needs. If you don't select a data source, the Data preview panel displays only sample views.
To view the data, follow these steps:
- In the search field, enter a few letters or numbers to search for the container ID or name. Alternatively, select a recent source from the list that appears.
- Select the Start block, then view the data in one of two ways.
- Select Container data. The actual data for your source displays in purple.
- Select Sample data to see example data that might populate each field but that is not related to your actual data. Sample data appears in teal.
- Optionally filter the data you see.
- Select Filter on known data types to view only data relevant for your action or other playbook block you are running. For example, if you are using
whois ip
, only ip-related data displays. - Use the search field to search for a datapath name or actual data. For example, you can search for a field containing the word
status
or search for a status message of success.
- Select Filter on known data types to view only data relevant for your action or other playbook block you are running. For example, if you are using
You will use the data to configure the individual playbook blocks after you add them.
Add an Action block using Quick Actions
You can add an action block directly from the Data preview panel. In this example, there has been a malicious URL request attempt and you want to create an action in your playbook to find out its origin.
To add an action block from the Data preview panel, follow these steps:
- In the playbook you created, select the block after which you want to create an action block. In this example, it will be the Start block, but it can also be any other playbook block.
- View either the sample or action data, filtering it if needed.
- Locate the data you want to work with. In this example, use
ip
. Some data with specific datatypes, for example,ip
, has a menu with three dots. Select the three dots to reveal the Run action menu, used for adding an action. The menu displays actions that are appropriate for the datatype you selected. For example, selectgeolocate_ip
to use the IP address in the data you are previewing. - (Conditional) If your instance has multiple installed applications with the same action name, an additional application selector appears. Select the application you want to use for the action.
- The action block appears on the playbook editor canvas, attached to the previous playbook block. Notice that the datapath associated with that datatype appears in the corresponding field in the action block's configuration panel, to the left of the canvas.
- Complete any additional fields in the configuration panel for this action. For example, you might have other required fields to add, or you can choose to add looping logic using the Loop tab.
For additional information on action blocks, see Add an action block to your playbook.
Add additional playbook blocks and specify configuration data
Use the data in the Data preview panel to configure each playbook block. In the geolocate_ip action scenario earlier, the action produces an output of the country where the source IP originated. Now you can use that output to configure a filter block. To add a new playbook block and configure its data, follow these steps:
- Select the block you want to configure. For example, select the geolocate_ip action configured previously. The sample view of the action should appear on the Data preview panel. Select the pin button to keep the sample view from changing when adding another block.
- From that action block, drag and drop its half-circle icon. From the menu, select a filter block type. You will use data from the action block output to configure the new filter block.
- In the Data preview panel results, locate and select the country_name datapath, then select the copy icon next to the sample value.
- In the filter configuration panel on the left side, paste the datapath from the action block into the first condition.. The datapath that you pasted should look like this:
geolocate_ip_1:action_result.data.*.country_name
. - Continue to configure the condition in the filter block. For example, if you have a select group of embargoed countries, you can create a custom list and specify that if the country name is not on that list.
- Select Done.
- In the Data preview panel, select Save and run. Messages inform you whether the playbook ran successfully. Switch to the Debugger tab to monitor the playbook's progress. See the Debug playbooks section in this article for more information on how to use the debugger tab.
- After the playbook run completes, return to the previously configured action block and notice that it now has an Action run view where you can see the real results of the action.
- Continue to add and configure blocks following these steps. After you create and configure the final block, connect it to the End block.
To view sample results or real results for playbook blocks, you must set the playbook block to synchronous mode in its configuration panel on the left.
See also
- For details on datapaths, including datapath structure, user-based datapaths, and custom datapaths:
- For details on other playbook block types:
- Add a new block to your playbook
- Run other playbooks inside your playbook in
- Add custom code to your playbook with the code block
- Set notable parameters in using the Utility block
- Use filters in your playbook to specify a subset of events before further processing
- Use decisions to send events to a specific downstream action in your playbook
- Customize the format of your playbook content
- Require user input using the Prompt block in your playbook
Use the icons in the Data preview panel to navigate through blocks in your playbook.
Debug playbooks
Use the debugger to test playbooks or troubleshoot issues, either while you are developing the playbook or if there are issues when the playbook runs.
To run your playbook using the debugger, the playbook must meet the following conditions:
- The playbook must be saved. You cannot debug playbooks in edit mode.
- The playbook cannot be marked active.
- The playbook must have an event to run against.
You can access the playbook debugger in the Data Preview panel of the Visual Playbook Editor. Within the Data Preview panel, select the Debugger tab.
To run the debugger for a specific container, finding, or investigation, follow these steps:
- Locate the ID for the container in the SOAR Events page, in the ID column
- Copy the ID and paste it into the search field above the Debugger tab.
- Select whether you want to run the debugger as the current user or as the selected automation user.
- Specify the scope for debugging. Select one of the following options:
- New Artifacts to include only the artifacts that were defined since the playbook last ran.
- All Artifacts to include all artifacts in the playbook.
- Select Test.
Each line in the debug content starts with a date time stamp. Log entries show which block is running, the parameters sent, inputs from earlier blocks or playbooks, and the outputs of the block. The API call to on_finish
represents a call to the End block. The playbook completes by logging a SUCCESS or FAILURE status.
Select Copy to copy the output of the debugger and paste it into a ticket or separate editor.
View or edit Python code
If you are experienced with Python, you can choose to select the Python editor tab in the Data preview panel to view or edit the underlying Python code in your playbook. The code in the Python editor tab is updated whenever you select Save and run in the Data preview panel.
For details, see View or edit the Python code in playbooks.
Find existing playbooks | Create a new playbook in |
This documentation applies to the following versions of Splunk® SOAR (On-premises): 6.3.1
Feedback submitted, thanks!