Certificate of Origin

Extract structured data from international shipping certificates of origin including exporter, consignee, ports, and goods details.

The fields this preset extracts.

exporter_namestring

Full legal name of the exporter or seller.

exporter_addressstring

Complete address of the exporter.

consignee_namestring

Full legal name of the consignee or buyer.

consignee_addressstring

Complete address of the consignee.

country_of_originstring

ISO 3166-1 alpha-2 country code or full country name where goods originate.

country_of_destinationstring

ISO 3166-1 alpha-2 country code or full country name of final destination.

port_of_loadingstring

Name and code of the port where cargo is loaded for shipment.

port_of_dischargestring

Name and code of the port where cargo will be discharged.

goods_descriptionstring

Detailed description of goods, including type, quantity, and specifications.

hs_codestring

Harmonized System (HS) code for the goods, optional.

invoice_numberstring

Commercial invoice number referenced in the CoO.

invoice_datestring

Date of the commercial invoice, in ISO-8601 format (YYYY-MM-DD).

curl
curl -X POST 'https://app.staging.xberg.io/v1/extract' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -F 'file=@your-document.pdf' \
  --form-string 'options={"preset":"certificate_of_origin"}'
Call mode
Text only
Citations
Enabled
Version
v1

The instructions Xberg gives the AI model when it extracts this document type.

You are a precise structured-data extractor for international Certificates of Origin. Extract all fields literally and exactly as they appear on the document. Do not infer, estimate, or guess values. If a field is absent, omit it from the output. Country names must match the document exactly. Dates are ISO-8601 format (YYYY-MM-DD). Port names and codes must be transcribed precisely. Goods descriptions must be complete and unmodified from the source. If the document does not match this preset, return {}. Extract only values supported by the document. Omit absent, illegible, or incomplete values, including within nested objects, while retaining other supported values. Do not infer, guess, supply defaults, or calculate missing values. Omit dates whose complete year, month, and day are not explicit. Do not emit null or placeholder strings such as "null" or "2023-XX-XX" for missing values.

Open-source primitives, composed into one backend. Curated cohort of design partners. Apply to work with us.

We value your privacy

Xberg uses cookies to improve your experience, personalize content, and analyze traffic. You can manage your preferences at any time.