Skip to main content
Version: 19

Docteller document assessment provider

🎯 Functional documentation​

This provider is used to assess documents using the external service from DocTeller. Its primary function is to analyze a document's content (like an identity document or tax statement) and extract key data points.

The provider's process is a single API call:

  • API Call (readDocument): The document bytes are packaged into a multipart/form-data request and sent to the DocTeller API.
  • Validation and Consolidation: The response is validated for readability and successful data extraction.

βš™οΈ Configuration​

Implementation classes​

  • DocTellerDocumentAssessmentProvider

Required authentication settings​

  • resourceUri: The base URL for the DocTeller API
  • API_KEY: The mandatory API key for authentication, read from settings or a vault.

Settings:​

  • docTellerProviderConfigurations (required): Define a list of configurations. It’s possible to configure a list in order to define different behaviour depending on the document type. Each configuration has the following properties:
  • documentTypes (required): Defines which document types apply to this configuration(cni_nouvelle_verso, cni_nouvelle_recto, cni_verso, cni_rect, passeport).
  • fieldMapping (required): Defines a list of all fields that need to be consolidated and their corresponding data point in Harmoney. Each mapping has the following properties:
    • docTellerFieldName (required): Defines the name of the field on docTeller side
    • inputFieldPath (required): Defines the field path of the Harmoney data point (JSON paths are supported, The path is evaluated against the DocumentAssessmentDataPoints, which combines fields from both the Dossier and the relevant Party.)
    • inputFieldType (optional): Define this when the data point is different from a String. E.g. type DATE is necessary to sent dates in the format dd.MM.yyyy. Default STRING
    • alphaNumeric (optional): When true, all non-alphanumeric fields are stripped from the value of the data point. Default false

Example Note: date_expiration is applicable in case of doc type cni_nouvelle_verso

{
"resourceUri": "resource_uri",
"API_KEY": "$vault{DOCTELLER_<client>_API_KEY}",
"docTellerProviderConfigurations": [
{
"documentTypes": ["cni_nouvelle_recto"],
"fieldMapping": [
{
"docTellerFieldName": "nom",
"inputFieldPath": "party.individual.lastName",
"inputFieldType": "STRING"
},
{
"docTellerFieldName": "prenoms",
"inputFieldPath": "party.individual.firstName",
"inputFieldType": "STRING"
},
{
"docTellerFieldName": "numero",
"inputFieldPath": "party.individual.identity.cardNumber",
"alphaNumeric": true
},
{
"docTellerFieldName": "date_expiration",
"inputFieldPath": "party.individual.identity.cardValidTo",
"inputFieldType": "DATE"
}
]
}
]
}