I am reading through the Dataweave documentation and am stumped with the example below.
The documentation says
Input directives allow you to make any number of input sources available in global variables, which can then be referenced in any part of the Transform’s body. To reference one of these, you can just call it by the name you defined in the directive.
Then follows up with the example below
%dw 1.0
%input in0
%output application/xml
---
payload
My questions:
In which scopes will mule look for the variable in0? Payload, Flow, Session or something else, and in which order?
In this example, where is in0 used? How does it help in this example?
Why would I need an input variable? Dataweave seems to allow flowVars.hello.