@veryfi/veryfi-sdk 1.1.4 → 1.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +6 -1
- package/.github/workflows/node.js.yml +0 -31
- package/test/deleteDocument.json +0 -4
- package/test/getDocument.json +0 -111
- package/test/getDocuments.json +0 -3509
- package/test/main.test.js +0 -161
- package/test/processDocument.json +0 -153
- package/test/processDocumentUrl.json +0 -183
- package/test/receipt.png +0 -0
- package/test/updateDocument.json +0 -255
package/package.json
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@veryfi/veryfi-sdk",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.5",
|
|
4
4
|
"description": "Node.js module for communicating with the Veryfi OCR API",
|
|
5
5
|
"main": "lib/main.js",
|
|
6
|
+
"typings": "types/main.d.ts",
|
|
6
7
|
"scripts": {
|
|
7
8
|
"test": "jest",
|
|
8
9
|
"doc": "jsdoc -d docs --configure jsconf.json main.js",
|
|
@@ -14,6 +15,10 @@
|
|
|
14
15
|
"Matthew Eng <matthew@veryfi.com>"
|
|
15
16
|
],
|
|
16
17
|
"license": "MIT",
|
|
18
|
+
"files": [
|
|
19
|
+
"lib",
|
|
20
|
+
"types"
|
|
21
|
+
],
|
|
17
22
|
"directories": {
|
|
18
23
|
"lib": "lib",
|
|
19
24
|
"test": "test"
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node
|
|
2
|
-
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
|
|
3
|
-
|
|
4
|
-
name: Node.js CI
|
|
5
|
-
|
|
6
|
-
on:
|
|
7
|
-
push:
|
|
8
|
-
branches: [ main ]
|
|
9
|
-
pull_request:
|
|
10
|
-
branches: [ main ]
|
|
11
|
-
|
|
12
|
-
jobs:
|
|
13
|
-
build:
|
|
14
|
-
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
|
|
17
|
-
strategy:
|
|
18
|
-
matrix:
|
|
19
|
-
node-version: [12.x, 14.x, 16.x]
|
|
20
|
-
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
|
|
21
|
-
|
|
22
|
-
steps:
|
|
23
|
-
- uses: actions/checkout@v2
|
|
24
|
-
- name: Use Node.js ${{ matrix.node-version }}
|
|
25
|
-
uses: actions/setup-node@v2
|
|
26
|
-
with:
|
|
27
|
-
node-version: ${{ matrix.node-version }}
|
|
28
|
-
cache: 'npm'
|
|
29
|
-
- run: npm ci
|
|
30
|
-
- run: npm run build --if-present
|
|
31
|
-
- run: npm test
|
package/test/deleteDocument.json
DELETED
package/test/getDocument.json
DELETED
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"abn_number":"",
|
|
3
|
-
"account_number":"",
|
|
4
|
-
"barcodes":[
|
|
5
|
-
|
|
6
|
-
],
|
|
7
|
-
"bill_to_address":"",
|
|
8
|
-
"bill_to_name":"",
|
|
9
|
-
"card_number":"",
|
|
10
|
-
"category":"Meals",
|
|
11
|
-
"created":"2021-02-04 00:19:07",
|
|
12
|
-
"currency_code":"COP",
|
|
13
|
-
"date":"2021-01-24 19:40:00",
|
|
14
|
-
"delivery_date":"",
|
|
15
|
-
"discount":0.0,
|
|
16
|
-
"document_title":"",
|
|
17
|
-
"document_type":"receipt",
|
|
18
|
-
"due_date":"",
|
|
19
|
-
"external_id":"",
|
|
20
|
-
"id":31727276,
|
|
21
|
-
"img_file_name":"c55c3a43-06ca-4da7-b780-60768d7f6155.jpg",
|
|
22
|
-
"img_thumbnail_url":"https://scdn.veryfi.com/receipts/c55c3a43-06ca-4da7-b780-60768d7f6155_1_t.jpg?Expires=1626052133&Signature=bQfb8nYHxKeQzaibhQv6lznNTM980DXxicImi9PFbb-iP9yejag4mgzacCcaOIoXEQms-L-EzmpHzpI6Y6q8pzfy5vhS8x2KjqZ2N2iGRadolKTsHTfuQCZdC2tassH~0faTnJ9L2NDrPlU97mnc06Nqa6graAj1zJ7uKOITeF4ONhVWVrj1cRM~lOFqwq9Gk5Xf9-uRVQPan0d7gpAbdx1sZE25ImphkzQen5IaduEvd6k4vhlHeqeOfj911Z8ReAXz2MWEgPuRcgj7H9DwHATiQMR6M4ft40d7zBd2TjyKRuSgH~fDfq8CFLLAtxoo6mhaawi-HIZi~4kwFDRQKg__&Key-Pair-Id=APKAJCILBXEJFZF4DCHQ",
|
|
23
|
-
"img_url":"https://scdn.veryfi.com/receipts/c55c3a43-06ca-4da7-b780-60768d7f6155.jpg?Expires=1626052133&Signature=bi4gQP2IOjPy1IsFk4apCdBOQLOOwxWZIM3xPTs-Ojzz7gJEQ5Jt6oc5gcR898rA8FrNJ-1RjzzxMiW5p3lPNcnXyeiWj8IH9HG45cb0M0-TK~YUsFjFRVXpflSN9PB5Xb3R56Mq1HPN2xTCE~o2lhnJyQEK52u--n4nyX4dg7aMQc7DLBuidqFZoB4eNrvPZ7q1uDpT~hcrD5x4i26g7owfiGTKsh60OwpljIcQV61vNqJxcyyVD6Dlk9pl-5MJZGQxUKWeuwY76fg6zUtuUqgRL1he2DKjOSLwNGbLTmFGcNq6R0AvHs45gtyMNKn5SdttvWnQJagHZl4tG8DF7g__&Key-Pair-Id=APKAJCILBXEJFZF4DCHQ",
|
|
24
|
-
"incoterms":"",
|
|
25
|
-
"insurance":"",
|
|
26
|
-
"invoice_number":"1381884",
|
|
27
|
-
"is_document":1,
|
|
28
|
-
"is_money_in":0,
|
|
29
|
-
"line_items":[
|
|
30
|
-
{
|
|
31
|
-
"date":"",
|
|
32
|
-
"description":"MimVaiCucManiChoco",
|
|
33
|
-
"discount":0.0,
|
|
34
|
-
"id":32895461,
|
|
35
|
-
"order":0,
|
|
36
|
-
"price":0.0,
|
|
37
|
-
"quantity":10.0,
|
|
38
|
-
"reference":"",
|
|
39
|
-
"section":"",
|
|
40
|
-
"sku":"",
|
|
41
|
-
"tax":0.0,
|
|
42
|
-
"tax_rate":0.0,
|
|
43
|
-
"total":5900.0,
|
|
44
|
-
"type":"food",
|
|
45
|
-
"unit_of_measure":"",
|
|
46
|
-
"weight":""
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
"date":"",
|
|
50
|
-
"description":"",
|
|
51
|
-
"discount":0.0,
|
|
52
|
-
"id":32895462,
|
|
53
|
-
"order":1,
|
|
54
|
-
"price":0.0,
|
|
55
|
-
"quantity":10.0,
|
|
56
|
-
"reference":"",
|
|
57
|
-
"section":"",
|
|
58
|
-
"sku":"",
|
|
59
|
-
"tax":0.0,
|
|
60
|
-
"tax_rate":0.0,
|
|
61
|
-
"total":5900.0,
|
|
62
|
-
"type":"",
|
|
63
|
-
"unit_of_measure":"",
|
|
64
|
-
"weight":""
|
|
65
|
-
}
|
|
66
|
-
],
|
|
67
|
-
"notes":"",
|
|
68
|
-
"ocr_text":"\nSomos Regimen Comun\nNo Somos Retenedores del IVA\nP.C.A PRODUCTORA Y COMERCIALIZADORA DE\nALIMENTOS S.A.S\nDG 51 35 12 CC PUERTA DEL NORTE\nNIT:890,912,221-4\nFactura de Venta Nro. 859 1381884\nNeg Pto Ter Fecha\tCajero\n001 859 001 24/01/2021 19:40 859\nDescripcion\tCant Valor\nMimVaiCucManiChoco 1.0 5,900.\n* Subtotal *\t\t5,900.\nCantidad Bolsas(*)\t\t0\nImpuesto Bolsas(*)\t\t0\n** T O T A L **\t5,900.\nEFECTIVO\t\t\t20,000.\nCAMBIO\t\t\t14,100.\n%\tBase Imp.\tTotal\n0\t5,900.\t0. 5,900.\nMIMO'S EXITO BELLO TEL 481 05 06\nResolucion Facturacion DIAN Nro\n18763003974691 Feb 4 2020\nAutorizacion Rango 859-1142814 al 859-138\n2856 Vigencia 12 Meses\n",
|
|
69
|
-
"order_date":"",
|
|
70
|
-
"payment_display_name":"Cash",
|
|
71
|
-
"payment_terms":"",
|
|
72
|
-
"payment_type":"cash",
|
|
73
|
-
"phone_number":"",
|
|
74
|
-
"purchase_order_number":"",
|
|
75
|
-
"reference_number":"VBDHC-7276",
|
|
76
|
-
"service_end_date":"",
|
|
77
|
-
"service_start_date":"",
|
|
78
|
-
"ship_date":"",
|
|
79
|
-
"shipping":0.0,
|
|
80
|
-
"subtotal":5900.0,
|
|
81
|
-
"tags":[
|
|
82
|
-
|
|
83
|
-
],
|
|
84
|
-
"tax":0,
|
|
85
|
-
"tax_lines":[
|
|
86
|
-
|
|
87
|
-
],
|
|
88
|
-
"tip":0.0,
|
|
89
|
-
"total":0.0,
|
|
90
|
-
"total_weight":"",
|
|
91
|
-
"tracking_number":"",
|
|
92
|
-
"updated":"2021-02-04 00:19:10",
|
|
93
|
-
"vat_number":"890,912,221-4",
|
|
94
|
-
"vendor":{
|
|
95
|
-
"address":"DG 51 35 12 CC PUERTA DEL NORTE",
|
|
96
|
-
"fax_number":"",
|
|
97
|
-
"name":"P.c.a Productora Y Comercializadora De",
|
|
98
|
-
"phone_number":"",
|
|
99
|
-
"raw_name":"P.C.A PRODUCTORA Y COMERCIALIZADORA DE",
|
|
100
|
-
"vendor_logo":"https://cdn.veryfi.com/logos/tmp/397947509.png",
|
|
101
|
-
"vendor_type":""
|
|
102
|
-
},
|
|
103
|
-
"vendor_account_number":"",
|
|
104
|
-
"vendor_bank_name":"",
|
|
105
|
-
"vendor_bank_number":"",
|
|
106
|
-
"vendor_bank_swift":"",
|
|
107
|
-
"vendor_iban":"",
|
|
108
|
-
"warnings":[
|
|
109
|
-
|
|
110
|
-
]
|
|
111
|
-
}
|