CBWatchlists
Display all watchlists and their details, queries, etc.
python · Carbon Black Enterprise Response
Details
| ID | CBWatchlists |
|---|---|
| Language | python |
| From Version | 5.0.0 |
| Docker Image | demisto/python3:3.12.13.10116658 |
| Tags | carbon-black |
README
Displays all watchlists and their details, queries, etc.
Script Data
| Name | Description |
|---|---|
| Script Type | python |
| Tags | carbon-black |
Dependencies
This script uses the following commands and scripts.
- cb-watchlist-get
Inputs
| Argument Name | Description |
|---|---|
| id | Display a specific watchlist by watchlist ID (numeric). |
Outputs
There are no outputs for this script.
import demistomock as demisto # noqa: F401 import pytest from CommonServerPython import * QUERY_COMMAND_RESPONSE = [ ( [{"Type": entryTypes["note"], "Contents": [{"name": "test_value", "last_hit_count": "3"}]}], [{"name": "test_value", "last_hit_count": "3"}], ), ([{"Type": entryTypes["note"], "Contents": []}], "No matches."), ] @pytest.mark.parametrize("res, contents", QUERY_COMMAND_RESPONSE) def test_mimecast_find_email(res, contents, mocker): mocker.patch.object(demisto, "executeCommand", return_value=res) mocker.patch.object(demisto, "results") mocker.patch.object(demisto, "args", return_value={}) from CBWatchlists import main main() results = demisto.results.call_args[0][0] assert results[0].get("Contents") == contents