Skip to content

GET Duplicates

Ksenyia edited this page Nov 7, 2016 · 1 revision

Getting list of the duplicates limited by 3 parameters "type", "limit" and "skip".

Resource URI

duplicates/{type}/{limit}/{skip}

Resource Properties

Parameter Description
limit It limit the search. Default is 50. Eg. duplicates/company/50/0
skip Offset of next page result. Default is 0. Eg. duplicates/company/50/0
type Possible variants of the types: project,company. Default is "company".

Response Attribute

{
   count: Integer,
   data: [
     {
         _id: String,
         created_date: Date,
         created_from: String,
         duplicate: {
             _id: String,
             company_aliases: Array,
             company_established_source: String,
             company_name: String,
             countries_of_operation: Array,
             country_of_incorporation: Array
         },
         entity: String,
         isDuplicate: null or Boolean (true or false),
         notes: String,
         original: {
             _id: String,
             company_aliases: Array,
             company_established_source: String,
             company_name: String,
             countries_of_operation: Array,
             country_of_incorporation: Array
         },
         resolved: Boolean (true or false),
         resolved_date: Date,
         score: Float
     }
  ]
}

HTTP GET

Default Request

curl -GET http://end-point-uri/duplicates/company/50/0

Response

HTTP Status Code 200

{
   count: 1,
   data: [
     {
         _id: "580defd4ca9ab2a23e01ddb7",
         created_date: "2016-10-24T11:26:12.716Z",
         created_from: "580defbdca9ab2a23e01d60f",
         duplicate: {
             _id: "580defc1ca9ab2a23e01d622",
             company_aliases: [],
             company_established_source: "580defc0ca9ab2a23e01d610",
             company_name: "African Consolidated Resources Plc",
             countries_of_operation: [
                 { 
                     country: "580def92ca9ab2a23e01d555",
                     source: "580defc0ca9ab2a23e01d610",
                     timestamp: "2016-10-24T11:25:05.000Z"
                 },
                 ...
             ],
             country_of_incorporation: []
         },
         entity: "company",
         isDuplicate: null,
         notes: "Found  47 potentially matching company name(s) for company African Consolidated Resources Plc after 
                import. Date: October 24, 2016 2:26 PM",
         original: {
             _id: "580defc2ca9ab2a23e01d7df",
             company_aliases: [],
             company_established_source: "580defc0ca9ab2a23e01d610",
             company_name: "Nevsun Resources Ltd.",
             countries_of_operation: [
                 { 
                     country: "580def92ca9ab2a23e01d5fa",
                     source: "580defc0ca9ab2a23e01d610",
                     timestamp: "2016-10-24T11:25:05.000Z"
                 },
                 ...
             ],
             country_of_incorporation: []
         },
         resolved: false,
         resolved_date: "2016-11-02T08:15:13.284Z",
         score: 0.5
     }
  ]
}
Clone this wiki locally