Skip to main content

Update a Document

PUT 

/api/v7/partner/documents/:document_id

Update a previously processed document. Since Veryfi's Machine Learning models undergo frequent training, changes that are made to processed documents are used during these training sessions and eventually help improve the accuracy of data extraction.

Request

Path Parameters

    document_id int64required

    ID of the document.

Body

required

Document update options.

    bill_to_name string

    Name of the Bill To contact

    bill_to_address string

    Address of the Bill To contact

    category string

    Category for the document

    date string

    Date on invoice/bill/receipt in YYYY-MM-DD HH:MM:SS format

    due_date string

    Date on invoice/bill/receipt in YYYY-MM-DD HH:MM:SS format

    invoice_number string

    Invoice number

    incoterms string
    insurance string
    line_items object[]

    List Of Line Items

  • Array [
  • category Category

    The category is taken from the line item with the same SKU and/or description. Otherwise from the root category field.

    country_of_origin Country Of Origin

    Possible values: [BV, SI, FR, BR, CF, DO, GS, MT, NC, MZ, SJ, TW, DM, AS, EG, RW, CY, KG, KW, GL, EE, MV, KI, NF, TH, SY, MC, FM, SK, GQ, MK, GA, TV, PR, DE, SL, CN, AU, NI, MW, NE, UG, LT, VG, SZ, KM, MU, HM, AE, EC, AQ, PT, SN, NL, CG, BZ, IQ, VU, MR, AI, TN, BH, BL, MS, TC, JE, HR, NU, CH, TL, VE, AG, MQ, CC, BD, TK, YT, IS, QA, SE, PG, PM, TT, PF, BI, IM, FJ, GT, UZ, CL, BS, SC, AR, KE, MN, LS, KR, PK, KN, YE, KZ, KH, GE, MD, CX, NA, UY, BO, TR, ID, SO, CV, FO, RS, CU, LA, LR, PN, JP, AL, NP, TM, LK, AD, BB, GI, NO, RO, FK, RU, GN, DJ, AW, MA, SB, CM, GP, LC, VI, MP, FI, GU, SA, SG, WS, ET, CR, AM, GY, LY, AF, GR, VC, PH, ST, OM, GM, KP, TJ, BJ, JM, AT, VA, PY, CK, HK, MF, IO, UA, MY, HT, TG, SV, NG, ZA, PE, BW, NZ, PS, AN, BM, WF, UM, IR, DZ, TD, TZ, IE, SR, GB, BE, DK, LI, SH, GH, GW, ML, TF, GD, IL, JO, BF, CD, LU, PW, SM, ER, AZ, BG, CA, KY, IT, PA, GF, MX, AX, EH, MM, CO, MH, CI, ZM, LV, MO, NR, BA, GG, TO, HN, ES, SD, PL, IN, HU, ZW, CZ, ME, US, BT, VN, BY, LB, RE, AO, MG, BN]

    The country of manufacture, production, design, or brand origin where the product comes from.

    date date

    The date found on the document and associated with the line item in ISO 8601 format.

    description Description

    The product or service's extracted name or description excluding date and price.

    discount_rate Discount Rate

    The discount percentage that was applied to the line item.

    discount Discount

    The amount deducted from the total price for the line item.

    end_date date

    A service end date identified for the line item. An end date could be a flight arrival date or hotel departure date in ISO 8601 format.

    hsn Hsn

    The Harmonized System Nomenclature (HSN) found for the line item.

    order Order
    lot Lot

    The batch or lot number for the line item.

    price Price

    The unit price for the line item.

    quantity Quantity

    The amount or number of units for the line item. This value is computable.

    reference Reference
    section Section

    A grouping indicated by formatted text on the receipt or invoice.

    sku Sku

    The Stock Keeping Unit (SKU) is the unique code associated with the product for the line item.

    start_date date

    A service start date identified for the line item. A start date could be a flight departure date or hotel arrival date in ISO 8601 format.

    tax_code Tax Code

    The classification of goods and services for tax purposes for the line item.

    manufacturer Manufacturer

    The name of the manufacturer of the product for the line item.

    tax_rate Tax Rate

    The percent at which the individual or corporation is taxed.

    tax Tax

    The amount at which the individual or corporation is taxed for the product on this line item.

    total Total

    The total price for this line item. This value is computable.

    subtotal Subtotal

    New, added 2023-07-10. The total of a set of numbers that will later be added to another set of numbers, such as tip and tax. This value is computable.

    type Type

    Possible values: [room, tax, parking, service, fee, delivery, product, food, alcohol, tobacco, transportation, fuel, refund, discount, payment, giftcard]

    The classification of the product. The line type predicted by Veryfi, e.g. food.

    unit_of_measure Unit Of Measure

    The unit of measurement for this line item.

    upc Upc

    The Universal Product Code (UPC), European Article Number (EAN), or Global Trade Item Number (GTIN) found for the line item on this document will be placed in this field.

    weight Weight

    The weight of the item for the line item. Usually found on logistic invoices.

  • ]
  • subtotal float

    Subtotal on the document

    tax float

    Tax on the document

    tip float

    Tip/gratuity on the document

    total float

    Total on the document

    total_weight string
    vendor object
    address string

    Vendor Address

    email string

    Vendor Email

    external_id string

    Vendor external id

    name string

    Vendor Name

    external_id string

    Optional custom document identifier. Use this if you would like to assign your own ID to documents

Responses

Document.

Schema
    abn_number string

    ABN Number (Australian Business Number)

    account_number string

    Account Number

    bill_to_address string

    Bill To Address

    bill_to_name string

    Bill To Name

    bill_to_vat_number string

    Bill To VAT Number

    card_number string

    Card Number

    cashback double

    Cashback

    category string

    Category

    created string

    Created Date

    currency_code string

    Currency Code

    date string

    Date

    delivery_date string

    Delivery Date

    discount double

    Discount

    document_reference_number string

    Document Reference Number

    document_title string

    Document Title

    document_type string

    Document Type

    due_date string

    Due Date

    duplicate_of string

    Duplicated Document ID

    external_id string

    External ID

    id integer

    Document ID

    img_file_name string

    Image File Name

    img_thumbnail_url string

    Image Thumbnail URL

    img_url string

    Image URL

    insurance double

    Insurance

    invoice_number string

    Invoice Number

    is_duplicate integer

    Is Duplicated

    is_money_in integer

    1 if refund or credit note

    line_items object[]

    List Of Line Items

  • Array [
  • date string

    Date

    description string

    Description

    discount double

    Discount

    discount_rate double

    Discount Rate

    id int64

    ID

    order integer

    Order

    price double

    Price

    quantity double

    Quantity

    reference string

    Reference Number

    section string

    Section

    sku string

    Stock Keeping Unit (SKU)

    tax double

    Tax

    tax_rate double

    Tax Rate

    text string

    Text

    total double

    Total

    type string

    Type

    unit_of_measure string

    Unit Of Measure

  • ]
  • notes string

    Notes

    ocr_text string

    OCR Text

    order_date string

    Order Date

    payment_display_name string

    Payment Display Name

    payment_terms string

    Payment Terms

    payment_type string

    Payment Type

    phone_number string

    Phone Number

    purchase_order_number string

    Purchase Order Number

    rounding double

    Rounding Number

    service_end_date string

    Service End Date

    service_start_date string

    Service Start Date

    ship_date string

    Shipping Date

    ship_to_address string

    Shipping Address

    ship_to_name string

    Shipping Recipient

    shipping double

    Shipping

    store_number string

    Store Number

    subtotal double

    Subtotal

    tax double

    Tax

    tax_lines object[]

    Tax Lines Breakdown

  • Array [
  • base double

    Tax Base

    name string

    Tax Name

    rate double

    Tax Rate %

    total double

    Tax Total

  • ]
  • tip double

    Tip

    total double

    Total

    total_weight string

    Total Weight

    tracking_number string

    Tracking Number

    updated string

    Updated Date

    vat_number string

    VAT Number

    vendor object
    address string

    Vendor Address

    category string

    Vendor Category

    email string

    Vendor Email

    fax_number string

    Vendor Fax Number

    name string

    Vendor Name

    parsed_address object
    city City

    The settlement including cities, towns, villages, hamlets, localities, etc.

    country Country

    The sovereign nations and their dependent territories, anything with an ISO-3166 code.

    postcode Postcode

    The postal code used for mail sorting

    state State

    A first-level administrative division. Scotland, Northern Ireland, Wales, and England in the UK are mapped to "state" as well

    street_address Street Address

    A sum of house_number road, building, unit.

    house House

    The venue name e.g. "Brooklyn Academy of Music", and building names e.g. "Empire State Building".

    house_number House Number

    Usually refers to the external (street-facing) building number. In some countries this may be a compound, hyphenated number, which also includes an apartment number, or a block number (a la Japan).

    road Road

    Street name(s)

    unit Unit

    An apartment, unit, office, lot, or other secondary unit designator.

    level Level

    The expressions indicating a floor number e.g. "3rd Floor", "Ground Floor", etc.

    staircase Staircase

    Numbered/lettered staircase

    entrance Entrance

    Numbered/lettered entrance

    po_box Po Box

    The post office box, typically found in non-physical (mail-only) addresses.

    suburb Suburb

    An unofficial neighborhood name like "Harlem", "South Bronx", or "Crown Heights".

    city_district City District

    The boroughs or districts within a city that serve some official purpose e.g. "Brooklyn" or "Hackney" or "Bratislava IV".

    island Island

    Named islands e.g. "Maui"

    state_district State District

    Usually a second-level administrative division or county.

    country_region Country Region

    Informal subdivision of a country without any political status.

    world_region World Region

    Only used for appending "West Indies" after the country name, a pattern frequently used in the English-speaking Caribbean e.g. "Jamaica, West Indies".

    phone_number string

    Vendor Phone Number

    raw_name string

    Vendor Raw Name

    vendor_logo string

    Vendor Logo

    vendor_reg_number string

    Vendor Registration Number

    vendor_type string

    Vendor Type

    web string

    Vendor Web

    vendor_account_number string

    Vendor Account Number

    vendor_bank_name string

    Vendor Bank Name

    vendor_bank_number string

    Vendor Bank Number

    vendor_bank_swift string

    Vendor Bank Swift

    vendor_iban string

    International Bank Account Number (IBAN)

Loading...