Example REST trigger mapping

This example calls a REST Service (GET call) that returns weather update. It illustrates how you can map fields from related objects in the request. The request mapping maps a field from one related object, Weather City ID, where Building is the base object to update weather for the selected City.

Configuring REST Service Query Parameters

The request mapping maps a field Weather City ID to Request Parameters. Also, creates a constant pair to map the appid to get the REST response.

Car Insurance Quote: Request Mapping

Building Response

After the fields are mapped to configure query parameters, the response is configured by invoking the REST Service. This enables you to build the response by selecting the Platform record you want to map to get the response.

 response building

Mapping Response tree

After a response is built, the response tree is generated with all the REST service objects. In this example, only Humidity is mapped to the Platform Outside Humidity field for an update.

Example: response tree

Result

The example trigger is configured to run after update. The following screen shows the the existing humidity value for the city, Bedford:

Example: before trigger is run

After the record was updated, the following screen shows that the trigger received a response with the value of the humidity:

Example: after trigger is run