Skip to content

Conversation

@content-bot
Copy link
Contributor

Original External PR

external pull request

Contributor

@Royee-Topper

Contributing to Cortex XSOAR Content

Make sure to register your contribution by filling the contribution registration form

The Pull Request will be reviewed only after the contribution registration form is filled.

Status

  • In Progress
  • Ready
  • In Hold - (Reason for hold)

Related Issues

fixes: https://jira-dc.paloaltonetworks.com/browse/CIAC-15385

Description

A few sentences describing the overall goals of the pull request's commits.

Must have

  • Tests
  • Documentation

* Add alerts initial_arr_flow_completed optional filter

* Update Packs/Claroty/Integrations/Claroty/Claroty.py

* Update Packs/Claroty/Integrations/Claroty/Claroty.py

* Update Packs/Claroty/Integrations/Claroty/Claroty.yml

---------

Co-authored-by: merit-maita <49760643+merit-maita@users.noreply.github.com>
@content-bot content-bot added Contribution Thank you! Contributions are always welcome! docs-approved Partner Contribution Form Filled Whether contribution form filled or not. Partner Support Level Indicates that the contribution is for Partner supported pack Internal PR Partner-Approved ready-for-pipeline-running Whether the pr is ready for running the whole pipeline, including testing on SAAS machines labels Jan 7, 2026
@merit-maita merit-maita enabled auto-merge (squash) January 7, 2026 10:34
@merit-maita merit-maita added the ready-for-ai-review The PR is ready for reviewing the PR with the AI Reviewer. label Jan 7, 2026
@github-actions
Copy link

github-actions bot commented Jan 7, 2026

Coverage

Coverage Report
FileStmtsMissCoverMissing
Packs/Claroty/Integrations/Claroty
   Claroty.py40217456%121–123, 125, 127, 138, 151–152, 154, 157, 160, 173, 176–178, 208–212, 222, 226–228, 230–232, 234, 238–239, 241, 243–246, 248–250, 252–254, 256–258, 260, 262–265, 267–268, 270–271, 273–274, 278–284, 286, 288, 290–291, 293–295, 297, 299–301, 303, 307–310, 312–314, 325–330, 334, 338, 341, 348, 354–355, 363–364, 366–367, 372, 393, 400, 455–459, 461–466, 486–489, 496–500, 524–528, 535, 543–546, 554–555, 557, 561–565, 574, 578, 583–588, 593, 648, 659–660, 662, 664, 666, 668, 670–672, 679–681, 683–684, 686–687, 689–690, 692–693, 695–696, 698–699, 701–702
TOTAL40217456% 

Tests Skipped Failures Errors Time
6 0 💤 0 ❌ 0 🔥 2.255s ⏱️

@merit-maita merit-maita added ready-for-ai-review The PR is ready for reviewing the PR with the AI Reviewer. skip-ai-review and removed ready-for-ai-review The PR is ready for reviewing the PR with the AI Reviewer. labels Jan 7, 2026
@content-bot content-bot removed the ready-for-ai-review The PR is ready for reviewing the PR with the AI Reviewer. label Jan 8, 2026
@content-bot
Copy link
Contributor Author

🤖 Content AI Reviewer: Analysis started. Please wait for results...

@content-bot
Copy link
Contributor Author

Validate summary
The following errors were thrown as a part of this pr: .
If the AG100 validation in the pre-commit GitHub Action fails, the pull request cannot be force-merged.

Verdict: PR can be force merged from validate perspective? ✅

@merit-maita merit-maita merged commit 31f4a97 into master Jan 8, 2026
27 of 28 checks passed
@merit-maita merit-maita deleted the contrib/Royee-Topper_bugfix/claroty/add-initial-arr-flow-completed-filter branch January 8, 2026 06:32
@content-bot
Copy link
Contributor Author

🤖 Content-bot Review Disclaimer

This review was generated by an AI-powered tool and may contain inaccuracies. Please be advised, and we extend our sincere apologies for any inconvenience this may cause.

Copy link
Contributor Author

@content-bot content-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the updates to the Claroty integration! I have a few suggestions to help polish the code and documentation.

Please consider using argToBoolean for consistency, adding type hints, and including a test case for fetch_incidents. There are also minor fixes needed in the README regarding output types and capitalization in the Release Notes.

Great work overall

@merit-maita please review and approve the results generated by the AI Reviewer by responding 👍 on this comment.

if bool(demisto.params().get("exclude_resolved_alerts", False)):
extra_filters_list = _add_exclude_resolved_alerts_filters(extra_filters_list)

if argToBoolean(demisto.params().get("include_only_arr_completed_alerts", False)):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consistency suggestion: Update line 156 to use argToBoolean.

return filters


def _add_include_only_arr_completed_alerts_filters(filters: list[Filter]):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Consider simplifying by removing this helper function.
  • Add a return type hint -> list[Filter].

assert response["objects"][0]["alert_indicators"]


def test_query_with_arr_filter__filter_is_applied(mocker, requests_mock):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding a test case for fetch_incidents to verify the filter application.

| Claroty.Alert.ResourceID | String | The alert resource ID (AlertID-SiteID). |
| Claroty.Alert.Severity | String | The alert severity. |
| Claroty.Alert.Category | String | The alert category. |
| Claroty.Alert.InitialArrFlowCompleted | Number | Whether the alert has completed its initial Automated Resolution Rules flow. |
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The output type should be Boolean to match the YAML definition.


##### Claroty

- Added support for **Include only ARR completed alerts** parameter that includes only alerts that have completed their initial automated resolution rules flow.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider capitalizing 'Automated Resolution Rules' to match the feature name and the YAML description.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Contribution Form Filled Whether contribution form filled or not. Contribution Thank you! Contributions are always welcome! docs-approved Internal PR Partner Support Level Indicates that the contribution is for Partner supported pack Partner Partner-Approved ready-for-pipeline-running Whether the pr is ready for running the whole pipeline, including testing on SAAS machines skip-ai-review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants