Customer Validation
Index:
| S.NO | Index Link |
|---|---|
| 1 | Customer Validation Rules |
| 2 | SMDS CMD Validation Rules |
For any new customer creation or updating existing customer, particular customer’s fields will be validated before persisting into database. All the fields are validated with general as well as specific validation rules. In below document all the validation rules for Each field and its sub fields are listed.
Validation Rules
| S. No | FIELDS | SUB FIELDS | VALIDATIONS/RULES Description | Sub fields mandatory status |
|---|---|---|---|---|
| 1 | Trading Name | Trading Name must not be null and should match its regular expression | Mandatory | |
| 2 | Legal Name | must match its defined regular expression | ||
| 3 | Customer Local Name | Local Name length must be between (3,200) | ||
| 4 | Customer Type | Customer Type can be only either ZICC or ZEXC, any other values are not allowed | ||
| 3 | Customer Address Required/Mandatory | Mandatory | ||
| Country | Mandatory | Mandatory | ||
| Country Code | Country Code must not be null and should match its regular expression | |||
| Country Code | Country Code is validated with database country codes. And its valid if it's present in ref_country table | |||
| Country Code | Mandatory | |||
| Country Name | Country Name must match its defined regular expression | |||
| Country Name | Country Name is validated with given country Code | |||
| Combination of Country Code and Country Name should be a valid combination. Example: IN + INDIA | ||||
| Region | ||||
| Region Code | Region Code must not be null and should match its regular expression | Mandatory | ||
| RegionCode is validated with database Region codes. And its valid if it's present in ref_Region table | ||||
| Region Name | Region Name must match its defined regular expression | |||
| Region Name is validated with given Region Code | ||||
| Combination of Region Code and region Name should be a valid combination. Example: MH + Maharashtra | ||||
| street Number | Regular expression validation | |||
| street Name | Regular expression validation | |||
| PoBox or Street Name is mandatory, either of them is required to perform ingest | ||||
| apartment Floor | Regular expression validation | |||
| sub-Area | Regular expression validation | |||
| district Name | Regular expression validation | |||
| city Name | Regular expression validation | Mandatory | ||
| poBox Number | Regular expression validation | |||
| PoBox or Street Name is mandatory, either of them is required to perform ingest | ||||
| postal Code | Regular expression validation | |||
| isoLanguageCode | Regular expression validation | |||
| Language code is validated with data present in database. It's valid only if its present in database | ||||
| latitude | No validation | |||
| longitude | No validation | |||
| 4 | Special Scenario for japan | For country JAPAN (JP) all above address fields are mandatory | ||
| 5 | TELECOMMUNICATION | |||
| communicationNumberType | Mandatory | Mandatory | ||
| must be either MOB or TEL other than these values will not be allowed | ||||
| Country | same validation mentioned under customerAddress | |||
| internationalDalingcode | Mandatory | Mandatory | ||
| must match its defined regular expression | ||||
| Number | Mandatory | Mandatory | ||
| must match its defined regular expression | ||||
| ExtensionNumber | must match its defined regular expression | |||
| IsDeletedFlag | Cannot be true in customer create scenario | |||
| Combination of International dailing code and phone Number should be valid. Example: +91 and 9849214822 (phone number should be valid working as per india tele network rules and regulations) | ||||
| Combination of countryCode and Internation dailing code should be valid. Example: IN and +91 | ||||
| 6 | customerStatus | |||
| statusCode | statusCode cannot be Suspended/Inactive during creation | Mandatory | ||
| Accepted values are only "A", "S", "I" which are Active,Inactive,Suspended | ||||
| statusReason | statusReason must be aligned with passed statusCode | |||
| 7 | url | URL length validation: must be between [3,100] characters | ||
| URL format validation | ||||
| 8 | invoiceISOLanguageCodePreference | must match its defined regular expression | ||
| 9 | isBrokerage | It is a boolean field, so could be either true or false only | ||
| 10 | isForwardersCompensation | It is a boolean field, so could be either true or false only | ||
| 11 | customerWorkflowIndicator | Value should match the regular expression defined | ||
| 12 | isSoleProprietor | It is a boolean field, so could be either true or false only | ||
| 13 | CustomerIdentifiers | Country | Mandatory fields validations: Without mandatory fields Ingest is not allowed | |
| identifierCode, mandatory | Regular Expression validations: All field's values must match their defined regex | Mandatory | ||
| identifierValue, mandatory | IdentifierValue is validated against the smds_generic_country and scpi_country_rules for the country specified in customerIdentifiers section | Mandatory | ||
| identifierType, mandatory | IdentifierType should be either TAX_NUM or REF_NUM | Mandatory | ||
| isDeletedFlag | Each identifier inside customerIdentifiers list is validated again smds_generic and scpi_country_rules based on respective each country fields | |||
| IdentifierCode is validated against the smds_generic_country and scpi_country_rules for the country specified in customerIdentifiers section | ||||
| 14 | ExternalSystemIdentifiers Mandatory | ExternalSystemName | Mandatory fields validations: Without mandatory fields Ingest is not allowed | Mandatory |
| ExternalSystemReference | Regular Expression validations: All field's values must match their defined regex | Mandatory | ||
| ExternalSystemName code should be present in reference table in database maintained for external system name codes | ||||
| 15 | Customer brands | brandCode | Mandatory fields validations: Without mandatory fields Ingest is not allowed | Mandatory |
| brandName | Regular Expression validations: All field's values must match their defined regex | |||
| brand code should be present in brands reference table in database which is maintained for all brands. | ||||
| brandsName provided in request should match the brandValue for given brandCode in brands_reference table in database | ||||
| 16 | CustomerWebBillLadings | brandCode | Mandatory fields validations: Without mandatory fields Ingest is not allowed | Mandatory |
| isNegotiableBL | Regular Expression validations: All field's values must match their defined regex | |||
| isNonNegotiableBL | brand code should be present in brands reference table in database which is maintained for all brands. | |||
| isNegotiableBL is a boolean field, So could be either true or false only | ||||
| isNonNegotiableBL is a boolean field, so could be either true or false only | ||||
| 17 | CustomerAuditData | user | Mandatory fields validations: Without mandatory fields Ingest is not allowed | Mandatory |
| sourceSystem | Regular Expression validations: All field's values must match their defined regex | Mandatory |
SMDS CMD Country specific rule set extract
| S.No | Date | Generic Country rules | SCPI Country rules |
|---|---|---|---|
| 1 | 26th Feb 2024 |
Was this page helpful?