Power Automate: xpath function
Parses an XML document to extract nodes, attributes, and counts. Input must be XML type.
Power Automate expressions are where a lot of the real magic happens, and this is my reference for the functions that power them. When the point-and-click designer runs out of road, a well-placed expression gets you exactly what you need. I document the everyday date and time helpers like the "addDays" function, the "addHours" function, and the "addMinutes" function, along with the more flexible "addToTime" function for shifting timestamps. I cover math with the "add" function, logic with the "and" function, and data shaping with the "addProperty" function and the "array" function. Need to convert data types? The "base64ToBinary" function gets its own walkthrough, and the "action" and "actions" functions let you reach into earlier steps. Every entry gives you the syntax, the parameters, the return value, a practical example, and the edge cases that catch people out.
Parses an XML document to extract nodes, attributes, and counts. Input must be XML type.
Returns the query string from a URL. Empty when there are no parameters.
Returns the protocol from a URL: 'https', 'ftp', or any valid scheme.
Returns the full path and query string from a URL.
Returns just the path segment from a URL.
Returns the first day of any month.
Returns the exact start of an hour from a timestamp.
Resets a timestamp to midnight.
Returns the last element of an array or the last character of a string.
Returns an action's full results inside an expression. The mechanism behind Dynamic Content.
Returns the current value of a variable.
Returns the domain name from a URL. Strips protocol, path, and query string.