Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/integration_testing/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "integration-testing"
version = "2.3.5"
version = "2.3.7"
description = "Blackbox testing infrastructure to test and run marketplace integration scripts locally using mocks."
readme = "README.md"
authors = [
Expand Down Expand Up @@ -48,7 +48,7 @@ testpaths = [
]

[tool.uv.sources]
tipcommon = { path = "../tipcommon/whls/TIPCommon-2.3.5-py3-none-any.whl" }
tipcommon = { path = "../tipcommon/whls/TIPCommon-2.3.7-py3-none-any.whl" }
environmentcommon = { path = "../envcommon/whls/EnvironmentCommon-1.0.2-py2.py3-none-any.whl" }
soar-sdk = { git = "https://github.com/chronicle/soar-sdk.git" }

Expand Down
10 changes: 5 additions & 5 deletions packages/integration_testing/uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
2 changes: 1 addition & 1 deletion packages/tipcommon/TIPCommon/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "TIPCommon"
version = "2.3.5"
version = "2.3.7"
description = "General Purpose CLI tool for Google SecOps Marketplace"
readme = "README.md"
authors = [
Expand Down
58 changes: 58 additions & 0 deletions packages/tipcommon/TIPCommon/src/TIPCommon/rest/soar_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -958,6 +958,64 @@ def resume_alert_sla(
validate_response(response, validate_json=False)


def resume_case_alerts_sla(
chronicle_soar: ChronicleSOAR,
case_id: int,
alert_identifiers: list[str],
message: str,
) -> tuple[list[str], list[str]]:
"""Resume alert SLA for multiple alerts in a case.

Args:
chronicle_soar: A chronicle soar SDK object.
case_id: Chronicle SOAR case ID.
alert_identifiers: List of Chronicle SOAR Alert Identifiers.
message: Chronicle SOAR message.
Returns:
Success and failed alert identifiers.
"""
success_alerts = []
failed_alerts = []
for alert_identifier in alert_identifiers:
try:
resume_alert_sla(chronicle_soar, case_id, alert_identifier, message)
success_alerts.append(alert_identifier)
except Exception as e:
chronicle_soar.LOGGER.error(f"Failed to resume SLA for alert {alert_identifier}: {e}")
failed_alerts.append(alert_identifier)

return success_alerts, failed_alerts


def pause_case_alerts_sla(
chronicle_soar: ChronicleSOAR,
case_id: int,
alert_identifiers: list[str],
message: str,
) -> tuple[list[str], list[str]]:
"""Pause alert SLA for multiple alerts in a case.

Args:
chronicle_soar: A chronicle soar SDK object.
case_id: Chronicle SOAR case ID.
alert_identifiers: List of Chronicle SOAR Alert Identifiers.
message: Chronicle SOAR message.
Returns:
Success and failed alert identifiers.
"""
success_alerts = []
failed_alerts = []
for alert_identifier in alert_identifiers:
try:
pause_alert_sla(chronicle_soar, case_id, alert_identifier, message)
success_alerts.append(alert_identifier)
except Exception as e:
chronicle_soar.LOGGER.error(f"Failed to pause SLA for alert {alert_identifier}: {e}")
failed_alerts.append(alert_identifier)

return success_alerts, failed_alerts


def change_case_description(
chronicle_soar: ChronicleSOAR,
case_id: int,
Expand Down
2 changes: 1 addition & 1 deletion packages/tipcommon/TIPCommon/uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
Loading