Map input/output data
This page provides examples of input and output data in the Map function, taken from the example stream Data Enrichment With Foreign Exchange Rates. These views can help you troubleshoot and validate that the function works as intended.
Here are some example streams that use the Map function. These pre-configured streams can be found and executed from the UsageCloud platform for further learning. See https://infozone.atlassian.net/wiki/x/rMB3 for more details.
Input data
The Input data panel shows the data forwarded from the previous function in the stream.
In the Data Enrichment With Foreign Exchange Rates stream, the Map function receives data from the following input:
Exchange Rate (HTTP Client processor)
Below is the sample input data:
[
{
"Name": "User-0",
"ServiceFee": 25,
"Currency": "SEK",
"httpResponse": {
"base": "SEK",
"date": "2026-01-06",
"rates": {
"USD": 0.10911
}
}
},
{
"Name": "User-1",
"ServiceFee": 10,
"Currency": "EUR",
"httpResponse": {
"base": "EUR",
"date": "2026-01-06",
"rates": {
"USD": 1.173103
}
}
},
{
"Name": "User-2",
"ServiceFee": 4,
"Currency": "GBP",
"httpResponse": {
"base": "GBP",
"date": "2026-01-06",
"rates": {
"USD": 1.354959
}
}
},
{
"Name": "User-3",
"ServiceFee": 7,
"Currency": "AUD",
"httpResponse": {
"base": "AUD",
"date": "2026-01-06",
"rates": {
"USD": 0.67288
}
}
}
]Output data
The Output data panel displays the output after input data has been calculated using the configured formulas in the Map function, reflecting any changes made through the function's configuration.
Click the Preview button to inspect the output results and confirm that the function has applied the formulas to transform the data fields as intended.
Below is the sample output data.
[
{
"Name": "User-0",
"ServiceFee": 25,
"Currency": "SEK",
"USD Exchange Rate": "0.10911",
"Service Fee (USD)": 2.7278
},
{
"Name": "User-1",
"ServiceFee": 10,
"Currency": "EUR",
"USD Exchange Rate": "1.173103",
"Service Fee (USD)": 11.731
},
{
"Name": "User-2",
"ServiceFee": 4,
"Currency": "GBP",
"USD Exchange Rate": "1.354959",
"Service Fee (USD)": 5.4198
},
{
"Name": "User-3",
"ServiceFee": 7,
"Currency": "AUD",
"USD Exchange Rate": "0.67288",
"Service Fee (USD)": 4.7102
}
]