From ba07875783c90b2c42171697fc8a46ddfabc1c03 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 29 Sep 2026 06:12:57 +0000 Subject: [PATCH 1/2] feat(deps-dev): bump @seamapi/types in the seam group Bumps the seam group with 1 update: [@seamapi/types](https://github.com/seamapi/types). Updates `@seamapi/types` from 1.1081.0 to 1.1082.0 - [Release notes](https://github.com/seamapi/types/releases) - [Commits](https://github.com/seamapi/types/compare/v1.1081.0...v1.1082.0) --- updated-dependencies: - dependency-name: "@seamapi/types" dependency-version: 1.1082.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: seam ... Signed-off-by: dependabot[bot] --- package-lock.json | 8 ++++---- package.json | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index f6ca24e..0719a9e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "@seamapi/blueprint": "^1.12.0", "@seamapi/fake-seam-connect": "2.0.6", "@seamapi/smith": "^1.1.0", - "@seamapi/types": "1.1081.0", + "@seamapi/types": "1.1082.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0", "prettier": "^3.2.5" @@ -864,9 +864,9 @@ } }, "node_modules/@seamapi/types": { - "version": "1.1081.0", - "resolved": "https://registry.npmjs.org/@seamapi/types/-/types-1.1081.0.tgz", - "integrity": "sha512-bFh94NyhpR1nukmihSxLR68TAgYGvbk+JeBnOWHtmNkP9FABSeuplw6cXBjB7S+xiVoazUCnclgrJ9lVnijCvw==", + "version": "1.1082.0", + "resolved": "https://registry.npmjs.org/@seamapi/types/-/types-1.1082.0.tgz", + "integrity": "sha512-QDuaHzjq+i/6yQ+fGs2jUmuZ8QomanqnLAuP2NULyGmfpTTeI/pEGkUp9YmRjUrbFoM8LHNT3ZmsFi8/2JJYmA==", "dev": true, "license": "MIT", "engines": { diff --git a/package.json b/package.json index 191cdf3..854af12 100644 --- a/package.json +++ b/package.json @@ -32,7 +32,7 @@ "@seamapi/blueprint": "^1.12.0", "@seamapi/fake-seam-connect": "2.0.6", "@seamapi/smith": "^1.1.0", - "@seamapi/types": "1.1081.0", + "@seamapi/types": "1.1082.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0", "prettier": "^3.2.5" From 62309916e824316d66107ee8e4603a867183960b Mon Sep 17 00:00:00 2001 From: Seam Bot Date: Tue, 29 Sep 2026 06:13:55 +0000 Subject: [PATCH 2/2] ci: Generate code --- lib/seam/resources/action_attempt.rb | 42 ++++++++++++++++++++++++++ lib/seam/resources/device.rb | 3 ++ lib/seam/resources/device_provider.rb | 3 ++ lib/seam/resources/unmanaged_device.rb | 3 ++ lib/seam/routes/thermostats.rb | 11 +++++++ 5 files changed, 62 insertions(+) diff --git a/lib/seam/resources/action_attempt.rb b/lib/seam/resources/action_attempt.rb index 4041a6c..8eb8680 100644 --- a/lib/seam/resources/action_attempt.rb +++ b/lib/seam/resources/action_attempt.rb @@ -1264,6 +1264,46 @@ class Result < BaseResource attr_accessor :status end + # Activating the weekly program is pending. + class ActivateWeeklyProgram < ActionAttempt + class Error < BaseResource + # Detailed description of the error. Provides insights into the issue and potentially how to rectify it. + # @return [String] + attr_accessor :message + # Type of the error. + # @return [String] + attr_accessor :type + end + + class Result < BaseResource + end + + # Error associated with the action. + # @return [Error, nil] + # Only present when `status` is `error`; `nil` otherwise. + resource_accessor :error, Error + available_only_for_statuses :error, ["error"] + # Result of the action. + # @return [Result, nil] + # Only present when `status` is `success`; `nil` otherwise. + resource_accessor :result, Result + available_only_for_statuses :result, ["success"] + # ID of the action attempt. + # @return [String] + attr_accessor :action_attempt_id + # Action attempt to track the status of returning a thermostat to its weekly program. + # @return [String] + # Known values: + # - `ACTIVATE_WEEKLY_PROGRAM` + attr_accessor :action_type + # @return [String] + # Known values: + # - `success` + # - `pending` + # - `error` + attr_accessor :status + end + # Simulating a keypad code entry is pending. class SimulateKeypadCodeEntry < ActionAttempt class Error < BaseResource @@ -1732,6 +1772,7 @@ class Result < BaseResource # - `SET_FAN_MODE` # - `SET_HVAC_MODE` # - `ACTIVATE_CLIMATE_PRESET` + # - `ACTIVATE_WEEKLY_PROGRAM` # - `SIMULATE_KEYPAD_CODE_ENTRY` # - `SIMULATE_MANUAL_LOCK_VIA_KEYPAD` # - `PUSH_THERMOSTAT_PROGRAMS` @@ -1762,6 +1803,7 @@ class Result < BaseResource "SET_FAN_MODE" => SetFanMode, "SET_HVAC_MODE" => SetHvacMode, "ACTIVATE_CLIMATE_PRESET" => ActivateClimatePreset, + "ACTIVATE_WEEKLY_PROGRAM" => ActivateWeeklyProgram, "SIMULATE_KEYPAD_CODE_ENTRY" => SimulateKeypadCodeEntry, "SIMULATE_MANUAL_LOCK_VIA_KEYPAD" => SimulateManualLockViaKeypad, "PUSH_THERMOSTAT_PROGRAMS" => PushThermostatPrograms, diff --git a/lib/seam/resources/device.rb b/lib/seam/resources/device.rb index 23f92a0..00981c7 100644 --- a/lib/seam/resources/device.rb +++ b/lib/seam/resources/device.rb @@ -2659,6 +2659,9 @@ class MaxAccessCodesReached < Warnings # Array of warnings associated with the device. Each warning object within the array contains two fields: `warning_code` and `message`. `warning_code` is a string that uniquely identifies the type of warning, enabling quick recognition and categorization of the issue. `message` provides a more detailed description of the warning, offering insights into the issue and potentially how to rectify it. # @return [Array] resource_list_accessor :warnings, Warnings + # Indicates whether the thermostat can be returned to its weekly program, the schedule that is configured on the device itself, releasing any hold that Seam has set. + # @return [Boolean, nil] + attr_accessor :can_activate_weekly_program # Indicates whether the lock supports configuring automatic locking. # @return [Boolean, nil] attr_accessor :can_configure_auto_lock diff --git a/lib/seam/resources/device_provider.rb b/lib/seam/resources/device_provider.rb index 1c5fd48..8a1c52f 100644 --- a/lib/seam/resources/device_provider.rb +++ b/lib/seam/resources/device_provider.rb @@ -3,6 +3,9 @@ module Seam module Resources class DeviceProvider < BaseResource + # Indicates whether the thermostat can be returned to its weekly program, the schedule that is configured on the device itself, releasing any hold that Seam has set. + # @return [Boolean, nil] + attr_accessor :can_activate_weekly_program # Indicates whether the lock supports configuring automatic locking. # @return [Boolean, nil] attr_accessor :can_configure_auto_lock diff --git a/lib/seam/resources/unmanaged_device.rb b/lib/seam/resources/unmanaged_device.rb index 53d3c23..7ec9f77 100644 --- a/lib/seam/resources/unmanaged_device.rb +++ b/lib/seam/resources/unmanaged_device.rb @@ -934,6 +934,9 @@ class MaxAccessCodesReached < Warnings # Array of warnings associated with the device. Each warning object within the array contains two fields: `warning_code` and `message`. `warning_code` is a string that uniquely identifies the type of warning, enabling quick recognition and categorization of the issue. `message` provides a more detailed description of the warning, offering insights into the issue and potentially how to rectify it. # @return [Array] resource_list_accessor :warnings, Warnings + # Indicates whether the thermostat can be returned to its weekly program, the schedule that is configured on the device itself, releasing any hold that Seam has set. + # @return [Boolean, nil] + attr_accessor :can_activate_weekly_program # Indicates whether the lock supports configuring automatic locking. # @return [Boolean, nil] attr_accessor :can_configure_auto_lock diff --git a/lib/seam/routes/thermostats.rb b/lib/seam/routes/thermostats.rb index 71104bd..100b25f 100644 --- a/lib/seam/routes/thermostats.rb +++ b/lib/seam/routes/thermostats.rb @@ -34,6 +34,17 @@ def activate_climate_preset(climate_preset_key:, device_id:, wait_for_action_att Seam::ActionAttemptResolver.resolve(Seam::Resources::ActionAttempt.load_from_response(res.body["action_attempt"]), @client, wait_for_action_attempt) end + # Returns a specified [thermostat](https://www.seam.co/docs/capability-guides/thermostats) to its [weekly program](https://www.seam.co/docs/capability-guides/thermostats/creating-and-managing-thermostat-programs), the schedule that is configured on the device itself, releasing any hold that Seam has set. Seam stops managing the thermostat's climate until you [activate a climate preset](https://www.seam.co/docs/capability-guides/thermostats/configure-current-climate-settings), make a direct climate setting change, or one of the thermostat's [scheduled](https://www.seam.co/docs/capability-guides/thermostats/creating-and-managing-thermostat-schedules) presets reaches its activation time. + # @param device_id [String] ID of the thermostat device that you want to return to its weekly program. + # @return [Seam::Resources::ActionAttempt] OK + def activate_weekly_program(device_id:, wait_for_action_attempt: nil) + res = @client.post("/thermostats/activate_weekly_program", {device_id: device_id}.compact) + + wait_for_action_attempt = wait_for_action_attempt.nil? ? @defaults.wait_for_action_attempt : wait_for_action_attempt + + Seam::ActionAttemptResolver.resolve(Seam::Resources::ActionAttempt.load_from_response(res.body["action_attempt"]), @client, wait_for_action_attempt) + end + # Sets a specified [thermostat](https://www.seam.co/docs/capability-guides/thermostats) to [cool mode](https://www.seam.co/docs/capability-guides/thermostats/configure-current-climate-settings). # @param device_id [String] ID of the thermostat device that you want to set to cool mode. # @param cooling_set_point_celsius [Float, nil] [Cooling set point](https://www.seam.co/docs/capability-guides/thermostats/understanding-thermostat-concepts/set-points) in °C that you want to set for the thermostat. You must set one of the `cooling_set_point` parameters.