diff --git a/.gitignore b/.gitignore
index 037c63f336f84b44ac7e3c427c99911372d00de7..2d0cca9d57805ba05452881023ffdb208a749289 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,8 +1,82 @@
+
+
+
+/.allure/
+/allure-results/
+
+# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
+# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
+
+# User-specific stuff
+.idea/**/workspace.xml
+.idea/**/tasks.xml
+.idea/**/usage.statistics.xml
+.idea/**/dictionaries
+.idea/**/shelf
+
+# Generated files
+.idea/**/contentModel.xml
+
+# Sensitive or high-churn files
+.idea/**/dataSources/
+.idea/**/dataSources.ids
+.idea/**/dataSources.local.xml
+.idea/**/sqlDataSources.xml
+.idea/**/dynamic.xml
+.idea/**/uiDesigner.xml
+.idea/**/dbnavigator.xml
+
+# Gradle
+.idea/**/gradle.xml
+.idea/**/libraries
+
+# CMake
+cmake-build-*/
+
+# Mongo Explorer plugin
+.idea/**/mongoSettings.xml
+
+# File-based project format
+*.iws
+
+# IntelliJ
+out/
+
+# mpeltonen/sbt-idea plugin
+.idea_modules/
+
+# JIRA plugin
+atlassian-ide-plugin.xml
+
+# Cursive Clojure plugin
+.idea/replstate.xml
+
+# Crashlytics plugin (for Android Studio and IntelliJ)
+com_crashlytics_export_strings.xml
+crashlytics.properties
+crashlytics-build.properties
+fabric.properties
+
+# Editor-based Rest Client
+.idea/httpRequests
+
+# Android studio 3.1+ serialized cache file
+.idea/caches/build_file_checksums.ser
+
+# .iml
+*.iml
+
+# Target java created
+**/target/**
+.idea/
+
+.settings/**
+
+**/.settings/**
 .classpath
 .project
-.gitignore
+**/.classpath
+**/.project
 
-.settings/
-/target/
-/*.iml
-/.idea/
+**/.allure/**
+**/allure-results/**
\ No newline at end of file
diff --git a/PixM_Feed_Documentation/README_PixMFeed.md b/PixM_Feed_Documentation/README_PixMFeed.md
new file mode 100644
index 0000000000000000000000000000000000000000..5dffc9524a86d67cdf91f8b49209183dd3887ecd
--- /dev/null
+++ b/PixM_Feed_Documentation/README_PixMFeed.md
@@ -0,0 +1,536 @@
+# PixM Feed
+
+>Version : 1.0.0 <br />
+>Date : 2021-08-26
+
+PixM Feed lets a user to proceed some operations with Cross-Referenced (X-ref) Patient.
+The User can do the following ITI-93 transactions : Create, Update, Delete and Merge Patient (called CUDM operations)
+Each operation will be decribed later.
+
+The PixM Feed has 2 components :
+* a PixM Consumer : the Client part, where the User can do CUDM operations through a SOAP UI project uploaded in Gazelle Webservice Tester (GWT). The SOAP UI project can perform also all cases covered by the standard and shall send/receive all the required requests.
+* a PixM Manager : the Server part, where all the CUDM operations are done in order to feed the Patient database. The PixM Manager has 2 parts :
+  + PixM Connector: interpret REST FHIR requests and data to transform it into a Gazelle Patient Model for the transfert toward Patient Registry.
+  + Patient Registry : manage transaction I/O of the Patient Database, CUDM and also X-ref. The access to PatReg has to be done with GIT-B webservices.<br />
+
+The communication between PixM Connector and Patient Registry is done by a Java Client in order to translate REST operation into SOAP operation done with GIT-B webservices.
+		
+![image info](./pictures/pixm_scheme_total.png)
+
+
+All the transactions between the PixM Client and the PixM Manager are ruled byt ITI-93 transactions.<br />
+https://fhir.ch/ig/ch-epr-mhealth/iti-93.html<br />
+https://www.ihe.net/uploadedFiles/Documents/ITI/IHE_ITI_Suppl_PMIR.pdf
+
+<br />
+
+## ITI-93 transactions
+_____________________________________________________________________________________
+ITI-93 transactions are basically Bundle messages exchanged between a Supplier and a Consumer.
+The Supplier sends a Mobile Patient Feed Request to a Consumer. This event is trigerred every time patients are created, updated, merged or deleted by the Supplier.	
+The Consumer sends back a Mobile Patient feed Response to a Supplier.
+	
+  ![image info](./pictures/iti_93_interaction_diagram.png "ITI 93 Interaction Diagram")
+	
+The **Bundle PixMFeed request** has 2 entries (https://fhir.ch/ig/ch-epr-mhealth/Bundle-BundlePIXmFeed.json.html) :
+- a Message header
+- a History Bundle, containing the Patient Resource (https://www.hl7.org/fhir/patient.html)
+
+This two entries are mandatory for each transactions.
+We will see further that not every fields are mandatory to proceed operations.
+
+The **Bundle PixMFeed response** has 1 entry (https://fhir.ch/ig/ch-epr-mhealth/Bundle-BundlePIXmResponse.json.html):
+- a message response that acknowledge the transaction is done.
+
+For our purpose, the message response will also return in case of :
+- CREATE : the uuid of the newly created patient will be returned in the message
+- UPDATE : the whole Patient will be returned
+- MERGE : The uuid of the original Patient is returned
+- DELETE : The DONE or GONE status
+
+<br />
+		
+## PIXM Consumer : SOAP UI Project
+__________________________________________________________________
+The SOAP UI Project for CHPixM Feed is splitted in 2 parts :
+- the one that the user can interact with to do its request to PixM Server, can test nominal and errors requests
+- the MOCK server test implemented methods and mimic the desired comportment from the PixM Server
+	
+4 methods are implemented and their related TestSuite & TestCase
+- CREATE (C)
+- DELETE (D)
+- UPDATE (U)
+- MERGE (M)
+		
+For each TestCase, the user can filled a prefilled body with following fields :
+
+- name.given (CU)
+- name.family (CU)
+- birthDate (CU)
+- gender (CU)
+- resource (CUDM)
+- system (CU)
+- value (CU)
+- uuid (UMD)
+- uuidToRedirect (M)
+
+These fields can be accessed in each TestSuite > TestCase
+then on the bottom-left corner click on the tab "Custom properties"
+	
+		
+### CREATE METHOD : 
+__________________________________________________________________
+
+#### NOMINAL CASE :
+
+Send the following REST Request
+
+	POST : {serverAdress}/ch_fhir/Bundle/
+		
+		
+With a prefilled body as following :
+
+```json				
+{
+    "resourceType" : "Bundle",
+    "id" : "BundlePIXmFeed",
+    "meta" : {
+      "profile" : [
+        "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle"
+      ]
+    },
+    "type" : "message",
+    "entry" : [
+      {
+        "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+        "resource" : {
+          "resourceType" : "MessageHeader",
+          "id" : "1",
+          "text" : {
+            "status" : "generated",
+            "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><p><b>focus</b>: <a href=\"#Bundle_abc\">See above (Bundle/abc)</a></p></div>"
+          },
+          "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+          "destination" : [
+            {
+              "endpoint" : "http://example.com/patientEndpoint"
+            }
+          ],
+          "source" : {
+            "endpoint" : "http://example.com/patientSource"
+          },
+          "focus" : [
+            {
+              "reference" : "Bundle/abc"
+            }
+          ]
+        }
+      },
+      {
+        "fullUrl" : "http://example.com/fhir/Bundle/abc",
+        "resource" : {
+          "resourceType" : "Bundle",
+          "id" : "abc",
+          "type" : "history",
+          "entry" : [
+            {
+              "fullUrl" : "http://example.com/fhir/Patient/PatientPIXmFeed",
+              "resource" : {
+                "resourceType" : "Patient",
+                "id" : "PatientPIXmFeed",
+                "text" : {
+                  "status" : "generated",
+                  "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>id</b>: PatientPIXmFeed</p><p><b>meta</b>: </p><p><b>identifier</b>: Medical record number = 8734</p><p><b>name</b>: Franz Muster , Muster </p><p><b>gender</b>: male</p><p><b>birthDate</b>: 1995-01-27</p></div>"
+                },
+                "contained" : [
+                  {
+                    "resourceType" : "Organization",
+                    "id" : "org1",
+                    "identifier" : [
+                      {
+                        "system" : "${system}",
+                        "value" : "${value}"
+                      }
+                    ],
+                    "address" : [
+                      {
+                        "use" : "work",
+                        "line" : [
+                          "Doktorgasse",
+                          "2"
+                        ],
+                        "city" : "Musterhausen",
+                        "postalCode" : "8888",
+                        "country" : "CH"
+                      }
+                    ]
+                  }
+                ],
+                "identifier" : [
+                  {
+                    "type" : {
+                      "coding" : [
+                        {
+                          "system" : "http://terminology.hl7.org/CodeSystem/v2-0203",
+                          "code" : "MR"
+                        }
+                      ]
+                    },
+                    "system" : "${#system}",
+                    "value" : "${#value}" 
+                  }
+                ],
+                "name" : [
+                  {
+                    "family" : "${#name.family}",
+                    "given" : [
+                      "${#name.given}"
+                    ]
+                  },
+                  {
+                    "family" : "${#name.family}",
+                    "_family" : {
+                      "extension" : [
+                        {
+                          "url" : "http://hl7.org/fhir/StructureDefinition/iso21090-EN-qualifier",
+                          "valueCode" : "BR"
+                        }
+                      ]
+                    }
+                  }
+                ],
+                "gender" : "${#gender}", 
+                "birthDate" : "${#birthDate}",
+                "managingOrganization" : {
+                  "reference" : "#org1"
+                }
+              },
+              "request" : {
+                "method" : "POST", 
+                "url" : "Patient"
+              },
+              "response" : {
+                "status" : "200"
+              }
+            }
+          ]
+        }
+      }
+    ]
+  }
+```  
+
+
+These parameters are mandatory in CREATE method
+* name.given 
+* name.family 
+* birthdate
+* gender
+
+
+
+The server then should answer a response bundle like : 
+ ```json
+{
+    "resourceType" : "Bundle",
+    "id" : "BundlePIXmResponse",
+    "meta" : {
+      "profile" : [
+        "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle-response"
+      ]
+    },
+    "type" : "message",
+    "entry" : [
+      {
+        "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+        "resource" : {
+          "resourceType" : "MessageHeader",
+          "id" : "1",
+          "text" : {
+            "status" : "generated",
+            "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><h3>Responses</h3><table class=\"grid\"><tr><td>-</td><td><b>Identifier</b></td><td><b>Code</b></td></tr><tr><td>*</td><td>1</td><td>ok</td></tr></table></div>"
+          },
+          "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+          "destination" : [
+            {
+              "endpoint" : "http://example.com/patientEndpoint"
+            }
+          ],
+          "source" : {
+            "endpoint" : "http://example.com/patientSource"
+          },
+          "response" : {
+            "identifier" : "1",
+            "code" : "ok"
+          }
+        }
+      }
+    ]
+  }
+
++ The ID of the new patient newly created
+``` 
+  
+
+The following assertion will be tested when the body is sent :
+- if the returned HTTP Status is "200"
+- if the gender is : male OR female OR unknown OR other
+- if the birthDay is an existed date in Calendar AND in the YYYY-MM-DD format AND NOT greater than the Current day
+- if the sourceIdentifier (if given) respect the following regex: 
+>urn:oid:([0-9]+)(\.[0-9]+)+\|([ -~]+) <br />
+>{start with "urn:oid:"} then {"any number"} then {sequence of "."+"any number"} then a pipe ["|"] then {"any string"}
+		
+<br/>
+
+#### TEST CASE (400)
+
+>Resource could not be parsed or failed basic FHIR validation rules | malformed bundle message.<br/>
+
+Same as Nominal Test excepting :
+
+* The Bundle message is intentionally malformed
+
+* The following assertion will be tested when the body is sent :
+  - if the returned HTTP Status is "400"
+
+<br/>
+
+
+#### TEST CASE (404)
+>Resource type not supported, or not a FHIR end-point : request URL is not valid 
+
+The following assertion will be tested when the body is sent :
+- if the returned HTTP Status is "404"
+		
+#### TEST CASE (422)
+
+>The proposed resource violated applicable FHIR profiles or server business rules. This should be accompanied by an OperationOutcome resource providing additional detail.
+
+The request is a right one but the submitted birthdate OR gender OR sourceIdentifier do NOT respect the assertion rules.
+
+The following assertion will be tested when the body is sent :
+	- if the returned HTTP Status is "422"
+				
+
+### DELETE METHOD
+______________________________________________________________________
+
+
+#### NOMINAL CASE :	
+Send the following REST Request
+>DELETE : {serverAdress}/{resource}/{id}
+		
+		
+Same body as a create except :
+* request method must be delete at the end :
+```json
+		
+              "request" : {
+                "method" : "DELETE", 
+                "url" : "Patient"
+              },
+```
+
+
+* Mandatory field to fill in case of DELETE method : 
+  * uuid
+			
+In the case of the DELETE method, none of the fields are taking into account, only the UUID is check, and the Server shall answer 2 DELETE status :
+- DONE if the Patient existed and is now deleted
+- GONE if the Patient to delete does NOT exist in Databse
+			
+The following assertion will be tested when the body is sent :	
+- if the returned HTTP Status is "204"
+
+
+<br/>
+
+#### TEST CASE (404)
+
+>case where uuid not exist in database
+
+
+Same as NOMINAL except :
+
+The following assertion will be tested when the body is sent :	
+- if the returned HTTP Status is "404"
+	
+
+### UPDATE METHOD
+__________________________________________________________________________________
+
+#### NOMINAL CASE :	
+Send the following REST Request
+>PUT : {serverAdress}/{resource}/{id}
+
+
+Same body as CREATE method but :
+* the request method should be put AND the patient id is replaced by an UUID
+```json
+              "request" : {
+                "method" : "PUT",
+                "url" : "Patient"
+              },
+              
+```
+
+* Mandatory fields : uuid
+ 
+* The body response shall return the modified Patient.
+ 
+<br/>
+
+#### TEST CASE (400)
+
+>resource could not be parsed or failed basic FHIR validation rules | malformed bundle message 
+
+
+Same as Nominal Test excepting :
+
+The Bundle message is intentionally malformed
+
+The following assertion will be tested when the body is sent :
+- if the returned HTTP Status is "400"
+
+ 
+
+
+
+#### TEST CASE (422)
+> the proposed resource violated applicable FHIR profiles or server business rules. This should be accompanied by an OperationOutcome resource providing additional detail.
+
+Same as Nominal Test excepting :
+
+
+The following assertion will be tested when the body is sent :
+- if the returned HTTP Status is "422"
+ 
+ <br/>
+			
+### MERGE METHOD (should be updated in further version)
+____________________________________________________________________________________
+Send the following REST Request :
+>PUT : {serverAdress}/{resource}/{id}
+
+The body is different because the MERGE is a used in the case where the same patient was created 2 times and the user would like to redirect the duplicated patient to the original one in the database.
+
+```json	
+{
+    "resourceType": "Bundle",
+    "type": "message",
+    "entry": [{
+        "fullUrl": "http://qualification.ihe-europe.net/fhir/MessageHeader/1",
+        "resource": {
+            "resourceType": "MessageHeader",
+            "id": "1",
+            "eventUri": "urn:ihe:iti:pmir:2019:patient-feed",
+            "source": {
+                "endpoint": "http://qualification.ihe-europe.net/patientSource"
+            },
+            "focus": [{
+                "reference": "Bundle/abc"
+            }],
+            "destination": [{
+                "endpoint": "http://qualification.ihe-europe.net/patientEndpoint"
+            }]
+        }
+    }, {
+        "fullUrl": "http://qualification.ihe-europe.net/fhir/Bundle/abc",
+        "resource": {
+            "resourceType": "Bundle",
+            "id": "abc",
+            "type": "history",
+            "entry": [{
+                "fullUrl": "http://qualification.ihe-europe.net/fhir/Patient/${uuid}",
+                "resource": {
+                    "resourceType": "Patient",
+                    "id": "${uuid}",
+                    "active": false,
+                    "link": [{
+                        "other": {
+                            "reference": "http://qualification.ihe-europe.net/fhir/Patient/${uuidToRedirect}"
+                        },
+                        "type": "replaced-by"
+                    }]
+                },
+                "request": {
+                    "method": "PUT",
+                    "url": "Patient/${uuid}"
+                },
+                "response": {
+                    "status": "200"
+                }
+            }]
+        }
+    }]
+}	
+```
+* Mandatory fields to fill in MERGE request : 
+  * uuid
+  * uuidToRedirect 
+
+* The response should be as Following :
+
+  - a Patient Identifier is mandatory [1..*]
+  - On the GWT, I can choose a project {projectName} and select the Merge Test Suite and modify : the endpoint, the formerSourceIdentifier I want to deprecate, the newSourceIdentifier I want for my Patient.
+  - 200 status is returned if the patient is merged
+  - 400 status is returned if I provided malformed Bundle Json
+  - 404 status is returned if I provided well-formed sourceIdentifier but not exist in PatReg
+  - 405 status is returned if I provide a sourceIdentifier for a deactivated patient
+  - 422 status is returned if I provide a malformed sourceIdentifier 
+
+<br/>
+
+## PIX-M MANAGER
+__________________________________________________________________________________
+
+### PixM Connector
+
+PixM Connector is a FHIR application server exposing REST services. It uses the HAPI FHIR Server framework (a fast solution to deploy a FHIR Server and implement a specific treatment for the request). 
+
+The PixM Connector is a Java Project which receives the SUT Request and transfer it to the Java Client for Patreg.
+It shall manage received CREATE, UPDATE, DELETE, MERGE request from SUT.
+It has also to convert a FHIR Bundle Object from ITI-93 transaction into a manageable Patient Object by Patient Registry.
+It has to received response message from Patient Registry to transfer to the SUT.
+
+It has 3 parts :
+* **server part** : define the context of the deployed FHIR Server
+* **provider part** : feed the server with the methods that it needs to expose. In our case it defines the treatment of parameters that needs to be transferred
+* **call-the-java-client part** : in this part, the module initialize the Java client with de Patient Registry adress. It uses the JAVA client to transfer the request and interpret the response and reported errors. It also prepares the content of the FHIR reponse and sends back to the SUT.
+
+<br/>
+
+### Java Client (part of PixM Connector)
+
+It acts like a connector to Patient Registry.
+Its role is to initialize the connection with Patient Registry and translate the research parameters into GITB Model.
+It implements the same interface as the service. This connector is embedded in PIXm-Connector to communicate with this module.
+
+<br/>
+
+### Patient Registry
+
+Patient Registry is a module that allows you to interact with the database of Patient Manager database. 
+This module has no web interface. It is only accessible through its webservices just like PIX-Connector. 
+With one exception, the latter uses REST webservices while Patient Registry uses Soap technology with a GITB overlay.
+
+The GITB model is a standardization project initiated by the European Commission.
+The specifications aim at the interoperability of the test tools in a test bucket. It is about
+defining a common interface between the tools and a test bench. This common interface
+defines the data exchanges via the webservices. They use a standardized data type standardized data type that requires a correspondence with the gazelle data models. 
+It is expected that in the next few years that the GITB standard will migrate to REST webservices.
+
+The Patient Registry Webservice implements the GITB model. It only receives requests in this format. It identifies the operation to be performed (here a cross-reference search operation) and
+operation) and establishes the reverse correspondence, from the GITB model to the
+Gazelle model. 
+
+The webservice then transmits these parameters to the service application layer which
+returns the result or the exceptions raised during the operation. Again, we perform the
+the results in a report indicating the status and the result of the operation.
+the result of the operation. This report is then translated and interpreted by the Java client.
+
+
+
+
+
+
diff --git a/PixM_Feed_Documentation/pictures/iti_93_interaction_diagram.png b/PixM_Feed_Documentation/pictures/iti_93_interaction_diagram.png
new file mode 100644
index 0000000000000000000000000000000000000000..d65ca11ee29cda0694cd6f2d5b2d25e81006542e
Binary files /dev/null and b/PixM_Feed_Documentation/pictures/iti_93_interaction_diagram.png differ
diff --git a/PixM_Feed_Documentation/pictures/pixm_connector.png b/PixM_Feed_Documentation/pictures/pixm_connector.png
new file mode 100644
index 0000000000000000000000000000000000000000..e2eb7b8aeb0b979b5bf7854aabde52452c89a8c8
Binary files /dev/null and b/PixM_Feed_Documentation/pictures/pixm_connector.png differ
diff --git a/PixM_Feed_Documentation/pictures/pixm_scheme_total.png b/PixM_Feed_Documentation/pictures/pixm_scheme_total.png
new file mode 100644
index 0000000000000000000000000000000000000000..ba1ad2f1ea3f7eb9b9ba0ffa63403eaa850929d9
Binary files /dev/null and b/PixM_Feed_Documentation/pictures/pixm_scheme_total.png differ
diff --git a/README.md b/README.md
index 274d2bf91a4135677814d3b39a258b34f25cff5d..74cf42de6d53a1d32b9e18a0668535e1cba3bb23 100644
--- a/README.md
+++ b/README.md
@@ -29,7 +29,22 @@ After building the project through Maven, the artifact created just has to be ad
 ```
 
 ---
-### Request a Patient on a specific Target Identifier
+### Overview 
+Here is a quick overview of the available functionnality from PIXm connector
+
+|Method|URL to call|Entry parameter|Returned value|
+|-|-|-|-|
+|Create Patient|```{FHIR.server.address}/Patient/$create```|ITI-93 Bundle| Patient Bundle
+|Delete Patient|```{FHIR.server.address}/Patient/$delete```|Patient SourceIdentifier|/
+|Read Patient|```{FHIR.server.address}/Patient```|Patient SourceIdentifier|Patient Bundle
+|Update Patient|```{FHIR.server.address}/Patient/$update```|ITI-93 Bundle with a Patient SourceIdentifier|Patient Bundle
+|Merge Patient|```{FHIR.server.address}/Patient/$merge```|2 Patient SourceIdentifier|Patient Bundle
+|Check Cross Referenced Patient|```{FHIR.server.address}/Patient/$ihe-pix```|A Patient sourceIdentifier and a TargetDomain|Patient Bundle
+
+
+
+---
+### Request a Patient Cross Reference on a specific Target Identifier (ITI-83)
 
 Once the project deployed on your WildFly, you can now call it to request a cross Referenced Patient in the Patient Registry.
 
@@ -80,7 +95,7 @@ The corresponding url will be :
 ```
 
 ---
-### Error returned
+#### Error returned
 Malformed requests can cause different types of error, here is a quick overview of how to troubleshoot them :
 
 ![nice cat](http://http.cat/400)
@@ -112,3 +127,121 @@ Common mistakes with the target system are the same as the aformentioned error 4
 
 An error 404 Not Found is returned when the patient identifier given within the source identifier parameter is not recognized by the Patient registry.
 In the case of our request above, the value "69420" is not a valid Identifier linked to an existing Patient.
+
+---
+### Requests on Patient resources (ITI-93)
+
+PIXm connector implements query for ITI-93 
+
+Many of those requests will take an ITI-93 Bundle as a Pramaeter
+
+---
+#### Create
+
+PIXm connector accepts the creation of a Patient in the Patient Manager.
+Although a Patient could be created without any information in the HL7 model, PIXm connector will only allow a Patient to be created with minimum information to permits cross referenciation.
+
+The request takes only one argument, a bundle with three required components :
+- A Message header.
+- A Bundle of type history, describing the Patient resource to be created.
+
+The "required" fields in the Patient are : 
+- A name (either Family, or Given, or both).
+- A Country.
+- A Gender.
+- An Identifier. (?)
+
+
+A MessageHeader shall contains
+|Componant Name|cardinality|example or description|
+|-|-|-|
+|eventUri|[1..1]|urn:ihe:iti:pmir:2019:patient-feed|
+|focus|[1..1]|shall reference the url of Bundle|
+|sourceEndpoint|[1..1]|Actual message source address or id|
+|destination|[1..*]|The destination(s) of this feed|
+
+A history type bundle shall contains
+|Componant Name|cardinality|example or description|
+|-|-|-|
+|type|[1..1]|should be History
+|entry|[1..*]|the same Patient Resource shall not appear twice in this Bundle
+|entry.request.method|[1..1]|POST PUT DELETE
+|entry.request.url|[1..1]|The URL for this entry, relative to the root (the address to which the request is posted).
+|entry.response.status|[1..1]|The response status shall be an HTTP response status of 200 
+
+
+If the Creation is succesful, an http response 200 will be returned, with a Bundle containing the Patient information, and an Endpoint to view the Patient in browser.
+
+If it's not the case, a myriad of error can be returned to help you pinpoint why your request cannot be interpreted.
+
+---
+![cute cat](http://http.cat/400)
+The Resource could not be parsed or failed basic FHIR validation rules. In the case of an error 400 being returned, please check the following guidelines to verify your query.
+- The Bundle does not countain minimum information needed for creation verify if the following arguments are given in the Patient and have the corresponding types and size.
+    - A name (either Family, or Given, or both).
+    - A Country.
+    - A Gender.
+    - An Identifier. (?)
+
+The Bundle might be malformed, and does not countain one of the main component
+    - A Message header.
+    - A Bundle of type history, describing the Patient resource to be created.
+
+---
+![cute cat](http://http.cat/404)
+Two main event can cause an 404 response.
+- The endpoint provided for the request might be wrong, check the validity of the url on your endpoint.
+Usually, your endpoint should look like
+
+```http
+    {wildfly18.address}/pixm_fhir_server/fhir_ihe/Patient/$create?{Bundle}
+```
+Check your wildfly18 address then, by opening it in a web browser you should get a 403 Forbidden error thrown out, indicating you're indeed pointing at the right server.
+
+- The other common reason causing this error is the Resource type asked not being supported by PIXm. This means the part "/Patient" in the url is not right, either because you choosed another Resource type (like an Observation or a Bundle instead of Patient) which does not support the operation create, or because you mistyped it.
+
+---
+![cute cat](http://http.cat/422)
+This error is complementary to the 400 Bad Request error. Whereas the 400 happens when the bundle is "syntactically" malformed. For example, a required element is not present in the bundle. The inside value of the parameter might be completly abnormal. In the case of an error 422, the Bundle object sent is **SEMANTICALLY** erroneous.
+
+In this case, check the core of your request, maybe the Message Header Value is incoherent. Maybe one of the value in the Patient does not have any endpoint.
+
+In this case the best way to solve this error is by checking the Payload sent to the server, maybe a Value is erroneous. This error case sends an Operation Outcome REsource with it, you should check it as it contains additional information about where the error shoud come from exactly.
+
+---
+![cute cat](http://http.cat/500)
+This error is surely none of your doing. If one of this occurs, send a Ticket to the corresponding authority providing you the service.
+
+---
+#### Update
+
+The Update method allows the user to update a Patient in the Patient Registry through PIXm. The Request sent is the same as the create method, The endpoint is the only difference between the two, since it encapsulates the method used. It also needs the sourceIdentifier from the Patient to modify, if you're not sure about it, you can always use the @Read Method described under.
+
+You can then follow the create operation explanation above for in-detail details about the parameters needed.
+
+The returned value is the Updated Patient.
+Error values returned contain the same as the Create operation and even more.
+We will not go through the errors already explained in the [Create section](#create) but will add information on the errors :
+
+---
+![cute cat](http://http.cat/401)
+Is returned when the token for authentication is not valid to perform this method.
+
+---
+![cute cat](http://http.cat/405)
+When the resource pointed is not found
+
+---
+![cute cat](http://http.cat/409)
+When the resource sended is not of the same version as the resource stored in patient registry
+
+---
+#### Merge
+The merge method allows the user to merge two patients together if it is deemed reasonable to think those two registered patients represent the same people
+
+---
+#### Delete
+
+---
+#### Read
+
diff --git a/pom.xml b/pom.xml
index 42869f4c18e3f6834a1d503abec5d1cd171282fa..a657d7ade9192a2617317a30ece0937ae795fd6b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -3,7 +3,7 @@
 	<groupId>net.ihe.gazelle</groupId>
 	<artifactId>pixm-connector</artifactId>
 	<packaging>war</packaging>
-	<version>1.0.1-SNAPSHOT</version>
+	<version>2.0.0-SNAPSHOT</version>
 	<name>Pixm Connector</name>
 
 	<properties>
@@ -14,6 +14,8 @@
 		<nexus.url>https://gazelle.ihe.net/nexus</nexus.url>
 		<nexus.path>/content/groups/public/</nexus.path>
 		<java.version>11</java.version>
+		<aspectj.version>1.9.7</aspectj.version>
+		<junit.jupiter.version>5.8.0-M1</junit.jupiter.version>
 		<maven-javadoc-plugin.version>3.1.1</maven-javadoc-plugin.version>
 		<git.user.name>gitlab-ci</git.user.name>
 		<git.user.token>changeit</git.user.token>
@@ -23,7 +25,7 @@
 		<hapifhir_version>5.4.0</hapifhir_version>
 		<maven.release.plugin.version>2.5.3</maven.release.plugin.version>
 		<nexus.staging.maven.plugin.version>1.6.8</nexus.staging.maven.plugin.version>
-		<sonar.maven.plugin>3.5.0.1254</sonar.maven.plugin>
+		<sonar.maven.plugin>3.9.0.2155</sonar.maven.plugin>
 	</properties>
 
 	<scm>
@@ -113,6 +115,7 @@
 		<finalName>pixm_fhir_server</finalName>
 
 		<plugins>
+
 			<plugin>
 				<groupId>org.apache.maven.plugins</groupId>
 				<artifactId>maven-release-plugin</artifactId>
@@ -136,18 +139,57 @@
 			<plugin>
 				<groupId>org.apache.maven.plugins</groupId>
 				<artifactId>maven-surefire-plugin</artifactId>
-				<version>2.22.2</version>
+				<version>3.0.0-M3</version>
+				<configuration>
+					<properties>
+						<property>
+							<name>listener</name>
+							<value>io.qameta.allure.junit5.AllureJunit5</value>
+						</property>
+					</properties>
+					<dependenciesToScan>
+						<dependency>net.ihe.gazelle:lib.unit-test</dependency>
+					</dependenciesToScan>
+					<testFailureIgnore>false</testFailureIgnore>
+					<argLine>
+						-javaagent:"${settings.localRepository}/org/aspectj/aspectjweaver/${aspectj.version}/aspectjweaver-${aspectj.version}.jar"
+					</argLine>
+					<systemProperties>
+						<property>
+							<name>junit.jupiter.extensions.autodetection.enabled</name>
+							<value>true</value>
+						</property>
+						<property>
+							<name>allure.results.directory</name>
+							<value>${project.basedir}/target/allure-results</value>
+						</property>
+					</systemProperties>
+					<argLine>${argLine}</argLine>
+				</configuration>
 				<dependencies>
 					<dependency>
-						<groupId>org.junit.platform</groupId>
-						<artifactId>junit-platform-surefire-provider</artifactId>
-						<version>1.2.0</version>
+						<groupId>org.junit.jupiter</groupId>
+						<artifactId>junit-jupiter-api</artifactId>
+						<version>${junit.jupiter.version}</version>
+					</dependency>
+					<dependency>
+						<groupId>org.junit.jupiter</groupId>
+						<artifactId>junit-jupiter-engine</artifactId>
+						<version>${junit.jupiter.version}</version>
+					</dependency>
+					<dependency>
+						<groupId>org.aspectj</groupId>
+						<artifactId>aspectjweaver</artifactId>
+						<version>${aspectj.version}</version>
 					</dependency>
 				</dependencies>
+			</plugin>
+			<plugin>
+				<groupId>io.qameta.allure</groupId>
+				<artifactId>allure-maven</artifactId>
+				<version>2.10.0</version>
 				<configuration>
-					<dependenciesToScan>
-						<dependency>net.ihe.gazelle:lib.unit-test</dependency>
-					</dependenciesToScan>
+					<allureDownloadUrl>https://github.com/allure-framework/allure-maven/archive/refs/tags/2.10.0.zip</allureDownloadUrl>
 				</configuration>
 			</plugin>
 
@@ -168,7 +210,7 @@
 			<plugin>
 				<groupId>org.jacoco</groupId>
 				<artifactId>jacoco-maven-plugin</artifactId>
-				<version>0.8.4</version>
+				<version>0.8.6</version>
 				<executions>
 					<execution>
 						<id>pre-unit-test</id>
@@ -177,15 +219,25 @@
 						</goals>
 					</execution>
 					<execution>
-						<id>post-unit-test</id>
-						<phase>test</phase>
+						<id>default-report</id>
+						<phase>package</phase>
 						<goals>
 							<goal>report</goal>
 						</goals>
+						<configuration>
+							<dataFile>${project.build.directory}/target/jacoco.exec</dataFile>
+						</configuration>
 					</execution>
 				</executions>
 			</plugin>
 
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-javadoc-plugin</artifactId>
+				<configuration>
+					<additionalparam>-Xdoclint:none</additionalparam>
+				</configuration>
+			</plugin>
 		</plugins>
 	</build>
 	<dependencies>
@@ -200,9 +252,21 @@
 			<version>1.0.0</version>
 		</dependency>
 		<dependency>
-			<groupId>junit</groupId>
-			<artifactId>junit</artifactId>
-			<version>4.13.2</version>
+			<groupId>org.junit.jupiter</groupId>
+			<artifactId>junit-jupiter</artifactId>
+			<version>5.6.0</version>
+			<scope>test</scope>
+		</dependency>
+		<!-- https://mvnrepository.com/artifact/org.junit.platform/junit-platform-commons -->
+		<dependency>
+			<groupId>org.junit.platform</groupId>
+			<artifactId>junit-platform-commons</artifactId>
+			<version>1.7.2</version>
+		</dependency>
+		<dependency>
+			<groupId>org.junit.platform</groupId>
+			<artifactId>junit-platform-launcher</artifactId>
+			<version>1.7.2</version>
 		</dependency>
 
 		<dependency>
@@ -258,19 +322,23 @@
 			<classifier>classes</classifier>
 			<scope>provided</scope>
 		</dependency>
-		
-		<!-- 
-		HAPI-FHIR uses Logback for logging support. The logback library is included
-		automatically by Maven as a part of the hapi-fhir-base dependency, but you
-		also need to include a logging library. Logback is used here, but log4j
-		would also be fine. 
-		-->
+
+		<!-- HAPI-FHIR uses Logback for logging support. The logback library is 
+			included automatically by Maven as a part of the hapi-fhir-base dependency, 
+			but you also need to include a logging library. Logback is used here, but 
+			log4j would also be fine. -->
 		<dependency>
 			<groupId>ch.qos.logback</groupId>
 			<artifactId>logback-classic</artifactId>
 			<version>1.1.7</version>
 		</dependency>
 
+		<dependency>
+			<groupId>info.debatty</groupId>
+			<artifactId>java-string-similarity</artifactId>
+			<version>RELEASE</version>
+		</dependency>
+
 		<!-- Needed for JEE/Servlet support -->
 		<dependency>
 			<groupId>javax</groupId>
@@ -306,7 +374,19 @@
 		<dependency>
 			<groupId>net.ihe.gazelle</groupId>
 			<artifactId>app.patient-registry-xref-search-client</artifactId>
-			<version>2.0.0</version>
+			<version>2.0.1-SNAPSHOT</version>
+		</dependency>
+
+		<dependency>
+			<groupId>net.ihe.gazelle</groupId>
+			<artifactId>app.patient-registry-search-client</artifactId>
+			<version>2.0.1-SNAPSHOT</version>
+		</dependency>
+
+		<dependency>
+			<groupId>net.ihe.gazelle</groupId>
+    		<artifactId>app.patient-registry-feed-client</artifactId>
+    		<version>2.0.1-SNAPSHOT</version>
 		</dependency>
 
 		<!-- Used for CORS support -->
@@ -334,5 +414,17 @@
 			<version>2.0.9</version>
 			<scope>test</scope>
 		</dependency>
+		<dependency>
+			<groupId>io.qameta.allure</groupId>
+			<artifactId>allure-junit5</artifactId>
+			<version>2.14.0</version>
+			<scope>test</scope>
+		</dependency>
+		<dependency>
+			<groupId>com.googlecode.json-simple</groupId>
+			<artifactId>json-simple</artifactId>
+			<version>1.1.1</version>
+		</dependency>
+
 	</dependencies>
 </project>
diff --git a/src/main/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverter.java b/src/main/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverter.java
new file mode 100644
index 0000000000000000000000000000000000000000..6e8c7022b2791ee2efa733715e21d47efac43c97
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverter.java
@@ -0,0 +1,226 @@
+package net.ihe.gazelle.adapter.connector;
+
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
+import net.ihe.gazelle.app.patientregistryapi.business.GenderCode;
+import net.ihe.gazelle.app.patientregistryapi.business.Person;
+import net.ihe.gazelle.app.patientregistryapi.business.PersonName;
+import org.hl7.fhir.r4.model.*;
+import org.hl7.fhir.r4.model.Address.AddressUse;
+import org.hl7.fhir.r4.model.Patient.ContactComponent;
+
+/**
+ * Class containing static methods to convert
+ *
+ * @author pvm
+ */
+public class BundleToPatientRegistryConverter {
+
+    /**
+     * private constructor to override the public implicit one.
+     */
+    private BundleToPatientRegistryConverter() {
+    }
+
+
+
+    public static net.ihe.gazelle.app.patientregistryapi.business.Patient fhirPatientToGazellePatient(Patient patient) throws ConversionException {
+        net.ihe.gazelle.app.patientregistryapi.business.Patient convertedPatient = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        if (patient.hasActive()) {
+            convertedPatient.setActive(patient.getActive());
+        }
+
+        if (patient.hasBirthDate()) {
+            convertedPatient.setDateOfBirth(patient.getBirthDate());
+        }
+
+        if (patient.hasDeceased()) {
+            convertedPatient.setDateOfDeath(patient.getDeceasedDateTimeType().getValue());
+        }
+
+        if (patient.hasGender()) {
+            convertedPatient.setGender(convertGender(patient.getGender()));
+        }
+
+        if (patient.hasMultipleBirth()) {
+            convertedPatient.setMultipleBirthOrder(patient.getMultipleBirthIntegerType().getValue());
+        }
+
+        if (patient.hasId()) {
+            convertedPatient.setUuid(patient.getId());
+        }
+
+        convertingLists(patient, convertedPatient);
+
+        return convertedPatient;
+    }
+
+    private static void convertingLists(Patient patient, net.ihe.gazelle.app.patientregistryapi.business.Patient convertedPatient) throws ConversionException {
+        if (patient.hasAddress()) {
+            for (Address address : patient.getAddress()) {
+                convertedPatient.addAddress(convertAddress(address));
+            }
+        }
+
+        if (patient.hasContact()) {
+            for (ContactComponent contact : patient.getContact()) {
+                convertedPatient.addContact(convertContact(contact));
+            }
+        }
+
+        if (patient.hasName()) {
+            for (HumanName name : patient.getName()) {
+                convertedPatient.addName(convertName(name));
+            }
+        }
+
+        if (patient.hasIdentifier()) {
+            for (Identifier id : patient.getIdentifier()) {
+                addEntity(convertedPatient, id);
+            }
+        }
+    }
+
+    private static void addEntity(net.ihe.gazelle.app.patientregistryapi.business.Patient convertedPatient, Identifier id) {
+        EntityIdentifier entityIdentifier = new EntityIdentifier();
+
+        if (id.hasSystem()) {
+            String systemID = id.getSystem();
+            systemID = systemID.replace("urn:oid:", "");
+            entityIdentifier.setSystemIdentifier(systemID);
+            entityIdentifier.setType("ISO");
+        }
+
+        if (id.hasValue()) {
+            entityIdentifier.setValue(id.getValue());
+        }
+        else {
+            throw new InvalidRequestException("Cannot create Patient without any Identifier");
+        }
+
+        convertedPatient.addIdentifier(entityIdentifier);
+    }
+
+    private static GenderCode convertGender(Enumerations.AdministrativeGender gender) throws ConversionException {
+        if (gender == null) {
+            throw new ConversionException("No gender present");
+        }
+
+        switch (gender) {
+            case MALE:
+                return GenderCode.MALE;
+            case FEMALE:
+                return GenderCode.FEMALE;
+            case UNKNOWN:
+                return GenderCode.UNDEFINED;
+            case OTHER:
+                return GenderCode.OTHER;
+            default:
+                throw new ConversionException(String.format("Cannot map GenderCode : %s", gender));
+
+        }
+
+
+    }
+
+    private static net.ihe.gazelle.app.patientregistryapi.business.Address convertAddress(Address address) throws ConversionException {
+        net.ihe.gazelle.app.patientregistryapi.business.Address convertedAddress = new net.ihe.gazelle.app.patientregistryapi.business.Address();
+
+        if (address.hasCity()) {
+            convertedAddress.setCity(address.getCity());
+        }
+
+        if (address.hasCountry()) {
+            convertedAddress.setCountryIso3(address.getCountry());
+        }
+
+        if (address.hasPostalCode()) {
+            convertedAddress.setPostalCode(address.getPostalCode());
+        }
+
+        if (address.hasState()) {
+            convertedAddress.setState(address.getState());
+        }
+
+        if (address.hasUse()) {
+            convertedAddress.setUse(convertAddressUse(address.getUse()));
+        }
+
+        if (address.hasLine()) {
+            for (StringType addressLine : address.getLine()) {
+                convertedAddress.addLine(addressLine.getValue());
+            }
+        }
+        return convertedAddress;
+    }
+
+    private static net.ihe.gazelle.app.patientregistryapi.business.AddressUse convertAddressUse(AddressUse addressUse) throws ConversionException {
+        if (addressUse != null) {
+            switch (addressUse) {
+                case BILLING:
+                    return net.ihe.gazelle.app.patientregistryapi.business.AddressUse.BILLING;
+                case HOME:
+                    return net.ihe.gazelle.app.patientregistryapi.business.AddressUse.HOME;
+				case OLD:
+					return net.ihe.gazelle.app.patientregistryapi.business.AddressUse.BAD;
+				case TEMP:
+                    return net.ihe.gazelle.app.patientregistryapi.business.AddressUse.TEMPORARY;
+                case WORK:
+                    return net.ihe.gazelle.app.patientregistryapi.business.AddressUse.WORK;
+                default:
+                    throw new ConversionException(String.format("Cannot map address use : %s", addressUse));
+            }
+        } else {
+            throw new ConversionException("No address use present");
+        }
+    }
+
+    private static Person convertContact(ContactComponent contact) throws ConversionException {
+        Person convertedContact = new Person();
+
+        if (contact.hasGender()) {
+            convertedContact.setGender(convertGender(contact.getGender()));
+        }
+
+        if (contact.hasAddress()) {
+            convertedContact.addAddress(convertAddress(contact.getAddress()));
+        }
+
+        if (contact.hasName()) {
+            convertedContact.addName(convertName(contact.getName()));
+        }
+        return convertedContact;
+    }
+
+    private static PersonName convertName(HumanName name) {
+        PersonName convertedName = new PersonName();
+
+        if (name.hasUse()) {
+            convertedName.setUse(name.getUse().toString());
+        }
+
+        if (name.hasFamily()) {
+            convertedName.setFamily(name.getFamily());
+        }
+
+        if (name.hasGiven()) {
+            for (StringType givenName : name.getGiven()) {
+                convertedName.addGiven(givenName.getValue());
+            }
+        }
+
+        if (name.hasPrefix()) {
+            for (StringType prefixName : name.getPrefix()) {
+                convertedName.setPrefix(prefixName.getValue());
+            }
+        }
+
+        if (name.hasSuffix()) {
+            for (StringType suffixName : name.getSuffix()) {
+                convertedName.setSuffix(suffixName.getValue());
+            }
+        }
+
+        return convertedName;
+    }
+}
diff --git a/src/main/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverter.java b/src/main/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverter.java
new file mode 100644
index 0000000000000000000000000000000000000000..5bac0bdbe157c61037664fc6655b8d712d43a2bf
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverter.java
@@ -0,0 +1,251 @@
+package net.ihe.gazelle.adapter.connector;
+
+import net.ihe.gazelle.app.patientregistryapi.business.Address;
+import net.ihe.gazelle.app.patientregistryapi.business.ContactPoint;
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryapi.business.*;
+import org.hl7.fhir.exceptions.FHIRException;
+import org.hl7.fhir.r4.model.*;
+import org.hl7.fhir.r4.model.Bundle.BundleEntryComponent;
+import org.hl7.fhir.r4.model.Bundle.BundleType;
+import org.hl7.fhir.r4.model.MessageHeader.MessageDestinationComponent;
+import org.hl7.fhir.r4.model.MessageHeader.MessageHeaderResponseComponent;
+import org.hl7.fhir.r4.model.MessageHeader.MessageSourceComponent;
+import org.hl7.fhir.r4.model.MessageHeader.ResponseType;
+import org.hl7.fhir.r4.model.Narrative.NarrativeStatus;
+
+import java.util.List;
+
+/**
+ * Converter to transform Patient Registry's {@link Patient} to {@link org.hl7.fhir.r4.model.Patient}.
+ *
+ * @author pvm
+ */
+public class BusinessToFhirConverter {
+
+    private static final String URN_PREFIX = "urn:oid:";
+
+    /**
+     * private constructor to override the implicit one.
+     */
+    private BusinessToFhirConverter() {
+    }
+
+    public static Bundle uuidToBundle(String uuid, String serverUrl) {
+
+        Bundle response = new Bundle();
+        response.setId("BundlePIXmResponse");
+        Meta metadata = new Meta();
+        metadata.addProfile("http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle-response");
+        response.setType(BundleType.MESSAGE);
+        BundleEntryComponent entry = new BundleEntryComponent();
+        entry.setFullUrl(serverUrl + "/pixm-connector/fhir_ch/Patient/" + uuid);
+        MessageHeader messageHeader = new MessageHeader();
+        messageHeader.setId(uuid);
+        Narrative narrative = new Narrative();
+        narrative.setStatus(NarrativeStatus.GENERATED);
+        messageHeader.setText(narrative);
+        MessageDestinationComponent mdc = new MessageDestinationComponent();
+        mdc.setEndpoint(serverUrl + "/pixm-connector/fhir_ch/Patient/" + uuid);
+        messageHeader.addDestination(mdc);
+        MessageSourceComponent msc = new MessageSourceComponent();
+        msc.setEndpoint(serverUrl + "/pixm-connector/fhir_ch/Patient/" + uuid);
+        messageHeader.setSource(msc);
+        MessageHeaderResponseComponent mhrc = new MessageHeaderResponseComponent();
+        mhrc.setIdentifier(uuid);
+        mhrc.setCode(ResponseType.OK);
+        messageHeader.setResponse(mhrc);
+        entry.setResource(messageHeader);
+        response.addEntry(entry);
+        response.setMeta(metadata);
+
+        return response;
+
+    }
+
+    public static org.hl7.fhir.r4.model.Patient patientToFhirPatient(Patient patient) throws ConversionException {
+        org.hl7.fhir.r4.model.Patient fhirPatient = new org.hl7.fhir.r4.model.Patient();
+        fhirPatient.setId(patient.getUuid());
+        setNames(fhirPatient, patient);
+        fhirPatient.setGender(getGenderCode(patient));
+        setCrossIdentifier(fhirPatient, patient);
+        setBirthDate(fhirPatient, patient);
+        setAddresses(fhirPatient, patient);
+        setTelecom(fhirPatient, patient);
+        fhirPatient.setActive(patient.isActive());
+        return fhirPatient;
+
+    }
+
+    private static void setNames(org.hl7.fhir.r4.model.Patient fhirPatient, Patient patient) throws ConversionException {
+        List<PersonName> patientNames = patient.getNames();
+        if (patientNames != null) {
+            for (PersonName personName : patientNames) {
+                if (personName != null) {
+                    HumanName name = new HumanName();
+                    name.setFamily(personName.getFamily());
+                    for (String given : personName.getGivens()) {
+                        name.addGiven(given);
+                    }
+                    try {
+                        name.setUse(HumanName.NameUse.fromCode(personName.getUse()));
+                    } catch (FHIRException e) {
+                        throw new ConversionException(String.format("Cannot convert PersonName use : %s", personName.getUse()), e);
+                    }
+                    name.addPrefix(personName.getPrefix());
+                    name.addSuffix(personName.getSuffix());
+                    fhirPatient.addName(name);
+                }
+            }
+        }
+    }
+
+    private static Enumerations.AdministrativeGender getGenderCode(Patient patient) throws ConversionException {
+        if (patient.getGender() != null) {
+            switch (patient.getGender()) {
+                case MALE:
+                    return Enumerations.AdministrativeGender.MALE;
+                case FEMALE:
+                    return Enumerations.AdministrativeGender.FEMALE;
+                case UNDEFINED:
+                    return Enumerations.AdministrativeGender.UNKNOWN;
+                case OTHER:
+                    return Enumerations.AdministrativeGender.OTHER;
+                default:
+                    throw new ConversionException(String.format("Cannot map GenderCode : %s", patient.getGender()));
+            }
+        }
+        return null;
+
+    }
+
+    private static void setCrossIdentifier(org.hl7.fhir.r4.model.Patient fhirPatient, Patient patient) {
+        if (patient.getIdentifiers() != null) {
+            for (EntityIdentifier currentPatientIdentifier : patient.getIdentifiers()) {
+                if (currentPatientIdentifier.getSystemIdentifier() != null) {
+                    String fhirSystem = getUniversalIDAsUrn(currentPatientIdentifier.getSystemIdentifier());
+                    fhirPatient.addIdentifier().setSystem(fhirSystem).setValue(currentPatientIdentifier.getValue());
+                }
+            }
+        }
+    }
+
+    private static void setBirthDate(org.hl7.fhir.r4.model.Patient fhirPatient, Patient patient) {
+        if (patient.getDateOfBirth() != null) {
+            fhirPatient.setBirthDate(patient.getDateOfBirth());
+        }
+    }
+
+    private static void setAddresses(org.hl7.fhir.r4.model.Patient fhirPatient, Patient patient) throws ConversionException {
+        List<Address> addressList = patient.getAddresses();
+        if (addressList != null) {
+            for (Address address : addressList) {
+                org.hl7.fhir.r4.model.Address fhirAddress = new org.hl7.fhir.r4.model.Address();
+                for (String line : address.getLines()) {
+                    fhirAddress.addLine(line);
+                }
+                fhirAddress.setCity(address.getCity());
+                fhirAddress.setCountry(address.getCountryIso3());
+                fhirAddress.setPostalCode(address.getPostalCode());
+                fhirAddress.setState(address.getState());
+                fhirAddress.setUse(getAddressUse(address.getUse()));
+                fhirPatient.addAddress(fhirAddress);
+            }
+        }
+    }
+
+    private static void setTelecom(org.hl7.fhir.r4.model.Patient fhirPatient, Patient patient) throws ConversionException {
+        List<ContactPoint> contactPoints = patient.getContactPoints();
+        if (contactPoints != null) {
+            for (ContactPoint contactPoint : contactPoints) {
+                if (contactPoint != null) {
+                    org.hl7.fhir.r4.model.ContactPoint fhirContactPoint = new org.hl7.fhir.r4.model.ContactPoint();
+                    fhirContactPoint.setSystem(getContactPointSystem(contactPoint.getType()));
+                    fhirContactPoint.setValue(contactPoint.getValue());
+                    fhirContactPoint.setUse(getContactPointUse(contactPoint.getUse()));
+                    fhirPatient.addTelecom(fhirContactPoint);
+                }
+            }
+        }
+    }
+
+    private static String getUniversalIDAsUrn(String universalID) {
+        if (universalID == null) {
+            return null;
+        } else if (universalID.startsWith(URN_PREFIX)) {
+            return universalID;
+        } else {
+            return URN_PREFIX + universalID;
+        }
+    }
+
+    private static org.hl7.fhir.r4.model.Address.AddressUse getAddressUse(AddressUse addressUse) throws ConversionException {
+        if (addressUse == null) {
+            return null;
+        }
+
+        switch (addressUse) {
+            case HOME:
+            case PRIMARY_HOME:
+                return org.hl7.fhir.r4.model.Address.AddressUse.HOME;
+            case WORK:
+                return org.hl7.fhir.r4.model.Address.AddressUse.WORK;
+            case VACATION_HOME:
+            case TEMPORARY:
+                return org.hl7.fhir.r4.model.Address.AddressUse.TEMP;
+            case BAD:
+                return org.hl7.fhir.r4.model.Address.AddressUse.OLD;
+            case BILLING:
+                return org.hl7.fhir.r4.model.Address.AddressUse.BILLING;
+            default:
+                throw new ConversionException(String.format("Cannot map AddressUse : %s", addressUse));
+        }
+
+    }
+
+    private static org.hl7.fhir.r4.model.ContactPoint.ContactPointUse getContactPointUse(ContactPointUse contactPointUse) throws ConversionException {
+        if (contactPointUse == null) {
+            return null;
+        }
+        switch (contactPointUse) {
+            case HOME:
+            case PRIMARY_HOME:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.HOME;
+            case MOBILE:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.MOBILE;
+            case WORK:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.WORK;
+            case TEMPORARY:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.TEMP;
+            default:
+                throw new ConversionException(String.format("Cannot map ContactPointUse : %s", contactPointUse.value()));
+        }
+    }
+
+    private static org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem getContactPointSystem(ContactPointType contactPointType)
+            throws ConversionException {
+        if (contactPointType == null) {
+            return null;
+        }
+        switch (contactPointType) {
+            case BEEPER:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.PAGER;
+            case PHONE:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.PHONE;
+            case FAX:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.FAX;
+            case URL:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.URL;
+            case EMAIL:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.EMAIL;
+            case SMS:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.SMS;
+            case OTHER:
+                return org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.OTHER;
+            default:
+                throw new ConversionException(String.format("Cannot map ContactPointType : %s", contactPointType));
+        }
+
+    }
+
+}
diff --git a/src/main/java/net/ihe/gazelle/adapter/connector/ConversionException.java b/src/main/java/net/ihe/gazelle/adapter/connector/ConversionException.java
new file mode 100644
index 0000000000000000000000000000000000000000..a610d08bbf61d192ffd0a768945387c83c1bf81b
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/adapter/connector/ConversionException.java
@@ -0,0 +1,25 @@
+package net.ihe.gazelle.adapter.connector;
+
+public class ConversionException extends Exception {
+	
+    public ConversionException() {
+        super();
+    }
+
+    public ConversionException(String message) {
+        super(message);
+    }
+
+    public ConversionException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+    public ConversionException(Throwable cause) {
+        super(cause);
+    }
+
+    public ConversionException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
+        super(message, cause, enableSuppression, writableStackTrace);
+    }
+
+}
diff --git a/src/main/java/net/ihe/gazelle/adapter/connector/DeletionBundle.java b/src/main/java/net/ihe/gazelle/adapter/connector/DeletionBundle.java
new file mode 100644
index 0000000000000000000000000000000000000000..4f072f92e37b80e051e1855e60e9cc357b9e6c02
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/adapter/connector/DeletionBundle.java
@@ -0,0 +1,52 @@
+package net.ihe.gazelle.adapter.connector;
+
+import org.hl7.fhir.r4.model.Bundle;
+import org.hl7.fhir.r4.model.MessageHeader;
+import org.hl7.fhir.r4.model.Meta;
+import org.hl7.fhir.r4.model.Narrative;
+
+public class DeletionBundle {
+    /**
+     * private constructor to override the implicit one.
+     */
+    private DeletionBundle() {
+    }
+
+    public static Bundle prepareBundleAfterDeletionOperation(String uuid, String url) {
+        Bundle response = new Bundle();
+        response.setId("BundlePIXmResponse");
+
+        Meta metadata = new Meta();
+        metadata.addProfile("http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle-response");
+        response.setType(Bundle.BundleType.MESSAGE);
+        response.setMeta(metadata);
+
+
+        Bundle.BundleEntryComponent entry = new Bundle.BundleEntryComponent();
+        entry.setFullUrl(url + "/pixm-connector/fhir_ch/Patient/" + uuid);
+
+        MessageHeader messageHeader = new MessageHeader();
+        messageHeader.setId(uuid);
+        Narrative narrative = new Narrative();
+        narrative.setStatus(Narrative.NarrativeStatus.GENERATED);
+        messageHeader.setText(narrative);
+
+        MessageHeader.MessageHeaderResponseComponent mhrc = new MessageHeader.MessageHeaderResponseComponent();
+        mhrc.setIdentifier(uuid);
+        mhrc.setCode(MessageHeader.ResponseType.OK);
+
+        messageHeader.setResponse(mhrc);
+        entry.setResource(messageHeader);
+
+        entry.getRequest()
+                .setUrl("Delete")
+                .setMethod(Bundle.HTTPVerb.DELETE);
+        entry.getResponse()
+                        .setStatus("DONE");
+        response.addEntry(entry);
+
+
+        return response;
+
+    }
+}
diff --git a/src/main/java/net/ihe/gazelle/adapter/connector/UpdateBundle.java b/src/main/java/net/ihe/gazelle/adapter/connector/UpdateBundle.java
new file mode 100644
index 0000000000000000000000000000000000000000..605257430a9ca62e6a2d4203a8eec097d8d95f8d
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/adapter/connector/UpdateBundle.java
@@ -0,0 +1,43 @@
+package net.ihe.gazelle.adapter.connector;
+import org.hl7.fhir.r4.model.Bundle;
+import org.hl7.fhir.r4.model.MessageHeader;
+import org.hl7.fhir.r4.model.Meta;
+import org.hl7.fhir.r4.model.Narrative;
+
+public class UpdateBundle {
+
+    /**
+     * private constructor to override the implicit one.
+     */
+    private UpdateBundle() {
+    }
+    public static Bundle prepareBundleAfterUpdateOperation(String uuid, String url) {
+        Bundle response = new Bundle();
+        response.setId("BundlePIXmResponse");
+        Meta metadata = new Meta();
+        metadata.addProfile("http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle-response");
+        response.setType(Bundle.BundleType.MESSAGE);
+        response.setMeta(metadata);
+
+        Bundle.BundleEntryComponent entry = new Bundle.BundleEntryComponent();
+        entry.setFullUrl(url + "/pixm-connector/fhir_ch/Patient/" + uuid);
+        MessageHeader messageHeader = new MessageHeader();
+        messageHeader.setId(uuid);
+        Narrative narrative = new Narrative();
+        narrative.setStatus(Narrative.NarrativeStatus.GENERATED);
+        messageHeader.setText(narrative);
+        MessageHeader.MessageHeaderResponseComponent mhrc = new MessageHeader.MessageHeaderResponseComponent();
+        mhrc.setIdentifier(uuid);
+        mhrc.setCode(MessageHeader.ResponseType.OK);
+        messageHeader.setResponse(mhrc);
+        entry.setResource(messageHeader);
+        response.addEntry(entry);
+
+        response.addEntry()
+                .getRequest()
+                .setUrl("PUT")
+                .setMethod(Bundle.HTTPVerb.PUT);
+        return response;
+
+    }
+}
diff --git a/src/main/java/net/ihe/gazelle/adapter/preferences/Preferences.java b/src/main/java/net/ihe/gazelle/adapter/preferences/Preferences.java
index aa43fcca09da73e34cf63a48e707c80b81ce91b5..7d60edc4e4c73933af941b4743ed6a2ef173a88c 100644
--- a/src/main/java/net/ihe/gazelle/adapter/preferences/Preferences.java
+++ b/src/main/java/net/ihe/gazelle/adapter/preferences/Preferences.java
@@ -2,7 +2,7 @@ package net.ihe.gazelle.adapter.preferences;
 
 public enum Preferences {
     XREF_PATREG(Namespaces.DEPLOYMENT, "xrefpatientregistry.url"),
-    PATIENT_PATREG(Namespaces.DEPLOYMENT, "patientregistry.url");
+    PATIENT_REGISTRY_URL(Namespaces.DEPLOYMENT, "patientregistry.url");
 
     private final Namespaces namespace;
     private final String key;
diff --git a/src/main/java/net/ihe/gazelle/adapter/servlet/ChHapiFhirServer.java b/src/main/java/net/ihe/gazelle/adapter/servlet/ChHapiFhirServer.java
index ccee6a4f39d6ecf785db82034032184eb391b183..de34314aaa579734e8206f2af0f278afd93e626c 100644
--- a/src/main/java/net/ihe/gazelle/adapter/servlet/ChHapiFhirServer.java
+++ b/src/main/java/net/ihe/gazelle/adapter/servlet/ChHapiFhirServer.java
@@ -8,6 +8,7 @@ import ca.uhn.fhir.rest.server.RestfulServer;
 import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
 import ca.uhn.fhir.rest.server.interceptor.ExceptionHandlingInterceptor;
 import ca.uhn.fhir.rest.server.interceptor.LoggingInterceptor;
+import net.ihe.gazelle.business.provider.CHBundleProvider;
 import net.ihe.gazelle.business.provider.ChPatientResourceProvider;
 
 import javax.inject.Inject;
@@ -21,9 +22,13 @@ import java.util.List;
 @WebServlet(urlPatterns = {"/fhir_ch/*"}, displayName = "FHIR Server CH")
 public class ChHapiFhirServer extends RestfulServer {
     private static final long serialVersionUID = 1L;
+
     @Inject
     private ChPatientResourceProvider chPatientResourceProvider;
 
+    @Inject
+    private CHBundleProvider chBundleProvider;
+
     /**
      * Constructor
      */
@@ -43,6 +48,7 @@ public class ChHapiFhirServer extends RestfulServer {
          */
         List<IResourceProvider> providers = new ArrayList<>();
         providers.add(chPatientResourceProvider);
+        providers.add(chBundleProvider);
         setResourceProviders(providers);
 
         //creating an interceptor to log in console an error occurring
@@ -66,6 +72,7 @@ public class ChHapiFhirServer extends RestfulServer {
         INarrativeGenerator narrativeGen = new DefaultThymeleafNarrativeGenerator();
         getFhirContext().setNarrativeGenerator(narrativeGen);
 
+
     }
 
 }
diff --git a/src/main/java/net/ihe/gazelle/application/PatientRegistryFeedClient.java b/src/main/java/net/ihe/gazelle/application/PatientRegistryFeedClient.java
new file mode 100644
index 0000000000000000000000000000000000000000..f93c2da77d38720f14dc063c284c32109f645f53
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/application/PatientRegistryFeedClient.java
@@ -0,0 +1,263 @@
+package net.ihe.gazelle.application;
+
+import ca.uhn.fhir.rest.server.exceptions.*;
+import net.ihe.gazelle.adapter.connector.BusinessToFhirConverter;
+import net.ihe.gazelle.adapter.connector.DeletionBundle;
+import net.ihe.gazelle.adapter.connector.UpdateBundle;
+import net.ihe.gazelle.adapter.preferences.Preferences;
+import net.ihe.gazelle.app.patientregistryapi.application.PatientFeedException;
+import net.ihe.gazelle.app.patientregistryapi.business.PersonName;
+import net.ihe.gazelle.app.patientregistryfeedclient.adapter.PatientFeedClient;
+import net.ihe.gazelle.framework.loggerservice.application.GazelleLogger;
+import net.ihe.gazelle.framework.loggerservice.application.GazelleLoggerFactory;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.NamespaceException;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.PreferenceException;
+import net.ihe.gazelle.lib.annotations.Package;
+import org.apache.commons.lang3.StringUtils;
+import org.hl7.fhir.r4.model.Bundle;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.xml.ws.WebServiceException;
+import java.net.InetAddress;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.net.UnknownHostException;
+
+@Named("PatientRegistryFeedClient")
+public class PatientRegistryFeedClient {
+
+	public static final String NO_UUID = "No UUID was retrieved from the created Patient";
+	public static final String NO_PATIENT_PARAMETER = "No Patient were given to create";
+	public static final String CLIENT_NOT_SET = "client not set";
+	public static final String INVALID_PARAMETERS = "Invalid parameters";
+	private String serverUrl;
+	private static final GazelleLogger logger = GazelleLoggerFactory.getInstance().getLogger(PatientRegistryFeedClient.class);
+	private OperationalPreferencesService operationalPreferencesService;
+	private PatientFeedClient client;
+
+	public PatientRegistryFeedClient() {
+	}
+
+	/**
+	 * Default constructor, used for injection.
+	 *
+	 * @param operationalPreferencesService {@link OperationalPreferencesService} used to retrieve Patient Registry's URL.
+	 */
+	@Inject
+	public PatientRegistryFeedClient(OperationalPreferencesService operationalPreferencesService) {
+
+		this.operationalPreferencesService = operationalPreferencesService;
+	}
+
+	/**
+	 * Package-private constructor used for test purposes.
+	 *
+	 * @param url {@link URL} to be used by this to instantiate the processing service to retrieve patients.
+	 */
+	@Package
+	PatientRegistryFeedClient(URL url) {
+		this.client = new PatientFeedClient(url);
+	}
+
+	@Package
+	public void setClient(PatientFeedClient client) {
+		this.client = client;
+	}
+
+	/**
+	 * Initialize the Search Client using the Operational Preferences Service.
+	 *
+	 * @throws PatientFeedException if the service cannot be instantiated.
+	 */
+	private void initializeClient() throws PatientFeedException {
+		String patientRegistryUrl = null;
+		getUrlOfServer();
+		try {
+			patientRegistryUrl = this.operationalPreferencesService.
+					getStringValue(Preferences.PATIENT_REGISTRY_URL.getNamespace().getValue(), Preferences.PATIENT_REGISTRY_URL.getKey());
+			this.client = new PatientFeedClient(new URL(patientRegistryUrl));
+		} catch (NamespaceException | PreferenceException e) {
+			throw new PatientFeedException(String.format("Unable to retrieve [%s] Preference !", Preferences.PATIENT_REGISTRY_URL.getKey()));
+		} catch (MalformedURLException e) {
+			throw new PatientFeedException(String.format("Preference [%s] with value [%s] is not a valid URL !",
+					Preferences.PATIENT_REGISTRY_URL.getKey(),
+					patientRegistryUrl));
+		} catch (WebServiceException e) {
+			logger.warn(e.getMessage());
+			throw new PatientFeedException(String.format("Can't connect to patient registry ! at address [%s]", patientRegistryUrl));
+		}
+	}
+
+	/**
+	 * Method called to create a Patient in the Patient Registry Database
+	 *
+	 * @param patient : the patient to add in database, represented in patientRegistry model
+	 * @return a string corresponding to the uuid of the newly created patient in the database.
+	 */
+	public Bundle createPatient(net.ihe.gazelle.app.patientregistryapi.business.Patient patient) throws PatientFeedException {
+		if (client == null) {
+			logger.info(CLIENT_NOT_SET);
+			initializeClient();
+		}
+		if (patient == null) {
+			throw new InvalidRequestException(NO_PATIENT_PARAMETER);
+		}
+
+		PersonName name = patient.getNames().get(0);
+		if (StringUtils.isBlank(name.getFamily()) || name.getGivens().isEmpty()) {
+			throw new InvalidRequestException("Mandatory fields are missing");
+		}
+		if (patient.getDateOfBirth() == null || patient.getGender() == null) {
+			throw new InvalidRequestException("Mandatory fields are missing");
+		}
+		String uuid = "";
+		try {
+			patient.setUuid("PatientPIXmFeed");
+			patient.setActive(true);
+			uuid = client.createPatient(patient);
+
+			if (StringUtils.isBlank(uuid)) {
+				throw new InternalErrorException(NO_UUID);
+			}
+
+
+		} catch (PatientFeedException e) {
+			switch (e.getCause().getMessage()) {
+				case "Impossible to cross reference the patient (not saved)":
+					throw new InternalErrorException("Impossible to cross reference the patient, it will not be saved !", e);
+				case "Unexpected Exception persisting Patient !":
+					throw new InternalErrorException("Unexpected Exception persisting Patient !", e);
+
+				default:
+					treatClientBaseErrors(e);
+			}
+		}
+		return BusinessToFhirConverter.uuidToBundle(uuid, serverUrl);
+	}
+
+	/**
+	 * Method called to update a Patient in the PAtient Registry Database.
+	 *
+	 * @param patient : the Patient object we want to insert in DB
+	 * @param uuid    : The uuid of the patient corresponding to it in DB
+	 * @return a String corresponding to the uuid confirming the transaction has been successful.
+	 */
+	public Bundle updatePatient(net.ihe.gazelle.app.patientregistryapi.business.Patient patient, String uuid) throws PatientFeedException {
+		if (client == null) {
+			logger.info(CLIENT_NOT_SET);
+			initializeClient();
+		}
+		if (patient == null || StringUtils.isBlank(uuid)) {
+			throw new InvalidRequestException(INVALID_PARAMETERS);
+		}
+
+		try {
+			patient.setUuid(uuid);
+			client.updatePatient(patient);
+		} catch (PatientFeedException e) {
+			treatClientBaseErrors(e);
+		}
+		return UpdateBundle.prepareBundleAfterUpdateOperation(uuid,serverUrl);
+
+	}
+
+	/**
+	 * Method called to merge two Patients in the Patient Registry Database.
+	 *
+	 * @param uuidOriginal   : the Patient object we want to insert in DB
+	 * @param uuidDuplicated : The uuid of the patient corresponding to it in DB
+	 * @return a String corresponding to the uuid confirming the transaction has been successful.
+	 */
+	public Bundle mergePatient(String uuidOriginal, String uuidDuplicated) throws PatientFeedException {
+		if (client == null) {
+			logger.info(CLIENT_NOT_SET);
+			initializeClient();
+		}
+		if (StringUtils.isBlank(uuidOriginal)) {
+			throw new InvalidRequestException(INVALID_PARAMETERS);
+		}
+		if (StringUtils.isBlank(uuidDuplicated)) {
+			throw new InvalidRequestException(INVALID_PARAMETERS);
+		}
+		Bundle response = new Bundle();
+		try {
+
+			response.setId(client.mergePatient(uuidOriginal, uuidDuplicated));
+
+		} catch (PatientFeedException e) {
+			treatClientBaseErrors(e);
+		}
+		return response;
+	}
+
+	/**
+	 *  Methode to delete a Patient with its uuid
+	 * @param uuid of the patient to delete
+	 * @return Result of the Deletion
+	 * @throws PatientFeedException If deletion cannot be performed.
+	 */
+	public Bundle delete(String uuid) throws PatientFeedException {
+		if (client == null) {
+			logger.info(CLIENT_NOT_SET);
+			initializeClient();
+		}
+		if (StringUtils.isBlank(uuid)) {
+			throw new InvalidRequestException("Invalid parameter");
+		}
+		try {
+			boolean deletionStatus = client.deletePatient(uuid);
+			if (!deletionStatus) {
+				throw new ResourceGoneException("Patient with UUID " + uuid);
+			}
+		} catch (PatientFeedException exception) {
+			switch (exception.getCause().getMessage()) {
+				case "The uuid cannot be null or empty":
+					throw new InternalErrorException("The uuid cannot be null or empty", exception);
+				case "Cannot proceed to delete":
+					throw new InternalErrorException("Cannot proceed to delete", exception);
+				default:
+					treatClientBaseErrors(exception);
+			}
+		}
+		return DeletionBundle.prepareBundleAfterDeletionOperation(uuid, serverUrl);
+	}
+
+	/**
+	 * The method is used to retrieve the url of the current server.
+	 */
+	private void getUrlOfServer() {
+		InetAddress ip;
+		try {
+			ip = InetAddress.getLocalHost();
+			serverUrl = ip.getCanonicalHostName();
+			logger.info(String.format("Your current Hostname : %s", serverUrl));
+
+		} catch (UnknownHostException exception) {
+			logger.error("Unable to find serverUrl");
+			serverUrl = "ReplaceByTheRightEndpoint";
+		}
+	}
+
+	/**
+	 * Private Method which goal is to process the first levels exceptions thrown by the Patient feed client.
+	 *
+	 * @param e the exception thrown
+	 * @throws InternalErrorException throws back the exception with the right http code and the stack trace.
+	 */
+	private void treatClientBaseErrors (Exception e) {
+		switch(e.getMessage()) {
+			case "Exception while Mapping with GITB elements !":
+				throw new InternalErrorException("Exception while Mapping with GITB elements !", e);
+			case "Invalid Response from distant PatientFeedProcessingService !":
+				throw new InternalErrorException("Invalid Response from distant PatientFeedProcessingService !", e);
+			case "Invalid operation used on distant PatientFeedProcessingService !":
+				throw new InternalErrorException("Invalid operation used on distant PatientFeedProcessingService !", e);
+			case "Invalid Request sent to distant PatientFeedProcessingService !":
+				throw new InternalErrorException("Invalid Request sent to distant PatientFeedProcessingService !", e);
+			default:
+				throw new InternalErrorException("An unhandled error was thrown.", e);
+		}
+	}
+}
diff --git a/src/main/java/net/ihe/gazelle/application/PatientRegistrySearchClient.java b/src/main/java/net/ihe/gazelle/application/PatientRegistrySearchClient.java
new file mode 100644
index 0000000000000000000000000000000000000000..8fab2cf957256115e99013db05025aff2b7683f5
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/application/PatientRegistrySearchClient.java
@@ -0,0 +1,208 @@
+package net.ihe.gazelle.application;
+
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
+import com.gitb.ps.ProcessingService;
+import net.ihe.gazelle.adapter.connector.BusinessToFhirConverter;
+import net.ihe.gazelle.adapter.connector.ConversionException;
+import net.ihe.gazelle.adapter.preferences.Preferences;
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryapi.business.PatientSearchCriterionKey;
+import net.ihe.gazelle.app.patientregistrysearchclient.adapter.PatientSearchClient;
+import net.ihe.gazelle.framework.loggerservice.application.GazelleLogger;
+import net.ihe.gazelle.framework.loggerservice.application.GazelleLoggerFactory;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.NamespaceException;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.PreferenceException;
+import net.ihe.gazelle.lib.annotations.Package;
+import net.ihe.gazelle.lib.searchmodelapi.business.SearchCriteria;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import net.ihe.gazelle.lib.searchmodelapi.business.searchcriterion.SearchCriterion;
+import net.ihe.gazelle.lib.searchmodelapi.business.searchcriterion.StringSearchCriterion;
+import org.hl7.fhir.r4.model.OperationOutcome;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.xml.ws.WebServiceException;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+@Named("patientRegistrySearchClient")
+public class PatientRegistrySearchClient {
+
+	private static final String INVALID_REQUEST = "Invalid Request sent to distant PatientFeedProcessingService !";
+	private static final String INVALID_OPERATION = "Invalid operation used on distant PatientFeedProcessingService !";
+	private static final String INVALID_RESPONSE = "Invalid Response from distant PatientFeedProcessingService !";
+	private static final String INVALID_MAPPING = "Exception while Mapping with GITB elements !";
+	public static final String PROCESSING_UUID_OF_PATIENT = "Processing uuid of Patient";
+	public static final String NOT_FOUND = "not-found";
+
+
+	private static final String CONVERSION_ERROR = "A problem occured when Converting Patient from Patient Registry model to hl7 v4";
+	private static final String NO_UUID = "No patient Uuid given in parameter";
+	private static final String NO_PATIENT_FOUND = "No Patient were found";
+	private static final String MORE_THAN_ONE_PATIENT_FOUND = "More than one Patient was found for this ID";
+
+	private static final GazelleLogger logger = GazelleLoggerFactory.getInstance().getLogger(PatientRegistrySearchClient.class);
+	private OperationalPreferencesService operationalPreferencesService;
+	private PatientSearchClient client;
+
+	/**
+	 * Default constructor, used for injection.
+	 *
+	 * @param operationalPreferencesService {@link OperationalPreferencesService} used to retrieve Patient Registry's URL.
+	 */
+	@Inject
+	public PatientRegistrySearchClient(OperationalPreferencesService operationalPreferencesService) {
+
+		this.operationalPreferencesService = operationalPreferencesService;
+	}
+
+	public PatientRegistrySearchClient() {
+
+	}
+
+	/**
+	 * Package-private constructor used for test purposes.
+	 *
+	 * @param url {@link URL} to be used by this to instantiate the processing service to retrieve patients.
+	 */
+	@Package
+	PatientRegistrySearchClient(URL url) {
+		this.client = new PatientSearchClient(url);
+	}
+
+
+	/**
+	 * Package-private constructor used for test purposes.
+	 *
+	 * @param service {@link ProcessingService} to be used by this to retrieve Patients.
+	 */
+	@Package
+	PatientRegistrySearchClient(ProcessingService service) {
+		this.client = new PatientSearchClient(service);
+	}
+
+	@Package
+	public void setClient(PatientSearchClient client) {
+		this.client = client;
+	}
+
+	/**
+	 * Method To call the Search Client from Patient Registry with the uuid of a Patient.
+	 *  
+	 * @param patientUuid the uuid of the Patient as a String
+	 * 
+	 * @return a single Patient (in hl7 v4 model) corresponding to the uuid given
+	 * 
+	 * @throws SearchException
+	 */
+	public org.hl7.fhir.r4.model.Patient searchPatient(String patientUuid) throws SearchException {
+		if(patientUuid == null || patientUuid.equals("")) {
+			logger.error(NO_UUID);
+			throw new InvalidRequestException(NO_UUID);
+
+		}
+
+		if (client == null) {
+			logger.info("client not set");
+			initializeSearchClient();
+		}
+
+		logger.info(PROCESSING_UUID_OF_PATIENT);
+
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(patientUuid);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		List<org.hl7.fhir.r4.model.Patient> resources = new ArrayList<>();
+
+		try {
+
+			logger.info("Sending request to patient registry");
+			List<Patient> patients = client.search(searchCriteria);
+
+			if (patients.isEmpty()) {
+				logger.error("No Patient found");
+				throw new ResourceNotFoundException(NO_PATIENT_FOUND, generateOperationOutcome(NOT_FOUND, NO_PATIENT_FOUND));
+			}
+
+			if (patients.size() > 1) {
+				logger.error("More than one Patient were found");
+				throw new ResourceNotFoundException(MORE_THAN_ONE_PATIENT_FOUND, generateOperationOutcome(NOT_FOUND, MORE_THAN_ONE_PATIENT_FOUND));
+			}
+
+			logger.info("Search complete");
+			for (Patient pat : patients) {
+				logger.info("converting patient to right model");
+				resources.add(BusinessToFhirConverter.patientToFhirPatient(pat));
+			}
+		} catch (ConversionException e) {
+			logger.error(CONVERSION_ERROR);
+			throw new InternalErrorException(CONVERSION_ERROR, e);
+		} catch (SearchException e) {
+			logger.warn(e.getMessage());
+			switch (e.getMessage()) {
+			case INVALID_REQUEST:
+				throw new InvalidRequestException(INVALID_REQUEST, generateOperationOutcome("code-invalid", INVALID_REQUEST));
+			case INVALID_OPERATION:
+				throw new InvalidRequestException(INVALID_OPERATION, generateOperationOutcome("code-invalid", INVALID_OPERATION));
+			case INVALID_RESPONSE:
+				throw new ResourceNotFoundException(INVALID_RESPONSE, generateOperationOutcome(NOT_FOUND, INVALID_RESPONSE));
+			case INVALID_MAPPING:
+				throw new InternalErrorException(INVALID_MAPPING);
+			default:
+				throw new InternalErrorException(e);
+			}
+		}
+
+
+		return resources.get(0);
+	}
+
+	/**
+	 * Initialize the Search Client using the Operational Preferences Service.
+	 *
+	 * @throws SearchException if the service cannot be instantiated.
+	 */
+	private void initializeSearchClient() throws SearchException {
+		String patientRegistryUrl = null;
+		try {
+			patientRegistryUrl = this.operationalPreferencesService.
+					getStringValue(Preferences.PATIENT_REGISTRY_URL.getNamespace().getValue(), Preferences.PATIENT_REGISTRY_URL.getKey());
+			this.client = new PatientSearchClient(new URL(patientRegistryUrl));
+		} catch (NamespaceException | PreferenceException e) {
+			throw new SearchException(String.format("Unable to retrieve [%s] Preference !", Preferences.PATIENT_REGISTRY_URL.getKey()));
+		} catch (MalformedURLException e) {
+			throw new SearchException(String.format("Preference [%s] with value [%s] is not a valid URL !", Preferences.PATIENT_REGISTRY_URL.getKey(),
+					patientRegistryUrl));
+		} catch (WebServiceException e) {
+			logger.warn(e.getMessage());
+			throw new SearchException(String.format("Can't connect to patient registry ! at address [%s]", patientRegistryUrl));
+		}
+
+	}
+
+
+	/**
+	 * Method to generate the Error outcome in the response
+	 *
+	 * @param codeString  Code of the error catch
+	 * @param diagnostics origin of the issue
+	 * @return generated Operation outcome for the Fhir response
+	 */
+	private OperationOutcome generateOperationOutcome(String codeString, String diagnostics) {
+		OperationOutcome code = new OperationOutcome();
+		OperationOutcome.OperationOutcomeIssueComponent issue = new OperationOutcome.OperationOutcomeIssueComponent();
+		issue.setSeverity(OperationOutcome.IssueSeverity.ERROR);
+		issue.setCode(OperationOutcome.IssueType.fromCode(codeString));
+		issue.setDiagnostics(diagnostics);
+		code.addIssue(issue);
+		return code;
+	}
+}
diff --git a/src/main/java/net/ihe/gazelle/business/provider/CHBundleProvider.java b/src/main/java/net/ihe/gazelle/business/provider/CHBundleProvider.java
new file mode 100644
index 0000000000000000000000000000000000000000..8bb75cc53a2b26b1bf188b61eb1d54792288688c
--- /dev/null
+++ b/src/main/java/net/ihe/gazelle/business/provider/CHBundleProvider.java
@@ -0,0 +1,148 @@
+package net.ihe.gazelle.business.provider;
+
+import ca.uhn.fhir.rest.annotation.*;
+import ca.uhn.fhir.rest.api.MethodOutcome;
+import ca.uhn.fhir.rest.server.IResourceProvider;
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import net.ihe.gazelle.lib.annotations.Package;
+import org.hl7.fhir.instance.model.api.IBaseResource;
+import org.hl7.fhir.r4.model.Bundle;
+import org.hl7.fhir.r4.model.IdType;
+import org.hl7.fhir.r4.model.Patient;
+import org.hl7.fhir.r4.model.ResourceType;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import java.util.List;
+
+@Named("chBundleProvider")
+public class CHBundleProvider implements IResourceProvider {
+	
+    private static final Logger patientLogger = LoggerFactory.getLogger(CHBundleProvider.class);
+
+    private CHBundleProvider() {
+    }
+
+    @Package
+    public CHBundleProvider(ChPatientResourceProvider chPatientResourceProvider) {
+        this.chPatientResourceProvider = chPatientResourceProvider;
+    }
+
+    @Inject
+    private ChPatientResourceProvider chPatientResourceProvider;
+
+    @Inject
+    private PatientRegistryFeedClient patientRegistryFeedClient;
+
+    @Package
+    public CHBundleProvider(PatientRegistryFeedClient client) {
+        this.patientRegistryFeedClient = client;
+    }
+
+    @Override
+    public Class<? extends IBaseResource> getResourceType() {
+        return Bundle.class;
+    }
+
+    /**
+     * Method called to create a Patient contained in an iti 93 bundle
+     *
+     * @param iti93Bundle : the Bundle containing the patient to add to Patient Registry.
+     * @return a Method Outcome containing
+     */
+    @Create
+    public MethodOutcome create(@ResourceParam Bundle iti93Bundle) {
+        if (iti93Bundle == null || iti93Bundle.getEntry().isEmpty()) {
+            patientLogger.error("Bundle is null or Empty");
+            throw new InvalidRequestException("Bundle is null or Empty");
+        }
+        Patient patientBundle = iti93BundleToPatient(iti93Bundle);
+        return chPatientResourceProvider.create(patientBundle);
+    }
+
+	/**
+	 * Method to delete a Patient - represented by its uuid - and a bundle representing the Patientas well.
+	 *
+     * @param theId : the uuid of the patient to delete in database
+	 * @param iti93Bundle : the bundle containing the patient to delete.
+     *
+	 * @return a method outcome containing a response Bundle with the patient and the http response.
+	 */
+	@Delete
+	public MethodOutcome delete(@IdParam IdType theId, @ResourceParam Bundle iti93Bundle) {
+
+	    if (theId == null || theId.isEmpty()) {
+            throw new InvalidRequestException("Invalid ID Parameter, either null or empty.");
+        }
+
+		if (iti93Bundle == null || iti93Bundle.getEntry().isEmpty()) {
+			throw new InvalidRequestException("Invalid bundle provided, either null or empty.");
+		}
+		try {
+			iti93BundleToPatient(iti93Bundle);
+			return chPatientResourceProvider.delete(theId);
+		} catch (InvalidRequestException e) {
+			throw new InvalidRequestException("Bundle Could not be converted to HL7 Patient");
+		}
+	}
+
+    /**
+     * Method called to update a Patient - represented by its uuid - with another Patient included in an iti 93 Bundle.
+     *
+     * @param theId : the id of the Patient to update in the database
+     * @param iti93Bundle : the new value of the patient to be saved.
+     * @return a Method Outcome containing the response bundle with a representation of the patient, and the http response
+     */
+	@Update
+    public MethodOutcome updatePatient(@IdParam IdType theId, @ResourceParam Bundle iti93Bundle) {
+
+        if (theId == null || theId.isEmpty()) {
+            throw new InvalidRequestException("Invalid ID Parameter, either null or empty.");
+        }
+
+        if (iti93Bundle == null || iti93Bundle.getEntry().isEmpty()) {
+            throw new InvalidRequestException("Invalid bundle provided, either null or empty.");
+        }
+
+        try {
+            Patient updatedPatient = iti93BundleToPatient(iti93Bundle);
+            return chPatientResourceProvider.update(theId, updatedPatient);
+        } catch (InvalidRequestException e) {
+            if (e.getMessage().equals("Cannot find resource Type Patient in Bundle")) {
+               throw e;
+            } else {
+                throw new InvalidRequestException("Patient Resource Provider could not take request.", e);
+            }
+        } catch (InternalErrorException e) {
+            throw new InternalErrorException("Patient Resource Provider could not take request.", e);
+        }
+
+    }
+
+    /**
+     * Private method to get back the Patient contained in an iti 93 Bundle.
+     * @param pixmFeed : the bundle in which to recover the Patient.
+     * @return the patient contained in the bundle for further checks and use.
+     */
+    private Patient iti93BundleToPatient(Bundle pixmFeed) {
+        List<Bundle.BundleEntryComponent> listOfEntries = pixmFeed.getEntry();
+        if (listOfEntries.size() != 2) {
+            throw new InvalidRequestException("PixM Feed should have 2 entries.");
+        }
+        for (Bundle.BundleEntryComponent entry : listOfEntries) {
+            if (entry.getResource().getResourceType() == ResourceType.Bundle) {
+                Bundle historyBundle = (Bundle) entry.getResource();
+                for (Bundle.BundleEntryComponent resource : historyBundle.getEntry()) {
+                    if (resource.getResource().getResourceType() == ResourceType.Patient) {
+                        return (Patient) resource.getResource();
+                    }
+                }
+            }
+        }
+        throw new InvalidRequestException("Cannot find resource Type Patient in Bundle");
+    }
+}
\ No newline at end of file
diff --git a/src/main/java/net/ihe/gazelle/business/provider/ChPatientResourceProvider.java b/src/main/java/net/ihe/gazelle/business/provider/ChPatientResourceProvider.java
index 8b836826dcbe08bd068acfcee216ee62686f425e..8d6a2e39be5818c69a5e375b69509ab75b0d96bb 100644
--- a/src/main/java/net/ihe/gazelle/business/provider/ChPatientResourceProvider.java
+++ b/src/main/java/net/ihe/gazelle/business/provider/ChPatientResourceProvider.java
@@ -1,32 +1,35 @@
 package net.ihe.gazelle.business.provider;
 
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.inject.Inject;
-import javax.inject.Named;
-
+import ca.uhn.fhir.rest.annotation.*;
+import ca.uhn.fhir.rest.api.MethodOutcome;
+import ca.uhn.fhir.rest.param.*;
+import ca.uhn.fhir.rest.server.IResourceProvider;
 import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
 import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
+import net.ihe.gazelle.adapter.connector.BundleToPatientRegistryConverter;
+import net.ihe.gazelle.adapter.connector.ConversionException;
+import net.ihe.gazelle.app.patientregistryapi.application.PatientFeedException;
+import net.ihe.gazelle.app.patientregistryapi.application.SearchCrossReferenceException;
+import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import net.ihe.gazelle.application.PatientRegistrySearchClient;
+import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
+import net.ihe.gazelle.lib.annotations.Package;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import org.apache.commons.lang3.StringUtils;
 import org.hl7.fhir.instance.model.api.IBaseResource;
+import org.hl7.fhir.r4.model.IdType;
 import org.hl7.fhir.r4.model.Parameters;
 import org.hl7.fhir.r4.model.Patient;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import ca.uhn.fhir.rest.annotation.Operation;
-import ca.uhn.fhir.rest.annotation.OperationParam;
-import ca.uhn.fhir.rest.param.StringAndListParam;
-import ca.uhn.fhir.rest.param.StringOrListParam;
-import ca.uhn.fhir.rest.param.StringParam;
-import ca.uhn.fhir.rest.param.TokenParam;
-import ca.uhn.fhir.rest.server.IResourceProvider;
-import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
-import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
-import net.ihe.gazelle.app.patientregistryapi.application.SearchCrossReferenceException;
-import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
-import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
-import net.ihe.gazelle.lib.annotations.Package;
+import javax.inject.Inject;
+import javax.inject.Named;
+import java.util.ArrayList;
+import java.util.List;
 
 /**
  * This is a resource provider which stores Patient resources in memory using a HashMap. This is obviously not a production-ready solution for many
@@ -35,6 +38,7 @@ import net.ihe.gazelle.lib.annotations.Package;
  */
 @Named("chPatientResourceProvider")
 public class ChPatientResourceProvider implements IResourceProvider {
+
     public static final String URN_OID = "urn:oid:";
     public static final String INVALID_REQUEST_BAD_SOURCE_IDENTIFIER = "Invalid request : bad sourceIdentifier";
     public static final String INVALID_REQUEST_TARGET_DOMAIN_CAN_NOT_BE_EMPTY = "Invalid request : targetDomain can not be empty";
@@ -44,15 +48,153 @@ public class ChPatientResourceProvider implements IResourceProvider {
     public static final String SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND = "sourceIdentifier Assigning Authority not found";
     public static final String TARGET_SYSTEM_NOT_FOUND = "targetSystem not found";
     private static final Logger patientLogger = LoggerFactory.getLogger(ChPatientResourceProvider.class);
+    public static final String NO_ID_PROVIDED = "No ID provided";
+    public static final String NO_BUNDLE_PROVIDED = "No Bundle provided";
+    public static final String NO_PATIENT_PROVIDED = "No Patient Provided";
+
     @Inject
     private PatientRegistryXRefSearchClient patientRegistryXRefSearchClient;
-    
-    public ChPatientResourceProvider() {
+
+    @Inject
+    private PatientRegistrySearchClient patientRegistrySearchClient;
+
+    @Inject
+    private PatientRegistryFeedClient patientRegistryFeedClient;
+
+    private ChPatientResourceProvider() {
     }
-    
+
     @Package
     public ChPatientResourceProvider(PatientRegistryXRefSearchClient client) {
-    	this.patientRegistryXRefSearchClient = client;
+        this.patientRegistryXRefSearchClient = client;
+    }
+
+    @Package
+    public ChPatientResourceProvider(PatientRegistryFeedClient client) {
+        this.patientRegistryFeedClient = client;
+    }
+
+    @Package
+    public ChPatientResourceProvider(PatientRegistrySearchClient client) {
+        this.patientRegistrySearchClient = client;
+    }
+
+
+    /**
+     * The getResourceType method comes from IResourceProvider, and must be overridden to indicate what type of resource this provider supplies.
+     */
+    @Override
+    public Class<? extends IBaseResource> getResourceType() {
+        return Patient.class;
+    }
+
+    /**
+     * Method to read a Patient through its uuid in the patient Manager database
+     *
+     * @param theId : Id Type given in the url. represents the uuid of the searched patient
+     * @return One patient corresponding to the uuid given in entry. If many Patients are found, we consider it as an error and won't return ANY
+     * patient.
+     */
+    @Read
+    public Patient read(@IdParam IdType theId) {
+        String uuid = theId.getIdPart();
+        if (StringUtils.isBlank(uuid)) {
+            patientLogger.error(NO_ID_PROVIDED);
+            throw new InvalidRequestException(NO_ID_PROVIDED);
+        }
+
+        try {
+            Patient retrievedPatient = patientRegistrySearchClient.searchPatient(uuid);
+            patientLogger.info("Patient Successfully found");
+            return retrievedPatient;
+        } catch (SearchException e) {
+            throw new InternalErrorException("Patient could not be retrieved", e);
+        }
+
+    }
+
+    /**
+     * Method called to create a Patient on Patient Registry
+     *
+     * @param iti93Patient : the Patient to create.
+     * @return a MethodOutcome containing a representation of the patient created.
+     */
+    @Create
+    public MethodOutcome create(@ResourceParam Patient iti93Patient) {
+        if (iti93Patient == null) {
+            patientLogger.error(NO_PATIENT_PROVIDED);
+            throw new InvalidRequestException(NO_PATIENT_PROVIDED);
+        }
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient patient =
+                    BundleToPatientRegistryConverter.fhirPatientToGazellePatient(iti93Patient);
+            MethodOutcome methodOutcome = new MethodOutcome();
+            methodOutcome.setResource(patientRegistryFeedClient.createPatient(patient));
+            if (methodOutcome.getResource() != null) {
+                return methodOutcome;
+            } else {
+                throw new ResourceNotFoundException("MethodOutcome was not created");
+            }
+
+        } catch (ConversionException e) {
+            throw new InvalidRequestException("Bundle Could not be converted to HL7 Patient");
+        } catch (PatientFeedException e) {
+            throw new InternalErrorException("Patient Feed client is not set");
+        }
+    }
+
+    /**
+     * Method to Update a patient related to PIXm Delete Method
+     *
+     * @param theId      the UUID of the Patient we want to update
+     * @param hl7Patient The Bundle content of the patient
+     * @return FhirBundle that contains the updated patient
+     */
+    @Update
+    public MethodOutcome update(@IdParam IdType theId, @ResourceParam Patient hl7Patient) {
+        String uuid = theId.getIdPart();
+        if (StringUtils.isBlank(uuid)) {
+            patientLogger.error(NO_ID_PROVIDED);
+            throw new InvalidRequestException(NO_ID_PROVIDED);
+        }
+        if (hl7Patient == null || !hl7Patient.hasId()) {
+            throw new InvalidRequestException(NO_BUNDLE_PROVIDED);
+        }
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient patientToUpdate =
+                    BundleToPatientRegistryConverter.fhirPatientToGazellePatient(hl7Patient);
+            MethodOutcome methodOutcome = new MethodOutcome();
+            methodOutcome.setResource(patientRegistryFeedClient.updatePatient(patientToUpdate, uuid));
+            return methodOutcome;
+        } catch (ConversionException e) {
+            throw new InvalidRequestException("Bundle Could not be converted to HL7 Patient", e);
+        } catch (PatientFeedException e) {
+            throw new InternalErrorException("Patient Feed client is not set");
+        }
+    }
+
+    /**
+     * Method to delete a Patient related to PIXm Delete Method
+     *
+     * @param theId of the patient to delete
+     * @return FhirBundle that contains the deletion status
+     */
+    @Delete
+    public MethodOutcome delete(@IdParam IdType theId) {
+
+        if (theId == null || theId.isEmpty()) {
+            throw new InvalidRequestException(NO_ID_PROVIDED);
+        }
+
+        String uuid = theId.getIdPart();
+        try {
+            MethodOutcome methodOutcome = new MethodOutcome();
+            methodOutcome.setResource(patientRegistryFeedClient.delete(uuid));
+            return methodOutcome;
+        } catch (PatientFeedException e) {
+            patientLogger.error("Error in deletion :", e);
+            throw new InternalErrorException("Internal Error :", e);
+        }
     }
 
     /**
@@ -62,16 +204,16 @@ public class ChPatientResourceProvider implements IResourceProvider {
      * @param sourceIdentifierParam : the source identifier of the patient, should be formatted "urn:oid:x.x.x.x.x.x.x.x.x.x|value"
      * @param targetSystemParam:    the target System(s) we want to find the Patient on, should be formatted "urn:oid:x.x.x.x.x.x.x.x.x.x,urn:oid:x
      *                              .x.x.x.x.x.x.x.x.x,"
-     * @return a Parameters element composed of a list of target identifier for every Patient found, and an url to the Patient in the server.
+     * @return a Parameter element composed of a list of target identifier for every Patient found, and an url to the Patient in the server.
      */
     @Operation(name = "$ihe-pix", idempotent = true)
-    public Parameters findPatientsByIdentifier(@OperationParam(name = "sourceIdentifier", min = 1, max = 1) TokenParam sourceIdentifierParam,
+    public Parameters findPatientsByIdentifier(@OperationParam(name = "sourceIdentifier", min = 1, max = 1) TokenAndListParam sourceIdentifierParam,
                                                @OperationParam(name = "targetSystem", min = 1, max = 2) StringAndListParam targetSystemParam) {
 
         EntityIdentifier sourceIdentifier = createEntityIdentifierFromSourceIdentifier(sourceIdentifierParam);
         List<String> targetSystemList = createTargetSystemListFromParam(targetSystemParam);
 
-        Parameters parametersResults = null;
+        Parameters parametersResults;
         try {
             parametersResults = patientRegistryXRefSearchClient.process(sourceIdentifier, targetSystemList);
         } catch (SearchCrossReferenceException e) {
@@ -80,30 +222,29 @@ public class ChPatientResourceProvider implements IResourceProvider {
         return parametersResults;
     }
 
-
     /**
-     * The getResourceType method comes from IResourceProvider, and must be overridden to indicate what type of resource this provider supplies.
+     * Private method used to transform a Source Identifier into an Entity Identifier for Patient Registry database
+     * @param sourceIdentifier : the source Identifier to convert
+     * @return An Entity Identifier understood by Patient Registry.
      */
-    @Override
-    public Class<? extends IBaseResource> getResourceType() {
-        return Patient.class;
-    }
-
-    private EntityIdentifier createEntityIdentifierFromSourceIdentifier(TokenParam sourceIdentifier) {
-        if (sourceIdentifier == null) {
-            throw new ResourceNotFoundException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
+    private EntityIdentifier createEntityIdentifierFromSourceIdentifier(TokenAndListParam sourceIdentifier) {
+        if (sourceIdentifier == null || sourceIdentifier.size()==0 || sourceIdentifier.size()>1) {
+            throw new InvalidRequestException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
         }
-        String sourceIdentifierSystem = sourceIdentifier.getSystem();
-        String sourceIdentifierValue = sourceIdentifier.getValue();
+        TokenOrListParam tokenOrListParams = sourceIdentifier.getValuesAsQueryTokens().get(0);
+        TokenParam source = tokenOrListParams.getValuesAsQueryTokens().get(0);
+
+        String sourceIdentifierSystem = source.getSystem();
+        String sourceIdentifierValue = source.getValue();
         if (sourceIdentifierSystem == null) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " null system");
-            throw new ResourceNotFoundException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
+            throw new InvalidRequestException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
         }
         if (sourceIdentifierValue == null) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " null value");
             throw new InvalidRequestException(SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND);
         }
-        if (sourceIdentifierSystem.isBlank() || sourceIdentifierValue.isBlank()) {
+        if (StringUtils.isBlank(sourceIdentifierSystem) || StringUtils.isBlank(sourceIdentifierValue)) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " empty system or value");
             throw new InvalidRequestException(SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND);
         }
diff --git a/src/main/java/net/ihe/gazelle/business/provider/IhePatientResourceProvider.java b/src/main/java/net/ihe/gazelle/business/provider/IhePatientResourceProvider.java
index d0995a97cdde9a2489a990bc5bcfcc7cd157b5b6..554e006f00503b4ee2eb125ac32fe8e0bd2cdca0 100644
--- a/src/main/java/net/ihe/gazelle/business/provider/IhePatientResourceProvider.java
+++ b/src/main/java/net/ihe/gazelle/business/provider/IhePatientResourceProvider.java
@@ -1,11 +1,10 @@
 package net.ihe.gazelle.business.provider;
 
+import ca.uhn.fhir.rest.annotation.IdParam;
 import ca.uhn.fhir.rest.annotation.Operation;
 import ca.uhn.fhir.rest.annotation.OperationParam;
-import ca.uhn.fhir.rest.param.StringAndListParam;
-import ca.uhn.fhir.rest.param.StringOrListParam;
-import ca.uhn.fhir.rest.param.StringParam;
-import ca.uhn.fhir.rest.param.TokenParam;
+import ca.uhn.fhir.rest.annotation.Read;
+import ca.uhn.fhir.rest.param.*;
 import ca.uhn.fhir.rest.server.IResourceProvider;
 import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
 import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
@@ -13,9 +12,13 @@ import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
 import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
 import net.ihe.gazelle.app.patientregistryapi.application.SearchCrossReferenceException;
 import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
+import net.ihe.gazelle.application.PatientRegistrySearchClient;
 import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
 import net.ihe.gazelle.lib.annotations.Package;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import org.apache.commons.lang3.StringUtils;
 import org.hl7.fhir.instance.model.api.IBaseResource;
+import org.hl7.fhir.r4.model.IdType;
 import org.hl7.fhir.r4.model.Parameters;
 import org.hl7.fhir.r4.model.Patient;
 import org.slf4j.Logger;
@@ -39,9 +42,14 @@ public class IhePatientResourceProvider implements IResourceProvider {
     public static final String SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND = "sourceIdentifier Patient Identifier not found";
     public static final String SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND = "sourceIdentifier Assigning Authority not found";
     public static final String TARGET_SYSTEM_NOT_FOUND = "targetSystem not found";
+    public static final String NO_ID_PROVIDED = "No ID provided";
+
     @Inject
     private PatientRegistryXRefSearchClient patientRegistryXRefSearchClient;
 
+    @Inject
+    private PatientRegistrySearchClient patientRegistrySearchClient;
+
     /**
      * The getResourceType method comes from IResourceProvider, and must be overridden to indicate what type of resource this provider supplies.
      */
@@ -58,24 +66,52 @@ public class IhePatientResourceProvider implements IResourceProvider {
         this.patientRegistryXRefSearchClient = client;
     }
 
+    @Package
+    public IhePatientResourceProvider(PatientRegistrySearchClient client) {
+        this.patientRegistrySearchClient = client;
+    }
+
+    /**
+     * Method to read a Patient through its uuid in the patient Manager database
+     *
+     * @param theId : Id Type given in the url. represents the uuid of the searched patient
+     * @return One patient corresponding to the uuid given in entry. If many Patients are found, we consider it as an error and won't return ANY
+     * patient.
+     */
+    @Read
+    public Patient read(@IdParam IdType theId) {
+        if (StringUtils.isBlank(theId.getIdPart())) {
+            patientLogger.error(NO_ID_PROVIDED);
+            throw new InvalidRequestException(NO_ID_PROVIDED);
+        }
+        String uuid = theId.getIdPart();
+        try {
+            Patient retrievedPatient = patientRegistrySearchClient.searchPatient(uuid);
+            patientLogger.info("Patient Successfully found");
+            return retrievedPatient;
+        } catch (SearchException e) {
+            throw new InternalErrorException("Patient could not be retrieved", e);
+        }
+
+    }
+
     /**
      * Search method for a Patient using the source identifier required parameter
      * and an optional list of target system
      *
      * @param sourceIdentifierParam : the source identifier of the patient, should be formatted "urn:oid:x.x.x.x.x.x.x.x.x.x|value"
-     * @param targetSystemParam:    the target System(s) we want to find the Patient on, should be formatted "urn:oid:x.x.x.x.x.x.x.x.x.x,urn:oid:x
-     *                              .x.x.x
-     *                              .x.x.x.x.x.x,"
+     * @param targetSystemParam:    the target System(s) we want to find the Patient on, should be formatted "urn:oid:x.x.x.x.x.x.x.x.x.x,
+     *                              urn:oid:x.x.x.x.x.x.x.x.x.x"
      * @return a Parameters element composed of a list of target identifier for every Patient found, and an url to the Patient in the server.
      */
     @Operation(name = "$ihe-pix", idempotent = true)
-    public Parameters findPatientsByIdentifier(@OperationParam(name = "sourceIdentifier", min = 1, max = 1) TokenParam sourceIdentifierParam,
+    public Parameters findPatientsByIdentifier(@OperationParam(name = "sourceIdentifier", min = 1, max = 1) TokenAndListParam sourceIdentifierParam,
                                                @OperationParam(name = "targetSystem") StringAndListParam targetSystemParam) {
 
         EntityIdentifier sourceIdentifier = createEntityIdentifierFromSourceIdentifier(sourceIdentifierParam);
         List<String> targetSystemList = createTargetSystemListFromParam(targetSystemParam);
 
-        Parameters parametersResults = null;
+        Parameters parametersResults;
         try {
             parametersResults = patientRegistryXRefSearchClient.process(sourceIdentifier, targetSystemList);
         } catch (SearchCrossReferenceException e) {
@@ -85,21 +121,24 @@ public class IhePatientResourceProvider implements IResourceProvider {
         return parametersResults;
     }
 
-    private EntityIdentifier createEntityIdentifierFromSourceIdentifier(TokenParam sourceIdentifier) {
-        if (sourceIdentifier == null) {
-            throw new ResourceNotFoundException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
+    private EntityIdentifier createEntityIdentifierFromSourceIdentifier(TokenAndListParam sourceIdentifier) {
+        if (sourceIdentifier == null || sourceIdentifier.size() == 0 || sourceIdentifier.size() > 1) {
+            throw new InvalidRequestException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
         }
-        String sourceIdentifierSystem = sourceIdentifier.getSystem();
-        String sourceIdentifierValue = sourceIdentifier.getValue();
+        TokenOrListParam tokenOrListParams = sourceIdentifier.getValuesAsQueryTokens().get(0);
+        TokenParam source = tokenOrListParams.getValuesAsQueryTokens().get(0);
+
+        String sourceIdentifierSystem = source.getSystem();
+        String sourceIdentifierValue = source.getValue();
         if (sourceIdentifierSystem == null) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " null system");
-            throw new ResourceNotFoundException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
+            throw new InvalidRequestException(SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND);
         }
         if (sourceIdentifierValue == null) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " null value");
             throw new InvalidRequestException(SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND);
         }
-        if (sourceIdentifierSystem.isBlank() || sourceIdentifierValue.isBlank()) {
+        if (StringUtils.isBlank(sourceIdentifierSystem) || StringUtils.isBlank(sourceIdentifierValue)) {
             patientLogger.error(INVALID_REQUEST_BAD_SOURCE_IDENTIFIER + " empty system or value");
             throw new InvalidRequestException(SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND);
         }
diff --git a/src/main/resources/SoapUI/IHE-Pixm-soapui-project.xml b/src/main/resources/SoapUI/IHE-Pixm-soapui-project.xml
index 71822cb5dec90e9583bbe0740d82f9d7813dcdba..dfd92274b6089691f7686ee37630f244c06283bb 100644
--- a/src/main/resources/SoapUI/IHE-Pixm-soapui-project.xml
+++ b/src/main/resources/SoapUI/IHE-Pixm-soapui-project.xml
@@ -30,7 +30,7 @@
   <con:entry key="Domain" value=""/>
   <con:entry key="Tool Args" value=""/>
   <con:entry key="Save Project" value="false"/>
-</xml-fragment>]]></con:setting></con:settings><con:interface xsi:type="con:RestService" id="3aa45915-2866-4224-a6c0-61c79628c944" wadlVersion="http://wadl.dev.java.net/2009/02" name="http://qualification.ihe-europe.net" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8580/pixm_fhir_server/fhir_ihe</con:endpoint><con:endpoint>http://qualification.ihe-europe.net/pixm_fhir_server/fhir_ihe</con:endpoint></con:endpoints><con:resource name="" path="/{resource}/{operation}" id="cf9419c5-50ad-4552-915e-bcb5492a80db"><con:settings/><con:parameters><con:parameter><con:name>resource</con:name><con:value/><con:style>TEMPLATE</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>operation</con:name><con:value/><con:style>TEMPLATE</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>sourceIdentifier</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>targetSystem</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>_format</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GET from sourceIdentifier" id="a06fed5a-ee7b-4b4b-be29-9368040008a4" method="GET"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html; charset=iso-8859-1</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html; charset=iso-8859-1</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>404 400 403 401</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>fhir+json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>fhir+xml</con:mediaType><con:status>200</con:status><con:params/><con:element>id</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+xml</con:mediaType><con:status>403</con:status><con:params/><con:element>id</con:element></con:representation><con:representation type="FAULT"><con:mediaType/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+json</con:mediaType><con:status>404</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+json; charset=UTF-8</con:mediaType><con:status>404 500 400</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/fhir+json; charset=UTF-8</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:request name="code 200" id="79fc74bf-5277-4aef-8f00-744072264e5e" mediaType="application/json" multiValueDelimiter=","><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers">&lt;xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@remove_empty_content">false</con:setting></con:settings><con:endpoint>http://localhost:8089/</con:endpoint><con:request/><con:originalUri>http://qualification.ihe-europe.net/Patient%2F%24ihe-pix</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters>
+</xml-fragment>]]></con:setting></con:settings><con:interface xsi:type="con:RestService" id="3aa45915-2866-4224-a6c0-61c79628c944" wadlVersion="http://wadl.dev.java.net/2009/02" name="http://qualification.ihe-europe.net" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8580/pixm_fhir_server/fhir_ihe</con:endpoint><con:endpoint>http://qualification.ihe-europe.net/pixm_fhir_server/fhir_ihe</con:endpoint></con:endpoints><con:resource name="" path="/{resource}/{operation}" id="cf9419c5-50ad-4552-915e-bcb5492a80db"><con:settings/><con:parameters><con:parameter><con:name>resource</con:name><con:value/><con:style>TEMPLATE</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>operation</con:name><con:value/><con:style>TEMPLATE</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>sourceIdentifier</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>targetSystem</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>_format</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GET from sourceIdentifier" id="a06fed5a-ee7b-4b4b-be29-9368040008a4" method="GET"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html; charset=iso-8859-1</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html; charset=iso-8859-1</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>404 400 403 401</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>fhir+json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>fhir+xml</con:mediaType><con:status>200</con:status><con:params/><con:element>id</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+xml</con:mediaType><con:status>403</con:status><con:params/><con:element>id</con:element></con:representation><con:representation type="FAULT"><con:mediaType/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>404</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType xsi:nil="true"/><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+json</con:mediaType><con:status>404</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+json; charset=UTF-8</con:mediaType><con:status>404 500 400</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Fault</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/fhir+json; charset=UTF-8</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:pat="http://qualification.ihe-europe.net/Patient%2F%24ihe-pix">pat:Response</con:element></con:representation><con:representation type="FAULT"><con:mediaType>application/fhir+xml; charset=UTF-8</con:mediaType><con:status>500 404</con:status><con:params/><con:element xmlns:fhir="http://hl7.org/fhir">fhir:OperationOutcome</con:element></con:representation><con:request name="code 200" id="79fc74bf-5277-4aef-8f00-744072264e5e" mediaType="application/json" multiValueDelimiter=","><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers">&lt;xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@remove_empty_content">false</con:setting></con:settings><con:endpoint>http://localhost:8089/</con:endpoint><con:request/><con:originalUri>http://qualification.ihe-europe.net/Patient%2F%24ihe-pix</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters>
   <con:entry key="sourceIdentifier" value="urn:oid:1.3.6.1.4.1.21367.2010.1.2.300|NA5404"/>
   <con:entry key="resource" value="Patient"/>
   <con:entry key="operation" value="/$ihe-pix"/>
@@ -46,7 +46,7 @@
   <con:entry key="sourceIdentifier" value="urn:oid:1.3.6.1.4.1.21367.2010.1.2.300|NA5404 "/>
   <con:entry key="resource" value="Patient"/>
   <con:entry key="operation" value="/$ihe-pix"/>
-</con:parameters><con:parameterOrder><con:entry>resource</con:entry><con:entry>operation</con:entry><con:entry>sourceIdentifier</con:entry><con:entry>targetSystem</con:entry><con:entry>_format</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:testSuite id="4008d084-2b9b-4853-90b1-75ae50eda188" name="PixM - Code 200"><con:description>TestSuite generated for REST Service [http://qualification.ihe-europe.net]</con:description><con:settings/><con:runType>SEQUENTIAL</con:runType><con:testCase id="c9b20a8c-efd3-4613-8b00-ed4cbbf5a582" failOnError="true" failTestCaseOnErrors="true" keepSession="false" maxResults="0" name="TestCase" searchProperties="true"><con:description>TestCase generated for REST Resource [] located at [/{resource}{operation}]</con:description><con:settings/><con:testStep type="transfer" name="Property Transfer" id="2bbdf78b-4de4-4c6b-b73d-e88fca4f3bd0"><con:settings/><con:config xsi:type="con:PropertyTransfersStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name>sourceIdentifier</con:name><con:sourceType>sourceIdentifier</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>sourceIdentifier</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name> targetSystem</con:name><con:sourceType>targetSystem</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>targetSystem</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name>_format</con:name><con:sourceType>_format</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>_format</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers></con:config></con:testStep><con:testStep type="restrequest" name="code 200" id="92a9dcef-29ec-4d16-a50b-8379860b7234"><con:settings/><con:config service="http://qualification.ihe-europe.net" resourcePath="/{resource}/{operation}" methodName="GET from sourceIdentifier" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="code 200" id="79fc74bf-5277-4aef-8f00-744072264e5e" mediaType="application/json" multiValueDelimiter=","><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers">&lt;xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@remove_empty_content">false</con:setting></con:settings><con:endpoint>localhost:8580/pixm_fhir_server/fhir_ihe/</con:endpoint><con:request/><con:originalUri>http://qualification.ihe-europe.net/Patient%2F%24ihe-pix</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="19207097-8fec-4017-89c0-f4ba61af51e4" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:assertion type="GroovyScriptAssertion" id="22513178-52bd-4e7a-9cf0-0e6d2eb7649d" name="Script Assertion"><con:configuration><scriptText>String sourceIdentifier = context.testCase.testSteps['code 200'].getPropertyValue( "sourceIdentifier" )
+</con:parameters><con:parameterOrder><con:entry>resource</con:entry><con:entry>operation</con:entry><con:entry>sourceIdentifier</con:entry><con:entry>targetSystem</con:entry><con:entry>_format</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:testSuite id="4008d084-2b9b-4853-90b1-75ae50eda188" name="PixM - Code 200"><con:description>TestSuite generated for REST Service [http://qualification.ihe-europe.net]</con:description><con:settings/><con:runType>SEQUENTIAL</con:runType><con:testCase id="c9b20a8c-efd3-4613-8b00-ed4cbbf5a582" failOnError="true" failTestCaseOnErrors="true" keepSession="false" maxResults="0" name="TestCase" searchProperties="true"><con:description>TestCase generated for REST Resource [] located at [/{resource}{operation}]</con:description><con:settings/><con:testStep type="transfer" name="Property Transfer" id="2bbdf78b-4de4-4c6b-b73d-e88fca4f3bd0"><con:settings/><con:config xsi:type="con:PropertyTransfersStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name>sourceIdentifier</con:name><con:sourceType>sourceIdentifier</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>sourceIdentifier</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name> targetSystem</con:name><con:sourceType>targetSystem</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>targetSystem</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers><con:transfers setNullOnMissingSource="true" transferTextContent="true" failOnError="true" ignoreEmpty="false" transferToAll="false" entitize="false" transferChildNodes="false"><con:name>_format</con:name><con:sourceType>_format</con:sourceType><con:sourceStep>#TestSuite#</con:sourceStep><con:targetType>_format</con:targetType><con:targetStep>code 200</con:targetStep><con:upgraded>true</con:upgraded></con:transfers></con:config></con:testStep><con:testStep type="restrequest" name="code 200" id="92a9dcef-29ec-4d16-a50b-8379860b7234"><con:settings/><con:config service="http://qualification.ihe-europe.net" resourcePath="/{resource}/{operation}" methodName="GET from sourceIdentifier" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="code 200" id="79fc74bf-5277-4aef-8f00-744072264e5e" mediaType="application/json" multiValueDelimiter=","><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers">&lt;xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@remove_empty_content">false</con:setting></con:settings><con:endpoint>http://qualification.ihe-europe.net/pixm-connector/fhir_ihe</con:endpoint><con:request/><con:originalUri>http://qualification.ihe-europe.net/Patient%2F%24ihe-pix</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="19207097-8fec-4017-89c0-f4ba61af51e4" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:assertion type="GroovyScriptAssertion" id="22513178-52bd-4e7a-9cf0-0e6d2eb7649d" name="Script Assertion"><con:configuration><scriptText>String sourceIdentifier = context.testCase.testSteps['code 200'].getPropertyValue( "sourceIdentifier" )
 log.info sourceIdentifier
 assert (sourceIdentifier ==~ /urn:oid:([0-9]*)(\.[0-9]*){10}\|([0-9A-Z])*/)</scriptText></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters>
   <con:entry key="sourceIdentifier" value="urn:oid:1.3.6.1.4.1.21367.2010.1.2.300|NA5404"/>
diff --git a/src/test/ResourcesToTestPurpose/post_request.json b/src/test/ResourcesToTestPurpose/post_request.json
new file mode 100644
index 0000000000000000000000000000000000000000..a2f344914ae70e382fd3b58d7f255b782c87aecc
--- /dev/null
+++ b/src/test/ResourcesToTestPurpose/post_request.json
@@ -0,0 +1,127 @@
+{
+  "resourceType" : "Bundle",
+  "id" : "BundlePIXmFeed",
+  "meta" : {
+    "profile" : [
+      "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle"
+    ]
+  },
+  "type" : "message",
+  "entry" : [
+    {
+      "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+      "resource" : {
+        "resourceType" : "MessageHeader",
+        "id" : "1",
+        "text" : {
+          "status" : "generated",
+          "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><p><b>focus</b>: <a href=\"#Bundle_abc\">See above (Bundle/abc)</a></p></div>"
+        },
+        "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+        "destination" : [
+          {
+            "endpoint" : "http://example.com/patientEndpoint"
+          }
+        ],
+        "source" : {
+          "endpoint" : "http://example.com/patientSource"
+        },
+        "focus" : [
+          {
+            "reference" : "Bundle/abc"
+          }
+        ]
+      }
+    },
+    {
+      "fullUrl" : "http://example.com/fhir/Bundle/abc",
+      "resource" : {
+        "resourceType" : "Bundle",
+        "id" : "abc",
+        "type" : "history",
+        "entry" : [
+          {
+            "fullUrl" : "http://example.com/fhir/Patient/PatientPIXmFeed",
+            "resource" : {
+              "resourceType" : "Patient",
+              "id" : "PatientPIXmFeed",
+              "text" : {
+                "status" : "generated",
+                "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>id</b>: PatientPIXmFeed</p><p><b>meta</b>: </p><p><b>identifier</b>: Medical record number = 8734</p><p><b>name</b>: Franz Muster , Muster </p><p><b>gender</b>: male</p><p><b>birthDate</b>: 1995-01-27</p></div>"
+              },
+              "contained" : [
+                {
+                  "resourceType" : "Organization",
+                  "id" : "org1",
+                  "identifier" : [
+                    {
+                      "system" : "urn:oid:2.51.1.3",
+                      "value" : "7601000201041"
+                    }
+                  ],
+                  "address" : [
+                    {
+                      "use" : "work",
+                      "line" : [
+                        "Doktorgasse",
+                        "2"
+                      ],
+                      "city" : "Musterhausen",
+                      "postalCode" : "8888",
+                      "country" : "CH"
+                    }
+                  ]
+                }
+              ],
+              "identifier" : [
+                {
+                  "type" : {
+                    "coding" : [
+                      {
+                        "system" : "http://terminology.hl7.org/CodeSystem/v2-0203",
+                        "code" : "MR"
+                      }
+                    ]
+                  },
+                  "system" : "urn:oid:2.16.756.888888.3.1",
+                  "value" : "8734"
+                }
+              ],
+              "name" : [
+                {
+                  "family" : "Muster",
+                  "given" : [
+                    "Franz"
+                  ]
+                },
+                {
+                  "family" : "Muster",
+                  "_family" : {
+                    "extension" : [
+                      {
+                        "url" : "http://hl7.org/fhir/StructureDefinition/iso21090-EN-qualifier",
+                        "valueCode" : "BR"
+                      }
+                    ]
+                  }
+                }
+              ],
+              "gender" : "male",
+              "birthDate" : "1995-01-27",
+              "managingOrganization" : {
+                "reference" : "#org1"
+              }
+            },
+            "request" : {
+              "method" : "POST",
+              "url" : "Patient"
+            },
+            "response" : {
+              "status" : "200"
+            }
+          }
+        ]
+      }
+    }
+  ]
+}
diff --git a/src/test/ResourcesToTestPurpose/post_request_1_entry.json b/src/test/ResourcesToTestPurpose/post_request_1_entry.json
new file mode 100644
index 0000000000000000000000000000000000000000..2272eb133135f2964bfff03f05dd6d74bd3c991c
--- /dev/null
+++ b/src/test/ResourcesToTestPurpose/post_request_1_entry.json
@@ -0,0 +1,37 @@
+{
+  "resourceType" : "Bundle",
+  "id" : "BundlePIXmFeed",
+  "meta" : {
+    "profile" : [
+      "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle"
+    ]
+  },
+  "type" : "message",
+  "entry" : [
+    {
+      "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+      "resource" : {
+        "resourceType" : "MessageHeader",
+        "id" : "1",
+        "text" : {
+          "status" : "generated",
+          "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><p><b>focus</b>: <a href=\"#Bundle_abc\">See above (Bundle/abc)</a></p></div>"
+        },
+        "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+        "destination" : [
+          {
+            "endpoint" : "http://example.com/patientEndpoint"
+          }
+        ],
+        "source" : {
+          "endpoint" : "http://example.com/patientSource"
+        },
+        "focus" : [
+          {
+            "reference" : "Bundle/abc"
+          }
+        ]
+      }
+    }
+  ]
+}
diff --git a/src/test/ResourcesToTestPurpose/post_request_NO_PATIENT.json b/src/test/ResourcesToTestPurpose/post_request_NO_PATIENT.json
new file mode 100644
index 0000000000000000000000000000000000000000..cf379192927cdca8059c68d95de0275eaa65a334
--- /dev/null
+++ b/src/test/ResourcesToTestPurpose/post_request_NO_PATIENT.json
@@ -0,0 +1,48 @@
+{
+  "resourceType" : "Bundle",
+  "id" : "BundlePIXmFeed",
+  "meta" : {
+    "profile" : [
+      "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle"
+    ]
+  },
+  "type" : "message",
+  "entry" : [
+    {
+      "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+      "resource" : {
+        "resourceType" : "MessageHeader",
+        "id" : "1",
+        "text" : {
+          "status" : "generated",
+          "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><p><b>focus</b>: <a href=\"#Bundle_abc\">See above (Bundle/abc)</a></p></div>"
+        },
+        "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+        "destination" : [
+          {
+            "endpoint" : "http://example.com/patientEndpoint"
+          }
+        ],
+        "source" : {
+          "endpoint" : "http://example.com/patientSource"
+        },
+        "focus" : [
+          {
+            "reference" : "Bundle/abc"
+          }
+        ]
+      }
+    },
+    {
+      "fullUrl" : "http://example.com/fhir/Bundle/abc",
+      "resource" : {
+        "resourceType" : "Bundle",
+        "id" : "abc",
+        "type" : "history",
+        "entry" : [
+
+        ]
+      }
+    }
+  ]
+}
diff --git a/src/test/ResourcesToTestPurpose/post_response.json b/src/test/ResourcesToTestPurpose/post_response.json
new file mode 100644
index 0000000000000000000000000000000000000000..213578d0951c640c5db90aea525fdf6891896d7f
--- /dev/null
+++ b/src/test/ResourcesToTestPurpose/post_response.json
@@ -0,0 +1,36 @@
+{
+  "resourceType" : "Bundle",
+  "id" : "BundlePIXmResponse",
+  "meta" : {
+    "profile" : [
+      "http://fhir.ch/ig/ch-epr-mhealth/StructureDefinition/ch-pixm-bundle-response"
+    ]
+  },
+  "type" : "message",
+  "entry" : [
+    {
+      "fullUrl" : "http://example.com/fhir/MessageHeader/1",
+      "resource" : {
+        "resourceType" : "MessageHeader",
+        "id" : "1",
+        "text" : {
+          "status" : "generated",
+          "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative</b></p><p><b>event</b>: <code>urn:ihe:iti:pmir:2019:patient-feed</code></p><h3>Destinations</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientEndpoint\">http://example.com/patientEndpoint</a></td></tr></table><h3>Sources</h3><table class=\"grid\"><tr><td>-</td><td><b>Endpoint</b></td></tr><tr><td>*</td><td><a href=\"http://example.com/patientSource\">http://example.com/patientSource</a></td></tr></table><h3>Responses</h3><table class=\"grid\"><tr><td>-</td><td><b>Identifier</b></td><td><b>Code</b></td></tr><tr><td>*</td><td>1</td><td>ok</td></tr></table></div>"
+        },
+        "eventUri" : "urn:ihe:iti:pmir:2019:patient-feed",
+        "destination" : [
+          {
+            "endpoint" : "http://example.com/patientEndpoint"
+          }
+        ],
+        "source" : {
+          "endpoint" : "http://example.com/patientSource"
+        },
+        "response" : {
+          "identifier" : "1",
+          "code" : "ok"
+        }
+      }
+    }
+  ]
+}
\ No newline at end of file
diff --git a/src/test/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverterTest.java b/src/test/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverterTest.java
new file mode 100644
index 0000000000000000000000000000000000000000..3d5f075160793a1cd67a2ac4e5d5b766584c77da
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/adapter/connector/BundleToPatientRegistryConverterTest.java
@@ -0,0 +1,235 @@
+package net.ihe.gazelle.adapter.connector;
+
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import io.qameta.allure.*;
+import net.ihe.gazelle.app.patientregistryapi.business.*;
+import net.ihe.gazelle.app.patientregistryapi.business.Person;
+import org.hl7.fhir.r4.model.*;
+import org.hl7.fhir.r4.model.Address;
+import org.hl7.fhir.r4.model.Patient;
+import org.junit.jupiter.api.Test;
+
+import java.time.LocalDate;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.fail;
+
+@Feature("BundleConverter")
+public class BundleToPatientRegistryConverterTest {
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Name conversion")
+    void TestPatientNameConversion(){
+        Patient pat = new Patient();
+        HumanName name = new HumanName();
+        name.addGiven("Patrick");
+        name.setUse(HumanName.NameUse.TEMP);
+        name.setFamily("Timsit");
+        name.addPrefix("Jr");
+        name.addSuffix("Sr");
+        pat.addName(name);
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat);
+            PersonName responseName = response.getNames().get(0);
+            assertEquals("Patrick", responseName.getGivens().get(0));
+            assertEquals("TEMP", responseName.getUse());
+            assertEquals("Timsit", responseName.getFamily());
+            assertEquals("Jr", responseName.getPrefix());
+            assertEquals("Sr", responseName.getSuffix());
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a name");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Gender conversion")
+    void TestPatientGenderConversion(){
+
+        Patient pat1 = new Patient();
+        pat1.setGender(Enumerations.AdministrativeGender.FEMALE);
+
+        Patient pat2 = new Patient();
+        pat2.setGender(Enumerations.AdministrativeGender.MALE);
+
+        Patient pat3 = new Patient();
+        pat3.setGender(Enumerations.AdministrativeGender.OTHER);
+
+        Patient pat4 = new Patient();
+        pat4.setGender(Enumerations.AdministrativeGender.UNKNOWN);
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat1);
+            assertEquals(GenderCode.FEMALE, response.getGender());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat2);
+            assertEquals(GenderCode.MALE, response.getGender());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat3);
+            assertEquals(GenderCode.OTHER, response.getGender());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat4);
+            assertEquals(GenderCode.UNDEFINED, response.getGender());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a gender");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Contact conversion")
+    void TestPatientContactConversion(){
+
+        Patient pat = new Patient();
+        Patient.ContactComponent comp = new Patient.ContactComponent();
+        comp.setGender(Enumerations.AdministrativeGender.OTHER);
+        Address address = new Address();
+        address.addLine("Henlo");
+        comp.setAddress(address);
+        comp.setName(new HumanName().addGiven("toto"));
+        pat.addContact(comp);
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat);
+            Person contact = response.getContacts().get(0);
+            assertEquals(GenderCode.OTHER, contact.getGender());
+            assertEquals("Henlo", contact.getAddresses().get(0).getLines().get(0));
+            assertEquals("toto", contact.getNames().get(0).getGivens().get(0));
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a contact");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Address conversion")
+    void TestPatientAddressConversion(){
+
+        Patient pat = new Patient();
+        Address address = new Address();
+        address.setCity("Chicoutimi");
+        address.setCountry("Canada");
+        address.setPostalCode("G7B 0G5");
+        address.setState("Québec");
+        address.setUse(Address.AddressUse.TEMP);
+        address.addLine("4 boulevard de l'Université");
+        pat.addAddress(address);
+
+        Patient pat1 = new Patient();
+        Address address1 = new Address();
+        address1.setUse(Address.AddressUse.BILLING);
+        pat1.addAddress(address1);
+        Patient pat2 = new Patient();
+        Address address2 = new Address();
+        address2.setUse(Address.AddressUse.HOME);
+        pat2.addAddress(address2);
+        Patient pat3 = new Patient();
+        Address address3 = new Address();
+        address3.setUse(Address.AddressUse.OLD);
+        pat3.addAddress(address3);
+        Patient pat4 = new Patient();
+        Address address4 = new Address();
+        address4.setUse(Address.AddressUse.WORK);
+        pat4.addAddress(address4);
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat);
+            net.ihe.gazelle.app.patientregistryapi.business.Address responseAddress = response.getAddresses().get(0);
+            assertEquals("Chicoutimi", responseAddress.getCity());
+            assertEquals("Canada", responseAddress.getCountryIso3());
+            assertEquals("G7B 0G5", responseAddress.getPostalCode());
+            assertEquals("Québec", responseAddress.getState());
+            assertEquals(AddressUse.TEMPORARY, responseAddress.getUse());
+            assertEquals("4 boulevard de l'Université", responseAddress.getLines().get(0));
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat1);
+            responseAddress = response.getAddresses().get(0);
+            assertEquals(AddressUse.BILLING, responseAddress.getUse());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat2);
+            responseAddress = response.getAddresses().get(0);
+            assertEquals(AddressUse.HOME, responseAddress.getUse());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat3);
+            responseAddress = response.getAddresses().get(0);
+            assertEquals(AddressUse.BAD, responseAddress.getUse());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat4);
+            responseAddress = response.getAddresses().get(0);
+            assertEquals(AddressUse.WORK, responseAddress.getUse());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just an address");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Single parameters conversion")
+    void TestPatientParametersConversion(){
+
+        LocalDate dateValue = LocalDate.now();
+
+        Patient pat = new Patient();
+        pat.setActive(true);
+        pat.setBirthDate(java.sql.Date.valueOf(dateValue));
+        pat.setId("Hello");
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat);
+            assertEquals(java.sql.Date.valueOf(dateValue), response.getDateOfBirth());
+            assertEquals("Hello", response.getUuid());
+            assertEquals(true, response.isActive());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with simple parameters");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Single parameters conversion")
+    void TestPatientIdentifiersConversion(){
+
+        Patient pat = new Patient();
+        Identifier id = new Identifier();
+        id.setSystem("urn:oid:Hello_Vincent");
+        id.setValue("69420");
+        pat.addIdentifier(id);
+
+        Patient pat1 = new Patient();
+        Identifier id1 = new Identifier();
+        pat.addIdentifier(id1);
+
+
+        try {
+            net.ihe.gazelle.app.patientregistryapi.business.Patient response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat);
+            assertEquals("Hello_Vincent", response.getIdentifiers().get(0).getSystemIdentifier());
+            assertEquals("69420", response.getIdentifiers().get(0).getValue());
+
+            response = BundleToPatientRegistryConverter.fhirPatientToGazellePatient(pat1);
+
+        } catch (InvalidRequestException e) {
+            assertEquals("Cannot create Patient without any Identifier", e.getMessage());
+        } catch (ConversionException e) {
+            fail();
+        }
+
+    }
+
+}
diff --git a/src/test/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverterTest.java b/src/test/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverterTest.java
new file mode 100644
index 0000000000000000000000000000000000000000..3261b7b0996ff414e7ea56b52ab9f4f61f00af1b
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/adapter/connector/BusinessToFhirConverterTest.java
@@ -0,0 +1,239 @@
+package net.ihe.gazelle.adapter.connector;
+
+import io.qameta.allure.Description;
+import io.qameta.allure.Severity;
+import io.qameta.allure.SeverityLevel;
+import io.qameta.allure.Story;
+import io.qameta.allure.Feature;
+import net.ihe.gazelle.app.patientregistryapi.business.*;
+import org.hl7.fhir.r4.model.Enumerations;
+import org.hl7.fhir.r4.model.Patient;
+import org.junit.jupiter.api.Test;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.fail;
+
+@Feature("Fhir to Business Converter")
+public class BusinessToFhirConverterTest {
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Gender conversion")
+    void TestPatientGenderConversion(){
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat1 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        pat1.setGender(GenderCode.FEMALE);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat2 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        pat2.setGender(GenderCode.MALE);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat3 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        pat3.setGender(GenderCode.OTHER);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat4 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        pat4.setGender(GenderCode.UNDEFINED);
+
+        try {
+            Patient response = BusinessToFhirConverter.patientToFhirPatient(pat1);
+            assertEquals(Enumerations.AdministrativeGender.FEMALE, response.getGender());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat2);
+            assertEquals(Enumerations.AdministrativeGender.MALE, response.getGender());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat3);
+            assertEquals(Enumerations.AdministrativeGender.OTHER, response.getGender());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat4);
+            assertEquals(Enumerations.AdministrativeGender.UNKNOWN, response.getGender());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a gender");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Address conversion")
+    void TestPatientAddressConversion(){
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        Address address = new Address();
+        address.setCity("Chicoutimi");
+        address.setCountryIso3("Canada");
+        address.setPostalCode("G7B 0H3");
+        address.setUse(AddressUse.WORK);
+        address.setState("Québec");
+        address.addLine("4 boulevard de l'université");
+        pat.addAddress(address);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat1 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        Address address1 = new Address();
+        address1.setUse(AddressUse.PRIMARY_HOME);
+        pat1.addAddress(address1);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat2 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        Address address2 = new Address();
+        address2.setUse(AddressUse.TEMPORARY);
+        pat2.addAddress(address2);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat3 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        Address address3 = new Address();
+        address3.setUse(AddressUse.BAD);
+        pat3.addAddress(address3);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat4 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        Address address4 = new Address();
+        address4.setUse(AddressUse.BILLING);
+        pat4.addAddress(address4);
+
+        try {
+            Patient response = BusinessToFhirConverter.patientToFhirPatient(pat);
+            org.hl7.fhir.r4.model.Address responseAddress = response.getAddress().get(0);
+            assertEquals("Chicoutimi", responseAddress.getCity());
+            assertEquals("Canada", responseAddress.getCountry());
+            assertEquals("G7B 0H3", responseAddress.getPostalCode());
+            assertEquals("Québec", responseAddress.getState());
+            assertEquals("4 boulevard de l'université", responseAddress.getLine().get(0).getValue());
+            assertEquals(org.hl7.fhir.r4.model.Address.AddressUse.WORK, responseAddress.getUse());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat1);
+            responseAddress = response.getAddress().get(0);
+            assertEquals(org.hl7.fhir.r4.model.Address.AddressUse.HOME, responseAddress.getUse());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat2);
+            responseAddress = response.getAddress().get(0);
+            assertEquals(org.hl7.fhir.r4.model.Address.AddressUse.TEMP, responseAddress.getUse());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat3);
+            responseAddress = response.getAddress().get(0);
+            assertEquals(org.hl7.fhir.r4.model.Address.AddressUse.OLD, responseAddress.getUse());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat4);
+            responseAddress = response.getAddress().get(0);
+            assertEquals(org.hl7.fhir.r4.model.Address.AddressUse.BILLING, responseAddress.getUse());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just an address");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("Gender conversion")
+    void TestPatientTelecomConversion(){
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp = new ContactPoint();
+        cp.setType(ContactPointType.BEEPER);
+        cp.setValue("Hello");
+        cp.setUse(ContactPointUse.WORK);
+        pat.addContactPoint(cp);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat1 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp1 = new ContactPoint();
+        cp1.setType(ContactPointType.PHONE);
+        cp1.setValue("Hello");
+        cp1.setUse(ContactPointUse.MOBILE);
+        pat1.addContactPoint(cp1);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat2 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp2 = new ContactPoint();
+        cp2.setType(ContactPointType.FAX);
+        cp2.setValue("Hello");
+        cp2.setUse(ContactPointUse.TEMPORARY);
+        pat2.addContactPoint(cp2);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat3 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp3 = new ContactPoint();
+        cp3.setType(ContactPointType.URL);
+        cp3.setValue("Hello");
+        cp3.setUse(ContactPointUse.HOME);
+        pat3.addContactPoint(cp3);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat4 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp4 = new ContactPoint();
+        cp4.setType(ContactPointType.EMAIL);
+        cp4.setValue("Hello");
+        cp4.setUse(ContactPointUse.PRIMARY_HOME);
+        pat4.addContactPoint(cp4);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat5 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp5 = new ContactPoint();
+        cp5.setType(ContactPointType.SMS);
+        cp5.setValue("Hello");
+        cp5.setUse(ContactPointUse.PRIMARY_HOME);
+        pat5.addContactPoint(cp5);
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat6 = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+        ContactPoint cp6 = new ContactPoint();
+        cp6.setType(ContactPointType.OTHER);
+        cp6.setValue("Hello");
+        cp6.setUse(ContactPointUse.PRIMARY_HOME);
+        pat6.addContactPoint(cp6);
+
+        try {
+            Patient response = BusinessToFhirConverter.patientToFhirPatient(pat);
+            assertEquals("Hello", response.getTelecom().get(0).getValue());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.WORK, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.PAGER, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat1);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.MOBILE, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.PHONE, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat2);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.TEMP, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.FAX, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat3);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.HOME, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.URL, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat4);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.HOME, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.EMAIL, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat5);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.HOME, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.SMS, response.getTelecom().get(0).getSystem());
+
+            response = BusinessToFhirConverter.patientToFhirPatient(pat6);
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointUse.HOME, response.getTelecom().get(0).getUse());
+            assertEquals(org.hl7.fhir.r4.model.ContactPoint.ContactPointSystem.OTHER, response.getTelecom().get(0).getSystem());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a Telecom");
+        }
+
+    }
+
+    @Test
+    @Description("Test on unitary conversion")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("CrossReference conversion")
+    void TestPatientCrossReferenceConversion(){
+
+        net.ihe.gazelle.app.patientregistryapi.business.Patient pat = new net.ihe.gazelle.app.patientregistryapi.business.Patient();
+
+        EntityIdentifier id = new EntityIdentifier();
+        id.setSystemIdentifier("Hello_Vincent");
+        id.setValue("69420");
+        pat.addIdentifier(id);
+
+        try {
+            Patient response = BusinessToFhirConverter.patientToFhirPatient(pat);
+            assertEquals("urn:oid:Hello_Vincent", response.getIdentifier().get(0).getSystem());
+            assertEquals("69420", response.getIdentifier().get(0).getValue());
+
+        } catch (ConversionException e) {
+            fail("could not convert Patient with just a gender");
+        }
+
+    }
+
+}
diff --git a/src/test/java/net/ihe/gazelle/application/PatientFeedClientMock.java b/src/test/java/net/ihe/gazelle/application/PatientFeedClientMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..4f8c525a53c6f4ed2bb98bfa367cfce3016b86c1
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/application/PatientFeedClientMock.java
@@ -0,0 +1,28 @@
+package net.ihe.gazelle.application;
+
+import com.gitb.ps.ProcessingService;
+
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryfeedclient.adapter.PatientFeedClient;
+
+public class PatientFeedClientMock extends PatientFeedClient{
+
+	public PatientFeedClientMock(ProcessingService processingService) {
+		super(processingService);
+	}
+
+	@Override
+	public String createPatient(Patient patient) {
+
+		return null;
+
+	}
+
+	@Override
+	public boolean deletePatient(String uuid) {
+
+		return false;
+
+	}
+
+}
diff --git a/src/test/java/net/ihe/gazelle/application/PatientFeedClientTest.java b/src/test/java/net/ihe/gazelle/application/PatientFeedClientTest.java
new file mode 100644
index 0000000000000000000000000000000000000000..6467fe8ab21502f6e68a32c307244f0f4ad0287b
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/application/PatientFeedClientTest.java
@@ -0,0 +1,568 @@
+package net.ihe.gazelle.application;
+
+import static org.junit.jupiter.api.Assertions.*;
+import static org.mockito.Matchers.anyObject;
+
+import java.net.MalformedURLException;
+import java.time.LocalDate;
+import java.time.ZoneId;
+import java.util.Date;
+
+import javax.xml.ws.WebServiceException;
+
+import ca.uhn.fhir.rest.server.exceptions.*;
+import org.hl7.fhir.r4.model.Bundle;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import io.qameta.allure.Description;
+import io.qameta.allure.Feature;
+import io.qameta.allure.Severity;
+import io.qameta.allure.SeverityLevel;
+import io.qameta.allure.Story;
+import net.ihe.gazelle.app.patientregistryapi.application.PatientFeedException;
+import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
+import net.ihe.gazelle.app.patientregistryapi.business.GenderCode;
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryapi.business.PersonName;
+import net.ihe.gazelle.app.patientregistryfeedclient.adapter.PatientFeedClient;
+import net.ihe.gazelle.app.patientregistryfeedclient.adapter.PatientFeedProcessResponseException;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.NamespaceException;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.PreferenceException;
+
+@Feature("PatientFeedClient")
+public class PatientFeedClientTest {
+
+	private static final String TEST_UUID = "123e4567-e89b-12d3-a456-426614174000";
+	private static final String MALFORMED_UUID = "123e4567-e89b-12d3-a456-42661417400000000000000000000000000";
+
+	@Mock
+	static private PatientFeedClient patientFeedClientMock;
+	@Mock
+	static private OperationalPreferencesService operationalPreferencesService;
+	@Mock
+	private PatientRegistryFeedClient patientRegistryFeedClient;
+
+	@BeforeAll
+	static void initialize() {
+		patientFeedClientMock = Mockito.mock(PatientFeedClient.class);
+		operationalPreferencesService = Mockito.mock(OperationalPreferencesService.class);
+	}
+
+	@Test
+	@Description("Test on initialization, when a namespace exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	void TestInitializeNameSpaceException() throws PreferenceException, NamespaceException {
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient(operationalPreferencesService);
+
+		Mockito.doThrow(NamespaceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+
+		Patient patient = new Patient();
+
+		assertThrows(PatientFeedException.class,
+				() -> patientRegistryFeedClient.createPatient(patient));
+	}
+
+	@Test
+	@Description("Test on initialization, when a preference exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	void TestInitializePreferenceException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(PreferenceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistryFeedClient = new PatientRegistryFeedClient(operationalPreferencesService);
+
+		Patient patient = new Patient();
+
+		assertThrows(PatientFeedException.class,
+				() -> patientRegistryFeedClient.updatePatient(patient,""));
+	}
+
+	@Test
+	@Description("Test on initialization, when the url of the server is malformed")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	void TestInitializeMalformedURLException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(MalformedURLException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistryFeedClient = new PatientRegistryFeedClient(operationalPreferencesService);
+
+		Patient patient = new Patient();
+
+		assertThrows(PatientFeedException.class,
+				() -> patientRegistryFeedClient.delete(""));
+	}
+
+	@Test
+	@Description("Test on initialization, when a web service exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	void TestInitializeWebServiceException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(WebServiceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistryFeedClient = new PatientRegistryFeedClient(operationalPreferencesService);
+
+		Patient patient = new Patient();
+
+		assertThrows(PatientFeedException.class,
+				() -> patientRegistryFeedClient.mergePatient("",""));
+	}
+
+	@Test
+	@Description("Test on create, nominal case")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestNominalCreation() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn(TEST_UUID).when(patientFeedClientMock).createPatient(anyObject());
+		assertEquals(TEST_UUID, patientRegistryFeedClient.createPatient(patient).getEntry().get(0).getResource().getId());
+	}
+
+	@Test
+	@Description("Test on create, null Patient")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestNullPatientException() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = null;
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.createPatient(patient));
+		try {
+			patientRegistryFeedClient.createPatient(patient);
+		} catch (InvalidRequestException e) {
+			assertEquals(PatientRegistryFeedClient.NO_PATIENT_PARAMETER, e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on create, when a blank uuid is returned")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestBlankUuidReturnedException() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn("").when(patientFeedClientMock).createPatient(anyObject());
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.createPatient(patient));
+		try {
+			patientRegistryFeedClient.createPatient(patient);
+		} catch (InternalErrorException e) {
+			assertEquals(PatientRegistryFeedClient.NO_UUID, e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on create, when a Malformed UUID is returned")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestMalformedUuidReturnedException() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn(MALFORMED_UUID).when(patientFeedClientMock).createPatient(anyObject());
+		try {
+			assertEquals(MALFORMED_UUID, patientRegistryFeedClient.createPatient(patient).getEntry().get(0).getResource().getId());
+		} catch (Exception e) {
+			 fail();
+		}
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestFeedThrowsPatientFeedCannotCrossRef() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("Impossible to cross reference the patient (not saved)");
+		PatientFeedException firstException = new PatientFeedException(embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).createPatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.createPatient(patient));
+		try {
+			patientRegistryFeedClient.createPatient(patient);
+		} catch (InternalErrorException e) {
+			assertEquals("Impossible to cross reference the patient, it will not be saved !", e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestFeedThrowsPatientFeedPersistingPatient() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("Unexpected Exception persisting Patient !");
+		PatientFeedException firstException = new PatientFeedException(embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).createPatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.createPatient(patient));
+		try {
+			patientRegistryFeedClient.createPatient(patient);
+		} catch (InternalErrorException e) {
+			assertEquals("Unexpected Exception persisting Patient !", e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("create")
+	void TestFeedThrowsPatientFeedExceptionSystemNotFound() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("name","name",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("System not found");
+		PatientFeedException firstException = new PatientFeedException("Exception while Mapping with GITB elements !", embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).createPatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.createPatient(patient));
+		try {
+			patientRegistryFeedClient.createPatient(patient);
+		} catch (InternalErrorException e) {
+			assertEquals("Exception while Mapping with GITB elements !", e.getMessage());
+		}
+	}
+
+
+
+
+
+
+	@Test
+	@Description("Test on update, exception thrown when no Patient is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("update")
+	void TestFeedUpdateNullPatient() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		String uuid = TEST_UUID;
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.updatePatient(null, uuid));
+
+	}
+
+
+	@Test
+	@Description("Test on update, exception thrown from PatReg")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("update")
+	void TestFeedUpdatePatientFeedInvalidOperationThrown() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		String uuid = TEST_UUID;
+		Patient patient = createPatient("","",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedException embedException = new PatientFeedException("Invalid operation used on distant PatientFeedProcessingService !");
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(embedException).when(patientFeedClientMock).updatePatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.updatePatient(patient, uuid));
+		try {
+			patientRegistryFeedClient.updatePatient(patient, uuid);
+		}
+		catch (InternalErrorException e) {
+			assertEquals("Invalid operation used on distant PatientFeedProcessingService !", e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on update, exception thrown from PatReg")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("update")
+	void TestFeedUpdatePatientInvalidRequest() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		String uuid = TEST_UUID;
+		Patient patient = createPatient("","",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedException embedException = new PatientFeedException("Invalid Request sent to distant PatientFeedProcessingService !");
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(embedException).when(patientFeedClientMock).updatePatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.updatePatient(patient, uuid));
+		try {
+			patientRegistryFeedClient.updatePatient(patient, uuid);
+		}
+		catch (InternalErrorException e) {
+			assertEquals("Invalid Request sent to distant PatientFeedProcessingService !", e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on update, exception thrown from PatReg")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("update")
+	void TestFeedUpdatePatientUnhandled() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		String uuid = TEST_UUID;
+		Patient patient = createPatient("","",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		PatientFeedException embedException = new PatientFeedException("");
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(embedException).when(patientFeedClientMock).updatePatient(anyObject());
+
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.updatePatient(patient, uuid));
+		try {
+			patientRegistryFeedClient.updatePatient(patient, uuid);
+		}
+		catch (InternalErrorException e) {
+			assertEquals("An unhandled error was thrown.", e.getMessage());
+		}
+	}
+
+	@Test
+	@Description("Test on update, exception thrown when no Uuid is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("update")
+	void TestFeedUpdateNullUuid() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		Patient patient = createPatient("","",LocalDate.of(1990, 06, 19), GenderCode.MALE);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.updatePatient(patient, null));
+
+	}
+
+	@Test
+	@Description("Test on merge, when feeding basic request")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("merge")
+	void TestFeedMergeNominalCase() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		EntityIdentifier identifier1 = new EntityIdentifier();
+		EntityIdentifier identifier2 = new EntityIdentifier();
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn(TEST_UUID).when(patientFeedClientMock).mergePatient(anyObject(), anyObject());
+		//TODO change expected value when feature will be done
+		assertEquals(TEST_UUID, patientRegistryFeedClient.mergePatient("identifier1", "identifier2").getId());
+
+	}
+
+	@Test
+	@Description("Test on merge, exception thrown when no Patient is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("merge")
+	void TestFeedMergeNullPatient() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		EntityIdentifier identifier2 = new EntityIdentifier();
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.mergePatient(null, null));
+
+	}
+
+	@Test
+	@Description("Test on merge, exception thrown when no Uuid is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("merge")
+	void TestFeedMergeNullUuid() {
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.mergePatient(null, null));
+
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDelete() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn(true).when(patientFeedClientMock).deletePatient(TEST_UUID);
+
+		try {
+			Bundle response = patientRegistryFeedClient.delete(TEST_UUID);
+			assertEquals(TEST_UUID, response.getEntry().get(0).getResource().getId());
+		} catch (InternalErrorException e) {
+			fail("Deletion should not have thrown an error");
+		}
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDeleteBlankUUID() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		assertThrows(InvalidRequestException.class, () -> patientRegistryFeedClient.delete(""));
+
+		try {
+			patientRegistryFeedClient.delete("");
+		} catch (InvalidRequestException e) {
+			assertEquals("Invalid parameter", e.getMessage());
+		} catch (Exception e) {
+			fail("Test failed, the expected result has not happend");
+		}
+	}
+
+	@Test
+	@Description("Test on create, for particular exceptions returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDeleteStatusGone() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doReturn(false).when(patientFeedClientMock).deletePatient(TEST_UUID);
+		assertThrows(ResourceGoneException.class, () -> patientRegistryFeedClient.delete(TEST_UUID));
+
+		try {
+			patientRegistryFeedClient.delete(TEST_UUID);
+		} catch (ResourceGoneException e) {
+			assertEquals("Patient with UUID " + TEST_UUID, e.getMessage());
+		} catch (Exception e) {
+			fail("Test failed, the expected result has not happend");
+		}
+	}
+
+	@Test
+	@Description("Test on delete, for a particular exception returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDeleteNoUuid() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("The uuid cannot be null or empty");
+		PatientFeedException firstException = new PatientFeedException(embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).deletePatient(TEST_UUID);
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.delete(TEST_UUID));
+
+		try {
+			patientRegistryFeedClient.delete(TEST_UUID);
+		} catch (InternalErrorException e) {
+			assertEquals("The uuid cannot be null or empty", e.getMessage());
+		} catch (Exception e) {
+			fail("Test failed, the expected result has not happend");
+		}
+	}
+
+	@Test
+	@Description("Test on delete, for a particular exception returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDeleteDeleteCannotOperate() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("Cannot proceed to delete");
+		PatientFeedException firstException = new PatientFeedException(embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).deletePatient(TEST_UUID);
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.delete(TEST_UUID));
+
+		try {
+			patientRegistryFeedClient.delete(TEST_UUID);
+		} catch (InternalErrorException e) {
+			assertEquals("Cannot proceed to delete", e.getMessage());
+		} catch (Exception e) {
+			fail("Test failed, the expected result has not happend");
+		}
+	}
+
+	@Test
+	@Description("Test on delete, for a particular exception returned from PatientFeedApplication")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("delete")
+	void TestFeedDeleteDeleteInvalidResponse() throws PreferenceException, NamespaceException, PatientFeedException {
+
+		PatientFeedProcessResponseException embedException = new PatientFeedProcessResponseException("other error");
+		PatientFeedException firstException = new PatientFeedException("Invalid Response from distant PatientFeedProcessingService !", embedException);
+
+		patientRegistryFeedClient = new PatientRegistryFeedClient();
+		patientRegistryFeedClient.setClient(patientFeedClientMock);
+
+		Mockito.doThrow(firstException).when(patientFeedClientMock).deletePatient(TEST_UUID);
+		assertThrows(InternalErrorException.class, () -> patientRegistryFeedClient.delete(TEST_UUID));
+
+		try {
+			patientRegistryFeedClient.delete(TEST_UUID);
+		} catch (InternalErrorException e) {
+			assertEquals("Invalid Response from distant PatientFeedProcessingService !", e.getMessage());
+		} catch (Exception e) {
+			fail("Test failed, the expected result has not happend");
+		}
+	}
+
+	private Patient createPatient(String familyName, String givenName, LocalDate birthDate, GenderCode gender) {
+
+		Patient patient = new Patient();
+
+		PersonName name = new PersonName();
+		name.addGiven(givenName);
+		name.setFamily(familyName);
+		patient.addName(name);
+		patient.setDateOfBirth(Date.from(birthDate.atStartOfDay(ZoneId.systemDefault()).toInstant()));
+		patient.setGender(gender);
+		return patient;
+
+	}
+
+}
diff --git a/src/test/java/net/ihe/gazelle/application/PatientRegistrySearchClientTest.java b/src/test/java/net/ihe/gazelle/application/PatientRegistrySearchClientTest.java
new file mode 100644
index 0000000000000000000000000000000000000000..899534e4ebb45818e0b584917b32b26f4397c6fc
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/application/PatientRegistrySearchClientTest.java
@@ -0,0 +1,321 @@
+package net.ihe.gazelle.application;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.mockito.Matchers.anyObject;
+import static org.mockito.Mockito.doAnswer;
+
+import java.net.MalformedURLException;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.ws.WebServiceException;
+
+import net.ihe.gazelle.adapter.connector.BusinessToFhirConverter;
+import net.ihe.gazelle.adapter.connector.ConversionException;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+import org.mockito.runners.MockitoJUnitRunner;
+
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
+import io.qameta.allure.Description;
+import io.qameta.allure.Feature;
+import io.qameta.allure.Severity;
+import io.qameta.allure.SeverityLevel;
+import io.qameta.allure.Story;
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryapi.business.PatientSearchCriterionKey;
+import net.ihe.gazelle.app.patientregistryapi.business.PersonName;
+import net.ihe.gazelle.app.patientregistrysearchclient.adapter.PatientSearchClient;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.NamespaceException;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.PreferenceException;
+import net.ihe.gazelle.lib.searchmodelapi.business.SearchCriteria;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import net.ihe.gazelle.lib.searchmodelapi.business.searchcriterion.SearchCriterion;
+import net.ihe.gazelle.lib.searchmodelapi.business.searchcriterion.StringSearchCriterion;
+
+
+@Feature("PatientSearchClientTest")
+@RunWith(MockitoJUnitRunner.class)
+public class PatientRegistrySearchClientTest {
+
+	private static final String TEST_UUID = "123e4567-e89b-12d3-a456-426614174000";
+	private static final String MALFORMED_UUID = "123e4567-e89b-12d3-a456-42661417400000000000000000000000000";
+
+	@Mock
+	static private PatientSearchClient patientSearchClientMock;
+	@Mock
+	static private OperationalPreferencesService operationalPreferencesService;
+	@Mock
+	private PatientRegistrySearchClient patientRegistrySearchClient;
+
+	@BeforeAll
+	static void initialize() {
+		patientSearchClientMock = Mockito.mock(PatientSearchClient.class);
+		operationalPreferencesService = Mockito.mock(OperationalPreferencesService.class);
+	}
+
+	@Test
+	@Description("Test on initialization, when a namespace exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	public void TestInitializeNameSpaceException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(NamespaceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistrySearchClient = new PatientRegistrySearchClient(operationalPreferencesService);
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		assertThrows(SearchException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on initialization, when a preference exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	public void TestInitializePreferenceException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(PreferenceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistrySearchClient = new PatientRegistrySearchClient(operationalPreferencesService);
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		assertThrows(SearchException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on initialization, when the url of the server is malformed")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	public void TestInitializeMalformedURLException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(MalformedURLException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistrySearchClient = new PatientRegistrySearchClient(operationalPreferencesService);
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		assertThrows(SearchException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on initialization, when a web service exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("initialization")
+	public void TestInitializeWebServiceException() throws PreferenceException, NamespaceException {
+		Mockito.doThrow(WebServiceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
+				"/operational" +
+				"-preferences", "patientregistry.url");
+		patientRegistrySearchClient = new PatientRegistrySearchClient(operationalPreferencesService);
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		assertThrows(SearchException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on read, a specific excpetion is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestSearchExceptionMapping() throws SearchException {
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		SearchException exception = new SearchException("Exception while Mapping with GITB elements !");
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		Mockito.doThrow(exception).when(patientSearchClientMock).search(anyObject());
+		assertThrows(InternalErrorException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on read, a specific excpetion is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestSearchExceptionInvalidResponse() throws SearchException {
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		SearchException exception = new SearchException("Invalid Response from distant PatientFeedProcessingService !");
+		Mockito.doThrow(exception).when(patientSearchClientMock).search(anyObject());
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(ResourceNotFoundException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on read, a specific exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestSearchExceptionInvalidOperation() throws SearchException {
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		SearchException exception = new SearchException("Invalid operation used on distant PatientFeedProcessingService !");
+		Mockito.doThrow(exception).when(patientSearchClientMock).search(anyObject());
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(InvalidRequestException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on read, a specific exception is thrown")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestSearchExceptionInvalidRequest() throws SearchException {
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		SearchException exception = new SearchException("Invalid Request sent to distant PatientFeedProcessingService !");
+		Mockito.doThrow(exception).when(patientSearchClientMock).search(anyObject());
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(InvalidRequestException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+	}
+
+	@Test
+	@Description("Test on read, when no patient is returned")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestNoPatientReturned() throws SearchException {
+
+		List <Patient> resources = new ArrayList<>();
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		doAnswer(invocation -> resources).when(patientSearchClientMock).search(anyObject());
+
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(ResourceNotFoundException.class,
+				() -> patientRegistrySearchClient.searchPatient(searchCriterion.getValue()));
+
+
+	}
+
+	@Test
+	@Description("Test on read, when exactly one patient is returned")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestOnePatientReturned() throws SearchException {
+
+		org.hl7.fhir.r4.model.Patient arthur = new org.hl7.fhir.r4.model.Patient();
+		arthur.addName().addGiven("Arthur");
+
+		List <Patient> resources = new ArrayList<>();
+		Patient pat = new Patient();
+		PersonName ps = new PersonName();
+		ps.addGiven("Arthur");
+		pat.addName(ps);
+		resources.add(pat);
+
+		SearchCriteria searchCriteria = new SearchCriteria();
+		SearchCriterion<String> searchCriterion = new StringSearchCriterion(PatientSearchCriterionKey.UUID);
+		searchCriterion.setValue(TEST_UUID);
+		searchCriteria.addSearchCriterion(searchCriterion);
+
+		doAnswer(invocation -> resources).when(patientSearchClientMock).search(anyObject());
+
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertEquals(arthur.getName().get(0).getGiven().toString(), patientRegistrySearchClient.searchPatient(searchCriterion.getValue()).getName().get(0).getGiven().toString());
+
+	}
+
+	@Test
+	@Description("Test on read, when more than one patient is returned")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestManyPatientsReturned() throws SearchException {
+
+		List <Patient> resources = new ArrayList<>();
+		resources.add(new Patient());
+		resources.add(new Patient());
+
+
+		doAnswer(invocation -> resources).when(patientSearchClientMock).search(anyObject());
+
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(ResourceNotFoundException.class,
+				() -> patientRegistrySearchClient.searchPatient(TEST_UUID));
+
+
+	}
+
+	//@Test
+	@Description("Test on read, when a conversion exception happens")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestConversionException() throws SearchException {
+
+		List <Patient> resources = new ArrayList<>();
+		resources.add(new Patient());
+		resources.add(new Patient());
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+		assertThrows(ResourceNotFoundException.class,
+				() -> patientRegistrySearchClient.searchPatient(TEST_UUID));
+
+
+	}
+
+
+	@Test
+	@Description("Test on read, when parameter is null")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("read")
+	public void TestNoEntry() throws SearchException {
+
+		patientRegistrySearchClient = new PatientRegistrySearchClient();
+		patientRegistrySearchClient.setClient(patientSearchClientMock);
+
+		assertThrows(InvalidRequestException.class,
+				() -> patientRegistrySearchClient.searchPatient(null));
+
+
+	}
+}
diff --git a/src/test/java/net/ihe/gazelle/application/PatientRegistryXRefSearchClientTest.java b/src/test/java/net/ihe/gazelle/application/PatientRegistryXRefSearchClientTest.java
index fa8fa612c0ef0c97a3b8cecc0478257128da906d..7b804ffc743d251d891dfdf41a0624f570a8fe18 100644
--- a/src/test/java/net/ihe/gazelle/application/PatientRegistryXRefSearchClientTest.java
+++ b/src/test/java/net/ihe/gazelle/application/PatientRegistryXRefSearchClientTest.java
@@ -4,6 +4,10 @@ import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
 import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
 import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
 import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
+import io.qameta.allure.Description;
+import io.qameta.allure.Severity;
+import io.qameta.allure.SeverityLevel;
+import io.qameta.allure.Story;
 import net.ihe.gazelle.app.patientregistryapi.application.SearchCrossReferenceException;
 import net.ihe.gazelle.app.patientregistryapi.business.EntityIdentifier;
 import net.ihe.gazelle.app.patientregistryapi.business.Patient;
@@ -46,6 +50,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on initialization, when a namespace exception is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("initialization")
     void TestInitializeNameSpaceException() throws PreferenceException, NamespaceException {
         Mockito.doThrow(NamespaceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
                 "/operational" +
@@ -61,6 +68,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on initialization, when a preference exception is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("initialization")
     void TestInitializePreferenceException() throws PreferenceException, NamespaceException {
         Mockito.doThrow(PreferenceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
                 "/operational" +
@@ -76,6 +86,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on initialization, when a malformed url exception is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("initialization")
     void TestInitializeMalformedURLException() throws PreferenceException, NamespaceException {
         Mockito.doThrow(MalformedURLException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
                 "/operational" +
@@ -91,6 +104,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on initialization, when a web service exception is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("initialization")
     void TestInitializeWebServiceException() throws PreferenceException, NamespaceException {
         Mockito.doThrow(WebServiceException.class).when(operationalPreferencesService).getStringValue("java:/app/gazelle/pixm-connector" +
                 "/operational" +
@@ -107,7 +123,10 @@ class PatientRegistryXRefSearchClientTest {
 
 
     @Test
-    void TestSearchCrossException() throws SearchCrossReferenceException {
+    @Description("Test on ihe_pix, a specific excpetion is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
+    void TestSearchCrossExceptionInvalidRequest() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
         sourceIdentifier.setValue("1");
@@ -121,7 +140,10 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
-    void TestSearchCrossException2() throws SearchCrossReferenceException {
+    @Description("Test on ihe_pix, a specific excpetion is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
+    void TestSearchCrossExceptionResourceNotFound() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
         sourceIdentifier.setValue("1");
@@ -135,7 +157,10 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
-    void TestSearchCrossException3() throws SearchCrossReferenceException {
+    @Description("Test on ihe_pix, a specific excpetion is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
+    void TestSearchCrossExceptionForbiddenOperation() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
         sourceIdentifier.setValue("1");
@@ -149,7 +174,10 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
-    void TestSearchCrossException4() throws SearchCrossReferenceException {
+    @Description("Test on ihe_pix, a specific excpetion is thrown")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
+    void TestSearchCrossExceptionInternalError() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
         sourceIdentifier.setValue("1");
@@ -163,6 +191,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on ihe_pix, when no Patient is returned")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
     void TestSearchCrossNoMember() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
@@ -178,6 +209,9 @@ class PatientRegistryXRefSearchClientTest {
 
 
     @Test
+    @Description("Test on ihe_pix, when one Patient is returned")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
     void TestSearchCross1Member() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
@@ -203,6 +237,9 @@ class PatientRegistryXRefSearchClientTest {
     }
 
     @Test
+    @Description("Test on ihe_pix, when one target domain was given as parameter")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
     void TestSearchNotargetDomain() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
         sourceIdentifier.setSystemIdentifier("Test1");
@@ -227,6 +264,9 @@ class PatientRegistryXRefSearchClientTest {
         Assert.assertEquals(1, parameters.getParameter().size());
     }
 
+    @Description("Test on ihe_pix, when two target domain was given as parameter")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix")
     @Test
     void TestSearchfullTargetDomain() throws SearchCrossReferenceException {
         EntityIdentifier sourceIdentifier = new EntityIdentifier();
diff --git a/src/test/java/net/ihe/gazelle/application/SearchClientMock.java b/src/test/java/net/ihe/gazelle/application/SearchClientMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..dd88d6a0a11765dcb06ac44745b270e4e5892000
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/application/SearchClientMock.java
@@ -0,0 +1,34 @@
+package net.ihe.gazelle.application;
+
+import java.util.List;
+
+import com.gitb.ps.ProcessingService;
+
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryapi.business.PatientAliases;
+import net.ihe.gazelle.app.patientregistrysearchclient.adapter.PatientSearchClient;
+import net.ihe.gazelle.lib.searchmodelapi.business.SearchCriteria;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import net.ihe.gazelle.lib.searchmodelapi.business.searchcriterion.SearchCriterion;
+
+public class SearchClientMock extends PatientSearchClient {
+
+	public SearchClientMock(ProcessingService processingService) {
+		super(processingService);
+	}
+
+	@Override
+	public List<Patient> search(SearchCriteria searchCriteria) throws SearchException {
+		PatientAliases patientAliases = new PatientAliases();
+		for (SearchCriterion criterion : searchCriteria.getSearchCriterions()) {
+			switch (criterion.toString()) {
+			case "":
+				return null;
+			default:
+				return null;
+			}
+		}
+		return null;
+	}
+
+}
diff --git a/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderMock.java b/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..fdebe3b2467bea201b0bfb6954f4d7ac7ec0720f
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderMock.java
@@ -0,0 +1,40 @@
+package net.ihe.gazelle.business.provider;
+
+
+import ca.uhn.fhir.context.FhirContext;
+import org.hl7.fhir.r4.model.Bundle;
+import org.json.simple.JSONArray;
+import org.json.simple.JSONObject;
+import org.json.simple.parser.JSONParser;
+import org.json.simple.parser.ParseException;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.FileReader;
+import java.io.IOException;
+
+public class CHBundleProviderMock  {
+
+    public final static String ID_TO_RETURN= "OK";
+    public final static String PATH_TO_RESOURCE="src/test/ResourcesToTestPurpose/";
+
+
+
+    protected Bundle returnBundleFromResource(String nameOfFile){
+        try{
+
+            if ("null.json".equals(nameOfFile)){
+                return null;
+            }
+            Bundle bundleResquest = (Bundle) FhirContext.forR4().newJsonParser().parseResource(new FileReader(PATH_TO_RESOURCE+nameOfFile));
+            return bundleResquest;
+        } catch (FileNotFoundException e) {
+            e.printStackTrace();
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+        return null;
+    }
+
+
+}// end class
\ No newline at end of file
diff --git a/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderTest.java b/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderTest.java
new file mode 100644
index 0000000000000000000000000000000000000000..a1cb969388cd7228d007ec1f279ebcc0d45372a3
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/business/provider/CHBundleProviderTest.java
@@ -0,0 +1,164 @@
+package net.ihe.gazelle.business.provider;
+
+import ca.uhn.fhir.rest.api.MethodOutcome;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import io.qameta.allure.*;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import org.hl7.fhir.r4.model.IdType;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+
+@Feature("CHBundleProvider Test")
+class CHBundleProviderTest {
+
+    @BeforeAll
+    static void initialized() {
+
+    }
+
+    private static PatientRegistryFeedClient feedClientMock = new PatientRegistryFeedClientMock();
+
+    private static final CHBundleProvider bundle_feed_provider = new CHBundleProvider(new CHPatientProviderMock(feedClientMock));
+    public static final String GOOD_UUID = "123e4567-e89b-12d3-a456-426614174000";
+    public static final String Throw_two_id = "LOLILO";
+    public static final String Throw_ID = "MDR";
+
+    CHBundleProviderMock cbpm = new CHBundleProviderMock();
+
+
+    @Test
+    @Description("Test on the Create Method for pixm-connector")
+    void testCreatePatient() {
+        String fileName = "post_request.json";
+        MethodOutcome mo = bundle_feed_provider.create(cbpm.returnBundleFromResource(fileName));
+        assertEquals(cbpm.ID_TO_RETURN,mo.getId().getValue());
+    }
+
+    @Test
+    @Description("Test on the Create Method for pixm-connector with a null Bundle")
+    void testCreateNullBundle() {
+        String fileName = "null.json";
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.create(cbpm.returnBundleFromResource(fileName)),"Bundle is null or Empty");
+    }
+
+    @Test
+    @Description("Test on the Create Method with a Bundle with No Patient inside")
+    void testCreateNoPatientInBundle() {
+        String fileName = "post_request_NO_PATIENT.json";
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.create(cbpm.returnBundleFromResource(fileName)),"Missing Patient in Bundle");
+    }
+
+    @Test
+    @Description("Test on the Create Method with a Bundle with 3 entries")
+    void testCreatePatientBundleWith1Entry() {
+        String fileName = "post_request_1_entry.json";
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.create(cbpm.returnBundleFromResource(fileName)));
+    }
+
+    @Test
+    @Description("Test on the delete operation, clean delete without issue")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("delete operation")
+    void testDeletePatient() {
+        String fileName = "post_request.json";
+        IdType id = new IdType(GOOD_UUID);
+        MethodOutcome mo = bundle_feed_provider.delete(id, cbpm.returnBundleFromResource(fileName));
+        assertEquals(cbpm.ID_TO_RETURN,mo.getId().getValue());
+    }
+
+    @Test
+    @Description("Test on the delete operation, deleting a Patient but with a null bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("delete operation")
+    void testDeletePatientNullBundle() {
+        String fileName = "null.json";
+        IdType id = new IdType(GOOD_UUID);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.delete(id, cbpm.returnBundleFromResource(fileName)),"Bundle is null or Empty");
+    }
+
+    @Test
+    @Description("Test on the delete operation, deleting a Patient but there is no Patient in the bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("delete operation")
+    void testDeletePatientBlank() {
+        String fileName = "post_request_NO_PATIENT.json";
+        IdType id = new IdType(GOOD_UUID);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.delete(id, cbpm.returnBundleFromResource(fileName)),"Bundle Could not be converted to HL7 Patient");
+    }
+
+    @Test
+    @Description("Test on the delete operation, deleting a Patient but with a null bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("delete operation")
+    void testDeleteBlankId() {
+        String fileName = "post_request.json";
+        IdType id = new IdType("");
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.delete(id, cbpm.returnBundleFromResource(fileName)),"Bundle is null or Empty");
+    }
+
+    @Test
+    @Description("Test on the update operation, clean update without issue")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdatePatient() {
+        String fileName = "post_request.json";
+        IdType id = new IdType(GOOD_UUID);
+        MethodOutcome mo = bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName));
+        assertEquals(cbpm.ID_TO_RETURN,mo.getId().getValue());
+    }
+
+    @Test
+    @Description("Test on the update operation, updating a Patient but with a null bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdatePatientNullBundle() {
+        String fileName = "null.json";
+        IdType id = new IdType(GOOD_UUID);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName)),"Bundle is null or Empty");
+    }
+
+    @Test
+    @Description("Test on the update operation, updating a Patient but there is no Patient in the bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdatePatientBlank() {
+        String fileName = "post_request_NO_PATIENT.json";
+        IdType id = new IdType(GOOD_UUID);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName)),"bizu");
+    }
+
+    @Test
+    @Description("Test on the update operation, updating a Patient but there is no Patient in the bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdateEmptyId() {
+        String fileName = "post_request_NO_PATIENT.json";
+        IdType id = new IdType("");
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName)),"Invalid ID Parameter, either null or empty.");
+    }
+
+    @Test
+    @Description("Test on the update operation, updating a Patient but there is no Patient in the bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdateInvalidRequest() {
+        String fileName = "post_request_NO_PATIENT.json";
+        IdType id = new IdType(Throw_ID);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName)),"Invalid ID Parameter, either null or empty.");
+    }
+
+    @Test
+    @Description("Test on the update operation, updating a Patient but there is no Patient in the bundle")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("update operation")
+    void testUpdateInternalError() {
+        String fileName = "post_request_NO_PATIENT.json";
+        IdType id = new IdType(Throw_two_id);
+        assertThrows(InvalidRequestException.class, ()-> bundle_feed_provider.updatePatient(id, cbpm.returnBundleFromResource(fileName)),"Invalid ID Parameter, either null or empty.");
+    }
+
+
+}
\ No newline at end of file
diff --git a/src/test/java/net/ihe/gazelle/business/provider/CHPatientProviderMock.java b/src/test/java/net/ihe/gazelle/business/provider/CHPatientProviderMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..e4ced8757c4ac70c400ffdd662de2c64b84a2225
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/business/provider/CHPatientProviderMock.java
@@ -0,0 +1,71 @@
+package net.ihe.gazelle.business.provider;
+
+import ca.uhn.fhir.rest.annotation.IdParam;
+import ca.uhn.fhir.rest.annotation.ResourceParam;
+import ca.uhn.fhir.rest.api.MethodOutcome;
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import org.hl7.fhir.instance.model.api.IIdType;
+import org.hl7.fhir.r4.model.IdType;
+import org.hl7.fhir.r4.model.Patient;
+
+public class CHPatientProviderMock extends ChPatientResourceProvider {
+
+
+    public CHPatientProviderMock(PatientRegistryFeedClient patientRegistryFeedClient) {
+        super(patientRegistryFeedClient);
+
+    }
+
+    @Override
+    public MethodOutcome create(@ResourceParam Patient iti93Patient) {
+        MethodOutcome mo = new MethodOutcome();
+        IIdType iIdType = new IdType();
+
+        //Case OK
+        if (iti93Patient.getId().equals("Patient/PatientPIXmFeed")) {
+            return mo.setId(iIdType.setValue("OK"));
+        }
+        //Case KO
+        if (iti93Patient.getId().equals("Bundle/PatientPIXmFeed")) {
+            return null;
+        }
+        //Case NULL
+        if (iti93Patient == null) {
+            return null;
+        }
+        return null;
+    }
+
+    @Override
+    public MethodOutcome delete(@ResourceParam IdType id) {
+        MethodOutcome mo = new MethodOutcome();
+        IdType iIdType = new IdType();
+
+        //Case OK
+        if (id.equals(CHBundleProviderTest.GOOD_UUID)) {
+            return mo.setId(iIdType.setValue("OK"));
+        }
+
+        return null;
+    }
+
+    @Override
+    public MethodOutcome update(@IdParam IdType theId, @ResourceParam Patient hl7Patient) {
+        MethodOutcome mo = new MethodOutcome();
+        IdType iIdType = new IdType();
+
+        //Case OK
+
+        if (theId.equals(CHBundleProviderTest.GOOD_UUID)) {
+            return mo.setId(iIdType.setValue("OK"));
+        } else if (theId.equals(CHBundleProviderTest.Throw_ID)) {
+            throw new InvalidRequestException("");
+        } else if (theId.equals(CHBundleProviderTest.Throw_two_id)) {
+            throw new InternalErrorException("");
+        }
+
+        return null;
+    }
+}
diff --git a/src/test/java/net/ihe/gazelle/business/provider/ChPatientResourceProviderTest.java b/src/test/java/net/ihe/gazelle/business/provider/ChPatientResourceProviderTest.java
index b7f67b8e3cd812cb64c0ea2c32913c61b4e99a57..9ff5dee8d3f822f0fb30e3b1a1c7c76f8ce7aa44 100644
--- a/src/test/java/net/ihe/gazelle/business/provider/ChPatientResourceProviderTest.java
+++ b/src/test/java/net/ihe/gazelle/business/provider/ChPatientResourceProviderTest.java
@@ -1,40 +1,50 @@
 package net.ihe.gazelle.business.provider;
 
-import static org.junit.jupiter.api.Assertions.assertEquals;
-
+import ca.uhn.fhir.rest.api.MethodOutcome;
+import ca.uhn.fhir.rest.param.*;
 import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
 import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
-import org.hl7.fhir.r4.model.Identifier;
-import org.hl7.fhir.r4.model.Parameters;
+import io.qameta.allure.*;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import net.ihe.gazelle.application.PatientRegistrySearchClient;
+import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
+import org.hl7.fhir.r4.model.*;
 import org.hl7.fhir.r4.model.Parameters.ParametersParameterComponent;
 import org.junit.jupiter.api.BeforeAll;
 import org.junit.jupiter.api.Test;
 
-import ca.uhn.fhir.rest.param.StringAndListParam;
-import ca.uhn.fhir.rest.param.StringOrListParam;
-import ca.uhn.fhir.rest.param.StringParam;
-import ca.uhn.fhir.rest.param.TokenParam;
-import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
-import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
+import static org.junit.jupiter.api.Assertions.*;
 
+@Feature("ChaPatientProvider")
 class ChPatientResourceProviderTest {
 	private static PatientRegistryXRefSearchClient xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
+	private static PatientRegistrySearchClient searchClientMock = new PatientRegistrySearchClientMock();
+	private static PatientRegistryFeedClient feedClientMock = new PatientRegistryFeedClientMock();
 	private static final ChPatientResourceProvider provider = new ChPatientResourceProvider(xRefSearchClientMock);
+	private static final ChPatientResourceProvider read_provider = new ChPatientResourceProvider(searchClientMock);
+	private static final ChPatientResourceProvider feed_provider = new ChPatientResourceProvider(feedClientMock);
 
 	@BeforeAll
-	static void initialized(){
+	static void initialized() {
 		xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when aiming for a patient on 1 target System, with unr:oid: type system identifiers")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testOkPatient() {
-		TokenParam sourceId = new TokenParam("urn:oid:1","69420");
+		TokenParam sourceId = new TokenParam("urn:oid:1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("urn:oid:2"));
 		targetDomains.addAnd(stringParam);
 
-		Parameters response = provider.findPatientsByIdentifier(sourceId, targetDomains);
+		Parameters response = provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
 		ParametersParameterComponent singleResponse = response.getParameter().get(0);
 		Identifier r4 = (Identifier) singleResponse.getValue();
 		assertEquals(PatientRegistryXRefSearchClientMock.URN_OK, r4.getValue());
@@ -43,31 +53,41 @@ class ChPatientResourceProviderTest {
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when aiming for a patient on 1 target System, with http system identifiers")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testOkPatientHttp() {
-		TokenParam sourceId = new TokenParam("http://1","69420");
+		TokenParam sourceId = new TokenParam("http://1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
-		Parameters response = provider.findPatientsByIdentifier(sourceId, targetDomains); 
+		Parameters response = provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
 		ParametersParameterComponent singleResponse = response.getParameter().get(0);
 		Identifier r4 = (Identifier) singleResponse.getValue();
 		assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getValue());
 		assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getSystem());
 
 	}
-	
+
 	@Test
+	@Description("Test on ihe_pix operation, when aiming for a patient on 2 target System")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testOkPatientTwoTargetSystem() {
-		TokenParam sourceId = new TokenParam("http://1","69420");
+		TokenParam sourceId = new TokenParam("http://1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		stringParam.add(new StringParam("http://3"));
 		targetDomains.addAnd(stringParam);
 
-		Parameters response = provider.findPatientsByIdentifier(sourceId, targetDomains); 
+		Parameters response = provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
 		ParametersParameterComponent singleResponse = response.getParameter().get(0);
 		Identifier r4 = (Identifier) singleResponse.getValue();
 		assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getValue());
@@ -76,126 +96,159 @@ class ChPatientResourceProviderTest {
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when the patient source identifiers is null")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testSourceIdentifierNull() {
 		TokenParam sourceId = new TokenParam();
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (InvalidRequestException e) {
 			assertEquals(ChPatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
 		}
 
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when the patient system identifiers is null")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testSourceIdentifierSystemNull() {
 		TokenParam sourceId = new TokenParam();
 		sourceId.setValue("69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (InvalidRequestException e) {
 			assertEquals(ChPatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
 		}
 
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when the patient source identifiers is null")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testSourceIdentifierValueNull() {
 		TokenParam sourceId = new TokenParam();
 		sourceId.setSystem("http://1");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (InvalidRequestException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (InvalidRequestException e) {
 			assertEquals(ChPatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
 		}
 
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when the patient system identifiers is blank")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testSourceIdentifierSystemBlank() {
-		TokenParam sourceId = new TokenParam("","69420");
+		TokenParam sourceId = new TokenParam("", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (InvalidRequestException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (InvalidRequestException e) {
 			assertEquals(ChPatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
 		}
 
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when the patient system identifier hasn't been recognized")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testMalformedSystemIdentifier() {
-		TokenParam sourceId = new TokenParam("1:2:3","69420");
+		TokenParam sourceId = new TokenParam("1:2:3", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (ResourceNotFoundException e) {
 			assertEquals(ChPatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
 		}
 
 	}
 
 	@Test
+	@Description("Test on ihe_pix operation, when target identifiers is blank")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testTargetIdentifierBlank() {
-		TokenParam sourceId = new TokenParam("http::/1","69420");
+		TokenParam sourceId = new TokenParam("http::/1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam(""));
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ForbiddenOperationException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (ForbiddenOperationException e) {
 			assertEquals(ChPatientResourceProvider.TARGET_SYSTEM_NOT_FOUND, e.getMessage());
 		}
 	}
-	
+
 	@Test
+	@Description("Test on ihe_pix operation, when no target identifiers is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testTargetIdentifierNull() {
-		TokenParam sourceId = new TokenParam("http::/1","69420");
+		TokenParam sourceId = new TokenParam("http::/1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ForbiddenOperationException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (ForbiddenOperationException e) {
 			assertEquals(ChPatientResourceProvider.TARGET_SYSTEM_NOT_FOUND, e.getMessage());
 		}
 	}
-	
+
 	@Test
+	@Description("Test on ihe_pix operation, when target identifiers don't have valid cardinality")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ihe_pix operation")
 	void testTargetIdentifierMoreThanTwo() {
-		TokenParam sourceId = new TokenParam("http::/1","69420");
+		TokenParam sourceId = new TokenParam("http::/1", "69420");
+		TokenAndListParam tokenAndListParam = new TokenAndListParam();
+		tokenAndListParam.addAnd(sourceId);
 		StringAndListParam targetDomains = new StringAndListParam();
 		StringOrListParam stringParam = new StringOrListParam();
 		stringParam.add(new StringParam("http://2"));
@@ -204,11 +257,168 @@ class ChPatientResourceProviderTest {
 		targetDomains.addAnd(stringParam);
 
 		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ForbiddenOperationException e) {
+			provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+		} catch (ForbiddenOperationException e) {
 			assertEquals(ChPatientResourceProvider.TARGET_SYSTEM_NOT_FOUND, e.getMessage());
 		}
+	}	
+
+	@Test
+	@Description("Test on read method, but resource is not found")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ReadMethod")
+	void testReadResourceNotFound() {
+		IdType id = new IdType();
+		id.setValue("1");
+		assertThrows(InternalErrorException.class,
+				() -> read_provider.read(id));
+	}
+
+
+
+	@Test
+	@Description("Test on read method, but no parameter is given")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ReadMethod")
+	void testReadNoIdGiven() {
+		IdType id = new IdType();
+		id.setValue("");
+		try {
+			read_provider.read(id);
+		} catch (InvalidRequestException e) {
+			assertEquals(ChPatientResourceProvider.NO_ID_PROVIDED, e.getMessage());
+		} catch (Exception e) {
+			fail();
+		}
+	}
+
+	@Test
+	@Description("Test on read method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("ReadMethod")
+	void testReadFine() {
+		IdType id = new IdType();
+		id.setValue("3");
+		assertEquals("[Arthur]", read_provider.read(id).getName().get(0).getGiven().toString());
+	}
+
+	@Test
+	@Description("Test on Update method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("UpdateMethod")
+	void testUpdateFine() {
+		IdType id = new IdType();
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("Plop");
+		id.setValue("3");
+		Bundle returnedValue = (Bundle) feed_provider.update(id, iti93Bundle).getResource();
+		assertEquals("Plop", returnedValue.getEntry().get(0).getResource().getId());
+	}
+
+	@Test
+	@Description("Test on Update method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("UpdateMethod")
+	void testUpdateUuidBlank() {
+		IdType id = new IdType();
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("Plop");
+		id.setValue("");
+		assertThrows(InvalidRequestException.class, () -> feed_provider.update(id, iti93Bundle));
+	}
+
+	@Test
+	@Description("Test on Update method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("UpdateMethod")
+	void testUpdatePatientBlank() {
+		IdType id = new IdType();
+		Patient iti93Bundle = new Patient();
+		id.setValue("3");
+		assertThrows(InvalidRequestException.class, () -> feed_provider.update(id, iti93Bundle));
+	}
+
+	@Test
+	@Description("Test on Update method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("UpdateMethod")
+	void testUpdatePatientFeedThrown() {
+		IdType id = new IdType();
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("Plop");
+		id.setValue("42");
+		assertThrows(InternalErrorException.class, () -> feed_provider.update(id, iti93Bundle));
+	}
+
+	@Test
+	@Description("Test on Create method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("CreateMethod")
+	void testCreateFine() {
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("PatientPixMFeed");
+		Bundle returnedValue = (Bundle) feed_provider.create(iti93Bundle).getResource();
+		assertEquals("1", returnedValue.getId());
+	}
+
+	@Test
+	@Description("Test on Create method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("CreateMethod")
+	void testCreatePatientBlank() {
+		assertThrows(InvalidRequestException.class, () -> feed_provider.create(null));
+	}
+
+	@Test
+	@Description("Test on Create method, returns nothing")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("CreateMethod")
+	void testCreatePatientNPE() {
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("Plop");
+		assertThrows(ResourceNotFoundException.class, () -> feed_provider.create(iti93Bundle));
+	}
+
+	@Test
+	@Description("Test on Create method, returns nothing")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("CreateMethod")
+	void testCreatePatientFeedThrown() {
+		Patient iti93Bundle = new Patient();
+		iti93Bundle.setId("throw_me_something");
+		assertThrows(InternalErrorException.class, () -> feed_provider.create(iti93Bundle));
+	}
+
+	@Test
+	@Description("Test on Delete method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("DeleteMethod")
+	void testDeleteFine() {
+		IdType theId = new IdType();
+		theId.setValue("PatientPixMFeed");
+		Bundle returnedValue = (Bundle) feed_provider.delete(theId).getResource();
+		assertEquals("PatientPixMFeed", returnedValue.getId());
+	}
+
+	@Test
+	@Description("Test on Delete method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("DeleteMethod")
+	void testDeleteUuidEmpty() {
+		IdType theId = new IdType();
+		theId.setValue("");
+		assertThrows(InvalidRequestException.class, () -> feed_provider.delete(theId));
+	}
+
+
+	@Test
+	@Description("Test on Delete method, returns ok")
+	@Severity(SeverityLevel.CRITICAL)
+	@Story("DeleteMethod")
+	void testDeletePatientFeedThrown() {
+		IdType theId = new IdType();
+		theId.setValue("42");
+		assertThrows(InternalErrorException.class, () -> feed_provider.delete(theId));
 	}
 
 }
\ No newline at end of file
diff --git a/src/test/java/net/ihe/gazelle/business/provider/IhePatientResourceProviderTest.java b/src/test/java/net/ihe/gazelle/business/provider/IhePatientResourceProviderTest.java
index 08d33ab8a815a7dcc4526300433cbc05e84d9353..ad50c476835497a30ef77f824ea950147747154f 100644
--- a/src/test/java/net/ihe/gazelle/business/provider/IhePatientResourceProviderTest.java
+++ b/src/test/java/net/ihe/gazelle/business/provider/IhePatientResourceProviderTest.java
@@ -1,165 +1,242 @@
 package net.ihe.gazelle.business.provider;
 
-import static org.junit.jupiter.api.Assertions.assertEquals;
-
+import ca.uhn.fhir.rest.param.*;
 import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
+import ca.uhn.fhir.rest.server.exceptions.InternalErrorException;
+import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
 import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException;
+import io.qameta.allure.Description;
+import io.qameta.allure.Severity;
+import io.qameta.allure.SeverityLevel;
+import io.qameta.allure.Story;
+import net.ihe.gazelle.app.patientregistryapi.application.SearchCrossReferenceException;
+import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
 import org.hl7.fhir.r4.model.Identifier;
 import org.hl7.fhir.r4.model.Parameters;
 import org.hl7.fhir.r4.model.Parameters.ParametersParameterComponent;
 import org.junit.jupiter.api.BeforeAll;
 import org.junit.jupiter.api.Test;
 
-import ca.uhn.fhir.rest.param.StringAndListParam;
-import ca.uhn.fhir.rest.param.StringOrListParam;
-import ca.uhn.fhir.rest.param.StringParam;
-import ca.uhn.fhir.rest.param.TokenParam;
-import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException;
-import net.ihe.gazelle.application.PatientRegistryXRefSearchClient;
+import static org.junit.jupiter.api.Assertions.assertEquals;
 
+@Story("IHE Patient Provider")
 class IhePatientResourceProviderTest {
-	private static PatientRegistryXRefSearchClient xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
-	private static final IhePatientResourceProvider provider = new IhePatientResourceProvider(xRefSearchClientMock);
-
-	@BeforeAll
-	static void initialized(){
-		xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
-	}
-
-	@Test
-	void testOkPatient() {
-		TokenParam sourceId = new TokenParam("urn:oid:1","69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("urn:oid:2"));
-		targetDomains.addAnd(stringParam);
-
-		Parameters response = provider.findPatientsByIdentifier(sourceId, targetDomains);
-		ParametersParameterComponent singleResponse = response.getParameter().get(0);
-		Identifier r4 = (Identifier) singleResponse.getValue();
-		assertEquals(PatientRegistryXRefSearchClientMock.URN_OK, r4.getValue());
-		assertEquals(PatientRegistryXRefSearchClientMock.URN_OK, r4.getSystem());
-
-	}
-
-	@Test
-	void testOkPatientHttp() {
-		TokenParam sourceId = new TokenParam("http://1","69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		Parameters response = provider.findPatientsByIdentifier(sourceId, targetDomains); 
-		ParametersParameterComponent singleResponse = response.getParameter().get(0);
-		Identifier r4 = (Identifier) singleResponse.getValue();
-		assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getValue());
-		assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getSystem());
-
-	}
-
-	@Test
-	void testSourceIdentifierNull() {
-		TokenParam sourceId = new TokenParam();
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
-			assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
-		}
-
-	}
-
-	@Test
-	void testSourceIdentifierSystemNull() {
-		TokenParam sourceId = new TokenParam();
-		sourceId.setValue("69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
-			assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
-		}
-
-	}
-
-	@Test
-	void testSourceIdentifierValueNull() {
-		TokenParam sourceId = new TokenParam();
-		sourceId.setSystem("http://1");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (InvalidRequestException e) {
-			assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
-		}
-
-	}
-
-	@Test
-	void testSourceIdentifierSystemBlank() {
-		TokenParam sourceId = new TokenParam("","69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (InvalidRequestException e) {
-			assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
-		}
-
-	}
-
-	@Test
-	void testMalformedSystemIdentifier() {
-		TokenParam sourceId = new TokenParam("1:2:3","69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam("http://2"));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ResourceNotFoundException e) {
-			assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
-		}
-
-	}
-
-	@Test
-	void testTargetIdentifierBlank() {
-		TokenParam sourceId = new TokenParam("http::/1","69420");
-		StringAndListParam targetDomains = new StringAndListParam();
-		StringOrListParam stringParam = new StringOrListParam();
-		stringParam.add(new StringParam(""));
-		targetDomains.addAnd(stringParam);
-
-		try {
-			provider.findPatientsByIdentifier(sourceId, targetDomains);
-		}
-		catch (ForbiddenOperationException e) {
-			assertEquals(IhePatientResourceProvider.TARGET_SYSTEM_NOT_FOUND, e.getMessage());
-		}
-
-	}
+    private static PatientRegistryXRefSearchClient xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
+    private static final IhePatientResourceProvider provider = new IhePatientResourceProvider(xRefSearchClientMock);
+
+    @BeforeAll
+    static void initialized() {
+        xRefSearchClientMock = new PatientRegistryXRefSearchClientMock();
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when aiming for a patient on 1 target System, with urn:oid: type system identifiers")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testOkPatient() {
+        TokenParam sourceId = new TokenParam("urn:oid:1", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("urn:oid:2"));
+        targetDomains.addAnd(stringParam);
+
+        Parameters response = provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        ParametersParameterComponent singleResponse = response.getParameter().get(0);
+        Identifier r4 = (Identifier) singleResponse.getValue();
+        assertEquals(PatientRegistryXRefSearchClientMock.URN_OK, r4.getValue());
+        assertEquals(PatientRegistryXRefSearchClientMock.URN_OK, r4.getSystem());
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when aiming for a patient on 1 target System, with http system identifiers")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testOkPatientHttp() {
+        TokenParam sourceId = new TokenParam("http://1", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        Parameters response = provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        ParametersParameterComponent singleResponse = response.getParameter().get(0);
+        Identifier r4 = (Identifier) singleResponse.getValue();
+        assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getValue());
+        assertEquals(PatientRegistryXRefSearchClientMock.HTTP_OK, r4.getSystem());
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the whole patient source identifier is null")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testSourceIdentifierNull() {
+        TokenParam sourceId = new TokenParam();
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (InvalidRequestException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the patient system identifiers is null")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testSourceIdentifierSystemNull() {
+        TokenParam sourceId = new TokenParam();
+        sourceId.setValue("69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (InvalidRequestException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the patient source identifiers is null")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testSourceIdentifierValueNull() {
+        TokenParam sourceId = new TokenParam();
+        sourceId.setSystem("http://1");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (InvalidRequestException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the patient system identifiers is blank")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testSourceIdentifierSystemBlank() {
+        TokenParam sourceId = new TokenParam("", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (InvalidRequestException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_ASSIGNING_AUTHORITY_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the target system is malformed and not recognized")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testMalformedSystemIdentifier() {
+        TokenParam sourceId = new TokenParam("1:2:3", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("http://2"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (ResourceNotFoundException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the target system is blank")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testTargetIdentifierBlank() {
+        TokenParam sourceId = new TokenParam("http::/1", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam(""));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (ForbiddenOperationException e) {
+            assertEquals(IhePatientResourceProvider.TARGET_SYSTEM_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the target system is blank")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testSourceIdentifierBlank() {
+        TokenParam sourceId = new TokenParam("http::/1", "69420");
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam(""));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(null, targetDomains);
+        } catch (InvalidRequestException e) {
+            assertEquals(IhePatientResourceProvider.SOURCE_IDENTIFIER_PATIENT_IDENTIFIER_NOT_FOUND, e.getMessage());
+        }
+
+    }
+
+    @Test
+    @Description("Test on ihe_pix operation, when the target system is blank")
+    @Severity(SeverityLevel.CRITICAL)
+    @Story("ihe_pix operation")
+    void testCrossRefException() {
+        TokenParam sourceId = new TokenParam("urn:oid:3", "69420");
+        TokenAndListParam tokenAndListParam = new TokenAndListParam();
+        tokenAndListParam.addAnd(sourceId);
+        StringAndListParam targetDomains = new StringAndListParam();
+        StringOrListParam stringParam = new StringOrListParam();
+        stringParam.add(new StringParam("urn:oid:3"));
+        targetDomains.addAnd(stringParam);
+
+        try {
+            provider.findPatientsByIdentifier(tokenAndListParam, targetDomains);
+        } catch (InternalErrorException e) {
+            assertEquals("net.ihe.gazelle.business.provider.PatientResourceProviderException: One of the target domain does not exist", e.getMessage());
+        }
+
+    }
 
 }
\ No newline at end of file
diff --git a/src/test/java/net/ihe/gazelle/business/provider/PatientRegistryFeedClientMock.java b/src/test/java/net/ihe/gazelle/business/provider/PatientRegistryFeedClientMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..669f20dc15cc95c96e7c9f1a026398e8e13ca475
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/business/provider/PatientRegistryFeedClientMock.java
@@ -0,0 +1,77 @@
+package net.ihe.gazelle.business.provider;
+
+import net.ihe.gazelle.adapter.connector.BusinessToFhirConverter;
+import net.ihe.gazelle.adapter.connector.ConversionException;
+import net.ihe.gazelle.app.patientregistryapi.application.PatientFeedException;
+import net.ihe.gazelle.app.patientregistryapi.business.Patient;
+import net.ihe.gazelle.app.patientregistryfeedclient.adapter.PatientFeedClient;
+import net.ihe.gazelle.application.PatientRegistryFeedClient;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+import org.hl7.fhir.r4.model.Bundle;
+
+public class PatientRegistryFeedClientMock extends PatientRegistryFeedClient {
+
+	public static final String HTTP_OK = "HTTP_OK";
+	public static final String URN_OK = "URN_OK";
+	private static final String CROSS_REFERENCE = "Cross Reference";
+
+	public PatientRegistryFeedClientMock() {
+	}
+
+	public PatientRegistryFeedClientMock(OperationalPreferencesService operationalPreferencesService) {
+		super(operationalPreferencesService);
+	}
+
+	public PatientRegistryFeedClientMock(PatientFeedClient searchClient) {
+		this.setClient(searchClient);
+	}
+
+	@Override
+	public Bundle createPatient(net.ihe.gazelle.app.patientregistryapi.business.Patient patient) throws PatientFeedException {
+
+		String uuid = patient.getUuid();
+		Bundle bundle = new Bundle();
+		bundle.setId("1");
+
+		switch (uuid){
+			case "PatientPixMFeed":
+				return bundle;
+			case "throw_me_something":
+				throw new PatientFeedException();
+			default:
+				return null;
+		}
+	}
+
+	@Override
+	public Bundle updatePatient(net.ihe.gazelle.app.patientregistryapi.business.Patient patientToUpdate, String uuid) throws PatientFeedException {
+		if (uuid.equals("42")) {
+			throw new PatientFeedException();
+		}
+		Bundle response = new Bundle();
+		Bundle.BundleEntryComponent component = new Bundle.BundleEntryComponent();
+		try {
+			component.setResource(BusinessToFhirConverter.patientToFhirPatient(patientToUpdate));
+		}
+		catch (ConversionException e) {
+			throw new PatientFeedException(e);
+		}
+		response.addEntry(component);
+		return response;
+	}
+
+	@Override
+	public Bundle delete(String uuid) throws PatientFeedException{
+
+		if (uuid.equals("42")) {
+			throw new PatientFeedException();
+		}
+
+		Bundle response = new Bundle();
+		response.setId(uuid);
+
+		return response;
+	}
+
+}
diff --git a/src/test/java/net/ihe/gazelle/business/provider/PatientRegistrySearchClientMock.java b/src/test/java/net/ihe/gazelle/business/provider/PatientRegistrySearchClientMock.java
new file mode 100644
index 0000000000000000000000000000000000000000..67d932c59aa9cde2179c92769f76e77ef7c78aba
--- /dev/null
+++ b/src/test/java/net/ihe/gazelle/business/provider/PatientRegistrySearchClientMock.java
@@ -0,0 +1,43 @@
+package net.ihe.gazelle.business.provider;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.hl7.fhir.r4.model.Patient;
+
+import net.ihe.gazelle.app.patientregistrysearchclient.adapter.PatientSearchClient;
+import net.ihe.gazelle.application.PatientRegistrySearchClient;
+import net.ihe.gazelle.framework.preferencesmodelapi.application.OperationalPreferencesService;
+import net.ihe.gazelle.lib.searchmodelapi.business.exception.SearchException;
+
+public class PatientRegistrySearchClientMock extends PatientRegistrySearchClient {
+	public static final String HTTP_OK = "HTTP_OK";
+	public static final String URN_OK = "URN_OK";
+	private static final String CROSS_REFERENCE = "Cross Reference";
+
+	public PatientRegistrySearchClientMock() {
+	}
+
+	public PatientRegistrySearchClientMock(OperationalPreferencesService operationalPreferencesService) {
+		super(operationalPreferencesService);
+	}
+
+	public PatientRegistrySearchClientMock(PatientSearchClient searchClient) {
+		setClient(searchClient);
+	}
+	@Override
+	public Patient searchPatient(String uuid) throws SearchException {
+
+		Patient arthur = new Patient();
+		arthur.addName().addGiven("Arthur");
+
+		switch (uuid){
+		case "1":
+			throw new SearchException("test exception");
+		case "3":
+			return arthur;
+		default:
+			return null;
+		}
+	}
+}
diff --git a/src/test/java/net/ihe/gazelle/provider/ProviderTestClass.java b/src/test/java/net/ihe/gazelle/provider/ProviderTestClass.java
deleted file mode 100644
index 58b81c885913ccc3828556b8f014adc90f26a433..0000000000000000000000000000000000000000
--- a/src/test/java/net/ihe/gazelle/provider/ProviderTestClass.java
+++ /dev/null
@@ -1,50 +0,0 @@
-package net.ihe.gazelle.provider;
-
-import ca.uhn.fhir.rest.param.StringAndListParam;
-import ca.uhn.fhir.rest.param.StringOrListParam;
-import ca.uhn.fhir.rest.param.StringParam;
-import ca.uhn.fhir.rest.param.TokenParam;
-import ca.uhn.fhir.rest.server.exceptions.ForbiddenOperationException;
-import net.ihe.gazelle.business.provider.IhePatientResourceProvider;
-import org.junit.Assert;
-import org.junit.jupiter.api.Test;
-
-public class ProviderTestClass {
-
-    public static final IhePatientResourceProvider provider = new IhePatientResourceProvider();
-
-//	@Test
-//	public void createPatientTest() {
-//		Patient pat = new Patient();
-//		MethodOutcome ret = provider.createPatient(pat);
-//		Assert.assertNotNull(ret);
-//	}
-
-
-    //	@Test
-//	public void findPatientsByNameTest() {
-//		StringType param = new StringType("WALTERS");
-//		Assert.assertNotNull(provider.findPatientsByName(param));
-//	}
-//
-    @Test
-    public void findPatientsByIdentifierTest() {
-        TokenParam sourceIdentifier = new TokenParam();
-        sourceIdentifier.setSystem("urn:oid:1.3.6.1.4.1.21367.13.20.3000");
-        sourceIdentifier.setValue("IHEBLUE-998");
-
-        StringAndListParam bigParam = new StringAndListParam();
-        StringOrListParam param = new StringOrListParam();
-        StringParam smallParam = new StringParam("1.3.6.1.4.1.21367.13.20.2000");
-        param.add(smallParam);
-        bigParam.addValue(param);
-
-        try {
-            Assert.assertNotNull(provider.findPatientsByIdentifier(sourceIdentifier, bigParam));
-        } catch (ForbiddenOperationException e) {
-            System.out.println(e);
-        }
-    }
-
-
-}