name=Mariano&lastName=de+Achaval
URL Encoded Format
MIME Type: application/x-www-form-urlencoded
ID: urlencoded
URL encoded data represents a collection of key-value pairs. DataWeave represents these values as an object in which each value is a string.
Examples
The following examples show uses of the URL Encoded format:
Example: Represent URL Encoded Data in the DataWeave (dw) Format
This example shows how DataWeave represents simple URL encoded data.
Input
The URL encoded data serves as input payload to the DataWeave source.
Example: Generate URL Encoded Data from a JSON Object
This example shows how to generate URL Encoded data.
Input
The JSON object serves as the input payload to the DataWeave source.
{
"name": "Mariano"
}
Example: Generate URL Encoded Data from a Collection of Key-Value Pairs
This DataWeave script produces the URL encoded output.
Example: Transform URL Encoded Data to the Text Plain Format
This example transforms URL Encoded input into the Text Plain format and MIME type.
Configuration Properties
DataWeave supports the following configuration properties for the URL Encoded format.
Writer (for URL Encoded Data)
The URL Encoded format accepts properties that provide instructions for writing output data.
Parameter | Type | Default | Description |
---|---|---|---|
|
|
|
Size of the writer buffer. |
|
|
|
When set to |
|
|
|
Encoding for the writer to use. |