Wait Weekday icon

Wait Weekday

Aguarda por um período específico respeitando dias permitidos

Overview

This node pauses the workflow execution for a specified amount of time, respecting allowed weekdays and optionally executing at a specific time of day. It is useful when you want to delay further processing until a certain time or day, such as waiting for business hours or avoiding weekends.

Practical examples:

  • Wait 3 days but only on weekdays (Monday to Friday), starting execution at 10:35 AM.
  • Pause the workflow for 2 hours before continuing.
  • Delay for 45 minutes regardless of the day.

Properties

Name Meaning
Unidade de Tempo Time unit to wait: "Dias" (days), "Horas" (hours), "Minutos" (minutes), "Segundos" (seconds)
Quantidade Amount of time to wait in the selected time unit
Especificar Horário de Execução Whether to execute at a specific time of day (only shown if time unit is "days")
Hora de Execução Hour of execution (0-23), used if specifying a specific time of day
Minuto de Execução Minute of execution (0-59), used if specifying a specific time of day
Dias Permitidos Allowed weekdays for execution (only shown if time unit is "days"): Monday to Friday selectable

Output

The node outputs the input data unchanged but adds a waitInfo object inside each item's JSON with details about the wait:

  • originalDate: ISO string of the start time when waiting began.
  • executionDate: ISO string of the calculated date/time when execution will resume.
  • waitUnit: The time unit used ("days", "hours", "minutes", or "seconds").
  • waitAmount: The amount of time waited.
  • If waiting by days and using a specific time:
    • executionDay: The name of the weekday when execution resumes.
    • useSpecificTime: Boolean indicating if a specific time was used.
    • executionTime: The time of day (HH:mm) when execution resumes.

No binary data output is produced.

Dependencies

  • No external services or API keys are required.
  • The node relies on JavaScript's native Date and setTimeout functions.
  • No special n8n environment variables or credentials needed.

Troubleshooting

  • Long wait times: Waiting for large amounts of time (especially days) may cause workflow executions to be held open for extended periods, which could impact system resources.
  • Incorrect day calculation: If the allowed days do not include the current or next days, the node will skip forward until it finds an allowed day. Ensure allowed days are correctly configured.
  • Time zone considerations: The node uses the server's local time zone. Differences between expected and actual execution times can occur if the server time zone differs from the user's.
  • Invalid time inputs: Hours must be between 0-23 and minutes between 0-59; invalid values may cause unexpected behavior.

Links and References

Discussion