REST API - link

The table summarizes the REST API - link.

Request

Format
PUT <baseurl>/globaldata/ref/<caseReference>/link/<roleName>
Path parameters
  • caseReference: The case reference of the case data you want to associate with other case data. For example, BDS-2-com.example.gddemo.Customer-1-1. You must only specify one. You can obtain the case reference by using findAllCases.
  • roleName: The name of the association. For example, claim.
Query parameters caseref=string: The case reference of the case data you want to associate the case data with. For example, BDS-2-com.example.gddemo.Claim-4-0. At least one case reference must be specified. The maximum number of case references that can be specified is limited by the limit of the path length. If you want to link lots of objects then it is best to use REST API - linkx.

Response

JSON Returns a JSON representation of the contents of a LinkCaseResponse element.
XML Returns the contents of a LinkCaseResponse element (from the BusinessDataServices schema).

Example

Request
PUT <baseurl>globaldata/ref/BDS-2-com.example.gddemo.Customer-1-0/link/cars?caseref=BDS-2-com.example.gddemo.Car-4-0&caseref=BDS-2-com.example.gddemo.Car-6-0
Response
{
       "xml-fragment":
       {
           "caseReference": "BDS-2-com.example.gddemo.Customer-1-1",
           "targetCaseReference":
           [
               "BDS-2-com.example.gddemo.Car-4-1",
               "BDS-2-com.example.gddemo.Car-6-1"
           ]
       }
}