Update delivery hours
const url = 'https://app.hostrepute.com/api/v1/alert-groups/01a178db-d7b4-730d-82fa-5fb952d888e4';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"Business hours","timezone":"America/New_York","schedule":{"mon":{"enabled":true,"start":"07:00","end":"19:00"},"tue":{"enabled":true,"start":"07:00","end":"19:00"},"wed":{"enabled":true,"start":"07:00","end":"19:00"},"thu":{"enabled":true,"start":"07:00","end":"19:00"},"fri":{"enabled":true,"start":"07:00","end":"19:00"}},"is_default":false,"alert_uuids":["01a178db-d7b6-7131-a50c-cb60224dd1cd"]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://app.hostrepute.com/api/v1/alert-groups/01a178db-d7b4-730d-82fa-5fb952d888e4 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "Business hours", "timezone": "America/New_York", "schedule": { "mon": { "enabled": true, "start": "07:00", "end": "19:00" }, "tue": { "enabled": true, "start": "07:00", "end": "19:00" }, "wed": { "enabled": true, "start": "07:00", "end": "19:00" }, "thu": { "enabled": true, "start": "07:00", "end": "19:00" }, "fri": { "enabled": true, "start": "07:00", "end": "19:00" } }, "is_default": false, "alert_uuids": [ "01a178db-d7b6-7131-a50c-cb60224dd1cd" ] }'Change a set of delivery hours. Send only the fields you want to change. The slug can’t be changed. A new schedule replaces the whole schedule.
Needs the alert-group:update ability.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The UUID of the delivery hours.
Example
01a178db-d7b4-730d-82fa-5fb952d888e4Request Body
Section titled “Request Body”object
A name for the delivery hours, up to 255 characters.
Example
Business hoursThe IANA timezone the times are in.
Example
America/New_YorkThe weekly schedule, keyed by day: mon, tue, wed, thu, fri, sat and sun. Each day is {"enabled": true, "start": "HH:MM", "end": "HH:MM"} in 24-hour time, and an enabled day must end after it starts. A day you leave out gets no alerts. Send null to allow alerts at any time.
object
Example
{ "mon": { "enabled": true, "start": "07:00", "end": "19:00" }, "tue": { "enabled": true, "start": "07:00", "end": "19:00" }, "wed": { "enabled": true, "start": "07:00", "end": "19:00" }, "thu": { "enabled": true, "start": "07:00", "end": "19:00" }, "fri": { "enabled": true, "start": "07:00", "end": "19:00" }}Make these the team’s default delivery hours.
Example
falseThe UUIDs of the alert channels that follow these hours. Replaces the current list.
Example
[ "01a178db-d7b6-7131-a50c-cb60224dd1cd"]Responses
Section titled “Responses”object
object
object
object
object
object
object
object
object
Example
{ "data": { "uuid": "01a178db-d7b4-730d-82fa-5fb952d888e4", "name": "Business hours", "slug": "business-hours", "timezone": "America/New_York", "schedule": { "mon": { "enabled": true, "start": "07:00", "end": "19:00" }, "tue": { "enabled": true, "start": "07:00", "end": "19:00" }, "wed": { "enabled": true, "start": "07:00", "end": "19:00" }, "thu": { "enabled": true, "start": "07:00", "end": "19:00" }, "fri": { "enabled": true, "start": "07:00", "end": "19:00" } }, "is_default": false, "alerts": [ { "uuid": "01a178db-d7b6-7131-a50c-cb60224dd1cd", "type": "email", "frequency": "once_on_listed_delisted", "is_active": true, "last_sent_at": "2026-10-25T21:31:02.000000Z", "created_at": "2026-07-15T13:04:51.000000Z", "updated_at": "2026-07-15T13:04:51.000000Z" } ], "created_at": "2026-07-15T13:02:19.000000Z", "updated_at": "2026-10-26T15:37:16.000000Z" }}No delivery hours with this UUID in your team
object
Example
{ "message": "No query results for model [App\\Models\\AlertGroup] 01a178db-d7b4-730d-82fa-5fb952d888e4"}Invalid schedule
object
object
Example
{ "message": "The end time must be after the start time.", "errors": { "schedule.mon.end": [ "The end time must be after the start time." ] }}
