diff --git a/src/speckle_automate/automation_context.py b/src/speckle_automate/automation_context.py index ac72cf9f..1043664d 100644 --- a/src/speckle_automate/automation_context.py +++ b/src/speckle_automate/automation_context.py @@ -355,6 +355,24 @@ def attach_warning_to_objects( visual_overrides, ) + def attach_success_to_objects( + self, + category: str, + object_ids: Union[str, List[str]], + message: Optional[str] = None, + metadata: Optional[Dict[str, Any]] = None, + visual_overrides: Optional[Dict[str, Any]] = None, + ) -> None: + """Add a new success case to the run results.""" + self.attach_result_to_objects( + ObjectResultLevel.SUCCESS, + category, + object_ids, + message, + metadata, + visual_overrides, + ) + def attach_info_to_objects( self, category: str, diff --git a/src/speckle_automate/schema.py b/src/speckle_automate/schema.py index 6e0b5649..ad2a7b93 100644 --- a/src/speckle_automate/schema.py +++ b/src/speckle_automate/schema.py @@ -69,6 +69,7 @@ class AutomationStatus(str, Enum): class ObjectResultLevel(str, Enum): """Possible status message levels for object reports.""" + SUCCESS = "SUCCESS" INFO = "INFO" WARNING = "WARNING" ERROR = "ERROR"