Business 360 REST API Reference > Business 360 REST API > Merge API
  

Merge API

Use the merge API to merge up to 10 source records or master records into a single master record. The API uses the entity-group resource.
To merge records, submit a POST request with the following URI:
<baseApiUrl>/business-entity/public/api/v1/entity-group/<businessEntity>
The businessEntity parameter is the internal ID of the business entity to which the records belong.
The response is in the JSON format.

Request body

To merge records, you can either use a combination of the sourcePKey and sourceSystem parameters or the businessId parameter in the request body.
Note: To ensure that the merge operation is successful, add up to 10 records in the request body.
To merge records, you can use the following parameters in the request body:
Parameter
Type
Description
sourcePKey
String
The primary key of the source record. Use it with the sourceSystem parameter.
sourceSystem
String
Internal ID of the source system to which the record belongs. Use it with the sourcePKey parameter.
businessId
String
Unique identifier of the record to merge.

Request response

The request response returns the business ID of the merged master record.
The following table lists the response parameters:
Parameter
Type
Description
approvalRequired
Boolean
Indicates whether approval workflow is configured. If the response is true, approval workflow is configured. If the response is false, approval workflow isn't configured.
businessId
String
Unique identifier of the merged master record.

Sample Request

You might use the following request to merge the source records of the Person business entity into a single master record:
POST https://use4-mdm.dm-us.informaticacloud.com/business-entity/public/api/v1/entity-group/c360.person
Content-Type: application/json
Accept: application/json
IDS-SESSION-ID: XXXXXXXXXXXXXXXXXXXXXX

[
{
"sourcePKey": "KR_001",
"sourceSystem": "sales_force"
},
{
"sourcePKey": "KR_002",
"sourceSystem": "sales_force"
},
{
"sourcePKey": "KR_003",
"sourceSystem": "sales_force"
}
{
"businessId": "P8X4AB78YU2WE2"
}
]

Sample Response

When you make a merge request, the response returns the business ID of the master record into which all the records are merged.
The following merge response contains the business ID of the master record into which multiple records merged:
HTTP/1.1 200 OK
Content-Type: application/json
{
"approvalRequired": false,
"businessId": "999000000000268"
}