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

# Workflow

> How to create or update entities.

## Create An Entity Workflow

<img src="https://mintcdn.com/lead/0UJlPqWdLCOMqs06/images/entity-creation-workflow.png?fit=max&auto=format&n=0UJlPqWdLCOMqs06&q=85&s=1002467eb073153e6c12f029b4cbe359" alt="Entity Creation Workflow" width="5084" height="2428" data-path="images/entity-creation-workflow.png" />

## **Create/Update Validations**

In addition to standard required vs optional fields and data type validations, Lead runs the following validations on data at the point of entry.

<Info>
  This list is non-exhaustive — we aim to be thoughtful and robust in validations that ensure high data quality to enable us to provide effective oversight.
</Info>

* Phone numbers follow E.123 format
  * E.123 format requires a `+` sign followed by a country code, followed by required spacing. Our Regex to validate E.123 is

    ```
    "^\\+\\d{1,3}\\s\\d{2,3}\\s\\d{2,3}\\s\\d{4}|^\\+\\d{1,3}\\s\\d{1,14}(\\s\\d{1,13})?|^\\(\\d{3}\\)\\s\\d{3}\\s\\d{4}?"
    ```
* Addresses and customer information must consist solely of valid UTF-8 characters
* One character values may not be passed for the business name field.
* PO Box addresses may not be used as physical addresses -- neither in line one, nor in line 2
* Registered Agent addresses and addresses in Prohibited Countries may not be used as physical addresses
* Address Line 1 may not have leading white space and must be at least 4 characters
* For US Addresses, State must be a valid US State and must use a valid USPS State code
* SSNs may not start with the number 9 (ITINs are sometimes mistakenly reported as SSNs which is the most common cause that triggers this validation failure)
* Postal Codes for US Addresses must be 5 or 9 digits
* OFAC and KYC dates must be dated prior to the time of the request.
