URL: /openempi-ws-rest/1.0/record-links
Parameters
Parameter | Value Type | Parameter Type | R/O | Description |
|---|---|---|---|---|
entityId | Integer | Query Parameter | R | The unique identifier of the entity type whose records are queried |
| firstResult | Integer | Query Parameter | O | The number of records to skip before the first result record |
| maxResults | Integer | Query Parameter | O | The maximum number of records that should be returned |
| linkState | String {M, A, P} | Query Parameter | O | Used to indicate that only links of a given state must be returned. The state can be one of M for match, A for all states (starting with the 3.5.7 release), or P for probable match |
| keyVal | String | Query Parameter | O | When present, it will cause the server to only return record links where both records in the link have the value specified in the value portion of the keyVal parameter in the field specified in the key portion of the keyVal parameter. The keyVal parameter takes the same form as in the findByAttributes request but you can only filter by a single field value. The keyVla parameter should look like keyVal=field,value. For example, adding the parameter keyVal=familyName,Chandler will only return record pairs where both records in each pair have the value 'Chandler' for the field 'familyName' (starting with version 3.5.9 and 3.6.3). |
Methods
GET
Returns the list of record links between records of the specified entity type and that match the query criteria specified in the additional parameters. If you don’t provide the linkState parameter then the system will return only match links. Starting with the 3.5.7 release, you can use the value ‘A’ for the linkState parameter to indicate that you want links of all states to be returned.
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
404 - Returned if there are no record links in the system that match the query criteria
Example
Version 1.0
Entity id is 7650.
http://localhost:8080/openempi-admin/openempi-ws-rest/1.0/record-links?entityId=7650
Return:
URL: /openempi-ws-rest/1.0/record-links/{recordLinkId}
Parameters
| Parameter
|
Value Type
|
Parameter Type
|
R/O
|
Description
| | --- | --- | --- | --- | --- | |
recordLinkId
|
Integer
|
Path Parameter
| R |
The unique identifier of the record link requested
|
Methods
GET
Returns the record link .
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
404 - Returned if there is no record link in the system with that identifier
Example
Version 1.0
Entity id is 7650.
Record link id is 1
http://localhost:8080/openempi-admin/openempi-ws-rest/1.0/record-links/1?entityId=7650
Return:
URL: /openempi-ws-rest/1.0/record-links/loadByRecordId
Parameters
Parameter | Value Type | Parameter Type | R/O | Description |
|---|---|---|---|---|
entityId | Integer | Query Parameter | R | The unique identifier of the entity type whose records are queried |
recordId | Integer | Query Parameter | R | The unique identifier of the record to which links are requested |
| linkState | String {M, A, P} | Query Parameter | O | Used to indicate that only links of a given state must be returned. The state can be one of M for match, A for all states (starting with the 3.5.7 release), or P for probable match |
Methods
GET
Returns the list of record links that are associated with the record identified by the recordId unique identifier. If you don’t provide the linkState parameter then the system will return only match links. Starting with the 3.5.7 release, you can use the value ‘A’ for the linkState parameter to indicate that you want links of all states to be returned.
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
404 - Returned if there are no record links in the system with that identifier
Example
Version 1.0
Entity id is 7650.
Record id is 4
Return:
URL(POST for add): /openempi-ws-rest/1.0/record-links
Parameters
| Parameter
|
Value Type
|
Parameter Type
|
R/O
|
Description
| | --- | --- | --- | --- | --- | | recordLink | RecordLink | Body | R | A RecordLink object which include the entity id, match status, weight, left record and right record |
Methods
POST
Returns the newly added recordLink.
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
400 - Returned if there is a bad request.
-
409 - Returned if there is a record conflict in the system.
Example
Version 1.0
Left Record is Record 20.
Right Record is Record 24.
POST
http://localhost:8080/openempi-admin/openempi-ws-rest/1.0/record-links
Content-Type: application/xml
Body:
Return:
Content-Type: application/json
Body:
{ “entityId” : “7650”, “leftRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordRight” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:39.307-04:00”, “identifier” : “identifierRight”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “26” }, “recordId” : “24” }, “rightRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordLeft” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:38.270-04:00”, “identifier” : “identifierLeft”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “25” }, “recordId” : “20” }, “state” : “M”, “weight” : “6.5” }
Return:
{ “entityId” : “7650”, “leftRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordRight” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:39.307-04:00”, “identifier” : “identifierRight”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “26” }, “recordId” : “24” }, “recordLinkId” : “115”, “rightRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordLeft” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:38.270-04:00”, “identifier” : “identifierLeft”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “25” }, “recordId” : “20” }, “state” : “M”, “weight” : “6.5” }
URL(PUT for updating match status): /openempi-ws-rest/1.0/record-links
Parameters
| Parameter
|
Value Type
|
Parameter Type
|
R/O
|
Description
| | --- | --- | --- | --- | --- | | recordLink | RecordLink | Body | R | A RecordLink object which include the entity id, match status, weight, left record and right record |
Methods
PUT
Returns the updated recordLink.
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
404 - Returned if there are no that record link in the system
-
409 - Returned if there is a record conflict in the system.
Example
Version 1.0
Update state as “P”
PUT
http://localhost:8080/openempi-admin/openempi-ws-rest/1.0/record-links
Content-Type: application/xml
Body:
Return:
Content-Type: application/json
Body:
{ “entityId” : “7650”, “leftRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordRight” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:39.307-04:00”, “identifier” : “identifierRight”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “26” }, “recordId” : “24” }, “recordLinkId” : “115”, “rightRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordLeft” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:38.270-04:00”, “identifier” : “identifierLeft”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “25” }, “recordId” : “20” }, “state” : “P”, “weight” : “6.5” }
Return:
{ “entityId” : “7650”, “leftRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordLeft” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:38.270-04:00”, “identifier” : “identifierLeft”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “25” }, “recordId” : “20” }, “recordLinkId” : “115”, “rightRecord” : { “entityId” : “7650”, “field” : [ { “name” : “givenName”, “value” : “recordRight” }, { “name” : “familyName”, “value” : “Test” } ], “identifier” : { “dateCreated” : “2013-10-04T12:04:39.307-04:00”, “identifier” : “identifierRight”, “identifierDomain” : { “dateCreated” : “2013-01-17T11:33:45.903-05:00”, “identifierDomainDescription” : “IHERED”, “identifierDomainId” : “2750”, “identifierDomainName” : “IHERED”, “namespaceIdentifier” : “IHERED”, “universalIdentifier” : “1.3.6.1.4.1.21367.13.20.1000”, “universalIdentifierTypeCode” : “ISO” }, “identifierDomainId” : “2750”, “identifierId” : “26” }, “recordId” : “24” }, “state” : “P”, “weight” : “6.5” }
URL(DELETE for remove): /openempi-ws-rest/1.0/record-links
Delete the recordLink in the database.
Parameters
| Parameter
|
Value Type
|
Parameter Type
|
R/O
|
Description
| | --- | --- | --- | --- | --- | |
entityId
|
Integer
|
Query Parameter
| R |
The unique identifier of the entity type whose records are queried
| | recordLinkId | Long | Path Parameter | R | The unique identifier of the recordLink |
Methods
DELETE
Returns no content if delete successfully.
Responses
-
200 - application/json - Returns a JSON representation of the response based on the Accept header
-
200 - application/xml - Returns an XML representation of the response based on the Accept header
-
404 - Returned if cannot find the record link to be deleted by recordLinkId
-
409 - Returned if there is some conflict in the system
Example
Version 1.0
Entity id is 7650.
Record id is 115
http://localhost:8080/openempi-admin/openempi-ws-rest/1.0/record-links/115?entityId=7650
Return:
No content if delete successfully