API Documentation
1. Create a New Job
POST https://doc2data.io/api/jobs
URL Query Parameters
Parameter | Description | Required | Sample |
---|---|---|---|
api_key | The API Key for the account | Yes | Your API key |
processor_id | The Processor ID to use | Yes | Create processor first |
Body Parameters
Parameter | Description | Required | Sample |
---|---|---|---|
input_file | The PDF file to process | Yes | A file to upload |
Sample
Request
{ "input_file": "efs_statement_2024_10_12.pdf" }
Response
{ "id": 14, "status": "new" }
2. Check Job Results
GET https://doc2data.io/api/jobs/:job_id
URL Route Parameters
Parameter | Description | Required | Sample |
---|---|---|---|
job_id | The Job ID to retrieve | Yes | Received during job creation process |
URL Query Parameters
Parameter | Description | Required | Sample |
---|---|---|---|
api_key | The API Key for the account | Yes | Your API key |
Sample
Request
{}
Response
{ "id": 14, "status": "completed", "output": "{\"Date\":\"08/29/24\",\"Order\":\"WA489498\"}" }
3. Available Templates
AI (Any Document)
This processor can extract information from any kind of document using AI.
To use this, follow these steps through the web interface:
- Create AI processor
- Specify the fields you want to extract from the document
- For each field, specify the key in the JSON object
- Define the type it has
- Apply a post-processor for correct formatting
- Specify if it is a sub-field of another field
{ "commodity": "Chilled food", "delivery_addresses": [ { "pallets": null, "pieces": 1, "delivery_to_company": "FEDEX-MIDCT", "delivery_date_and_time": "01/30/2023 14:00", "delivery_address": "49 Fedex Dr #49, Middletown, CT 06457" } ], "id_number": "0405727", "pick_up_addresses": [ { "pick_up_from_company": "FACTOR CASTELLINI (KY)", "pick_up_date_and_time": "01/28/2023 13:00", "pick_up_address": "2 Plum St, Wilder, KY 41076" } ], "rate": 3000, "special_instructions": [ "Special instructions here" ], "broker": "AIT Truckload Solutions", "weight": 30000, "temperature": null, "pick_up_order_numbers": [ "CR W05.23SA_KY_FEDEX-MIDCT4", "TN 186533416" ], "delivery_order_numbers": [ "CR W05.23SA_KY_FEDEX-MIDCT4" ], "broker`s address": "PO Box 775379, Chicago, IL 60677-5379" }
EFS Statement
FleetOne Holdings
Description
e-Statement for fuel costs from FleetOne
{ "fleetone_address": "FleetOne Holdings, LLC, PO Box 630038, Cincinnati, OH 45263-0038", "own_address": "ACR Logistics LLC, 460 ZION ROAD, EGG HARBOR TOWNSHIP, NJ 08234", "statement_date": "2024-10-16", "statement_period": { "start": "2024-10-14", "end": "2024-10-16" }, "customer_number": "3770001905718", "statement_number": "80394907", "voice_number": null, "fax": null, "email": "[email protected]", "account_summary": { "overall_credit_limit": 7000, "credit_deposit": 0 }, "payment_summary": { "payment": -2253.29, "total": -2253.29 }, "balance_summary": { "beginning_balance": 2253.29, "payment_total": -2253.29, "balance_after_payments": 0, "statement_total": 2596.38, "ending_account_balance": 2596.38, "past_due_balance": 0 }, "statement_activity": { "reefer": 111.36, "other": 7.95, "diesel": 2406.2, "def": 70.87, "statement_total": 2596.38 }, "ending_account_balance": 2596.38, "statement_due_date": "2024-10-18", "fuel_transaction_summary": { "Diesel": { "count": 5, "total_volume": 742.4, "gross_ppu": 4.25, "sub_total": 3155.26, "discount_amount": 749.06, "net_ppu": 3.24, "total_amount": 2406.2 }, "Reefer": { "count": 2, "total_volume": 33.87, "gross_ppu": 4.03, "sub_total": 136.78, "discount_amount": 25.42, "net_ppu": 3.28, "total_amount": 111.36 }, "Unleaded": { "count": 0, "total_volume": 1, "gross_ppu": 0, "sub_total": 0, "discount_amount": 0, "net_ppu": 0, "total_amount": 0 }, "CNG": { "count": 0, "total_volume": 1, "gross_ppu": 0, "sub_total": 0, "discount_amount": 0, "net_ppu": 0, "total_amount": 0 }, "LNG": { "count": 0, "total_volume": 1, "gross_ppu": 0, "sub_total": 0, "discount_amount": 0, "net_ppu": 0, "total_amount": 0 }, "Propane": { "count": 0, "total_volume": 1, "gross_ppu": 0, "sub_total": 0, "discount_amount": 0, "net_ppu": 0, "total_amount": 0 }, "Kerosene": { "count": 0, "total_volume": 1, "gross_ppu": 0, "sub_total": 0, "discount_amount": 0, "net_ppu": 0, "total_amount": 0 }, "DEF": { "count": 2, "total_volume": 18.69, "gross_ppu": 3.79, "sub_total": 70.87, "discount_amount": 0, "net_ppu": 3.79, "total_amount": 70.87 } }, "statement_details": [ { "date": "2024-10-14", "category": "Beginning Balance 10/14/24", "use": null, "description": null, "card": null, "unit": null, "prompt_data": null, "check_number": null, "location_number": null, "location_name": null, "state": null, "quantity": 0, "gross_ppg": 0, "sales_tax": 0, "fed_tax": 0, "gross_amount": 0, "discrete_amount": 0, "fees": 0, "total_amount": 2253.29 }, { "date": "2024-10-14", "category": "PMT", "use": null, "description": "Payment Receipt", "card": "PMT", "unit": null, "prompt_data": null, "check_number": null, "location_number": null, "location_name": null, "state": null, "quantity": 0, "gross_ppg": 0, "sales_tax": 0, "fed_tax": 0, "gross_amount": 0, "discrete_amount": 0, "fees": 0, "total_amount": -2253.29 }, { "date": "2024-10-15", "category": "OTHER", "use": null, "description": "MONTHLY ACCT MAINT F", "card": "00000", "unit": null, "prompt_data": null, "check_number": "26044837", "location_number": null, "location_name": null, "state": null, "quantity": 1, "gross_ppg": 0, "sales_tax": 0, "fed_tax": 0, "gross_amount": 7.95, "discrete_amount": 0, "fees": 0, "total_amount": 7.95 }, { "date": "2024-10-14", "category": "Diesel", "use": null, "description": "ULTRA LOW SULFUR DIESEL", "card": "00369", "unit": "106", "prompt_data": "N-CARLOSOLIVERA", "check_number": "1309945398", "location_number": "514511", "location_name": "TA WILLINGTON", "state": "CT", "quantity": 152.68, "gross_ppg": 5.399, "sales_tax": 0, "fed_tax": 0, "gross_amount": 824.32, "discrete_amount": 306.73, "fees": 0, "total_amount": 517.59 }, { "date": "2024-10-14", "category": "Diesel", "use": null, "description": "ULTRA LOW SULFUR DIESEL", "card": "00013", "unit": "103", "prompt_data": "N-WALIDELGEDAWY", "check_number": "1310089823", "location_number": "514614", "location_name": "PETRO BORDENTOWN", "state": "NJ", "quantity": 143.92, "gross_ppg": 4.039, "sales_tax": 0, "fed_tax": 0, "gross_amount": 581.28, "discrete_amount": 107.2, "fees": 0, "total_amount": 474.08 }, { "date": "2024-10-15", "category": "DEF", "use": null, "description": "DEF BULK", "card": "00294", "unit": "108", "prompt_data": "N-AnthonyJohnson", "check_number": "1310391169", "location_number": "502045", "location_name": "AUBURN IRVING", "state": "ME", "quantity": 8.37, "gross_ppg": 3.999, "sales_tax": 0, "fed_tax": 0, "gross_amount": 33.46, "discrete_amount": 0, "fees": 0, "total_amount": 33.46 }, { "date": "2024-10-15", "category": "Reefer", "use": null, "description": "REEFER", "card": "00294", "unit": "108", "prompt_data": "N-AnthonyJohnson", "check_number": "1310391169", "location_number": "502045", "location_name": "AUBURN IRVING", "state": "ME", "quantity": 0.03, "gross_ppg": 3.999, "sales_tax": 0, "fed_tax": 0, "gross_amount": 0.12, "discrete_amount": 0.02, "fees": 0, "total_amount": 0.1 }, { "date": "2024-10-15", "category": "Diesel", "use": null, "description": "PRODUCT [ULSD]", "card": "00294", "unit": "108", "prompt_data": "N-AnthonyJohnson", "check_number": "1310391169", "location_number": "502045", "location_name": "AUBURN IRVING", "state": "ME", "quantity": 177.05, "gross_ppg": 3.999, "sales_tax": 0, "fed_tax": 0, "gross_amount": 708.01, "discrete_amount": 139.86, "fees": 0, "total_amount": 568.15 }, { "date": "2024-10-15", "category": "DEF", "use": null, "description": "DIESEL EXHAUST FLUID UREA", "card": "00260", "unit": "111", "prompt_data": "N-HAROLDUTLEY", "check_number": "1310556823", "location_number": "514614", "location_name": "PETRO BORDENTOWN", "state": "NJ", "quantity": 8.32, "gross_ppg": 4.499, "sales_tax": 0, "fed_tax": 0, "gross_amount": 37.41, "discrete_amount": 0, "fees": 0, "total_amount": 37.41 }, { "date": "2024-10-15", "category": "Diesel", "use": null, "description": "ULTRA LOW SULFUR DIESEL", "card": "00260", "unit": "111", "prompt_data": "N-HAROLDUTLEY", "check_number": "1310556823", "location_number": "514614", "location_name": "PETRO BORDENTOWN", "state": "NJ", "quantity": 131.75, "gross_ppg": 4.039, "sales_tax": 0, "fed_tax": 0, "gross_amount": 532.15, "discrete_amount": 98.96, "fees": 0, "total_amount": 433.19 }, { "date": "2024-10-15", "category": "Reefer", "use": null, "description": "REEFER ULTRA LOW SULFUR", "card": "00260", "unit": "111", "prompt_data": "N-HAROLDUTLEY", "check_number": "1310556823", "location_number": "514614", "location_name": "PETRO BORDENTOWN", "state": "NJ", "quantity": 33.84, "gross_ppg": 4.039, "sales_tax": 0, "fed_tax": 0, "gross_amount": 136.66, "discrete_amount": 25.4, "fees": 0, "total_amount": 111.26 }, { "date": "2024-10-16", "category": "Diesel", "use": null, "description": "ULTRA LOW SULFUR DIESEL", "card": "00344", "unit": "295", "prompt_data": "N-JosueCastroGarcia#-0", "check_number": "1311226583", "location_number": "514578", "location_name": "TA GREENLAND", "state": "NH", "quantity": 137, "gross_ppg": 3.719, "sales_tax": 0, "fed_tax": 0, "gross_amount": 509.5, "discrete_amount": 96.31, "fees": 0, "total_amount": 413.19 }, { "date": "2024-10-16", "category": "Ending Balance 10/16/24", "use": null, "description": null, "card": null, "unit": null, "prompt_data": null, "check_number": null, "location_number": null, "location_name": null, "state": null, "quantity": 0, "gross_ppg": 0, "sales_tax": 0, "fed_tax": 0, "gross_amount": 0, "discrete_amount": 0, "fees": 0, "total_amount": 2596.38 } ] }
W4 Form
Department of the Treasury Internal Revenue Service
Description
Employee Withholding Certificate form W4
{ "Step1_Personal_Information": { "Personal_Name": "John K. Doe", "Special_Security_Number": null, "Address": "14200 1st Avenue South Ste AA", "City_Town_State_Zipcode": "Burien, Washington, 98168" }, "Step3_Claim_Dependent_and_Other_Credits": { "Multiply_the_number_of_qualifying_children_under_age_17": 2000, "Multiply_the_number_of_other_dependents": 500, "Total_Amount": 3500 }, "Step4_Other_Adjustments": { "Other_Income": 0, "Deductions": 0, "Extra_Withholding": 0 }, "Step5_Employers_Only": { "Employer_Information": "2408 C St, Anchorage, Alaska, 99503", "First_Date_Of_Employment": "2024-10-23", "Employer_Identification_Information": "123-123-12" }, "Mutiple_Jobs_Worksheet": { "Two_jobs": null, "Three_Jobs": { "A": null, "B": null, "C": null }, "Number_Of_Pay_Period": null, "Divide_Annual_Amount": null }, "Deductions_Worksheet": { "Estimate_Of_Your_2024_itemized_deductions": 1200, "Second_amount": 14600, "Third_amount": 0, "Fourth_amount": 0, "Fifth_amount": 0 } }
RBC Statement
Royal Bank of Canada
Description
e-Statement from Royal Bank of Canada
{ "comp_address": "Royal Bank of Canada, P.O. Box 4047Terminal A, Toronto, ON M5W 1L5", "customer_name": "SUSAN SAMPLE", "own_address": "1234 ANYSTREET, SUITE 5678, ADDR, CI TY, PROVINCE A1B 2C3", "statement_period": { "start": "March 12, 2004", "end": "April 12, 2004" }, "bank_number": "RBCPDA0001-123456789-01-000001-1-0001", "bank_number_last": "19715", "account_number": "02782-5094431", "bank_telephone": "1-800 ROYAL 1-1(1-800-769-2511)", "email": "www.rbcroyalbank.com/deposits", "signature": "02782-5094431", "local_bank": "5879 ROULE JEAN-BAPTISTE, MONTREAL, PQ H3C 3B8", "open_balance_date": "March 12, 2004", "open_balance_money": 4247.14, "total_deposit": 145.15, "total_withdraw": -727.5, "close_balance_date": "March 12, 2004", "close_balance_money": 3664.79, "statement_details": [ { "description": "Opening balance", "withdrawals": 0.0, "deposits": 0.0, "balance": 4247.14 }, { "date": "15 Mar", "description": "Transfer", "withdrawals": 0.0, "deposits": 85, "balance": null }, { "description": "Interest paid", "withdrawals": 0.0, "deposits": 0.15, "balance": null }, { "description": "ATM withdrawal", "withdrawals": 100, "deposits": null, "balance": null }, { "description": "Interac purchase -1361 - Nasr Foods Inc.", "withdrawals": 47.82, "deposits": 0.0, "balance": 4184.47 }, { "date": "17 Mar", "description": "Overdraft interest", "withdrawals": 0.93, "deposits": 0.0, "balance": 4183.54 }, { "date": "18 Mar", "description": "Cheque #30", "withdrawals": 40, "deposits": null, "balance": null }, { "description": "Cheque #31", "withdrawals": 148.11, "deposits": 0.0, "balance": 3995.43 }, { "date": "19 Mar", "description": "ATM withdrawal", "withdrawals": 60, "deposits": 0.0, "balance": 3935.43 }, { "date": "22 Mar", "description": "ATM withdrawal", "withdrawals": 20, "deposits": null, "balance": null }, { "description": "Interac purchase - 1361 - The Bay", "withdrawals": 125.13, "deposits": null, "balance": null }, { "description": "Interac purchase - 1361 - Highland Farms", "withdrawals": 6.94, "deposits": 0.0, "balance": 3783.36 } ] }
AWS Invoice
Amazon Web Services
Description
Invoice for Amazon Web Services
{ "doc_name": "Amazon Web Services, Inc. Invoice", "account_number": "369855269930", "invoice_number": "1607903145", "invoice_date": "March 2 , 2024", "total_amount": { "due_to": "March 2 , 2024", "amount": "$4.02" }, "customer_name": "Umar Shoaib", "comp_address": "muhammadi street muhammadi colony phool, nagar, Bhai Pheru, Punjab, 55260, PK", "summary": { "start": "February 1", "end": "February 29 , 2024", "description": "AWS Service Charges", "charges": "$4.02", "credits": "$0.00", "summary_Tax": "$0.00", "total_invoice": "$4.02" }, "description": [ { "detail_description": "Amazon Simple Storage Service", "detail_amount": "$0.00", "detail_charges": "$0.00", "detail_VAT": "$0.00" }, { "detail_description": "AWS Data Transfer", "detail_amount": "$0.02", "detail_charges": "$0.02", "detail_VAT": "$0.00" }, { "detail_description": "AmazonCloudWatch", "detail_amount": "$0.00", "detail_charges": "$0.00", "detail_VAT": "$0.00" }, { "detail_description": "Amazon Elastic Compute Cloud", "detail_amount": "$2.61", "detail_charges": "$2.61", "detail_VAT": "$0.00" }, { "detail_description": "AWS Key Management Service", "detail_amount": "$0.00", "detail_charges": "$0.00", "detail_VAT": "$0.00" }, { "detail_description": "Amazon Virtual Private Cloud", "detail_amount": "$0.89", "detail_charges": "$0.89", "detail_VAT": "$0.00" }, { "detail_description": "Amazon Route 53", "detail_amount": "$0.50", "detail_charges": "$0.50", "detail_VAT": "$0.00" } ] }
AWS Statement
Amazon Web Services
Description
Monthly e-Statement for Amazon Web Services
{ "doc_name": "Amazon Web Services Statement", "account_number": "730335298058", "statement_number": "1753725553", "statement_date": "July 2 , 2024", "total_amount": { "due_to": "July 2 , 2024", "amount": "INR 2,393.63" }, "comp_name": "SS Enterprises", "project_name": "Go Eye", "comp_address": "C-7, 31 Sector 7, Near Swati Associates, Rohini Delhi, Delhi, Delhi, 110085, IN", "summary": { "start": "June 1", "end": "June 30 , 2024", "description": "AWS Service Charges", "charges": "$24.33", "credits": "$0.00", "summary_GST": "$4.38", "total_usd": "$28.71", "total_statement": "INR 2,393.63", "rate": "1 USD = 83.372820000 INR" }, "description": [ { "detail_description": "Amazon Simple Storage Service", "detail_amount": "$0.09", "detail_charges": "$0.07", "detail_GST": "$0.02" }, { "detail_description": "AWS Data Transfer", "detail_amount": "$28.62", "detail_charges": "$24.26", "detail_GST": "$4.36" }, { "detail_description": "Amazon Elastic Compute Cloud", "detail_amount": "$0.00", "detail_charges": "$0.00", "detail_GST": "$0.00" }, { "detail_description": "Amazon Virtual Private Cloud", "detail_amount": "$0.00", "detail_charges": "$0.00", "detail_GST": "$0.00" } ] }
Adobe Cloud Invoice
Adobe
Description
Invoice for Adobe Cloud services
{ "comp_name": "Adobe Systems Software Ireland Ltd, 4-6 Riverwalk", "comp_address": "Citywest Business Park, Dublin 24, Ireland", "GST_NO": "IE6364992H", "invoice_no": "2630935219", "invoice_data": "15-DEC-2023", "payment_terms": "Credit Card", "purchase_order": "AB03221100000CIN", "order_number": "7136374127", "customer_number": "561572559", "currency": "INR", "customer_name": "Jitender Malik", "customer_company": "kaff appliances india pvt.ltd", "customer_address": "4th Floor, SS Plaza, 122018 GURGAON, INDIA", "customer_GST_no": "06AADCK2121Q1ZI", "statement_period": { "start": "15-DEC-2023", "end": "13-NOV-2024" }, "statement_details": [ { "product_number": "65229226", "product_description": "Creative Cloud All Apps", "quantity_unity": "1 EA", "unit_price": "59,451.54", "net_amount": "59,451.54", "tax_rate": "0.00%", "taxes": "0.00", "total": "59,451.54" } ], "net_amount": "59,451.54", "taxes": "0.00", "Grand_total": "59,451.54", "contact_info": "https://helpx.adobe.com/contact.html" }
Google Cloud Platform Invoice
Google Cloud Platform
Description
Invoice for Google Cloud Platform services
{ "comp_name": "Google Asia Pacific Pte. Ltd.", "comp_address": "70 Pasir Panjang Road, #03-71, Mapletree Business City, Singapore 117371", "bin": "003769273-0208", "customer_name": "Kenakata App", "customer_company": "KenaKata Inc.", "customer_address": "Krishnanagar pata, Jhenaidah 7300, Bangladesh", "invoice_number": "4098164404", "total_usd": "$92.38", "summary": { "start": "Mar 1, 2022", "end": "Mar 31, 2022", "subtotal_usd": "$80.33", "vat_usd": "$12.05", "total_usd": "$92.38", "subtotal_other": "BDT 6,906.37", "vat_other": "BDT 1,036.00", "total_other": "BDT 7,942.37", "exchange_rate": "USD 1 : BDT 85.975" }, "description": [ { "sub_description": "Google Cloud - Fee for March 2022", "des_amount": "80.33", "subtotal": "$80.33", "vat": "$12.05", "total": "$92.38" } ] }