> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lendflow.com/llms.txt
> Use this file to discover all available pages before exploring further.

# LexisNexis UCC Filings

## LexisNexis UCC Filings

The **LexisNexis UCC Filings** block combines a UCC search with a detailed filing report.

## What the service returns

| Service ID | Role | Stored result |
| - | - | - |
| `lexis_nexis_ucc_filing_search` | Finds UCC filing candidates and stores the first record's TMS and business IDs. | `commercial_data.lexis_nexis.ucc_filing_search` |
| `lexis_nexis_ucc_filing_report` | Uses the stored IDs to retrieve detailed filings, debtors, and secured parties. | `commercial_data.lexis_nexis.ucc_filing_report` |

The current implementation takes `TMSId` from the first search record and `BusinessId` from that record's first secured party. Review the search match before using the report.

## Requirements

### Search

| Application field | Requirement | Notes |
| - | - | - |
| Business legal name | Optional | Used to identify potential business matches when available. |
| Primary business address | Optional | Street, city, state, and ZIP code can improve matching. State and ZIP code must pass validation when provided. |
| EIN | Optional | The value must pass validation when provided. |
| Owner SSN | Optional | The value can improve matching and must pass validation when provided. |
| Owner and end-user contact information | Optional | Available names, addresses, and phone numbers can improve matching. Phone, state, and ZIP code must pass applicable validation when provided. |

### Report

| Application field | Requirement | Notes |
| - | - | - |
| UCC filing search result | Conditional | A report requires the record identifier from the first search result and the business identifier from its first secured party. If no usable search result is stored, Lendflow runs UCC Filing Search first. |

## Run the services

Call [Enrich Business Credit Application](/api-reference/workflow-management/enrich-business-credit-application) at `PUT /api/applications/{application_id}/enrich`.

```json theme={"system"}
{ "provider": "lexis_nexis_ucc_filing_search" }
```

Then run:

```json theme={"system"}
{ "provider": "lexis_nexis_ucc_filing_report" }
```

If report IDs are absent, the report automatically runs search first. The report requires both stored `BusinessId` and `TMSId`.

Search behavior is fixed: 20 records starting at record 1, full return, phonetic and nickname matching, and also-found records. Callers cannot override it.

## Retrieve results

Poll `GET /api/applications/{application_id}/commercial_data` through [Get Commercial Data](/api-reference/workflow-management/get-commercial-data) with both service IDs in `services[]`.

| Data | Search path | Report path |
| - | - | - |
| Result | `commercial_data.lexis_nexis.ucc_filing_search` | `commercial_data.lexis_nexis.ucc_filing_report` |
| Status | `statuses.lexis_nexis.ucc_filing_search` | `statuses.lexis_nexis.ucc_filing_report` |
| Request | `request_data.lexis_nexis.ucc_filing_search` | `request_data.lexis_nexis.ucc_filing_report` |
| Date | `dates.lexis_nexis_ucc_filing_search` | `dates.lexis_nexis_ucc_filing_report` |

[Get Commercial Data](/api-reference/workflow-management/get-commercial-data) returns the latest `statuses`, `dates`, `commercial_data`, and `request_data` values for each requested service ID.

## Asynchronous behavior

Each call queues a separate job. `{"data":{"onqueue":true}}` means accepted, not completed. Poll search and report independently. A report rerun reuses stored IDs unless they are absent.

## Example response

Search result:

```json theme={"system"}
{
  "UCCSearch2ResponseEx": {
    "response": {
      "Header": { "Status": 0, "QueryId": "101", "TransactionId": "txn-search" },
      "Records": {
        "Record": [{
          "TMSId": "UCEXAMPLE001",
          "OriginFilingType": "UCC-1 FINANCING STATEMENT",
          "OriginFilingNumber": "2023-00123",
          "OriginFilingDate": { "Month": 10, "Day": 21, "Year": 2023 },
          "FilingJurisdiction": "CO",
          "Debtors": { "Debtor": [{ "OriginName": "EXAMPLE LLC" }] },
          "Secureds": { "Secured": [{ "OriginName": "EXAMPLE BANK" }] }
        }],
        "RecordCount": 1
      }
    }
  }
}
```

Report result:

```json theme={"system"}
{
  "UCCReport2ResponseEx": {
    "response": {
      "Header": { "Status": 0, "QueryId": "101", "TransactionId": "txn-report" },
      "UCCFilings": {
        "UCCFiling": [{
          "TMSId": "UCEXAMPLE001",
          "OriginFilingType": "UCC-1 FINANCING STATEMENT",
          "OriginFilingNumber": "2023-00123",
          "OriginFilingDate": { "Month": 10, "Day": 21, "Year": 2023 },
          "Filings": { "Filing": [{ "ExpirationDate": { "Month": 10, "Day": 21, "Year": 2028 } }] }
        }]
      }
    }
  }
}
```

## Response fields

| Field | Type | Meaning | Format or behavior |
| - | - | - | - |
| `UCCSearch2ResponseEx.response` | object | LexisNexis UCC-search response envelope. | Contains `Header` and `Records`. |
| `UCCReport2ResponseEx.response` | object | LexisNexis UCC-report response envelope. | Contains `Header` and `UCCFilings`. |
| `Header` | object | Provider status and correlation metadata. | Returned by search and report. |
| `Header.Status` | integer | Provider response status. | `0` appears in successful fixtures. |
| `Header.QueryId` | string | Request correlation value. | Derived from the owner record when available. |
| `Header.TransactionId` | string | Provider transaction ID. | Provider-generated. |
| `Records` | object | Search-result container. | Contains `Record` and `RecordCount`. |
| `Records.Record` | array | UCC search candidates. | Can be empty. |
| `Record[].TMSId` | string | Provider record ID used for report lookup. | First record is selected. |
| `OriginFilingType` | string | Original filing type. | Provider text. |
| `OriginFilingNumber` | string | Original filing number. | Jurisdiction-defined text. |
| `OriginFilingDate` | object | Original filing date. | `Month`, `Day`, and `Year` integers. |
| `FilingJurisdiction` | string | Filing jurisdiction. | Commonly a state code. |
| `Debtors.Debtor` | array | Debtor parties. | Can be empty or omitted. |
| `Debtor[].OriginName` | string | Debtor name as filed. | Provider text. |
| `Secureds.Secured` | array | Secured parties. | First party can supply the report `BusinessId`. |
| `Secured[].OriginName` | string | Secured-party name as filed. | Provider text. |
| `Records.RecordCount` | integer | Number of search records reported. | `0` means no candidates. |
| `UCCFilings` | object | Detailed filing container. | Contains `UCCFiling`. |
| `UCCFilings.UCCFiling` | array | Detailed report filings. | Can be empty. |
| `Filings` | object | Filing-event container. | Contains `Filing`. |
| `Filings.Filing` | array | Filing events or details. | Can be empty. |
| `Filing[].ExpirationDate` | object or null | Filing expiration date. | Date-parts object when known. |

Only fields shown in the sanitized example are defined here. Additional provider fields can be returned.

## Data Orchestration

The block is available under **UCCs → LexisNexis**. UCC conditions use `lexis_nexis_ucc_filing_search`; the report is not the prerequisite for those conditions.

## Errors

| Result | Meaning | Action |
| - | - | - |
| HTTP `401` or `403` | Authentication or authorization failed. | Use an authorized bearer token. |
| HTTP `422` | Service access, body, or application data validation failed. | Confirm both services and correct invalid identifiers or address/contact data. |
| Report requires `BusinessId` or `TMSId` | Search did not store usable IDs from the first record and secured party. | Review the search result and improve application match inputs. |
| `failed_at` or error status | Provider or execution failure. | Inspect the exact service lifecycle error and status. |

## FAQ

<AccordionGroup>
  <Accordion title="Why can search succeed while report fails?">
    The report requires both IDs. A candidate can exist without the first record and first secured party supplying the required values.
  </Accordion>

  <Accordion title="Can I change the search limit or matching settings?">
    No. The current service exposes no options.
  </Accordion>

  <Accordion title="Does RecordCount describe the report?">
    No. It is the search response's reported candidate count.
  </Accordion>

  <Accordion title="Does onqueue true mean the report is ready?">
    No. Poll the report service until it finishes or fails.
  </Accordion>
</AccordionGroup>
