Skip to content

Schemas

API reference

Every object in the public API. Fields typed … | null are always present in responses and may be null.

Address

FieldTypeRequiredDescription
streetstringyesStreet and house number.
postal_codestringyesPostal code.
citystringyesCity.
countrystring | nullCountry code as printed, usually ISO 3166-1 alpha-2.

ClassifiedEmail

An e-mail that was classified as something other than a purchase order.

FieldTypeRequiredDescription
request_idstringyesUnique identifier for the request/email Format: uuid.
email_typestringyesThe classified type of the email
senderstringyesEmail address of the sender
from_namestringyesDisplay name of the sender
subjectstringyesEmail subject
timestampstringyesWhen the email was received and classified Format: date-time.
metadataobjectAdditional metadata about the email
message_idstring | nullRFC 5322 Message-ID (dedup key)
classification_reasonstring | nullWhy the classifier chose the type
rejection_statusstring | nullRejected-email triage: None (handled) | pending | overridden
original_email_typestring | nullClassifier's original type, preserved on operator override

Customer

A customer (debtor) record as stored in AIOTIC.

FieldTypeRequiredDescription
numberstringyesYour customer (debtor) number — the key of this record.
idstringInternal identifier, generated by AIOTIC. Format: uuid.
namestring | nullCompany name
postal_codestring | nullPostal code
citystring | nullCity
addressstring | nullAddress
contact_personstring | nullContact person
phone_numberstring | nullPhone number
vat_numberstring | nullBTW (VAT) number
emailstring | nullCustomer email
coc_numberstring | nullChamber of Commerce number
home_pagestring | nullCompany website URL
similaritynumber | nullMatch score, only populated in search results.
archived_atstring | nullSet when the record is archived because its name carries a legacy or closure marker (e.g. "formerly", "do not use"). Archived customers are never chosen by identification but still resolve when explicitly referenced.
superseded_bystring | nullCustomer number this record redirects to, derived from a "see customer N" marker in the name (e.g. *** ZIE 12306 ***). Orders matched to this record are filed under the successor.

CustomerListResponse

A page of customers.

FieldTypeRequiredDescription
itemsarray of CustomeryesList of customer objects
totalintegeryesTotal number of customers in the system
limitintegeryesMaximum number of customers returned in this response
offsetintegeryesNumber of customers skipped in this response

CustomerProduct

A mapping from a customer's own article code to one of your articles.

FieldTypeRequiredDescription
customer_numberstringyesCustomer identifier referencing the customers table
customer_item_numberstringyesCustomer's own item number for this product
item_numberstringyesSupplier product item number
language_codestringyesProduct language code
created_atstringyesWhen this mapping was created in AIOTIC Format: date-time.

CustomerProductListResponse

A page of customer item mappings.

FieldTypeRequiredDescription
itemsarray of CustomerProductyes
totalintegeryes
limitintegeryes
offsetintegeryes

CustomerProductUpsert

Fields accepted when creating or updating a customer item mapping.

FieldTypeRequiredDescription
item_numberstringyesSupplier product item number
language_codestringyesProduct language code
created_atstringWhen this mapping was created in AIOTIC Format: date-time.

CustomerSearchResponse

Customers matching a search, best match first.

FieldTypeRequiredDescription
itemsarray of CustomeryesList of customer objects with similarity scores
totalintegeryesTotal number of customers in the system
limitintegeryesMaximum number of customers returned in this response

CustomerUpsert

Fields accepted when creating or updating a customer. All optional; the more you fill, the better identification works.

FieldTypeRequiredDescription
idstring | nullUnique customer identifier (UUID, auto-generated if not provided)
namestring | nullCompany name
postal_codestring | nullPostal code
citystring | nullCity
addressstring | nullAddress
contact_personstring | nullContact person
phone_numberstring | nullPhone number
vat_numberstring | nullBTW (VAT) number
emailstring | nullCustomer email
coc_numberstring | nullChamber of Commerce number
home_pagestring | nullCompany website URL
similaritynumber | nullSimilarity score

EmailClassificationResponse

The category an uploaded e-mail would be classified as.

FieldTypeRequiredDescription
categoryenumyesThe category of the email Values: purchase_order, order_confirmation, invoice, delivery_note, quotation, receipt, credit_note, unknown.

ErpAddress

Postal address in the ERP hand-off payload (all keys present, values may be null).

FieldTypeRequiredDescription
streetstring | nullyesStreet and house number.
postal_codestring | nullyesPostal code as printed or as stored in your master record.
citystring | nullyesCity.
countrystring | nullyesCountry code as printed, usually ISO 3166-1 alpha-2.

ErpCustomer

FieldTypeRequiredDescription
customer_idstring | nullyesYour customer (debtor) number as synced via PUT /customer/{number}. null only when an operator explicitly sent an unidentified order.
companystring | nullyesCustomer company name.
contact_personstring | nullyesPerson who placed this order, as printed on the document (document-authoritative, not the master record).
emailstring | nullyesCustomer e-mail address.
phonestring | nullyesCustomer phone number.
ibanstring | nullyesBank account when printed on the order; usually null.
bicstring | nullyesBank identifier when printed on the order; usually null.
vat_idstring | nullyesVAT registration number.
addressErpAddressyesCustomer (bill-to) postal address.

ErpOrderItem

One order line in the ERP hand-off payload (a fixed subset of OrderItem).

FieldTypeRequiredDescription
article_numberstring | nullyesYour article number (SKU) after resolution through your catalog and customer item mappings. null only on an explicit override send of an unresolved line.
descriptionstring | nullyesLine description as printed by the customer.
quantityinteger | nullyesOrdered quantity in whole units. null only when the quantity was unreadable and an operator overrode the review.
unitstring | nullyesUnit of measure as printed (ST, PCS, Stk, m, KG, …) — map it to your ERP's codes.
pricenumber | nullyesUnit price as stated by the customer, or null.
currencystring | nullyesLine currency, normally equal to the header currency.
line_totalnumber | nullyesLine amount as printed (quantity × price), or null.

ErpPurchaseOrder

The purchase order as delivered to your ERP receive endpoint — the reviewed values with operator corrections applied. Keys are always present (null when unknown).

FieldTypeRequiredDescription
order_numberstringyesThe customer's purchase-order number as printed, with / replaced by -. Map it to the "your reference" / external document number of the sales order.
order_datestring | nullyesOrder date as an ISO YYYY-MM-DD string where the document allowed it; otherwise as printed.
delivery_datestring | nullyesRequested delivery date (YYYY-MM-DD) or null. When the document stated a window it is already collapsed to a single date.
currencystring | nullyesCurrency code as printed on the document (e.g. EUR) or null.
total_pricenumber | nullyesThe document's printed total, which may include VAT, or the recalculated net sum when e-mail instructions changed lines. Informational — let your ERP compute totals.
additional_informationstring | nullyesFree text from the document and e-mail plus notes AIOTIC appends (e.g. the original printed total after a recalculation).
supplierSupplier | nullyesYour own company as configured for the tenant — identical on every order, never read from the document. Safe to ignore.
customerErpCustomeryesThe identified customer (debtor). customer_id is your customer number; the address block is canonicalised from your master record on a confident match.
shipping_detailsErpShippingDetailsyesShip-to recipient and delivery instructions. Filled from the customer block when the document has no explicit delivery address.
itemsarray of ErpOrderItemyesOne entry per order line, in document order. Lines without an ordered quantity (assortment listings) are already dropped.

ErpReceiveRequest

Body AIOTIC POSTs to your ERP receive endpoint.

FieldTypeRequiredDescription
request_idstringyesAIOTIC's order id (UUID). Stable across retries of the same send — use it as the idempotency key and store it on your sales order as external reference. Format: uuid.
purchase_orderErpPurchaseOrderyesThe reviewed purchase order with operator corrections applied. Every key below is always present; unknown values are null.

ErpReceiveResponse

Body your ERP receive endpoint must return. success is authoritative — AIOTIC ignores the HTTP status for the business outcome (a 500 with success: false and a success: true with 200 are both handled correctly; a non-JSON body is treated as a server error).

FieldTypeRequiredDescription
successbooleanyes
order_numberstringYour ERP's reference for the created order; stored as erp_ref and shown to operators
errorstringHuman-readable reason when success is false; shown to operators

ErpRecipient

Ship-to block in the ERP hand-off payload.

FieldTypeRequiredDescription
companystring | nullyesShip-to company name.
departmentstring | nullyesDepartment or address line 2.
contact_personstring | nullyesShip-to contact for the carrier.
emailstring | nullyesShip-to e-mail.
phonestring | nullyesShip-to phone.
addressErpAddressyesDelivery address.

ErpSendResponse

FieldTypeRequiredDescription
successbooleanyes
request_idstringyesFormat: uuid.
dataErpReceiveResponseyesThe JSON body your ERP receive endpoint returned, verbatim.

ErpShippingDetails

Shipping section of the ERP hand-off payload.

FieldTypeRequiredDescription
recipientErpRecipientyesThe ship-to block.
special_instructionsstring | nullyesFree-text delivery instructions ("deliver before noon", dock number).

ErrorResponse

Standard error body. detail is usually a string; a few endpoints return a structured object (documented per endpoint).

FieldTypeRequiredDescription
detailstring | objectyes

FetchAllEmailsResponse

Result of a manual mailbox fetch.

FieldTypeRequiredDescription
statusstringyes
emails_queuedintegeryes
emails_totalintegeryes
messagestringyes

HTTPValidationError

Request validation error (malformed parameters).

FieldTypeRequiredDescription
detailarray of ValidationError

OrderCustomer

The identified customer (debtor). customer_id is your customer number and is set only when AIOTIC resolved the customer with confidence.

FieldTypeRequiredDescription
customer_idstring | null
companystringyes
contact_personstring | null
emailstring | null
phonestring | null
branchstring | nullIssuing branch / location named on the document, when any
vat_idstring | null
ibanstring | null
bicstring | null
addressAddressyes

OrderGroup

FieldTypeRequiredDescription
email_group_idstringyesFormat: uuid.
message_idstring | null
order_countintegeryes
ordersarray of OrderStatusyes

OrderItem

One order line as stored on the order (result.items[]).

FieldTypeRequiredDescription
article_numberstring | nullYour (supplier-side) article number, resolved through the catalog and customer mappings where possible
customer_item_numberstring | nullThe customer's own article number as printed, when present
descriptionstring | null
quantityinteger | nullOrdered quantity in whole units; null when unreadable (see quantity_state)
quantity_statestring | nullWhat the quantity column literally showed. Unrecognised rows keep an empty quantity and put the order in ATTENTION. Values: Valid, Empty, Zero, Unrecognised.
unitstring | nullUnit of measure as printed (e.g. ST, PCS, KG)
pricenumber | nullUnit price
currencystring | null
line_totalnumber | null

OrderListResponse

A page of orders, newest first.

FieldTypeRequiredDescription
itemsarray of OrderStatusyesList of order status objects
totalintegeryesTotal number of orders in the system
limitintegeryesMaximum number of orders returned in this response
offsetintegeryesNumber of orders skipped in this response

OrderRef

Reference to one child order of a split e-mail.

FieldTypeRequiredDescription
request_idstringyesUnique identifier for the child order Format: uuid.
statusOrderStatusValueyes
order_labelstring | nullSplitter-assigned label for the order

OrderRetryBody

FieldTypeRequiredDescription
hil_promptstring | null

OrderStatus

The processing status of one order, with the extracted purchase order once available.

FieldTypeRequiredDescription
request_idstringyesUnique identifier for the request Format: uuid.
attachmentsobjectFile names of the order with size and MIME type.
metadataobjectExtra form fields supplied at upload, plus source.
timestampstringyesWhen this status was recorded Format: date-time.
statusOrderStatusValueyes
resultPurchaseOrder | nullThe extracted purchase order once processing finished; null before that and for failed orders.
stateobject | nullFree-form processing details used by the AIOTIC app (validation notes, flags). Informational.
erp_refstring | nullERP-assigned order reference returned on successful send
email_group_idstring | nullCorrelates orders from the same source email
order_labelstring | nullHuman-readable label, e.g. 'PO-12345' or 'Order 1 of 2'
retry_countintegerNumber of retry attempts for transient failures Default: 0.
next_retry_atstring | nullWhen to attempt next retry
last_errorstring | nullLast error message from transient failure

OrderStatusValue

Order lifecycle status.

Values: QUEUED, PROCESSING, ATTENTION, PROCESSED, FAILED, RETRY_PENDING, MODIFIED, REPROCESSED, SENDING, SENT, CANCELED

OrderUploadBody

FieldTypeRequiredDescription
filesarray of stringyes
request_idstring | null

OrderUploadResponse

Result of an upload. When split is true, poll the child orders[] instead of request_id.

FieldTypeRequiredDescription
request_idstringyesUnique identifier for the uploaded document Format: uuid.
splitbooleanTrue when the upload was split into multiple orders; poll orders[] rather than request_id Default: false.
email_group_idstring | nullCorrelation id for child orders when the email was split into multiple orders
ordersarray of OrderRef | nullChild order references when the email was split into multiple orders

ProcessingWebhookRequest

Body of the optional processing webhook, sent when extraction completes (before any human review).

FieldTypeRequiredDescription
request_idstringyesFormat: uuid.
purchase_orderPurchaseOrderyes

Product

An article record (one per article number and language).

FieldTypeRequiredDescription
item_numberstringyesUnique identifier for the product
language_codestringyesLanguage code for the product description
descriptionstring | nullProduct description
remarkstring | nullAdditional remarks about the product
created_atstringyesWhen this product was created in AIOTIC Format: date-time.

ProductListResponse

A page of products.

FieldTypeRequiredDescription
itemsarray of Productyes
totalintegeryes
limitintegeryes
offsetintegeryes

ProductUpsert

Fields accepted when creating or updating a product.

FieldTypeRequiredDescription
descriptionstringyesProduct description
remarkstring | nullAdditional remarks about the product
created_atstringWhen this product was created in AIOTIC Format: date-time.

PurchaseOrder

The extracted purchase order as returned in OrderStatus.result. Every field is always present; optional fields are null, never omitted.

FieldTypeRequiredDescription
order_numberstringyesCustomer's PO number. / is replaced by -.
order_datestringyesISO 8601 date (YYYY-MM-DD) where the document allowed it
delivery_datestring | nullSingle requested delivery date (resolved from a window per tenant preference)
delivery_date_fromstring | nullLower bound when the document states a delivery window
delivery_date_tostring | nullUpper bound when the document states a delivery window
supplierSupplieryes
customerOrderCustomer | null
shipping_detailsShippingDetails | null
itemsarray of OrderItemyes
total_pricenumber | null
currencystring | null
additional_informationstring | nullFree text from the document / e-mail, plus audit notes AIOTIC appends (e.g. original document total)

RawEmailClassifyBody

FieldTypeRequiredDescription
filestringyes

RawEmailUploadBody

FieldTypeRequiredDescription
filestringyes
request_idstring | null

RawUploadRejection

FieldTypeRequiredDescription
detailstring | objectyes

RejectedEmailListResponse

A page of rejected e-mails.

FieldTypeRequiredDescription
itemsarray of ClassifiedEmailRejected emails on this page
totalintegeryesTotal rejected emails matching the rejection_status filter
limitintegeryesPage size
offsetintegeryesPagination offset

ReprocessResponse

Result of forcing a rejected e-mail through order processing.

FieldTypeRequiredDescription
request_idstringyesThe request being reprocessed (reuses the original id) Format: uuid.
statusstringyesOutcome, e.g. 'reprocessing'

ShippingDetails

FieldTypeRequiredDescription
recipientShippingRecipientyesThe ship-to block.
special_instructionsstring | nullFree-text delivery instructions.

ShippingRecipient

FieldTypeRequiredDescription
companystringyesShip-to company name.
contact_personstring | nullShip-to contact for the carrier.
departmentstring | nullDepartment or address line 2.
emailstring | nullShip-to e-mail.
phonestring | nullShip-to phone.
addressAddressyesDelivery address.

Supplier

The receiving company — your company. Pinned from tenant configuration, not extracted per document.

FieldTypeRequiredDescription
companystringyesYour company name as configured for the tenant.
contact_personstring | nullContact person configured for the tenant, if any.
emailstring | nullOrder intake e-mail address of the tenant.
addressAddressyesYour company address as configured.

SystemStatus

FieldTypeRequiredDescription
statusenumyesValues: operational, degraded, unknown.
messagestring | null
updated_atstring | nullFormat: date-time.

ValidationError

One request validation problem.

FieldTypeRequiredDescription
locarray of string | integeryes
msgstringyes
typestringyes
inputobject
ctxobject

Documentation revision 3 · Published 8 September 2026 · commit 6862d5e. Verified against AIOTIC API v1.0.0. AIOTIC is a product of DevOps Company.