Data specification

Invoice

NameRead onlyData typeMaximum lengthValue
invoice_idString10Twisto Invoice ID
parent_invoice_idString10Twisto Invoice ID of the invoice from which this one was created by using split invoice
eshop_invoice_idString10Eshop invoice ID. If filled, It will be used as a variable code to send a payment to your e-shop account. Only digits are allowed.
external_idString50E-shop order/invoice ID. If filled, it will be returned in API responses and it will appear in XLSX Overview.
customer_emailString254Customer email
billing_addressAddress Billingaddress
delivery_addressAddressDelivery address
date_createdStringISO 8601Date and time of creating of the invoice
date_returnedStringISO 8601Date and time of returning of the invoice. Set only for fully returned invoice.
date_cancelledStringISO 8601Date and time of cancellation of the invoice
date_activatedStringISO 8601Date and time of activation of the invoice
date_paidStringISO 8601Date and time of invoice payment
date_dueStringISO 8601Current due date of the invoice
initial_date_dueStringISO 8601Initial due date of the invoice
pdf_urlString255URL of the PDF invoice file for the customer. Appears after activating invoice (until then, the PDF invoice is not created).
total_price_vatNumber8.2Total price incl. VAT. 8 digits, 2 decimal places.
itemsItem[]Order items
has_accountBooleanCustomer has Twisto account
margin_amountNumber8.2Total amount of Twisto margin without VAT rounded to 2 decimal points.
margin_amount_vatNumber8.2Total amount of Twisto margin with VAT rounded to 2 decimal points.
paid_to_merchant_amountNumberPaid to merchant amount. If null, not paid yet. If 0 customer has returned invoice. If more than 0, twisto has paid to merchant.

Customer

NameRequiredData typeMaximum lengthValue Example
emailString254Customer email "jan.novak@example.com"
nameString255Name "Jan Novák"
facebook_idString50Facebook ID "123456789"
company_idString15Company ID "12345678"
vat_idString15Tax ID number "CZ12345678"

Order

NameRequiredData typeMaximum lengthValueExample
date_createdStringISO 8601Date and time of order creation"2013-07-22T14:57:18+00:00"
billing_addressAddressBilling address
delivery_addressAddressDelivery address
total_price_vatNumber8.2Total price including VAT1432.23
itemsItem[]Order items
delivery_methodNumberDelivery method type: 11 - delivery company, 12 - courier, 13 - post,14 - personal pickup, 15 - box, 16 - dispensing point, 17 - virtual goods, 10 - other11
delivery_method_detailString255Delivery method detail. Fill this for respective Delivery method type: 11 (delivery company): name, 15 (box): name and address, 16 (dispensing point): name and address, 10 (other): description"DPD"

Item

NameRequiredData typeMaximum lengthValueExample
typeNumberType of item: 0 - goods, 1 - shipment, 2 - payment, 4 - discount, 32 - round0
nameString255Item name"Růžový šátek s ornamenty"
product_idString255Product ID (unique per order)"1001"
quantityNumberQuantity2
price_vatNumberPrice incl. VAT406.07
vatNumberVAT rate percentage21
ean_codeString13EAN Code
isbn_codeString13ISBN Code
issn_codeString8ISSN Code
heureka_categoryNumberHeureka categories list you can find here1469
is_virtualBooleanSet true for virtual goods like vouchers.false

Item split

NameRequiredData typeMaximum lengthValueExample
product_idString255Product ID (unique per order)"1001"
quantityNumberThe number of pieces for splitting (greater than 0)2

Adress

NameRequiredData typeMaximum lengthValueExample
typeNumber1
nameString100Name"Jan Novák"
streetString100Street"Wilsonova 300/8"
cityString100City"Praha"
zipcodeString5Postal code"11000"
phone_numberString20Phone number"+420733123456"
countryString2Country code in ISO 3166-1 alpha-2 format"CZ"