GET
/
v1-preview
/
models
/
commercial-invoice
/
{documentId}
using ABBYY.DocumentAI;
using ABBYY.DocumentAI.Schemas.Components;

var sdk = new DocumentAI(apiKeyAuth: "<YOUR_BEARER_TOKEN_HERE>");

var res = await sdk.Models.CommercialInvoice.GetExtractedFieldsAsync(documentId: "wh23anb5xjf0ntw5taase5qz");

// handle response
{
  "meta": {
    "id": "wh23anb5xjf0ntw5taase5qz",
    "name": "document.jpg",
    "createdAt": "2025-02-07T17:44:06.949Z",
    "model": "commercial-invoice",
    "status": "Processed",
    "pageCount": 10,
    "errors": [
      {
        "message": "Total is required"
      }
    ]
  },
  "fields": {
    "consignee": {
      "name": "Global Imports Ltd",
      "taxId": "GB123456789",
      "address": "456 Commerce Street, London, UK EC2A 4PB",
      "consigneeId": "CUST123",
      "postalCode": "EC2A 4PB",
      "street": "456 Commerce Street",
      "city": "London",
      "stateOrProvince": "Greater London",
      "country": "United Kingdom"
    },
    "vendor": {
      "name": "ACME Manufacturing Inc.",
      "taxId": "US123456789",
      "address": "123 Production Ave, Industrial Park, Detroit, MI 48201",
      "vendorId": "VEND456",
      "postalCode": "48201",
      "street": "123 Production Ave",
      "city": "Detroit",
      "stateOrProvince": "Michigan",
      "country": "United States",
      "nationalTaxId": "US123456789",
      "iban": "US12ABCD1234567890123456",
      "bankCode": "123456",
      "bankAccount": "987654321"
    },
    "shipTo": {
      "name": "Global Imports Ltd",
      "address": "456 Commerce Street, London, UK EC2A 4PB"
    },
    "billTo": {
      "name": "Global Imports Ltd",
      "address": "456 Commerce Street, London, UK EC2A 4PB"
    },
    "invoiceNumber": "INV123456",
    "invoiceDate": "2024-01-10",
    "dueDate": "2024-02-10",
    "countryOfOrigin": "United States",
    "countryOfExport": "United States",
    "countryOfDestination": "United Kingdom",
    "incoTerm": "DDP",
    "weight": 2750,
    "weightUom": "kg",
    "totalPallets": 25,
    "total": 50000,
    "currency": "USD",
    "additionalCosts": [
      {
        "type": "Freight",
        "amount": 2500,
        "currency": "USD"
      },
      {
        "type": "Insurance",
        "amount": 500,
        "currency": "USD"
      }
    ],
    "lineItems": [
      {
        "position": 1,
        "countryOfOrigin": "United States",
        "hsCode": "8483.30.51",
        "description": "Industrial machinery parts",
        "quantity": 50,
        "uom": "cartons",
        "unitPrice": 1000,
        "totalPrice": 50000,
        "currency": "USD",
        "netWeight": 2500,
        "netWeightUom": "kg",
        "grossWeight": 2750,
        "grossWeightUom": "kg"
      }
    ]
  }
}

Authorizations

Authorization
string
header
required

Our API offers authentication via API keys. You can obtain an API key from https://developer.abbyy.com

Path Parameters

documentId
string
required

The id of the document

Response

200
application/json

Extracted Commercial Invoice Data Response