Skip to content

docs: add today_with_timezone and min to macros #481

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
📝 Add today_with_timezone and min to macros
This commit adds the today_with_timezone and min macros to the list of
macros defined in `declarative_component_schema.yaml`. This is important
because this file is used to generate the YAML reference in Airbyte's
documentation.

See the fetchSchema script in main repository for details.
  • Loading branch information
Morgan Kerle authored and morgan-dgk committed May 2, 2025
commit 2cd70489fce6b584cf2f033298cee26fd103756f
15 changes: 15 additions & 0 deletions airbyte_cdk/sources/declarative/declarative_component_schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4262,6 +4262,14 @@ interpolation:
examples:
- "'{{ today_utc() }}' -> '2021-09-01'"
- "'{{ today_utc().strftime('%Y/%m/%d')}}' -> '2021/09/01'"
- title: today_with_timezone
description: Returns the current date in the specified timezone. The output is a date object.
arguments:
timezone: timezone expressed as IANA keys format.
return_type: Date
examples:
- "'{{ today_with_timezone('Australia/Sydney') }}' -> '2021-09-01'"
- "'{{ today_with_timezone('Europe/Lisbon') }}' -> '2021-08-01'"
- title: timestamp
description: Converts a number or a string representing a datetime (formatted as ISO8601) to a timestamp. If the input is a number, it is converted to an int. If no timezone is specified, the string is interpreted as UTC.
arguments:
Expand All @@ -4273,6 +4281,13 @@ interpolation:
- "'{{ timestamp('2022-02-28T00:00:00Z') }}' -> 1646006400"
- "'{{ timestamp('2022-02-28 00:00:00Z') }}' -> 1646006400"
- "'{{ timestamp('2022-02-28T00:00:00-08:00') }}' -> 1646035200"
- title: min
description: Returns the smallest object of a iterable, or or two or more arguments.
arguments:
args: iterable or a sequence of two or more arguments
examples:
- "'{{ min(2, 3) }}' -> 2"
- "'{{ min([2, 3]) }}' -> 2"
- title: max
description: Returns the largest object of a iterable, or or two or more arguments.
arguments:
Expand Down
Loading