Yes, you can achieve the same lead data enrichment using the RestLookupService. The format of the data that the API should return depends on the specific requirements of your use case, but it typically should be in a format that can be easily processed and integrated into your data flow.
For example, if you are looking to perform simple key-value lookups, the API could return data in JSON format with a structure similar to the following:
{
"key1": "value1",
"key2": "value2",
...
}
You can then use the values returned from the API to update or add fields in your data flow by mapping the keys in the API response to fields in your data.
It's important to note that the RestLookupService can handle a variety of data formats, including JSON, XML, or even plain text. The choice of format depends on the specific requirements of your use case and the capabilities of the API you are using.