For the complete documentation index, see llms.txt. This page is also available as Markdown.

GIS Changes

Introduction

This article provides an overview of the changes to Grading Integration Service (GIS), and provides examples of responses for Verify and Validate endpoints.

Verify

Call POST /v2/diamonds/kzsrfx4dxupa7a8uyn15wund/verify

{
    "carat_weight": 0.160,
    "shape_group": "Princess"
}
{
    "status": "success",
    "is_locked": true | false              
}
{
    "status": "failure",
    "data": {
        "carat_weight": {
            "matched": false,
            "known_value": "0.160",
            "given_value": "2.010",
            "tolerance": "0.020"
        },
        "shape_group": {
            "matched": true,
            "known_value": "Princess",
            "given_value": "Princess"
        }
    }
}

Returned when a diamond is not eligibile for grading because it has been deleted.

Returned when a diamond is not eligibile for grading.

  • Diamond Not Polished

  • Diamond has no scan report

  • Diamond has an unsupported scan report

  • Diamond has an unparseable scan report

Validate

Call POST /v2/diamonds/kzsrfx4dxupa7a8uyn15wund/validate-json

{
    "shape_group": "Cushion",
    "estimated_weight_crt": 0.88,
    "girdle_avg_mm": 0.14,
    "table_avg_mm": 0.015,
    "total_depth_mm": 0.006,
    "crown_angle_deg": 0.005, 
    "pavillion_angle_deg": 0.045 
}
{
    "diamond_id": "kzsrfx4dxupa7a8uyn15wund",
    "request_id": "un33utr58f8zm6twyl6eaqym",
    "status_url": "https://api.gis.uat.tracr.com/v2/diamonds/kzsrfx4dxupa7a8uyn15wund/validate/un33utr58f8zm6twyl6eaqym",
    "verification_status": "Pending"
}

Returned when a diamond is not eligibile for grading because it has been deleted.

{
  "reason": "diamond_has_been_deleted"
}

Returned when a diamond is not eligibile for grading.

  • Diamond Not Polished

{
  "reason": "diamond_is_not_polished"
}
  • Diamond has no scan report

{
  "reason": "diamond_has_no_scan_report"
}
  • Diamond has an unsupported scan report

{
  "reason": "scan_report_not_supported",
  "detail": {
    "generic_error": "'.csv' is not a supported file type for polished scan reports"
  }
}
  • Diamond has an unparseable scan report

{
  "reason": "scan_report_parse_error",
  "detail": {
    {
      "table_size_average": [
        {
          "value": "Some",
          "xpath": "/sarinDetails/stone/stone_part[@type='table']/width[@type='avg']/mm/text()",
          "error_type": "value_not_a_decimal"
        }
      ]
    }
  }
}

Returned when a diamond does not have a supported shape group, or fallback shape group.

Last updated