> For the complete documentation index, see [llms.txt](https://docs.borndigital.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.borndigital.ai/digital-agent/tools-reference/date-and-time.md).

# Date & time

Dates, times, working hours and holidays.

Dates, times, working hours and holidays. How to add a tool and use its result is described in [Tools & smart functions](https://docs.borndigital.ai/digital-agent/tools-reference.md).

| Tool                              | Technical name            | What it does                                                                                                                     | Languages                              |
| --------------------------------- | ------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------- |
| Birthdate extractor               | `birthdate`               | Guess and return a user-provided date in ISO format (YYYY-MM-DD) from natural language input.                                    | cs, de, pl, sk, ro, sv, en             |
| Check working hours               | `is_open_input_data`      | Return whether a specified time (or now) falls within the working hours for a given project and list the intervals for that day. | any                                    |
| Closest workday                   | `get_closest_work_day`    | Return iso-format date of the closest workday (Holidays extension marks it).                                                     | any                                    |
| Current date extractor            | `current_date`            | Today's date in the Europe/Prague time zone, as text (YYYY-MM-DD).                                                               | any                                    |
| Current time extractor            | `current_time`            | The current date and time in the Europe/Prague time zone, as ISO text.                                                           | any                                    |
| Current UTC time millis extractor | `current_utc_time_millis` | Return the current UTC date and time in ISO format with millisecond precision.                                                   | any                                    |
| Date and time                     | `dateandtime`             | Try to guess date and time intended by user. Supports single precise events for now.                                             | cs, sk, pl                             |
| Date extractor                    | `date`                    | Try to guess date intended by user. Supports single precise events for now.                                                      | cs, sk, pl, de, ro, en, nl, fr, hu, sv |
| Holiday checker                   | `holidays`                | Return True if the specified date or today is a holiday or weekend in the given countries, otherwise False.                      | sk, cs, pl, de                         |
| Month name into a number          | `detect_month`            | If month mentioned by word, return the numeric order of it as an integer.                                                        | cs, sk, de                             |
| Readable date                     | `to_readable_date`        | Convert a date in dd.mm.yyyy format into a human-readable word form in the specified language                                    | cs, sk                                 |
| Time extractor                    | `time`                    | Extract the time mentioned in the user’s utterance and return it in HH:MM format                                                 | cs, sk, pl, de, en, ro, nl, fr, hu     |
| To date                           | `to_date`                 | The date part (YYYY-MM-DD) of a date and time.                                                                                   | any                                    |
| UTC to local time                 | `utc_to_local`            | Convert a UTC ISO 8601 timestamp to Europe/Prague local time using daylight-saving rules.                                        | any                                    |

## Birthdate extractor

Technical name: `birthdate`

Guess and return a user-provided date in ISO format (YYYY-MM-DD) from natural language input.

* Languages: cs, de, pl, sk, ro, sv, en.

| Parameter    | Name           | Required | Default | Description                                                                       |
| ------------ | -------------- | -------- | ------- | --------------------------------------------------------------------------------- |
| Custom input | `custom_input` | no       |         | Provide text containing the date to parse instead of using the last user message. |

**Example input:** On January 15, 2020 at eight o'clock

**Example output:**

```
2020-01-15
```

## Check working hours

Technical name: `is_open_input_data`

Return whether a specified time (or now) falls within the working hours for a given project and list the intervals for that day.

* Can also be used in expressions as `is_open_input_data()`.

| Parameter          | Name                 | Required | Default | Description                                                                  |
| ------------------ | -------------------- | -------- | ------- | ---------------------------------------------------------------------------- |
| Table name         | `table_name`         | yes      |         | Name of the input data table that contains working hours.                    |
| Lookup row name    | `lookup_row_name`    | yes      |         | Name of the project to look up working hours for.                            |
| Lookup column name | `lookup_column_name` | yes      |         | Name of the column to match the project name.                                |
| Open hours column  | `open_hours_column`  | yes      |         | Name of the column containing working-hour ranges.                           |
| Date to check      | `date_to_check`      | no       |         | (Optional) Specific date and time to check in ISO format (YYYY-MM-DDThh:mm). |

**Example input:** This function does not use the user input utterance.

**Example output:**

```
[False, []]
```

## Closest workday

Technical name: `get_closest_work_day`

Return iso-format date of the closest workday (Holidays extension marks it).

* Can also be used in expressions as `get_closest_work_day()`.

| Parameter    | Name           | Required | Default | Description                                                                                                         |
| ------------ | -------------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------- |
| Countries    | `countries`    | no       |         | List of iso2 codes of the country. But single code is also accepted.                                                |
| Offset       | `offset`       | no       | `0`     | Number of days to offset the output business day.                                                                   |
| Custom input | `custom_input` | no       |         | Custom input defined by the user from the flow. If set then it will be used as input instead of the last utterance. |

**Example input:** 2023-12-23

**Example output:**

```
2023-12-27
```

## Current date extractor

Technical name: `current_date`

Today's date in the Europe/Prague time zone.

* Not shown in the tool list until you type its name – start typing `current_date`.
* Can also be used in expressions as `current_date()`.
* Advanced – usually set up together with Born Digital.

**Example input:** This function does not use the user input utterance.

**Example output:**

```
2026-10-16
```

**In expressions** `current_date()` returns today's date, for example `current_date().month == 12`. Used as a tool, it stores the date as text, for example `2026-10-16`.

## Current time extractor

Technical name: `current_time`

The current date and time in the Europe/Prague time zone.

* Not shown in the tool list until you type its name – start typing `current_time`.
* Can also be used in expressions as `current_time()`.
* Advanced – usually set up together with Born Digital.

**Example input:** This function does not use the user input utterance.

**Example output:**

```
2026-10-19T14:00:00+02:00
```

Used as a tool, it stores the date and time as text in ISO format, as above.

**In expressions** `current_time()` returns the current date and time in the Europe/Prague time zone, so you can use its parts directly:

```python
current_time().hour            # 0–23
current_time().weekday()       # Monday is 0, Sunday is 6
current_time().strftime("%H:%M")
```

The Function node's **Time** toolkit inserts these snippets for you. Used as a tool, it stores the time as text, for example `2026-10-16T14:05:09.123456+02:00`. See also [Setting time-based greetings](https://docs.borndigital.ai/for-advanced-users/conversation-design-tips/setting-time-based-greetings.md).

## Current UTC time millis extractor

Technical name: `current_utc_time_millis`

Return the current UTC date and time in ISO format with millisecond precision.

* Can also be used in expressions as `current_utc_time_millis()`.

**Example input:** This function does not use the user input utterance.

**Example output:**

```
2025-05-30T14:00:00.000Z
```

## Date and time

Technical name: `dateandtime`

Try to guess date and time intended by user. Supports single precise events for now.

* Languages: cs, sk, pl.

| Parameter    | Name               | Required | Default | Description                                                                                                           |
| ------------ | ------------------ | -------- | ------- | --------------------------------------------------------------------------------------------------------------------- |
| Current date | `current_datetime` | no       |         | All relative information are computed from this datetime, if not set, use datetime at the moment of user interaction. |
| Time offset  | `time_offset`      | no       | `2`     | Time offset in hours for temporal phrase `today` with no context.                                                     |
| Custom input | `custom_input`     | no       |         | User's custom input defined from the flow.                                                                            |

**Example input:** Zavolajte mi 1. Februára.

**Example output:**

```
2024-02-01T00:00:00
```

## Date extractor

Technical name: `date`

Try to guess date intended by user. Supports single precise events for now.

* Languages: cs, sk, pl, de, ro, en, nl, fr, hu, sv.

| Parameter    | Name           | Required | Default | Description                                                     |
| ------------ | -------------- | -------- | ------- | --------------------------------------------------------------- |
| current date | `current_date` | no       |         | reference point for relative terms like tomorrow or next Monday |
| Custom input | `custom_input` | no       |         | users custom input defined from the flow                        |

**Example input:** Dvacátého čtvrtého prosince slavíme štědrý večer 2021.

**Example output:**

```
2021-12-24
```

## Holiday checker

Technical name: `holidays`

Return True if the specified date or today is a holiday or weekend in the given countries, otherwise False.

* Can also be used in expressions as `holidays()`.
* Languages: sk, cs, pl, de.

| Parameter       | Name              | Required | Default | Description                                                                                                                |
| --------------- | ----------------- | -------- | ------- | -------------------------------------------------------------------------------------------------------------------------- |
| Date string     | `datestring`      | no       |         | Custom date to check in YYYY-MM-DD format.                                                                                 |
| Countries       | `countries`       | no       |         | List of ISO country codes to check holidays for (e.g., \['de', 'at']); defaults to language-based country if not provided. |
| Custom holidays | `custom_holidays` | no       |         | List of additional holiday dates in YYYY-MM-DD format.                                                                     |

**Example input:** Is today a holiday?

**Example output:**

```
False
```

## Month name into a number

Technical name: `detect_month`

If month mentioned by word, return the numeric order of it as an integer.

* Languages: cs, sk, de.

| Parameter    | Name           | Required | Default | Description                                                                                                         |
| ------------ | -------------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------- |
| Custom input | `custom_input` | no       |         | Custom input defined by the user from the flow. If set then it will be used as input instead of the last utterance. |

**Example input:** patnáctýho února 1928 v osm hodin.

**Example output:**

```
2
```

## Readable date

Technical name: `to_readable_date`

Convert a date in dd.mm.yyyy format into a human-readable word form in the specified language

* Can also be used in expressions as `to_readable_date()`.
* Languages: cs, sk.

| Parameter | Name   | Required | Default | Description                                          |
| --------- | ------ | -------- | ------- | ---------------------------------------------------- |
| Date      | `date` | yes      |         | Date string in dd.mm.yyyy format to convert to words |

**Example input:** The date is 12.04.1993

**Example output:**

```
dvanáctého dubna tisíc devětset devadesát tři
```

## Time extractor

Technical name: `time`

Extract the time mentioned in the user’s utterance and return it in HH:MM format

* Languages: cs, sk, pl, de, en, ro, nl, fr, hu.

| Parameter            | Name                   | Required | Default | Description                                        |
| -------------------- | ---------------------- | -------- | ------- | -------------------------------------------------- |
| Current time         | `current_time`         | no       |         | Reference datetime for interpreting relative times |
| Later minutes offset | `later_minutes_offset` | no       | `75`    | Minutes offset to apply for relative 'later' terms |
| Custom input         | `custom_input`         | no       |         | Custom utterance text provided by the flow         |

**Example input:** At half past five

**Example output:**

```
17:30
```

## To date

Technical name: `to_date`

Return the date part (YYYY-MM-DD) of a date and time given in the `time` argument – for example of `current_time()`.

* Can also be used in expressions as `to_date()`.

**Example input:** This function does not use the user input utterance.

**Example output:**

```
2025-06-09
```

## UTC to local time

Technical name: `utc_to_local`

Convert a UTC ISO 8601 timestamp to Europe/Prague local time using daylight-saving rules. The result carries the offset valid on that date – `+01:00` in winter, `+02:00` in summer – so times from flight or booking systems are shown correctly all year.

* This function does not use the user input utterance.

| Parameter     | Name           | Required | Default         | Description                                                                |
| ------------- | -------------- | -------- | --------------- | -------------------------------------------------------------------------- |
| UTC timestamp | `utc_datetime` | yes      |                 | UTC ISO 8601 timestamp with an explicit UTC offset (`Z` or `+00:00`).      |
| Timezone      | `timezone`     | no       | `Europe/Prague` | IANA timezone identifier. `Europe/Prague` is currently the only supported. |

**Example input:** `{utc_datetime: "2026-07-15T12:00:00Z"}`

**Example output:**

```
2026-07-15T14:00:00+02:00
```
