> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hubtalk.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# FAQ: hours, window and campaign day

> Hour checks, cutting the campaign end to the window, the notice key, moving the campaign to tomorrow.

# FAQ: cutting the campaign by the current time and the working window

> [accordion] Which hour checks the adapter performs
>
> First come the four V2 checks by hour — minutes are ignored. The window is the adapter account window; the current hour is in the organization's time zone.
>
> | Check | Text to the client |
> | - | - |
> | 1. `ending_hour` outside the adapter account window (`create` only) | End time is out of eligible range from 10 to 21 (the numbers in the text are a V2 legacy, not the actual limits) |
> | 2. Current hour ≥ `ending_hour`, and the window is still open (`create` only) | The end time is set incorrectly, the current time is greater than the end time |
> | 3. `start_hour` ≥ `ending_hour` (`create` only) | The end time is set incorrectly, the end time is less than or equal to the start time |
> | 4. `start_hour` outside the window (any operation with `start_hour`) | The time is set incorrectly, restrictions from 8 to 19 |
>
> Then hours with minutes are calculated: end = `ending_hour:ending_minute` (24 means 23:59), and it is cut to the earlier of the adapter account window end and the organization's calling window end. When the end is cut, the client gets the key `"notice":"End time 21:30 is out of eligible range, cut to 21:00"` in the response. If the start (the specified one or the adapter account's start hour) is not earlier than the cut end, the client gets the text of check 3.

> [accordion] The client sees a notice key in the response. Is it an error?
>
> No. The request is accepted and the campaign is created; only the end is shortened to the window. This is the only key beyond the V2 templates; a client that parses JSON by key will skip it. If the client compares the whole response body, it needs to send an end inside the window.

> [accordion] The request went to tomorrow, although the client expected calls today
>
> The «campaign day» rule: if 5 minutes or less remain until the end of the campaign day, or it has already passed, the campaign is created for the next day with the same hours. The end of the campaign day is the earliest of the organization window end, the adapter account window end, and the request end after the cut. The V2 rule «from 19:56 to tomorrow» was not carried over. Check the date in the campaign name and `rl_today`.

> [accordion] Every repeat of the request gets «Internal error», and the campaign is cancelled at once
>
> Probable cause: the organization's calling window was narrowed after the adapter account was set up, and the request start became earlier than the start of the organization window. The cut shortens only the end, and the platform rejects a start that is too early.
>
> **What to do:** narrow the adapter account window in the edit window (the cabinet shows the organization window) and ask the client to send a start inside the window. Engineers will confirm the exact cause in the logs.

> [accordion] The client sent an end of 21:30, but the campaign shows 21:00. Are the minutes lost?
>
> Yes: the end is cut to the adapter account window end of 21:00, and the minutes of the window's last hour are lost. If minutes matter to the client, the adapter account window must end later.

See also: [Hours](https://docs.hubtalk.ai/v4/compat-adapter/create.md#hours) and [Campaign day and campaign](https://docs.hubtalk.ai/v4/compat-adapter/create.md#campaign-day-and-campaign).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.