> For the complete documentation index, see [llms.txt](https://gl-docs.gitbook.io/zkpass/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gl-docs.gitbook.io/zkpass/use-cases/loan-application-screening/loan-screening-dvr.md).

# Loan Screening DVR

Following the zkPass SDK guideline, BCA Finance which takes the client role of the Proof Verifier,  defines the “Loan Screening” [DVR](/zkpass/getting-started/key-concepts/dvr.md) for users who are applying for the car loan. The requirements for the car loan are encapsulated in a query, which is detailed in the Data Verification Request (DVR). This query is formulated using the zkPass Query language, which is JSON-based.

## <mark style="color:blue;">Query</mark>

The DVR Query for Ramana Maharshi looks like the following.

{% tabs %}
{% tab title="Human Format" %}
All these conditions must be met for the overall criteria to be satisfied:

1. The Document ID (`bcaDocID`) should exactly match "DOC897923CP", which is the document id for BCA Customer Profile.
2. The first name under `personalInfo` should match "Ramana" (case insensitive).
3. The last name under `personalInfo` should match "Maharshi" (case insensitive).
4. The driver's license number under `personalInfo` should match "DL77108108" (case insensitive).
5. The credit rating from Pefindo, found under `financialInfo`, should be equal to or greater than 650.
6. The balance in the savings account, under `financialInfo`, should be equal to or greater than 55,000,000.
   {% endtab %}

{% tab title="JSON" %}
{% code lineNumbers="true" %}

```json
[
  {
    "assign": {
      "loan_application": {
        "and": [
          {
            "==": [
              {
                "dvar": "bcaDocID"
              },
              "DOC897923CP"
            ]
          },
          {
            "~==": [
              {
                "dvar": "personalInfo.firstName"
              },
              "Ramana"
            ]
          },
          {
            "~==": [
              {
                "dvar": "personalInfo.lastName"
              },
              "Maharshi"
            ]
          },
          {
            "~==": [
              {
                "dvar": "personalInfo.driverLicenseNumber"
              },
              "DL77108108"
            ]
          },
          {
            ">=": [
              {
                "dvar": "financialInfo.creditRatings.pefindo"
              },
              650
            ]
          },
          {
            ">=": [
              {
                "dvar": "financialInfo.accounts.savings.balance"
              },
              55000000
            ]
          }
        ]
      }
    }
  },
  {
    "output": {
      "title": "Loan Query Results"
    }
  },
  {
    "output": {
      "result": {
        "lvar": "loan_application"
      }
    }
  },
  {
    "if": {
      "condition": {
        "lvar": "loan_application"
      },
      "then": [
        {
          "output": {
            "name": {
              "dvar": "personalInfo.firstName"
            }
          }
        }
      ],
      "else": [
        {
          "output": {
            "rejected": "Your loan application has been rejected."
          }
        }
      ]
    }
  }
]
```

{% endcode %}
{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://gl-docs.gitbook.io/zkpass/use-cases/loan-application-screening/loan-screening-dvr.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
