From 1ece5aed493c5a909e2d948ebf24433bfbd89793 Mon Sep 17 00:00:00 2001 From: "linear-code[bot]" <222613912+linear-code[bot]@users.noreply.github.com> Date: Mon, 6 Jul 2026 14:21:53 +0000 Subject: [PATCH] Add owner_group_ids to heartbeat create/update models Adds the owner_group_ids field to NewHeartbeatDataAttributes and UpdateHeartbeatDataAttributes so team-scoped API keys can create and update team-owned heartbeats through the SDK. The public OpenAPI spec already exposes this field on the heartbeat create/update schemas; the generated models had not been regenerated to include it. Generated with [Linear](https://linear.app/rootly/issue/IR-5978/rootly-python-newupdate-heartbeat-schema-missing-owner-group-ids#agent-session-ecdd5403) Co-authored-by: linear-code[bot] <222613912+linear-code[bot]@users.noreply.github.com> --- rootly_sdk/models/new_heartbeat_data_attributes.py | 11 +++++++++++ rootly_sdk/models/update_heartbeat_data_attributes.py | 11 +++++++++++ 2 files changed, 22 insertions(+) diff --git a/rootly_sdk/models/new_heartbeat_data_attributes.py b/rootly_sdk/models/new_heartbeat_data_attributes.py index 05a9817..d53146f 100644 --- a/rootly_sdk/models/new_heartbeat_data_attributes.py +++ b/rootly_sdk/models/new_heartbeat_data_attributes.py @@ -32,6 +32,7 @@ class NewHeartbeatDataAttributes: description (None | str | Unset): The description of the heartbeat alert_description (None | str | Unset): Description of alerts triggered when heartbeat expires. alert_urgency_id (None | str | Unset): Urgency of alerts triggered when heartbeat expires. + owner_group_ids (list[str] | Unset): List of team IDs that own this heartbeat enabled (bool | Unset): Whether to trigger alerts when heartbeat is expired. """ @@ -44,6 +45,7 @@ class NewHeartbeatDataAttributes: description: None | str | Unset = UNSET alert_description: None | str | Unset = UNSET alert_urgency_id: None | str | Unset = UNSET + owner_group_ids: list[str] | Unset = UNSET enabled: bool | Unset = UNSET def to_dict(self) -> dict[str, Any]: @@ -77,6 +79,10 @@ def to_dict(self) -> dict[str, Any]: else: alert_urgency_id = self.alert_urgency_id + owner_group_ids: list[str] | Unset = UNSET + if not isinstance(self.owner_group_ids, Unset): + owner_group_ids = self.owner_group_ids + enabled = self.enabled field_dict: dict[str, Any] = {} @@ -97,6 +103,8 @@ def to_dict(self) -> dict[str, Any]: field_dict["alert_description"] = alert_description if alert_urgency_id is not UNSET: field_dict["alert_urgency_id"] = alert_urgency_id + if owner_group_ids is not UNSET: + field_dict["owner_group_ids"] = owner_group_ids if enabled is not UNSET: field_dict["enabled"] = enabled @@ -146,6 +154,8 @@ def _parse_alert_urgency_id(data: object) -> None | str | Unset: alert_urgency_id = _parse_alert_urgency_id(d.pop("alert_urgency_id", UNSET)) + owner_group_ids = cast(list[str], d.pop("owner_group_ids", UNSET)) + enabled = d.pop("enabled", UNSET) new_heartbeat_data_attributes = cls( @@ -158,6 +168,7 @@ def _parse_alert_urgency_id(data: object) -> None | str | Unset: description=description, alert_description=alert_description, alert_urgency_id=alert_urgency_id, + owner_group_ids=owner_group_ids, enabled=enabled, ) diff --git a/rootly_sdk/models/update_heartbeat_data_attributes.py b/rootly_sdk/models/update_heartbeat_data_attributes.py index e9d622c..6b0b418 100644 --- a/rootly_sdk/models/update_heartbeat_data_attributes.py +++ b/rootly_sdk/models/update_heartbeat_data_attributes.py @@ -32,6 +32,7 @@ class UpdateHeartbeatDataAttributes: notification_target_id (str | Unset): notification_target_type (UpdateHeartbeatDataAttributesNotificationTargetType | Unset): The type of the notification target. Please contact support if you encounter issues using `Functionality` as a target type. + owner_group_ids (list[str] | Unset): List of team IDs that own this heartbeat enabled (bool | Unset): Whether to trigger alerts when heartbeat is expired. """ @@ -44,6 +45,7 @@ class UpdateHeartbeatDataAttributes: interval_unit: UpdateHeartbeatDataAttributesIntervalUnit | Unset = UNSET notification_target_id: str | Unset = UNSET notification_target_type: UpdateHeartbeatDataAttributesNotificationTargetType | Unset = UNSET + owner_group_ids: list[str] | Unset = UNSET enabled: bool | Unset = UNSET def to_dict(self) -> dict[str, Any]: @@ -81,6 +83,10 @@ def to_dict(self) -> dict[str, Any]: if not isinstance(self.notification_target_type, Unset): notification_target_type = self.notification_target_type + owner_group_ids: list[str] | Unset = UNSET + if not isinstance(self.owner_group_ids, Unset): + owner_group_ids = self.owner_group_ids + enabled = self.enabled field_dict: dict[str, Any] = {} @@ -104,6 +110,8 @@ def to_dict(self) -> dict[str, Any]: field_dict["notification_target_id"] = notification_target_id if notification_target_type is not UNSET: field_dict["notification_target_type"] = notification_target_type + if owner_group_ids is not UNSET: + field_dict["owner_group_ids"] = owner_group_ids if enabled is not UNSET: field_dict["enabled"] = enabled @@ -163,6 +171,8 @@ def _parse_alert_urgency_id(data: object) -> None | str | Unset: _notification_target_type ) + owner_group_ids = cast(list[str], d.pop("owner_group_ids", UNSET)) + enabled = d.pop("enabled", UNSET) update_heartbeat_data_attributes = cls( @@ -175,6 +185,7 @@ def _parse_alert_urgency_id(data: object) -> None | str | Unset: interval_unit=interval_unit, notification_target_id=notification_target_id, notification_target_type=notification_target_type, + owner_group_ids=owner_group_ids, enabled=enabled, )