FHIR mapping example
In this example, you use a FHIR connection to access a patient's records on the HAPI FHIR test server using a GET REST API operation.
1In Data Integration, click New > Mappings > Mapping and then click Create.
2In the Source transformation, select the FHIR connection.
3Select GET as the operation.
4In the request options, configure the request message.
5Copy and paste the following request message:
<!--1 or more repetitions:-->
<proc:GET_INPUT xmlns:proc="http://xml.schemas/infa/procedure/">
<!--Optional:-->
<GET>
<!--Optional:-->
<requestHeaders/>
<!--Optional:-->
<pathParams>11111,_history,<pathParams/>
<!--Optional:-->
<queryParams>given=Benjamin;id=2123;identifier=bcook74;gender=male<queryParams/>
</GET>
</proc:GET_INPUT>
6In the advanced properties, configure the following properties:
- aEnter /Patient as the path.
- bSelect buffer as the request body type.
- cEnable the option to convert the request data format.
- dEnter /root/FHIR/ as the response directory.
7On the Field Mapping tab, map the output of the GET request to the output field.
8In the Target transformation, configure a flat file connection and use a POST request to write the output to a flat file.