await seam.thermostats.dailyPrograms.update({
thermostat_daily_program_id: "6baf3a53-ba83-4052-8ea5-143584e18f03",
name: "Weekday Program",
periods: [
{ starts_at_time: "07:00:00", climate_preset_key: "Home" },
{ starts_at_time: "09:00:00", climate_preset_key: "Away" },
{ starts_at_time: "17:00:00", climate_preset_key: "Home" },
{ starts_at_time: "22:30:00", climate_preset_key: "Sleep" },
],
});
/*
{
"action_attempt_id": "a1b2c3d4-e5f6-4a3b-2c1d-0e9f8a7b6c5d",
"action_type": "PUSH_THERMOSTAT_PROGRAMS",
"error": null,
"result": {},
"status": "success"
}
*/{
"action_attempt": {
"action_attempt_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"action_type": "PUSH_THERMOSTAT_PROGRAMS",
"error": {
"message": "<string>",
"type": "<string>"
},
"result": {},
"status": "success"
}
}Daily Programs
Update a Thermostat Daily Program
Updates a specified thermostat daily program. The periods that you specify overwrite any existing periods for the daily program.
PATCH
/
thermostats
/
daily_programs
/
update
await seam.thermostats.dailyPrograms.update({
thermostat_daily_program_id: "6baf3a53-ba83-4052-8ea5-143584e18f03",
name: "Weekday Program",
periods: [
{ starts_at_time: "07:00:00", climate_preset_key: "Home" },
{ starts_at_time: "09:00:00", climate_preset_key: "Away" },
{ starts_at_time: "17:00:00", climate_preset_key: "Home" },
{ starts_at_time: "22:30:00", climate_preset_key: "Sleep" },
],
});
/*
{
"action_attempt_id": "a1b2c3d4-e5f6-4a3b-2c1d-0e9f8a7b6c5d",
"action_type": "PUSH_THERMOSTAT_PROGRAMS",
"error": null,
"result": {},
"status": "success"
}
*/{
"action_attempt": {
"action_attempt_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"action_type": "PUSH_THERMOSTAT_PROGRAMS",
"error": {
"message": "<string>",
"type": "<string>"
},
"result": {},
"status": "success"
}
}Authorizations
client_session_tokenpersonal_access_tokenapi_key
Body
application/json
Was this page helpful?