Ir al contenido

Actualizar configuración de horarios

PATCH
/handler-system/schedule-config/{id}
curl --request PATCH \
--url https://api.matiasimpulso.com/handler-system/schedule-config/1 \
--header 'Content-Type: application/json' \
--data '{ "whatsappId": 1, "schedules": { "monday": { "enabled": true, "ranges": [ { "start": "09:00", "end": "18:00" } ] }, "saturday": { "enabled": false, "ranges": [] } }, "holidays": [ "2026-12-25", "2027-01-01" ], "outOfHoursEnabled": true, "outOfHoursAiPolicy": "only_without_ai", "outOfHoursMessage": "example", "afterHoursHandlerType": "example", "collectiveVacationEnabled": true, "collectiveVacationStart": "example", "collectiveVacationEnd": "example", "collectiveVacationMessage": "example", "timezone": "example" }'
id
required
number

ID de la configuración

Media type application/json
object
whatsappId

ID del canal WhatsApp

number
schedules

Horarios por día: hasta 4 tramos HH:MM con fin posterior al inicio (sin cruzar la medianoche)

object
key
additional properties
any

Example

{
"monday": {
"enabled": true,
"ranges": [
{
"start": "09:00",
"end": "18:00"
}
]
},
"saturday": {
"enabled": false,
"ranges": []
}
}
holidays

Días festivos (YYYY-MM-DD, máximo 60)

Array<string>

Example

[
"2026-12-25",
"2027-01-01"
]
outOfHoursEnabled

Responder fuera de horario (apagado por defecto)

boolean
outOfHoursAiPolicy

Qué hacer si atiende un agente IA

string
Allowed values: only_without_ai before_ai instead_of_ai
outOfHoursMessage

Mensaje fuera de horario (variables de chat)

string
nullable <= 1000 characters
afterHoursHandlerType

Ignorado (campo heredado de wchat)

string
<= 50 characters
collectiveVacationEnabled

Vacaciones colectivas activas

boolean
collectiveVacationStart

Inicio de vacaciones colectivas (YYYY-MM-DD)

string
nullable
collectiveVacationEnd

Fin de vacaciones colectivas (YYYY-MM-DD)

string
nullable
collectiveVacationMessage

Mensaje durante vacaciones colectivas

string
nullable <= 1000 characters
timezone

Zona horaria IANA. Al crear sin ella se usa la del país de la empresa

string
<= 50 characters

Configuración actualizada exitosamente

Configuración no encontrada