Skip to main content

Value Modifiers

This page provides you with a comprehensive list of all the available modifications you can apply to text, numbers, lists, and dates within DealerClear. Each modifier includes its purpose, a brief description, and the expected input parameters.


Important

Modifiers are a powerful tool for refining and transforming data, especially for matching and mapping logic. However, their flexibility comes with responsibility. To ensure accuracy and avoid unintended outcomes, it’s crucial to carefully test and validate your modifier configurations before applying them to live services.

The results of poorly tested modifiers can be app-breaking. When in doubt, contact support.

Text Modifiers

Note: All string/text mods begin with the str__ prefix.

ModifierDescriptionParametersExample
str__add_prefixAdds a prefix to the value.<prefix>Input: value, Prefix: pre_pre_value
str__add_suffixAdds a suffix to the value.<suffix>Input: value, Suffix: _postvalue_post
str__removeRemoves instances of a character or set of characters from the value.<char>Input: hello, Remove: lheo
str__replaceReplaces instances of a character or set of characters with a substitute.<char>||<substitute>Input: cat, Replace: c||bbat
str__splitSplits the value by a delimiter and grabs an item by index (starting at 0).<delimiter>||<index>Input: a,b,c, Split: ,||1b
str__cut_leftRemoves a specified number of characters from the left of the value.<num_chars>Input: abcdef, Cut: 3def
str__cut_rightRemoves a specified number of characters from the right of the value.<num_chars>Input: abcdef, Cut: 3abc
str__trimRemoves leading and trailing whitespace.NoneInput: hello hello
str__pad_leftPads the value on the left with spaces to the specified total length.<total_length>Input: cat, Pad: 5 cat
str__pad_rightPads the value on the right with spaces to the specified total length.<total_length>Input: cat, Pad: 5cat
str__capitalizeCapitalizes the first character of the value.NoneInput: helloHello
str__title_caseConverts the value to title case.NoneInput: hello worldHello World
str__upper_caseConverts the value to upper case.NoneInput: helloHELLO
str__lower_caseConverts the value to lower case.NoneInput: HELLOhello
str__repeatRepeats the value a specified number of times.<times>Input: ha, Repeat: 3hahaha
str__reverseReverses the value.NoneInput: helloolleh
str__sliceExtracts a substring using start and end indices.<start_index>||<end_index>Input: abcdef, Slice: 1||4bcd

Number Modifiers

Note: All numerical mods begin with the num__ prefix.

ModifierDescriptionParametersExample
num__addAdds a specified number to the value.<number>Input: 10, Add: 515
num__subtractSubtracts a specified number from the value.<number>Input: 10, Subtract: 37
num__multiplyMultiplies the value by a specified number.<number>Input: 4, Multiply: 312
num__divideDivides the value by a specified number. Returns 0 if divisor is 0.<number>Input: 10, Divide: 25; Divisor: 00
num__roundRounds the value to a specified number of decimal places.<decimal_places>Input: 3.14159, Round: 23.14
num__floorRounds the value down to the nearest whole number.NoneInput: 4.84
num__ceilRounds the value up to the nearest whole number.NoneInput: 4.25
num__modulusReturns the remainder of the value divided by a specified number.<number>Input: 10, Modulus: 31
num__powerRaises the value to the power of a specified number.<exponent>Input: 2, Power: 38
num__formatFormats the value as a string using a specified format (e.g., .2f for two decimal places).<format_string>Input: 3.14159, Format: .2f3.14

List Modifiers

Note: All list mods begin with the list__ prefix.

ModifierDescriptionParametersExample
list__lengthReturns the number of elements in the list.NoneInput: [1, 2, 3]3
list__getRetrieves the element at the specified index.<index>Input: [10, 20, 30], Index: 120
list__appendAppends a specified value to the list.<value>Input: [1, 2], Append: 3[1, 2, 3]
list__extendExtends the list with elements from a comma-separated string.<comma_separated_values>Input: [1, 2], Extend: 3,4[1, 2, 3, 4]
list__removeRemoves all instances of the specified value from the list.<value>Input: [1, 2, 2, 3], Remove: 2[1, 3]
list__sliceReturns a portion of the list based on specified start and end indices.<start_index>||<end_index>Input: [1, 2, 3, 4], Slice: 1||3[2, 3]

Date & Time Modifiers

Note: All date mods begin with the date__ prefix and datetime mods with datetime__.
The official date/datetime formats:

  • Date = YYYY-MM-DD
  • DateTime = YYYY-MM-DD HH:MM:SS
ModifierDescriptionParametersExample
date__from_formatParses a date string using the specified format and returns a date object.<format>Input: 2023-12-01, Format: YYYY-MM-DD → Date Object: 2023-12-01
datetime__from_formatParses a datetime string using the specified format and returns a datetime object.<format>Input: 2023-12-01 14:30:00, Format: YYYY-MM-DD HH:MM:SS → Datetime Object: 2023-12-01 14:30:00
date__to_formatFormats a date string into the specified format (e.g., YYYY-MM-DD).<format>Input: 01/12/2023, Format: DD/MM/YYYY2023-12-01
datetime__to_formatFormats a datetime string into the specified format (e.g., YYYY-MM-DD HH:MM:SS).<format>Input: 01-12-2023 02:30 PM, Format: DD-MM-YYYY hh:mm A2023-12-01 14:30:00
datetime__add_daysAdds a specified number of days to a date.<number_of_days>Input: 2023-12-01, Add: 52023-12-06
datetime__subtract_daysSubtracts a specified number of days from a date.<number_of_days>Input: 2023-12-01, Subtract: 52023-11-26
datetime__add_hoursAdds a specified number of hours to a datetime.<number_of_hours>Input: 2023-12-01 14:00:00, Add: 32023-12-01 17:00:00
datetime__subtract_hoursSubtracts a specified number of hours from a datetime.<number_of_hours>Input: 2023-12-01 14:00:00, Subtract: 32023-12-01 11:00:00
datetime__day_of_weekReturns the day of the week for a specified date.NoneInput: 2023-12-01Friday
datetime__day_of_yearReturns the day of the year for a specified date.NoneInput: 2023-12-01335
datetime__yearExtracts the year from a specified date.NoneInput: 2023-12-012023
datetime__monthExtracts the month from a specified date.NoneInput: 2023-12-0112
datetime__dayExtracts the day from a specified date.NoneInput: 2023-12-011
date_splitSplits a date into year, month, and day components as a list.NoneInput: 2023-12-01[2023, 12, 1]

This reference is a quick guide to all available modifications, organized by data type. Use it to quickly find the modifiers that meet your needs.