# KYC/CIP Compliance

## IDMatchCOMPLY5.1

<mark style="color:green;">`POST`</mark> `https://production.idresponse.com/process/comprehensive/gateway`

Make an **HTTPS POST** request with the following body parameters to find out if the target has provided valid identity attributes. You will receive a synchronous response in 2-3 seconds with a **result** object that includes an **action, detail** and **issues object**.

#### Request Body

| Name                                      | Type   | Description                                                        |
| ----------------------------------------- | ------ | ------------------------------------------------------------------ |
| user<mark style="color:red;">\*</mark>    | string | Your account's API username                                        |
| pass<mark style="color:red;">\*</mark>    | string | Your account's API password                                        |
| service<mark style="color:red;">\*</mark> | string | The service name (IDMatch5.0)                                      |
| reference                                 | string | A unique identifier for your customer                              |
| target                                    | object | The individual being sent for verification                         |
| fn<mark style="color:red;">\*</mark>      | string | The target's first name                                            |
| ln<mark style="color:red;">\*</mark>      | object | The target's last name                                             |
| addr<mark style="color:red;">\*</mark>    | string | The target's street address (line 1 and line 2)                    |
| city                                      | string | the target's city                                                  |
| state                                     | string | The target's state                                                 |
| zip<mark style="color:red;">\*</mark>     | string | The target's zip                                                   |
| dob                                       | string | The target's Date of Birth (YYYYMMDD format)                       |
| ssn                                       | string | The target's SSN (either 4 or 9)                                   |
| phone                                     | string | The target's phone number                                          |
| email                                     | string | The target's email address                                         |
| age                                       | string | The age to check (must be sent like "age+" i.e. "18+", "21+" etc.) |
| test\_key                                 | string | The test key value that you are using to test                      |

{% tabs %}
{% tab title="200 Transaction processed and result returned" %}

```javascript
{
  "meta": {
    "company": "Company ABC, Inc.",
    "confirmation": "21201890",
    "reference": "12345 {A UNIQUE ID}",
    "service": "IDMatchCOMPLY5.1",
    "timestamp": "2020-08-08 17:56:14",
    "user": "user@company.com"
  },
  "result": {
    "action": "REVIEW",
    "detail": "TRANSACTION REQUIRES FURTHER ATTENTION",
    "issues": [
      "SSN CHECK FAILED"
    ]
  }
}
```

{% endtab %}
{% endtabs %}

## Sample Request Body

```javascript
{
      "user": "USERNAME",
      "pass": "PASSWORD",
      "service": "IDMatchCOMPLY5.1",
      "reference": "12345 {A UNIQUE ID}",
      "target":{
            "fn":"Barbara",
            "ln": "Miller",
            "addr": "123 Main St",
            "city": "Stratford",
            "state": "CT",
            "zip": "06614",
            "dob": "19740821",
            "ssn": "854125698",
            "phone": "2015106000",
            "email": "bmiller@veratad.com",
            "age": "21+",
            "test_key": "general_identity"
          }
  }
```

## Action and Detail Responses

The following are all values that will be returned in the result object of the response.

| Action | Detail                                 | Description                                                                                                                                                                                                             |
| ------ | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| FAIL   | NO MATCH                               | No matching identity found in the data sources                                                                                                                                                                          |
| FAIL   | TARGET IS DECEASED                     | Target found as a deceased identity                                                                                                                                                                                     |
| REVIEW | TRANSACTION REQUIRES FURTHER ATTENTION | Target found and not deceased, but at least one identity attribute provided does not match. This will also populate the "issues" object with a list of the identity attributes that did not match. See full list below. |
| PASS   | ALL CHECKS PASSED                      | <p>Target was found, is not deceased and has passed all verification checks.</p><p>A <code>PASS</code> will still occur if the only issue is <code>ADDRESS DISCREPANCY</code></p>                                       |

## Issues Responses

When a transaction returns as `REVIEW` then there will be a list of issues. This list can include any of the below values.

| Issue                      | Description                                                           |
| -------------------------- | --------------------------------------------------------------------- |
| ADDRESS CHECK FAILED       | The address provided does not match any on file                       |
| ADDRESS DISCREPANCY        | The address provided is a partial match to one of the addresses found |
| YEAR OF BIRTH CHECK FAILED | The Year of Birth provided does not match any on file                 |
| SSN CHECK FAILED           | The SSN provided does not match any on file                           |
| NAME FOUND ON WATCHLIST    | The target has been found on a watchlist                              |

### Example for PASS with an issue

{% hint style="info" %}
This service is slightly different from other services in that it can return one issue with a `PASS` action. This issue is `ADDRESS DISCREPANCY` and it will only return as `PASS` if there are no other issues present.
{% endhint %}

```javascript
{
  "meta": {
    "company": "Company ABC, Inc.",
    "confirmation": "21201890",
    "reference": "12345 {A UNIQUE ID}",
    "service": "IDMatchCOMPLY5.1",
    "timestamp": "2017-08-08 17:56:14",
    "user": "user@company.com"
  },
  "result": {
    "action": "PASS",
    "detail": "ALL CHECKS PASSED",
    "issues": [
      "ADDRESS DISCREPANCY"
    ]
  }
}
```

## Rules

IDMatch+COMPLY will process with the default base ruleset:

{% hint style="success" %}
The base ruleset will return a PASS when:

* A match is found
* The target is not deceased
* The target has provided all valid identity attributes or the only issue is `ADDRESS DISCREPANCY`
  {% endhint %}

{% hint style="warning" %}
The base ruleset will return a REVIEW when:

* A match is found
* The target is not deceased
* The target's identity attributes do not all match
  {% endhint %}

{% hint style="danger" %}
The base ruleset will return a FAIL when:

* A match is not found
* The target is deceased
  {% endhint %}

## Service Testing

{% hint style="info" %}
Use the test\_key attribute to test the service. When the test\_key is provided the system will dynamically drop the live data sources and use the testing database. These transactions are free of charge. To access live data do not send this attribute. The below sample request is one of the available test cases. To access more click the link below.
{% endhint %}

{% content-ref url="../../testing-1/additional-test-cases" %}
[additional-test-cases](https://api.veratad.com/testing-1/additional-test-cases)
{% endcontent-ref %}
