When enrichment data has been uploaded and fits to a certain prediction it is added to the results from the GET /document/jobs/{id
} endpoint.
Enrichment data is refreshed automatically every 4 hours. It might take up to 4 hours until the enrichment data prediction is available in the response. If the enrichment data prediction is NOT available in the response in your first try, perform again (some hours later) steps 4 and 5. Do not perform steps 7 and 8 before you see the enrichment data prediction in the response in step 5.
-
Expand the GET /document/jobs/{id
} endpoint.
-
Click Try it out.
-
Set returnNullValues
and extractedValues
to true
.
-
Enter the id
received in the POST /document/jobs endpoint as the id
.
-
Click Execute.
The endpoint request and response look as follows:

What just happened?
In this example, in the response, one of the extracted fields is the sender name Sliced Invoices. This information is enriched with the supplier ID enrichment data created in step 2. The prediction suggests the supplier ID BE0001 (from sender name Sliced Invoices) with higher probability than the supplier ID BE0002 (from sender name Sliced).
This is an example of a full prediction including the enrichment data part:
{
"status": "DONE",
"id": "afc5f228-7393-431a-ae9a-3dddf440a9bd",
"fileName": "sample-invoice-1.pdf",
"documentType": "invoice",
"created": "2020-11-11T12:30:22.023360+00:00",
"finished": "2020-11-11T12:32:05.308440+00:00",
"country": "XX",
"extraction": {
"headerFields": [
{
"name": "taxRate",
"category": "amounts",
"value": null,
"type": "number",
"page": null,
"confidence": null,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
},
"group": 1
},
{
"name": "taxAmount",
"category": "amounts",
"value": 8.5,
"type": "number",
"page": 1,
"confidence": 0.999595546722412,
"coordinates": {
"x": 0.877468764781952,
"y": 0.481470912694931,
"w": 0.0362756848335266,
"h": 0.00883695483207703
},
"group": 1
},
{
"name": "senderName",
"category": "sender",
"value": "Sliced Invoices",
"type": "string",
"page": 1,
"confidence": 0.617510483307498,
"coordinates": {
"x": 0.0709391374445788,
"y": 0.156784492588369,
"w": 0.100362756952842,
"h": 0.00826681870011403
}
},
{
"name": "documentNumber",
"category": "document",
"value": "INV-3337",
"type": "string",
"page": 1,
"confidence": 0.656084211099715,
"coordinates": {
"x": 0.759774284562676,
"y": 0.136830102622577,
"w": 0.0612656187021362,
"h": 0.00826681870011403
}
},
{
"name": "purchaseOrderNumber",
"category": "details",
"value": "12345",
"type": "string",
"page": 1,
"confidence": 0,
"coordinates": {
"x": 0.760177347843611,
"y": 0.155644241733181,
"w": 0.0390971382507054,
"h": 0.00798175598631698
}
},
{
"name": "receiverAddress",
"category": "receiver",
"value": "123 Somewhere St Melbourne, VIC 3000",
"type": "string",
"page": 1,
"confidence": 0.584470650866444,
"coordinates": {
"x": 0.0725513905683192,
"y": 0.303591790193843,
"w": 0.138250705360742,
"h": 0.0250855188141391
}
},
{
"name": "grossAmount",
"category": "amounts",
"value": 93.5,
"type": "number",
"page": 1,
"confidence": 0.653526421749231,
"coordinates": {
"x": 0.869407496977025,
"y": 0.500285062713797,
"w": 0.0447400241837969,
"h": 0.0091220068415051
}
},
{
"name": "netAmount",
"category": "amounts",
"value": 85,
"type": "number",
"page": 1,
"confidence": 0.641649420965802,
"coordinates": {
"x": 0.869407496977025,
"y": 0.462371721778791,
"w": 0.0447400241837969,
"h": 0.00969213226909921
}
},
{
"name": "receiverName",
"category": "receiver",
"value": "Test Business",
"type": "string",
"page": 1,
"confidence": 0.610726446327236,
"coordinates": {
"x": 0.071745264006449,
"y": 0.2884834663626,
"w": 0.0923014913341395,
"h": 0.00826681870011403
}
},
{
"name": "senderAddress",
"category": "sender",
"value": "Suite 5A-1204 123 Somewhere Street Your City AZ 12345",
"type": "string",
"page": 1,
"confidence": 0.602965183910869,
"coordinates": {
"x": 0.0721483272873841,
"y": 0.1730330672748,
"w": 0.15074566706973,
"h": 0.040193842645382
}
},
{
"name": "receiverContact",
"category": "receiver",
"value": null,
"type": "string",
"page": null,
"confidence": null,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
},
{
"name": "taxId",
"category": "amounts",
"value": null,
"type": "string",
"page": null,
"confidence": null,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
},
"group": 1
},
{
"name": "shippingAmount",
"category": "amounts",
"value": null,
"type": "number",
"page": null,
"confidence": null,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
},
{
"name": "currencyCode",
"category": "amounts",
"value": "USD",
"type": "string",
"page": 1,
"confidence": 0.933853209018707,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
},
{
"name": "documentDate",
"category": "document",
"value": "2016-01-25",
"type": "date",
"page": 1,
"confidence": 0.986256398260593,
"coordinates": {
"x": 0.758968158000806,
"y": 0.174458380843786,
"w": 0.1136638452237,
"h": 0.00940706955530218
}
}
],
"lineItems": [
[
{
"name": "description",
"category": "details",
"value": "Web Design This is a sample description...",
"type": "string",
"page": 1,
"confidence": 0.620112451872042,
"coordinates": {
"x": 0.171704957678356,
"y": 0.413911060433295,
"w": 0.174929463925836,
"h": 0.0216647662485747
}
},
{
"name": "quantity",
"category": "details",
"value": 1,
"type": "number",
"page": 1,
"confidence": 0.638236153693426,
"coordinates": {
"x": 0.102378073357517,
"y": 0.42018244013683,
"w": 0.0270052398226522,
"h": 0.00826681870011403
}
},
{
"name": "netAmount",
"category": "amounts",
"value": 85,
"type": "number",
"page": 1,
"confidence": 0.63175144701293,
"coordinates": {
"x": 0.869407496977025,
"y": 0.419612314709236,
"w": 0.0447400241837969,
"h": 0.00940706955530213
}
},
{
"name": "unitPrice",
"category": "details",
"value": 85,
"type": "number",
"page": 1,
"confidence": 0.638240830464797,
"coordinates": {
"x": 0.609834744054817,
"y": 0.419612314709236,
"w": 0.0447400241837969,
"h": 0.00940706955530213
}
},
{
"name": "materialNumber",
"category": "details",
"value": null,
"type": "string",
"page": 1,
"confidence": null,
"coordinates": {
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
}
]
]
},
"fileType": "pdf",
"enrichment": {
"sender": [
{
"id": "BE0001",
"confidence": 0.5625
},
{
"id": "BE0002",
"confidence": 0.4625
}
],
"employee": []
}
}
You have now successfully used the business entity to get enrichment data predictions for the document you uploaded to Document Information Extraction.