DataWeave is the programming language designed by MuleSoft for data transformation. It enables you to build a simple solution for a common integration developer use case: read and parse data from one format, transform the data, and write it out as a different format.
Flex Gateway supports a subset of DataWeave in policy configuration expressions. DataWeave is only supported in included policies and custom policies created with PDK..
-
Null
-
Boolean
-
String
-
Number
(Driven as 64 bits floating points) -
Array
-
Object
(Repeated keys are not available)
-
Null
(Writing anull
literal is not supported) -
Object
(Objects can not be defined as literals)
-
substringAfter(String, String): String
-
substringAfter(Null, String): Null
-
substringAfterLast(String, String): String
-
substringAfterLast(Null, String): Null
-
substringBefore(String, String): String
-
substringBefore(Null, String): Null
-
attributes
-
attributes.headers
-
attributes.method
(Only available in request context) -
attributes.queryParams
(Only available in request context) -
attributes.queryString
(Only available in request context) -
attributes.requestPath
(Only available in request context) -
attributes.requestUri
(Only available in request context) -
attributes.localAddress
(Only available in request context) -
attributes.remoteAddress
(Only available in request context) -
attributes.scheme
(Only available in request context) -
attributes.version
(Only available in request context) -
attributes.statusCode
(Only available in response context)
-
-
authentication
-
authentication.clientId
-
authentication.clientName
-
authentication.principal
-
authentication.properties
-
-
payload
-
payload
-
-
vars
-
vars.claimSet.*
(Only available for JWT Policy configuration)
-