POST api/Contacts/{id}/Merge

Merges a contact with one or more duplicate contacts.

Request

Parameters

Name Description Default
id Contact number (unique ID) of the contact to retain.

Body

Content Type: application/xml or application/json
IDs of the contacts to merge.

XML JSON
<Request>                
  <Contacts>             <!--Array of 'Item'--> 
    <Item>long</Item>    
  </Contacts>            
</Request>               
{                           
   "Contacts": [ "long" ]   
}                           
                            

Response

Body

Content Type: application/xml or application/json
Status message or an error message.

XML JSON
<Response>                     
  <Result>string</Result>      <!--Always 'Success'--> 
  <Message>string</Message>    <!--Error message--> 
</Response>                    
{                         
   "Result": "string",    // Always 'Success'
   "Message": "string"    // Error message
}                         
                          

Status Codes

Code Condition
200 OKThe contacts were successfully merged.
400 Bad RequestInvalid contact ID or contacts cannot be merged.
401 Unauthorized Access token is invalid, expired or not specified.
403 ForbiddenOne or more contacts are protected against accidental deletion.
404 Not FoundOne or more contacts were not found.
406 Not Acceptable Content type specified in the Accept header isn't supported.
500 Internal Server Error An internal error occurred.

Remarks

All non-empty properties from the source contact(s) (except duplicate entries) are copied to the target contact. The merge operation updates all records referencing the source contact(s) to point to the target contact instead. The source contact(s) are deleted if the operation succeeds.

You must specify at least one contact to merge with the target contact. The source and target contacts cannot be the same. Contacts of different types (individual/entity) cannot be merged.