Search a Record

The various details of how to search a record is explained in this section.

HTTP Method
Endpoint URL See Endpoint
Resource /records/{repositoryName}/search
Request Parameters Specify the following parameters:
Name Description Type Data Type
Required
repositoryName Name of the repository. path string
Optional
includeSystemAttributes Specify whether you want to include system attributes. The default value is false. query boolean
findRootRecord Specify whether you want to find root record only. The default value is false. query boolean
Media Type application/json
Request Model
{
  "name": "string",
  "productKey": 0,
  "attributes": [
    {
      "name": "string",
      "value": [
        {}
      ],
      "operator": "string",
      "caseSensitive": true
    }
  ],
  "multivalueAttributes": {
    "additionalProp1": [
      {}
    ],
    "additionalProp2": [
      {}
    ],
    "additionalProp3": [
      {}
    ]
  },
  "relationships": [
    {
      "name": "string",
      "count": 0,
      "checkExistence": true,
      "relationshipAttributes": [
        {
          "name": "string",
          "value": [
            {}
          ],
          "operator": "string",
          "caseSensitive": true
        }
      ],
      "repository": {
        "name": "string",
        "productKey": 0,
        "attributes": [
          {
            "name": "string",
            "value": [
              {}
            ],
            "operator": "string",
            "caseSensitive": true
          }
        ]
      }
    }
  ],
  "startIndex": 0,
  "recordCount": 0
}
Response Model
{
  "records": [
    {
      "productId": "string",
      "productIdExt": "string",
      "productKeyId": "string",
      "version": "string",
      "state": "string",
      "effectiveDate": "string",
      "attributes": [
        {
          "name": "string",
          "value": "string",
          "displayName": "string",
          "multivalues": [
            {}
          ],
          "multivalue": false,
          "id": 0,
          "groupName": "string"
        }
      ],
      "repositoryName": "string",
      "relationships": {
        "relationshipAttributes": [
          {
            "name": "string",
            "value": "string",
            "displayName": "string",
            "multivalues": [
              {}
            ],
            "multivalue": false,
            "id": 0,
            "groupName": "string"
          }
        ],
        "targetRecord": {}
      },
      "deleted": false
    }
  ],
  "totalCount": 0
}
Request Example: Basic Search Searching for a record where address is "IL USA" in the repository named "Company".
{
  "name": "Company",
  "productKey": -1,
  "attributes": [
    {
      "name": "Address",
      "value": [
        "IL USA"
      ],
      "operator": "eq",
      "caseSensitive": false
    }
  ]
}
Response Example: Basic Search The response returns all the records matching the search criteria. In following response example, city is equal to "IL USA":
{
   "records": [   {
      "productId": "record1-1",
      "productIdExt": "record1-1",
      "productKeyId": "12798",
      "version": "1",
      "state": "CONFIRMED",
      "isDeleted": false,
      "attributes":       [
                  {
            "name": "PRODUCTID",
            "value": "record1-1",
            "displayName": "Record ID",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "PRODUCTIDEXT",
            "value": "record1-1",
            "displayName": "Record ID Extension",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "CONTAINS",
            "value": "",
            "displayName": "Related Records",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Name",
            "value": "TIBCO",
            "displayName": "Name",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Address",
            "value": "IL USA",
            "displayName": "Address",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Street",
            "value": null,
            "displayName": "Street",
            "multivalues":             [
               "11th St",
               "Rockford"
            ],
            "groupName": "Unassigned",
            "multivalue": true
         },
                  {
            "name": "Website",
            "value": "https://www.google.co.in/",
            "displayName": "Website",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Rating",
            "value": "10.10",
            "displayName": "Rating",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "CompanySource",
            "value": "IT SOURCE",
            "displayName": "CompanySource",
            "multivalues": null,
            "groupName": "CompanyType",
            "multivalue": false
         },
                  {
            "name": "CompanyRating",
            "value": "9",
            "displayName": "CompanyRating",
            "multivalues": null,
            "groupName": "CompanyType",
            "multivalue": false
         }
      ],
      "repositoryName": "COMPANY",
      "relationships": {},
      "deleted": false
   }],
   "totalCount": 1
}
Request Example: Related Record Search Searching for a related record where street name is "Rockford", customer type is not equal to "NonIT", and customer's date of birth is greater than "03/10/1985" in the "Company" and "Customer" repositories.
{
  "name": "Company",
  "productKey": -1,
  "attributes": [
    {
      "name": "Street",
      "value": [
        "Rockford"
      ],
      "operator": "eq",
      "caseSensitive": false
    }
  ],
  "relationships": [
    {
      "name": "companycustomer",
      "count": 1,
      "checkExistence": true,
      "relationshipAttributes": [
        {
          "name": "RCustomerType",
          "value": [
            "NONIT"
          ],
          "operator": "ne",
          "caseSensitive": false
        }
      ],
      "repository": {
        "name": "Customer",
        "attributes": [
          {
            "name": "DOB",
            "value": [
              "03/10/1985"
            ],
            "operator": "gt",
            "caseSensitive": false
          }
        ]
      }
    }
  ]
}
Response Example: Related Record Search The response returns all the records matching the search criteria. In the following response example, street name is "Rockford", customer type is "IT", and customer's date of birth is greater than "03/10/1985".
{
   "records": [   {
      "productId": "REC1",
      "productIdExt": "REC1",
      "productKeyId": "12799",
      "version": "1",
      "state": "CONFIRMED",
      "isDeleted": false,
      "attributes":       [
                  {
            "name": "PRODUCTID",
            "value": "REC1",
            "displayName": "Record ID",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "PRODUCTIDEXT",
            "value": "REC1",
            "displayName": "Record ID Extension",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "CONTAINS",
            "value": "",
            "displayName": "Related Records",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Name",
            "value": "TIBCO",
            "displayName": "Name",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Address",
            "value": "IL USA",
            "displayName": "Address",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Street",
            "value": null,
            "displayName": "Street",
            "multivalues":             [
               "11th St",
               "Rockford"
            ],
            "groupName": "Unassigned",
            "multivalue": true
         },
                  {
            "name": "Website",
            "value": "https://www.google.co.in/",
            "displayName": "Website",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "Rating",
            "value": "10.10",
            "displayName": "Rating",
            "multivalues": null,
            "groupName": "Unassigned",
            "multivalue": false
         },
                  {
            "name": "CompanySource",
            "value": "IT SOURCE",
            "displayName": "CompanySource",
            "multivalues": null,
            "groupName": "CompanyType",
            "multivalue": false
         },
                  {
            "name": "CompanyRating",
            "value": "9",
            "displayName": "CompanyRating",
            "multivalues": null,
            "groupName": "CompanyType",
            "multivalue": false
         }
      ],
      "repositoryName": "COMPANY",
      "relationships": {"companycustomer": [      {
         "relationshipAttributes":          [
                        {
               "name": "RCustomerType",
               "value": "IT",
               "displayName": null,
               "multivalues": null,
               "groupName": null,
               "multivalue": false
            },
                        {
               "name": "RCompanyType",
               "value": "IT PVT",
               "displayName": null,
               "multivalues": null,
               "groupName": null,
               "multivalue": false
            }
         ],
         "targetRecord":          {
            "productId": "REC2",
            "productIdExt": "REC2",
            "productKeyId": "12800",
            "version": "1",
            "state": "CONFIRMED",
            "isDeleted": false,
            "attributes":             [
                              {
                  "name": "PRODUCTID",
                  "value": "REC2",
                  "displayName": "Record ID",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "PRODUCTIDEXT",
                  "value": "REC2",
                  "displayName": "Record ID Extension",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "CONTAINS",
                  "value": "",
                  "displayName": "Related Records",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "CustName",
                  "value": "daniel reichard",
                  "displayName": "CustName",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "CustAddress",
                  "value": "UK",
                  "displayName": "CustAddress",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "DOB",
                  "value": "03/10/1986",
                  "displayName": "DOB",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "Salary",
                  "value": "45000",
                  "displayName": "Salary",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "Gender",
                  "value": "M",
                  "displayName": "Gender",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               },
                              {
                  "name": "CustRating",
                  "value": "7",
                  "displayName": "CustRating",
                  "multivalues": null,
                  "groupName": "Unassigned",
                  "multivalue": false
               }
            ],
            "repositoryName": "CUSTOMER",
            "relationships": {},
            "deleted": false
         }
      }]},
      "deleted": false
   }],
   "totalCount": 1
}
Success Response Example:

Code: 200 successful operation

Error Response If the response is unsuccessful, either of the following error code is displayed:

Example:

Code: 400 Parameters required are missing

OR

Code: 404 Record not found

OR

Code: 500 Invalid Request

For error code response, see Error Handling .