Power Automate (WDL) function
reverse — Power Automate (WDL) function reference
Reverse array order.
Syntax
wdl
reverse(collection)
Examples
wdl
reverse(variables('rows'))→ Reversed array
wdl
first(reverse(body('Get_items')?['value']))→ The last item in the result set, without an OData sort
wdl
reverse(split(item()?['Path'], '/'))
→ The path segments in reverse order
Common mistakes & gotchas
- Works on arrays and strings, but not on objects.
- Like all WDL functions it doesn't mutate in place — it returns a new array/string, so capture the result (Compose or variable) to reuse it more than once.
Related Workflow Definition Language functions
From Arrays & collections