# Requery Liveness Verification

## Query liveness verification with reference

<mark style="color:blue;">`GET`</mark> `https://vapi.verifyme.ng/v1/verifications/liveness/:reference`

#### Path Parameters

| Name                                        | Type   | Description |
| ------------------------------------------- | ------ | ----------- |
| reference<mark style="color:red;">\*</mark> | String |             |

{% tabs %}
{% tab title="200: OK Query ran successfully" %}

```javascript
{
    "isLive": false,
    "identityMatches": true,
    "identityDetails": {
        "idType": "nin",
        "idNumber": "12839485762",
        "firstname": "John",
        "lastname": "Doe",
        "dob": "2000-01-01",
        "photo": "base 64 string image",
        "photoMatching": {
            "match": true,
            "maxScore": 100,
            "percentageSimilarity": "98.99998",
            "matchingThreshold": "80"
        }
    },
    "verifiedAt": "2021-11-08T14:30:28.454Z"
}
```

{% endtab %}

{% tab title="404: Not Found Liveness verification not found" %}

```javascript
{
    "status": "error",
    "message": "Verification not Found",
    "code": "NOT_FOUND_ERROR"
}
```

{% endtab %}
{% endtabs %}

Query using the reference returned on a successfull liveness verification

#### Sample request

{% tabs %}
{% tab title="CURL" %}

```
curl --verbose  
    --header "Authorization: Bearer <public key>" 
    --request "GET" "https://vapi.verifyme.ng/v1/verifications/liveness/:reference
    
```

{% endtab %}

{% tab title="Javascript" %}

```
fetch(`https://vapi.verifyme.ng/v1/verifications/liveness/${response.reference}`, {
    headers: {
      authorization: `Bearer ${pkey}`
    }
  })
  .then((resp) => resp.json())
  .then(data => {
    console.log('> data', data);
  })
  .catch(e => console.error)
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.verifyme.ng/widget-services/requery-liveness-verification.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
