# Exercise draft In this exercise you will run some search requests and define your own search parameter. You may either use a REST client like Postman to run your requests or paste them directly in your browser. Start by reading the case description. Here below are a couple of links that you may find useful during this exercise: * FHIR search framework: https://www.hl7.org/fhir/search.html * FHIR Resourcelist: https://www.hl7.org/fhir/searchparameter-registry.html * Patient Resource: https://www.hl7.org/fhir/patient.html * SearchParameter Resource: https://www.hl7.org/fhir/searchparameter.html * FHIRPath: http://hl7.org/fhirpath/ * Link to download Postman: https://www.getpostman.com/ ## Steps to follow ### 1. Examples of search requests 1. Search for Patients named Jim Chalmers on the public Vonk server. 2. Search for Patients that are 18 years or older. 3. Search for Patients born in 1975. 4. Search for female Patients. Also search for Patients that are not male. Do the numbers match? Can you explain this? ### 2. Customized search parameter 1. To search for Patients that are part of multiple birth you will need to create a customized search parameter. Before you do so, always check if there's no existing parameter that you can reuse. 2. Open a XML-editor (or NotePad) and create your own SearchParameter. Hint: take a look at the XML code of the SearchParameter `periodofuse` in the Nictiz example above. At least include the following elements: url, name, status, publisher, code, base, type, description and expression. Here below are some details on adding these elements. Stop reading if you want to try it yourself first. If you wish to learn more about FHIRPath to create expressions, please follow the module on this topic or visit http://hl7.org/fhirpath/ * *url* - provide the end-point of your search parameter, note that it should end with the name of your search parameter, e.g. http://hl7.org/fhir/SearchParameter/Patient-multiplebirth * *name* - provide a name for your search parameter, it is good practice to start it with the name of the base Resource followed by the code of the parameter e.g. Patient-multiplebirth * *status* - just keep it on draft for now * *publisher* - you can put your own name here * *code* - provide the code of your search parameter, this is the code that you will need to use the parameter in a search request, e.g. multiplebirth * *base* - provide the base Resource(s) that support(s) your search parameter, in this case Patient * *type* - provide the data type of your search parameter, for a Boolean you can use a token * *description* - provide a short description in natural language * *expression* - provide the expression used to extract the value from a Resource to define if it is a match or not, in this case you could use the expression `Patient.multipleBirthBoolean | Patient.multipleBirthInteger.exists()`