General Invoice OCR
Extract invoice information from image
Response Definition
200
-
-
400
1001
Too low image resolution (image must be base64 and image size must between 500x500 and 10000x10000)
400
1002
Image quality not acceptable (image must be base64 and image size must between 500x500 and 10000x10000)
400
1003
cannot convert image please check your image (image must be base64 and image size must between 500x500 and 10000x10000)
500
2001
some error occur in serverside
List of key
invoice_net_amount_word
type_doc
seller_address
buyer_name
branch_buyer
buyer_address
buyer_tax_id_no
tax_invoice_id
seller_tax_id_no
book_no
branch_seller
branch_seller_no
invoice_id
invoice_net_amount
total_tax
invoice_amout
date
seller_name
discount
seller_phone_number
comission
provincial_tax
non_vatable
service_chrage
tax_withholding
po_number
branch_buyer_no
Extract invoice information from image
POST
https://apis.aigen.online/aiscript/general-invoice/v1
Request Body
image*
String
Base64 image encoded string
{
"response_id": "996b3cf298d546adb97c719711504e58",
"status": "1",
"message": "success",
"data": [
{
"key": "invoice_net_amount",
"value": "2,603.00",
"rect": [
1751,
95,
25
],
"rect_norm": [
0.8694074969770254,
0.7486105173150919,
0.05743651753325272,
0.010688328345446772
],
"confidence": 0.9977123737335205
},
{
"key": "invoice_net_amount_word",
"value": "สองพันหกร้อยสามบาทถ้วนTWO THOUSAND, SIX HUNDRED AND THREE BAHT",
"rect": [
1043,
1826,
492,
72
],
"rect_norm": [
0.7648125755743652,
0.7806755023514322,
0.1626360338573156,
0.012825994014536126
],
"confidence": 0.9982241988182068
},
{
"key": "type_doc",
"value": "ใบเสร็จรับเงิน/ใบกำกับภาษีRECEIPT/TAX INVOICE",
"rect": [
1152,
198,
302,
86
],
"rect_norm": [
0.6964933494558646,
0.08465156049593843,
0.1825876662636034,
0.01581872595126122
],
"confidence": 0.9964017069005138
},
{
"key": "seller_address",
"value": "89 ALA CAPITAL CENTER, 24TH FLOOR RATCHADAPISEK ROADDINDAENG SUB-DISTRICT DINDAENG DISTRICT BANGKOK 10400",
"rect": [
393,
250,
597,
72
],
"rect_norm": [
0.23941958887545345,
0.10688328345446772,
0.3567110036275695,
0.012825994014536126
],
"confidence": 0.9966099804959399
},
{
"key": "buyer_name",
"value": "บริษัท มายคอรเปอร์เรชัน จำกัด",
"rect": [
509,
418,
307,
30
],
"rect_norm": [
0.30773881499395406,
0.17870884993587002,
0.18561064087061668,
0.012825994014536126
],
"confidence": 0.9788598463525915
},
{
"key": "buyer_address",
"value": "1941 แขวง คลองตัน เขต คลองเตย กรุงเทพมหานคร10110",
"rect": [
509,
458,
509,
70
],
"rect_norm": [
0.30773881499395406,
0.19581017528858485,
0.12696493349455865,
0.012825994014536126
],
"confidence": 0.9852892125990116
},
{
"key": "buyer_tax_id_no",
"value": "0105560049211",
"rect": [
507,
580,
175,
28
],
"rect_norm": [
0.30652962515114873,
0.2479692176143651,
0.10580411124546554,
0.011970927746900385
],
"confidence": 0.9942404956960829
},
{
"key": "invoice_id",
"value": "2021061300233520210613002335",
"rect": [
1278,
421,
190,
28
],
"rect_norm": [
0.7726723095525998,
0.17999144933732364,
0.11487303506650544,
0.011970927746900385
],
"confidence": 0.99785315990448
},
{
"key": "seller_tax_id_no",
"value": "0105558019581",
"rect": [
704,
332,
167,
25
],
"rect_norm": [
0.42563482466747277,
0.14194100042753313,
0.10096735187424426,
0.010688328345446772
],
"confidence": 0.5247059455969776
},
{
"key": "branch_seller",
"value": "HEAD OFFICEHEAD OFFICE",
"rect": [
879,
332,
132,
25
],
"rect_norm": [
0.5314389359129383,
0.14194100042753313,
0.07980652962515115,
0.010688328345446772
],
"confidence": 0.9596424267097916
},
{
"key": "total_tax",
"value": "170.29",
"rect": [
1455,
1712,
79,
25
],
"rect_norm": [
0.8796856106408706,
0.731936725096195,
0.047762998790810154,
0.010688328345446772
],
"confidence": 0.9982433784044531
},
{
"key": "invoice_amout",
"value": "2,432.71",
"rect": [
1438,
1590,
92,
28
],
"rect_norm": [
0.8694074969770254,
0.6797776827704147,
0.05562273276904474,
0.011970927746900385
],
"confidence": 0.9933148641428211
},
{
"key": "date",
"value": "13/06/2021",
"rect": [
1278,
460,
129,
28
],
"rect_norm": [
0.7726723095525998,
0.19666524155622062,
0.07799274486094317,
0.011970927746900385
],
"confidence": 0.9722278149211618
},
{
"key": "seller_name",
"value": "SHOPEE (THAILAND) CO., LTD.",
"rect": [
517,
208,
348,
32
],
"rect_norm": [
0.31257557436517536,
0.08892689183411714,
0.21039903264812576,
0.013681060282171868
],
"confidence": 0.98518804741623
},
{
"key": "discount",
"value": "0.00",
"rect": [
1483,
1632,
51,
23
],
"rect_norm": [
0.8966142684401451,
0.6977340743907653,
0.03083434099153567,
0.00983326207781103
],
"confidence": 0.9955986272333632
},
{
"key": "seller_phone_number",
"value": "+66-21189195",
"rect": [
423,
332,
152,
25
],
"rect_norm": [
0.25574365175332525,
0.14194100042753313,
0.09189842805320435,
0.010688328345446772
],
"confidence": 0.9737620667593774
}
],
"table_data": [
{
"row_data": [
{
"key": "table_description",
"value": "SERVICE FEE",
"rect": [
269,
746,
124,
28
],
"rect_norm": [
0.1626360338573156,
0.3189397178281317,
0.07496977025392987,
0.011970927746900385
],
"confidence": 0.9963712666051805
},
{
"key": "table_price_per_unit",
"value": "1,575.70",
"rect": [
1278,
748,
95,
28
],
"rect_norm": [
0.7726723095525998,
0.31979478409576745,
0.05743651753325272,
0.011970927746900385
],
"confidence": 0.9945479814639384
},
{
"key": "table_amount",
"value": "1,575.70",
"rect": [
1438,
748,
97,
28
],
"rect_norm": [
0.8694074969770254,
0.31979478409576745,
0.058645707376058044,
0.011970927746900385
],
"confidence": 0.9954840713548947
},
{
"key": "table_quantity",
"value": "1",
"rect": [
1162,
750,
14,
18
],
"rect_norm": [
0.7025392986698912,
0.32064985036340315,
0.008464328899637243,
0.007695596408721676
],
"confidence": 0.9905359360361743
},
{
"key": "table_item_number",
"value": "1",
"rect": [
203,
753,
13,
16
],
"rect_norm": [
0.12273276904474002,
0.3219324497648568,
0.007859733978234583,
0.006840530141085934
],
"confidence": 0.9889791441457447
}
],
"row_info": {
"mean_topleft_x": 870,
"mean_topleft_y": 749,
"count_col": 5,
"rect": [
203,
746,
1332,
30
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "TRANSACTION FEE",
"rect": [
269,
788,
173,
25
],
"rect_norm": [
0.1626360338573156,
0.33689610944848225,
0.10459492140266022,
0.010688328345446772
],
"confidence": 0.9657038853159085
},
{
"key": "table_price_per_unit",
"value": "857.01",
"rect": [
1296,
788,
76,
25
],
"rect_norm": [
0.7835550181378477,
0.33689610944848225,
0.045949214026602174,
0.010688328345446772
],
"confidence": 0.9909099699002581
},
{
"key": "table_amount",
"value": "857.01",
"rect": [
1455,
788,
76,
25
],
"rect_norm": [
0.8796856106408706,
0.33689610944848225,
0.045949214026602174,
0.010688328345446772
],
"confidence": 0.9899769360361788
},
{
"key": "table_quantity",
"value": "1",
"rect": [
1162,
792,
14,
16
],
"rect_norm": [
0.7025392986698912,
0.3386062419837537,
0.008464328899637243,
0.006840530141085934
],
"confidence": 0.971374655652113
},
{
"key": "table_item_number",
"value": "2",
"rect": [
201,
790,
19,
21
],
"rect_norm": [
0.1215235792019347,
0.337751175716118,
0.011487303506650543,
0.00897819581017529
],
"confidence": 0.9888069033622742
}
],
"row_info": {
"mean_topleft_x": 876.6,
"mean_topleft_y": 789.2,
"count_col": 5,
"rect": [
201,
788,
1330,
25
]
}
}
],
"table_dict": {
"description": {
"0": "VATIS REVAMP NEW VERSION: CONTRACT SIGNED 10% OF TOTAL APPLICATION DEVELOPMENT",
"1": "VATIS REVAMP NEW VERSION: M1 DELIVERY NEW VATIS SPRINT#1 20% OF TOTAL APPLICATION DEVELOPMENT"
},
"price_per_unit": {
"0": "253,600.00 ",
"1": "507,200.00 "
},
"amount": {
"0": "253,600.00 ",
"1": "507,200.00 "
}
},
"request_id": "996b3cf298d546adb97c719711504e11",
"list_data_by_page": [
{
"data": [
{
"key": "eng_seller_address",
"value": "PLOT NO. 2801/3A&B,2802/B,2803/2 2804 & INO:28562431347 PHASE 6-243078 PI 396195 INDIA",
"rect": [
36,
133,
709,
74
],
"rect_norm": [
0.026602176541717048,
0.05686190679777683,
0.3355501813784764,
0.011970927746900385
],
"confidence": 0.8955790217608346
},
{
"key": "invoice_id",
"value": "TAX 0000000 000000 000000",
"rect": [
790,
86,
443,
51
],
"rect_norm": [
0.47762998790810157,
0.04660111158614793,
0.10096735187424426,
0.011970927746900385
],
"confidence": 0.6514289251935299
},
{
"key": "date",
"value": "26.11.2021",
"rect": [
970,
109,
129,
28
],
"rect_norm": [
0.5864570737605804,
0.04660111158614793,
0.07799274486094317,
0.011970927746900385
],
"confidence": 0.9487718941861658
}
],
"table_data": [
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1167,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.4989311671654553,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.9730473621571569
},
{
"key": "table_description",
"value": "63UF4010/5P4",
"rect": [
348,
1167,
147,
23
],
"rect_norm": [
0.21039903264812576,
0.4989311671654553,
0.08887545344619105,
0.00983326207781103
],
"confidence": 0.9056909297580447
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1167,
49,
23
],
"rect_norm": [
0.6644498186215235,
0.4989311671654553,
0.02962515114873035,
0.00983326207781103
],
"confidence": 0.9796233193663113
},
{
"key": "table_price_per_unit",
"value": "1.20",
"rect": [
1298,
1167,
46,
23
],
"rect_norm": [
0.7847642079806529,
0.4989311671654553,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.6961355666033597
},
{
"key": "table_amount",
"value": "6.00",
"rect": [
1472,
1167,
46,
23
],
"rect_norm": [
0.8899637243047158,
0.4989311671654553,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.9349299091511654
}
],
"row_info": {
"mean_topleft_x": 852,
"mean_topleft_y": 1167,
"count_col": 5,
"rect": [
43,
1167,
1475,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX INTENSIVE CYAN",
"rect": [
348,
1190,
279,
23
],
"rect_norm": [
0.21039903264812576,
0.5087644292432664,
0.1686819830713422,
0.00983326207781103
],
"confidence": 0.9371049222153687
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1190,
"count_col": 1,
"rect": [
348,
1190,
279,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1237,
29,
25
],
"rect_norm": [
0.02599758162031439,
0.5288584865327063,
0.017533252720677146,
0.010688328345446772
],
"confidence": 0.9379263894302916
},
{
"key": "table_description",
"value": "61UF7832/5P4",
"rect": [
350,
1237,
145,
25
],
"rect_norm": [
0.21160822249093109,
0.5288584865327063,
0.08766626360338574,
0.010688328345446772
],
"confidence": 0.9633641799157893
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1237,
86,
25
],
"rect_norm": [
0.6644498186215235,
0.5288584865327063,
0.05199516324062878,
0.010688328345446772
],
"confidence": 0.8331578267410791
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
1237,
57,
25
],
"rect_norm": [
0.8827085852478839,
0.5288584865327063,
0.034461910519951636,
0.010688328345446772
],
"confidence": 0.606960381186326
}
],
"row_info": {
"mean_topleft_x": 738,
"mean_topleft_y": 1237,
"count_col": 4,
"rect": [
43,
1237,
1474,
25
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX YELLOW 7832",
"rect": [
348,
1260,
373,
25
],
"rect_norm": [
0.21039903264812576,
0.5386917486105173,
0.22551390568319227,
0.010688328345446772
],
"confidence": 0.9204687455977449
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1260,
"count_col": 1,
"rect": [
348,
1260,
373,
25
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1309,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.559640872167593,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.9263947203195251
},
{
"key": "table_description",
"value": "61UF7855/5P4",
"rect": [
350,
1309,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.559640872167593,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9977670398318992
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1309,
49,
23
],
"rect_norm": [
0.6644498186215235,
0.559640872167593,
0.02962515114873035,
0.00983326207781103
],
"confidence": 0.7917274444378037
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
1309,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.559640872167593,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9863346815109253
}
],
"row_info": {
"mean_topleft_x": 738,
"mean_topleft_y": 1309,
"count_col": 4,
"rect": [
43,
1309,
1474,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX ORANGE 7855",
"rect": [
348,
1333,
373,
23
],
"rect_norm": [
0.21039903264812576,
0.5699016673792219,
0.22551390568319227,
0.00983326207781103
],
"confidence": 0.971683523900353
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1333,
"count_col": 1,
"rect": [
348,
1333,
373,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1380,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.5899957246686618,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.9240150636080138
},
{
"key": "table_description",
"value": "61UF7875/5P4",
"rect": [
350,
1380,
145,
25
],
"rect_norm": [
0.21160822249093109,
0.5899957246686618,
0.08766626360338574,
0.010688328345446772
],
"confidence": 0.9983814236732087
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1380,
86,
25
],
"rect_norm": [
0.6644498186215235,
0.5899957246686618,
0.05199516324062878,
0.010688328345446772
],
"confidence": 0.8541316761783335
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
1380,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.5899957246686618,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9899071317721777
}
],
"row_info": {
"mean_topleft_x": 738,
"mean_topleft_y": 1380,
"count_col": 4,
"rect": [
43,
1380,
1474,
25
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX YELLOW 7875",
"rect": [
348,
1403,
370,
23
],
"rect_norm": [
0.21039903264812576,
0.5998289867464729,
0.22370012091898428,
0.00983326207781103
],
"confidence": 0.990549547974723
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1403,
"count_col": 1,
"rect": [
348,
1403,
370,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
44,
1452,
28,
23
],
"rect_norm": [
0.026602176541717048,
0.6207781103035486,
0.016928657799274487,
0.00983326207781103
],
"confidence": 0.9478721305174247
},
{
"key": "table_description",
"value": "62UF7830/5P4",
"rect": [
350,
1452,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.6207781103035486,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9986496739343913
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1452,
86,
23
],
"rect_norm": [
0.6644498186215235,
0.6207781103035486,
0.05199516324062878,
0.00983326207781103
],
"confidence": 0.8470237851142883
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
1452,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.6207781103035486,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9933968134767213
}
],
"row_info": {
"mean_topleft_x": 738.25,
"mean_topleft_y": 1452,
"count_col": 4,
"rect": [
44,
1452,
1473,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX RED 7830",
"rect": [
348,
1473,
324,
23
],
"rect_norm": [
0.21039903264812576,
0.6297563061137238,
0.19588875453446192,
0.00983326207781103
],
"confidence": 0.9859210761064681
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1473,
"count_col": 1,
"rect": [
348,
1473,
324,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1522,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.6507054296707995,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.9390739069509983
},
{
"key": "table_description",
"value": "62UF7831/5P4",
"rect": [
348,
1522,
147,
23
],
"rect_norm": [
0.21039903264812576,
0.6507054296707995,
0.08887545344619105,
0.00983326207781103
],
"confidence": 0.9987563442718042
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1522,
84,
21
],
"rect_norm": [
0.6644498186215235,
0.6507054296707995,
0.05078597339782346,
0.00897819581017529
],
"confidence": 0.8824222087860107
},
{
"key": "table_amount",
"value": "10.20",
"rect": [
1460,
1522,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.6507054296707995,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9932301755581534
}
],
"row_info": {
"mean_topleft_x": 737.5,
"mean_topleft_y": 1522,
"count_col": 4,
"rect": [
43,
1522,
1474,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX RED 7831",
"rect": [
348,
1546,
322,
21
],
"rect_norm": [
0.21039903264812576,
0.6609662248824284,
0.1946795646916566,
0.00897819581017529
],
"confidence": 0.9769989120156737
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1546,
"count_col": 1,
"rect": [
348,
1546,
322,
21
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
1592,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.6806327490380505,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.9336142598188282
},
{
"key": "table_description",
"value": "63UF7826/5P4",
"rect": [
350,
1592,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.6806327490380505,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9986338019371033
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1592,
86,
23
],
"rect_norm": [
0.6644498186215235,
0.6806327490380505,
0.05199516324062878,
0.00983326207781103
],
"confidence": 0.8997417737416527
},
{
"key": "table_amount",
"value": "15.05",
"rect": [
1460,
1592,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.6806327490380505,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9853072166442871
}
],
"row_info": {
"mean_topleft_x": 738,
"mean_topleft_y": 1592,
"count_col": 4,
"rect": [
43,
1592,
1474,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX VIOLET 7826",
"rect": [
350,
1616,
357,
25
],
"rect_norm": [
0.21160822249093109,
0.6908935442496793,
0.2158403869407497,
0.010688328345446772
],
"confidence": 0.9751864593212289
}
],
"row_info": {
"mean_topleft_x": 350,
"mean_topleft_y": 1616,
"count_col": 1,
"rect": [
350,
1616,
357,
25
]
}
}
],
"table_dict": {
"item_number": {
"0": "02 ",
"1": "02 ",
"2": "02 ",
"3": "02 ",
"4": "02 ",
"5": "02 ",
"6": "02 "
},
"description": {
"0": "63UF4010/5P4 NEWV FLEX INTENSIVE CYAN",
"1": "61UF7832/5P4 NEWV FLEX CRSMAXX YELLOW 7832",
"2": "61UF7855/5P4 NEWV FLEX CRSMAXX ORANGE 7855",
"3": "61UF7875/5P4 NEWV FLEX CRSMAXX YELLOW 7875",
"4": "62UF7830/5P4 NEWV FLEX CRSMAXX RED 7830",
"5": "62UF7831/5P4 NEWV FLEX CRSMAXX RED 7831",
"6": "63UF7826/5P4 NEWV FLEX CRSMAXX VIOLET 7826"
},
"quantity": {
"0": "5.00 ",
"1": "5.00 ",
"2": "5.00 ",
"3": "5.00 ",
"4": "5.00 ",
"5": "5.00 ",
"6": "5.00 "
},
"price_per_unit": {
"0": "1.20 ",
"1": " ",
"2": " ",
"3": " ",
"4": " ",
"5": " ",
"6": " "
},
"amount": {
"0": "6.00 ",
"1": "10.00 ",
"2": "10.00 ",
"3": "10.00 ",
"4": "10.00 ",
"5": "10.20 ",
"6": "15.05 "
}
}
},
{
"data": [
{
"key": "invoice_net_amount_word",
"value": "S ONE HUNDRED SEVENTY FOUR AND TWENTY FIVE CENTS ONLY",
"rect": [
114,
1721,
885,
30
],
"rect_norm": [
0.06892382103990327,
0.7366395895681915,
0.3899637243047158,
0.011970927746900385
],
"confidence": 0.9709082165247417
},
{
"key": "type_doc",
"value": "INVOICE",
"rect": [
664,
56,
129,
28
],
"rect_norm": [
0.4014510278113664,
0.02394185549380077,
0.07799274486094317,
0.011970927746900385
],
"confidence": 0.9876232147216797
},
{
"key": "invoice_id",
"value": "VP",
"rect": [
790,
107,
38,
28
],
"rect_norm": [
0.47762998790810157,
0.04574604531851219,
0.022974607013301087,
0.011970927746900385
],
"confidence": 0.6668250645594398
},
{
"key": "invoice_net_amount",
"value": "174.25",
"rect": [
1432,
1677,
84,
25
],
"rect_norm": [
0.8657799274486094,
0.7169730654125694,
0.05078597339782346,
0.010688328345446772
],
"confidence": 0.9973289370536804
},
{
"key": "date",
"value": "26.11.2021",
"rect": [
970,
107,
129,
28
],
"rect_norm": [
0.5864570737605804,
0.04574604531851219,
0.07799274486094317,
0.011970927746900385
],
"confidence": 0.9158821870346223
}
],
"table_data": [
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
308,
29,
25
],
"rect_norm": [
0.02599758162031439,
0.13168020521590423,
0.017533252720677146,
0.010688328345446772
],
"confidence": 0.8980279274991503
},
{
"key": "table_description",
"value": "63UF7836/5P4",
"rect": [
350,
308,
145,
25
],
"rect_norm": [
0.21160822249093109,
0.13168020521590423,
0.08766626360338574,
0.010688328345446772
],
"confidence": 0.9962537825124258
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
308,
49,
25
],
"rect_norm": [
0.6644498186215235,
0.13168020521590423,
0.02962515114873035,
0.010688328345446772
],
"confidence": 0.976565957069397
},
{
"key": "table_price_per_unit",
"value": "2.00",
"rect": [
1298,
308,
46,
25
],
"rect_norm": [
0.7847642079806529,
0.13168020521590423,
0.02781136638452237,
0.010688328345446772
],
"confidence": 0.7874541694571301
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
308,
57,
25
],
"rect_norm": [
0.8827085852478839,
0.13168020521590423,
0.034461910519951636,
0.010688328345446772
],
"confidence": 0.9640883861703244
}
],
"row_info": {
"mean_topleft_x": 850,
"mean_topleft_y": 308,
"count_col": 5,
"rect": [
43,
308,
1474,
25
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX CYAN 7836",
"rect": [
348,
334,
342,
23
],
"rect_norm": [
0.21039903264812576,
0.14279606669516887,
0.2067714631197098,
0.00983326207781103
],
"confidence": 0.9644901942614297
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 334,
"count_col": 1,
"rect": [
348,
334,
342,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
381,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.1628901239846088,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.7318244718199658
},
{
"key": "table_description",
"value": "64UF7822/5P4",
"rect": [
348,
381,
147,
23
],
"rect_norm": [
0.21039903264812576,
0.1628901239846088,
0.08887545344619105,
0.00983326207781103
],
"confidence": 0.9931674777432988
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
381,
84,
21
],
"rect_norm": [
0.6644498186215235,
0.1628901239846088,
0.05078597339782346,
0.00897819581017529
],
"confidence": 0.9710646271705627
},
{
"key": "table_amount",
"value": "12.50",
"rect": [
1460,
381,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.1628901239846088,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9930448532104492
}
],
"row_info": {
"mean_topleft_x": 737.5,
"mean_topleft_y": 381,
"count_col": 4,
"rect": [
43,
381,
1474,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX GREEN 7822",
"rect": [
348,
404,
350,
21
],
"rect_norm": [
0.21039903264812576,
0.17272338606241983,
0.21160822249093109,
0.00897819581017529
],
"confidence": 0.9936475097972348
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 404,
"count_col": 1,
"rect": [
348,
404,
350,
21
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "02",
"rect": [
43,
453,
29,
21
],
"rect_norm": [
0.02599758162031439,
0.1936725096194955,
0.017533252720677146,
0.00897819581017529
],
"confidence": 0.7987812475906999
},
{
"key": "table_description",
"value": "63UF7818/5P4",
"rect": [
350,
453,
145,
21
],
"rect_norm": [
0.21160822249093109,
0.1936725096194955,
0.08766626360338574,
0.00897819581017529
],
"confidence": 0.9923581276237883
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
453,
86,
21
],
"rect_norm": [
0.6644498186215235,
0.1936725096194955,
0.05199516324062878,
0.00897819581017529
],
"confidence": 0.9789652824401855
},
{
"key": "table_amount",
"value": "7.00",
"rect": [
1472,
453,
46,
21
],
"rect_norm": [
0.8899637243047158,
0.1936725096194955,
0.02781136638452237,
0.00897819581017529
],
"confidence": 0.9917820389504755
}
],
"row_info": {
"mean_topleft_x": 741,
"mean_topleft_y": 453,
"count_col": 4,
"rect": [
43,
453,
1475,
21
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAX REFLEX BLUE 7818",
"rect": [
350,
474,
415,
23
],
"rect_norm": [
0.21160822249093109,
0.2026507054296708,
0.250906892382104,
0.00983326207781103
],
"confidence": 0.9870236362935998
}
],
"row_info": {
"mean_topleft_x": 350,
"mean_topleft_y": 474,
"count_col": 1,
"rect": [
350,
474,
415,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
523,
29,
21
],
"rect_norm": [
0.02599758162031439,
0.22359982898674646,
0.017533252720677146,
0.00897819581017529
],
"confidence": 0.6134171723503314
},
{
"key": "table_description",
"value": "67UF0002/5P4",
"rect": [
350,
523,
145,
21
],
"rect_norm": [
0.21160822249093109,
0.22359982898674646,
0.08766626360338574,
0.00897819581017529
],
"confidence": 0.9911916784515391
},
{
"key": "table_quantity",
"value": "10.00",
"rect": [
1089,
523,
95,
21
],
"rect_norm": [
0.658403869407497,
0.22359982898674646,
0.05743651753325272,
0.00897819581017529
],
"confidence": 0.9603376622328312
},
{
"key": "table_amount",
"value": "15.00",
"rect": [
1460,
523,
57,
21
],
"rect_norm": [
0.8827085852478839,
0.22359982898674646,
0.034461910519951636,
0.00897819581017529
],
"confidence": 0.9939995945598383
}
],
"row_info": {
"mean_topleft_x": 735.5,
"mean_topleft_y": 523,
"count_col": 4,
"rect": [
43,
523,
1474,
21
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX OPAQUE BRIGHT WHITE",
"rect": [
348,
544,
383,
25
],
"rect_norm": [
0.21039903264812576,
0.23257802479692177,
0.23155985489721886,
0.010688328345446772
],
"confidence": 0.991164942067364
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 544,
"count_col": 1,
"rect": [
348,
544,
383,
25
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
591,
28,
21
],
"rect_norm": [
0.02599758162031439,
0.2526720820863617,
0.016928657799274487,
0.00897819581017529
],
"confidence": 0.7326175067141776
},
{
"key": "table_description",
"value": "60UF7850/5P4",
"rect": [
350,
591,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.2526720820863617,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9971935841961788
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
591,
86,
23
],
"rect_norm": [
0.6644498186215235,
0.2526720820863617,
0.05199516324062878,
0.00983326207781103
],
"confidence": 0.969123363494873
},
{
"key": "table_amount",
"value": "5.25",
"rect": [
1472,
591,
46,
23
],
"rect_norm": [
0.8899637243047158,
0.2526720820863617,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.954589076765302
}
],
"row_info": {
"mean_topleft_x": 741,
"mean_topleft_y": 591,
"count_col": 4,
"rect": [
43,
591,
1475,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX TRANS WHITE 7850",
"rect": [
348,
615,
426,
25
],
"rect_norm": [
0.21039903264812576,
0.2629328772979906,
0.25755743651753327,
0.010688328345446772
],
"confidence": 0.9880709914576542
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 615,
"count_col": 1,
"rect": [
348,
615,
426,
25
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
661,
29,
25
],
"rect_norm": [
0.02599758162031439,
0.2825994014536127,
0.017533252720677146,
0.010688328345446772
],
"confidence": 0.7605792087298084
},
{
"key": "table_description",
"value": "61UF401OR/5P4",
"rect": [
350,
661,
158,
25
],
"rect_norm": [
0.21160822249093109,
0.2825994014536127,
0.09552599758162031,
0.010688328345446772
],
"confidence": 0.9699182347376407
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
661,
86,
25
],
"rect_norm": [
0.6644498186215235,
0.2825994014536127,
0.05199516324062878,
0.010688328345446772
],
"confidence": 0.9746928394924623
},
{
"key": "table_amount",
"value": "6.00",
"rect": [
1472,
664,
46,
23
],
"rect_norm": [
0.8899637243047158,
0.28388200085506626,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.9940298706909658
}
],
"row_info": {
"mean_topleft_x": 741,
"mean_topleft_y": 661.75,
"count_col": 4,
"rect": [
43,
661,
1475,
26
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX INTENSIVE YELLOW",
"rect": [
348,
687,
342,
23
],
"rect_norm": [
0.21039903264812576,
0.2937152629328773,
0.2067714631197098,
0.00983326207781103
],
"confidence": 0.9855492762484985
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 687,
"count_col": 1,
"rect": [
348,
687,
342,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
734,
28,
23
],
"rect_norm": [
0.02599758162031439,
0.3138093202223172,
0.016928657799274487,
0.00983326207781103
],
"confidence": 0.7716353550438271
},
{
"key": "table_description",
"value": "62UF4010/5P4",
"rect": [
350,
734,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.3138093202223172,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9966525107505433
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
734,
86,
23
],
"rect_norm": [
0.6644498186215235,
0.3138093202223172,
0.05199516324062878,
0.00983326207781103
],
"confidence": 0.9306427452416557
},
{
"key": "table_amount",
"value": "6.00",
"rect": [
1472,
734,
46,
23
],
"rect_norm": [
0.8899637243047158,
0.3138093202223172,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.9947748542324888
}
],
"row_info": {
"mean_topleft_x": 741,
"mean_topleft_y": 734,
"count_col": 4,
"rect": [
43,
734,
1475,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX INTENSIVE MAGENTA",
"rect": [
348,
757,
325,
23
],
"rect_norm": [
0.21039903264812576,
0.32364258230012827,
0.19649334945586458,
0.00983326207781103
],
"confidence": 0.9455815831909327
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 757,
"count_col": 1,
"rect": [
348,
757,
325,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "69UF40T075P4",
"rect": [
350,
806,
145,
21
],
"rect_norm": [
0.21160822249093109,
0.34459170585720394,
0.08766626360338574,
0.00897819581017529
],
"confidence": 0.9621244417866066
},
{
"key": "table_quantity",
"value": "3.006",
"rect": [
1099,
806,
84,
21
],
"rect_norm": [
0.6644498186215235,
0.34459170585720394,
0.05078597339782346,
0.00897819581017529
],
"confidence": 0.9755281150803476
},
{
"key": "table_amount",
"value": "5.25",
"rect": [
1470,
806,
47,
21
],
"rect_norm": [
0.8887545344619106,
0.34459170585720394,
0.028415961305925032,
0.00897819581017529
],
"confidence": 0.9743045328389002
}
],
"row_info": {
"mean_topleft_x": 973,
"mean_topleft_y": 806,
"count_col": 3,
"rect": [
350,
806,
1167,
21
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX INTENSIVE BLACK",
"rect": [
348,
828,
291,
21
],
"rect_norm": [
0.21039903264812576,
0.3539974348011971,
0.1759371221281741,
0.00897819581017529
],
"confidence": 0.9751233739940943
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 828,
"count_col": 1,
"rect": [
348,
828,
291,
21
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "61UF7874/5P4",
"rect": [
350,
877,
145,
23
],
"rect_norm": [
0.21160822249093109,
0.3749465583582728,
0.08766626360338574,
0.00983326207781103
],
"confidence": 0.9945035077240085
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
877,
84,
23
],
"rect_norm": [
0.6644498186215235,
0.3749465583582728,
0.05078597339782346,
0.00983326207781103
],
"confidence": 0.9789200926840493
},
{
"key": "table_amount",
"value": "10.00",
"rect": [
1460,
877,
57,
23
],
"rect_norm": [
0.8827085852478839,
0.3749465583582728,
0.034461910519951636,
0.00983326207781103
],
"confidence": 0.9889295345696496
}
],
"row_info": {
"mean_topleft_x": 969.6666666666666,
"mean_topleft_y": 877,
"count_col": 3,
"rect": [
350,
877,
1167,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX YELLOW 7874",
"rect": [
350,
898,
368,
23
],
"rect_norm": [
0.21160822249093109,
0.38392475416844807,
0.22249093107617895,
0.00983326207781103
],
"confidence": 0.9788451448007542
}
],
"row_info": {
"mean_topleft_x": 350,
"mean_topleft_y": 898,
"count_col": 1,
"rect": [
350,
898,
368,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
947,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.40487387772552375,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.7835679336213595
},
{
"key": "table_description",
"value": "67UF7840/5P4",
"rect": [
348,
947,
147,
23
],
"rect_norm": [
0.21039903264812576,
0.40487387772552375,
0.08887545344619105,
0.00983326207781103
],
"confidence": 0.9969754760154643
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
947,
84,
21
],
"rect_norm": [
0.6644498186215235,
0.40487387772552375,
0.05078597339782346,
0.00897819581017529
],
"confidence": 0.9820130467414856
},
{
"key": "table_amount",
"value": "5.50",
"rect": [
1472,
947,
46,
23
],
"rect_norm": [
0.8899637243047158,
0.40487387772552375,
0.02781136638452237,
0.00983326207781103
],
"confidence": 0.9931533336639404
}
],
"row_info": {
"mean_topleft_x": 740.5,
"mean_topleft_y": 947,
"count_col": 4,
"rect": [
43,
947,
1475,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX WHITE 7840",
"rect": [
348,
970,
350,
23
],
"rect_norm": [
0.21039903264812576,
0.41470713980333473,
0.21160822249093109,
0.00983326207781103
],
"confidence": 0.9877554994605333
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 970,
"count_col": 1,
"rect": [
348,
970,
350,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
1017,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.4348011970927747,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.8030805192380264
},
{
"key": "table_description",
"value": "62UF7838/5P4",
"rect": [
348,
1017,
147,
23
],
"rect_norm": [
0.21039903264812576,
0.4348011970927747,
0.08887545344619105,
0.00983326207781103
],
"confidence": 0.9974434448769074
},
{
"key": "table_quantity",
"value": "5.00",
"rect": [
1099,
1017,
86,
23
],
"rect_norm": [
0.6644498186215235,
0.4348011970927747,
0.05199516324062878,
0.00983326207781103
],
"confidence": 0.9125320311970775
},
{
"key": "table_amount",
"value": "8.00",
"rect": [
1470,
1017,
47,
23
],
"rect_norm": [
0.8887545344619106,
0.4348011970927747,
0.028415961305925032,
0.00983326207781103
],
"confidence": 0.9933471081748309
}
],
"row_info": {
"mean_topleft_x": 740,
"mean_topleft_y": 1017,
"count_col": 4,
"rect": [
43,
1017,
1474,
23
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX CRSMAXX MAGENTA 7838",
"rect": [
348,
1040,
388,
23
],
"rect_norm": [
0.21039903264812576,
0.4446344591705857,
0.23458282950423218,
0.00983326207781103
],
"confidence": 0.9810075460098915
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1040,
"count_col": 1,
"rect": [
348,
1040,
388,
23
]
}
},
{
"row_data": [
{
"key": "table_item_number",
"value": "01",
"rect": [
43,
1087,
29,
23
],
"rect_norm": [
0.02599758162031439,
0.46472851646002566,
0.017533252720677146,
0.00983326207781103
],
"confidence": 0.8995438649813607
},
{
"key": "table_description",
"value": "67UF0009/5P4",
"rect": [
348,
1087,
147,
25
],
"rect_norm": [
0.21039903264812576,
0.46472851646002566,
0.08887545344619105,
0.010688328345446772
],
"confidence": 0.9766036790823662
},
{
"key": "table_amount",
"value": "12.50",
"rect": [
1460,
1087,
57,
25
],
"rect_norm": [
0.8827085852478839,
0.46472851646002566,
0.034461910519951636,
0.010688328345446772
],
"confidence": 0.8871843814849854
}
],
"row_info": {
"mean_topleft_x": 617,
"mean_topleft_y": 1087,
"count_col": 3,
"rect": [
43,
1087,
1474,
25
]
}
},
{
"row_data": [
{
"key": "table_description",
"value": "NEWV FLEX WHITE SL HIGH SLIP TONED",
"rect": [
348,
1113,
373,
28
],
"rect_norm": [
0.21039903264812576,
0.4758443779392903,
0.22551390568319227,
0.011970927746900385
],
"confidence": 0.8964600413411716
}
],
"row_info": {
"mean_topleft_x": 348,
"mean_topleft_y": 1113,
"count_col": 1,
"rect": [
348,
1113,
373,
28
]
}
}
],
"table_dict": {
"item_number": {
"0": "02 ",
"1": "02 ",
"2": "02 ",
"3": "01 ",
"4": "01 ",
"5": "01 ",
"6": "01 ",
"7": " ",
"8": " ",
"9": "01 ",
"10": "01 ",
"11": "01 "
},
"description": {
"0": "63UF7836/5P4 NEWV FLEX CRSMAXX CYAN 7836",
"1": "64UF7822/5P4 NEWV FLEX CRSMAXX GREEN 7822",
"2": "63UF7818/5P4 NEWV FLEX CRSMAX REFLEX BLUE 7818",
"3": "67UF0002/5P4 NEWV FLEX OPAQUE BRIGHT WHITE",
"4": "60UF7850/5P4 NEWV FLEX CRSMAXX TRANS WHITE 7850",
"5": "61UF401OR/5P4 NEWV FLEX INTENSIVE YELLOW",
"6": "62UF4010/5P4 NEWV FLEX INTENSIVE MAGENTA",
"7": "69UF40T075P4 NEWV FLEX INTENSIVE BLACK",
"8": "61UF7874/5P4 NEWV FLEX CRSMAXX YELLOW 7874",
"9": "67UF7840/5P4 NEWV FLEX CRSMAXX WHITE 7840",
"10": "62UF7838/5P4 NEWV FLEX CRSMAXX MAGENTA 7838",
"11": "67UF0009/5P4 NEWV FLEX WHITE SL HIGH SLIP TONED"
},
"quantity": {
"0": "5.00 ",
"1": "5.00 ",
"2": "5.00 ",
"3": "10.00 ",
"4": "5.00 ",
"5": "5.00 ",
"6": "5.00 ",
"7": "3.006 ",
"8": "5.00 ",
"9": "5.00 ",
"10": "5.00 ",
"11": " "
},
"price_per_unit": {
"0": "2.00 ",
"1": " ",
"2": " ",
"3": " ",
"4": " ",
"5": " ",
"6": " ",
"7": " ",
"8": " ",
"9": " ",
"10": " ",
"11": " "
},
"amount": {
"0": "10.00 ",
"1": "12.50 ",
"2": "7.00 ",
"3": "15.00 ",
"4": "5.25 ",
"5": "6.00 ",
"6": "6.00 ",
"7": "5.25 ",
"8": "10.00 ",
"9": "5.50 ",
"10": "8.00 ",
"11": "12.50 "
}
}
}
]
},
{
"response_id": "996b3cf298d546adb97c719711504e58",
"status": "0",
"error_list": [
{
"code": "1001",
"message": "Too low image resolution (image must be base64 and image size must between 500x500 and 10000x10000)"
}
],
"request_id": "996b3cf298d546adb97c719711504e11"
}
{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}
{
"response_id": "996b3cf298d546adb97c719711504e57",
"status": "0",
"error_list": [
{
"code": "2001",
"message": "some error occur in serverside"
}
],
"request_id": "996b3cf298d546adb97c719711504e11"
}
Example code
import requests
import json
"https://apis.aigen.online/aiscript/general-invoice/v1"
headers = {"x-aigen-key": "<key>", "content-type": "application/json"}
data = json.dumps({"image": "<base64_string>"})
res = requests.post(api, data=data, headers=headers)
print(res.json())
const axios = require("axios");
const api = "https://apis.aigen.online/aiscript/general-invoice/v1";
const headers = {
"x-aigen-key": "<key>",
};
const data = { image: "<base64_string>" };
axios
.post(api, data, { headers: headers })
.then((res) => {
console.log(res.data);
})
.catch((err) => {
console.error(err.response.data);
});
Last updated