List of functions
- Name:
element_text
- Description: Extracts text from
html
. Strips leading and trailing whitespaces. - Args: n/a
- Valid input types:
html
- Expected output types:
str
- Name:
xpath
- Description: Executes an XPath expression on the given input value. If the execution fails to produce a result, the following expression in the array is used. XSLT functions can be used in expressions. XPath version 1.0 is supported. XSLT version 1.0 is supported.
- Args:
xpath_expressions
- Type:
[str]
- Required:
true
- Valid input types:
html
- Expected output types:
[str]
[html]
str
float
bool
- Name:
xpath_one
- Description: Works the same way as
xpath
, but returns only the first value even if more than one value is selected by the provided XPath. - Args:
xpath_expressions
- Type:
[str]
- Required:
true
- Valid input types:
html
- Expected output types:
str
html
str
float
bool
- Name:
css
- Description: Executes an CSS expression on the given input value. If the execution fails to produce a result, the following expression in the array is used. Please note that the output of the
css
function always is a JSON array containing HTML elements (including the opening and closing tags). If you're interested in extracting the content of the element, you may execute theelement_text
function afterwards. - Args:
css_expressions
- Type:
[str]
- Required:
true
- Valid input types:
html
- Expected output types:
[html_element]
- Name:
css_one
- Description: Works the same way as
css
, but returns only the first value even if more than one value is selected by the provided CSS expression. Please note that the output of thecss_one
function always is an HTML element (including the opening and closing tags). If you're interested in extracting the content of the element, you may execute theelement_text
function afterwards. - Args:
css_expressions
- Type:
[str]
- Required:
true
- Valid input types:
html
- Expected output types:
html_element
- Name:
amount_from_string
- Description: Find the first occurrence of a numeric value in a string and convert it to a float.
- Args: n/a
- Valid input types:
str
- Expected output types:
float
- Name:
amount_range_from_string
- Description: Finds all occurrences of numeric values in a string and converts them to floats.
- Args: n/a
- Valid input types:
str
- Expected output types:
[float]
- Name:
join
- Description: Joins a list of strings into a single string. Joined values are separated by the
separator
value. - Args:
separator
- Type:
str
- Required:
false
- Default:
""
- Valid input types:
[str]
- Expected output types:
str
- Name:
regex_find_all
- Description: Finds all strings that match a given RegEx expression.
- Args:
regex_pattern
- Type:
str
- Required:
true
- Valid input types:
str
- Expected output types:
[str]
- Name:
regex_search
- Description: Finds a string that matches the given RegEx expression. Returns the specified matching group (defaults to
0
). - Args:
regex_pattern
- Type:
str
- Required:
true
group_to_return
- Type:
int
- Required:
false
- Default:
0
- Valid input types:
str
- Expected output types:
str
- Name:
regex_substring
- Description: Finds a string that matches the given RegEx expression. Returns the specified matching group (defaults to
0
). - Args:
regex_pattern
- Type:
str
- Required:
true
group_to_return
- Type:
int
- Required:
false
- Default:
0
- Valid input types:
str
- Expected output types:
str
- Name:
length
- Description: Gets the length of the array. If a multi-dimensional array is provided as input, the function will work on the innermost array.
- Args: n/a
- Valid input types:
[OneDimensionalArray]
- Expected output types:
int
- Name:
select_nth
- Description: Returns the nth array element. Zero-based indexing is used. Supports negative indexes to select last (
-1
), second last (-2
), … item from an array. - Args:
index
- Type:
int
- Required:
true
- Valid input types:
[AnyType]
- Expected output types:
AnyType
- Name:
convert_to_float
- Description: Converts a string or an int to a float.
- Args: n/a
- Valid input types:
str
int
- Expected output types:
float
- Name:
convert_to_int
- Description: Converts a string or a float to an int.
- Args: n/a
- Valid input types:
str
float
- Expected output types:
int
- Name:
convert_to_str
- Description: Converts an int or a float to a string.
- Args: n/a
- Valid input types:
int
float
- Expected output types:
string
- Name:
average
- Description: Calculates the average of values in an array.
- Args:
round_precision
- Type:
int
- Required:
false
- Valid input types:
[int]
[float]
- Expected output types:
float
- Name:
max
- Description: Finds the greatest value in an array.
- Args: n/a
- Valid input types:
[float]
[int]
- Expected output types:
float
int
- Name:
min
- Description: Finds the smallest value in an array.
- Args: n/a
- Valid input types:
[float]
[int]
- Expected output types:
float
int
- Name:
product
- Description: Returns the multiplication product of all array values.
- Args: n/a
- Valid input types:
[float]
[int]
- Expected output types:
float
int
Last modified 3mo ago