Aller au contenu principal

Dev News 19 – eReceipt API

· 4 minutes de lecture
Hannah Roegele

fiskaly eReceipt API Update

A major version change to the eReceipt API (version 2.0.0) and updates are planned for Thursday, 23rd March 2023, starting at 2 pm.
The new version will be more consistent and reliable, with several bug fixes included.

Changelog

  • Removal of default values for various schema fields in the CreateReceipt endpoint:
    For a list of properties (see Table 1 below), the default value 0 will be removed in the CreateReceipt endpoint. For mandatory fields, a value now needs to be provided explicitly. Invalid requests with missing mandatory fields will return error code 400 with the corresponding error message.

  • Removal of the possibility to send additional fields in the CreateReceipt endpoint:
    The option to send additional properties in various objects in the CreateReceipt endpoint will be removed. Until now, additional fields with any name and any type could be sent. This option will be removed to improve clarity and consistency. See Table 2 below for a list of affected objects.
    Exception: optional fields remain available for all objects contained in the EkabsSecurity object, to allow for flexibility when providing responses from different fiscalization endpoints.

Table 1: Affected schema fields

Object typeSchema fieldMandatory
EkabsPaymentType.amountyes
EkabsLineItem.quantityyes
.price_per_unityes
EkabsLineVatAmountGross.percentageyes
.incl_vatyes
EkabsLineVatAmountNet.percentageyes
.excl_vatyes
.vatyes
EkabsVatAmountTotal.percentageyes
.incl_vatyes
.excl_vatyes
.vatyes
EkabsData.full_amount_incl_vatyes
Discount.discount_valueyes
EkabsPaymentType.changeno
EkabsData.full_amount_incl_vat_before_discountno
.total_discount_valueno
HospitalitySchema.tipno

Table 2: Affected schema objects

ObjectSchema oldSchema new
ReceiptSchemaEkabsV0{
custom_elements: CustomElements[],
data: EkabsData,
head: EkabsHead,
language: Language,
misc: EkabsMisc,
security: EkabsSecurity,
property name*: any
}
{
custom_elements: CustomElements[],
data: EkabsData,
head: EkabsHead,
language: Language,
misc: EkabsMisc,
security: EkabsSecurity
}
EkabsData{
currency: EkabsCurrency,
full_amount_incl_vat: string,
full_amount_incl_vat_before_discount: string,
lines: EkabsLine[],
payment_types: EkabsPaymentType[],
total_discount_value: string,
vat_amounts: EkabsVatAmountTotal,
property name*: any
}
{
currency: EkabsCurrency,
full_amount_incl_vat: string,
full_amount_incl_vat_before_discount: string,
lines: EkabsLine[],
payment_types: EkabsPaymentType[],
total_discount_value: string,
vat_amounts: EkabsVatAmountTotal
}
EkabsLine{
additional_text: string,
delivery_period_end: integer,
delivery_period_start: integer,
discounts: Discount[],
item: EkabsLineItem,
sort_order: integer,
text: string,
vat_amounts: EkabsLineVatAmountGross[] or EkabsLineVatAmountNet[],
property name*: any
}
{
additional_text: string,
delivery_period_end: integer,
delivery_period_start: integer,
discounts: Discount[],
item: EkabsLineItem,
sort_order: integer,
text: string,
vat_amounts: EkabsLineVatAmountGross[] or EkabsLineVatAmountNet[]
}
EkabsLineItem{
full_amount: string,
gtin: string,
number: string,
price_per_unit: string,
quantity: string,
quantity_measure: string,
property name*: any
}
{
full_amount: string,
gtin: string,
number: string,
price_per_unit: string,
quantity: string,
quantity_measure: string
}
EkabsLineVatAmountGross{
incl_vat: string,
percentage: string,
property name*: any
}
{
incl_vat: string,
percentage: string
}
EkabsLineVatAmountNet{
excl_vat: string,
percentage: string,
vat: string,
property name*: any
}
{
excl_vat: string,
percentage: string,
vat: string
}
EkabsPaymentType{
amount: string,
change: string,
display_name: string,
foreign_amount: string,
foreign_currency: EkabsCurrency,
name: string,
payment_identifier: string,
remaining_balance: string,
sort_order: integer,
property name*: any
}
{
amount: string,
change: string,
display_name: string,
foreign_amount: string,
foreign_currency: EkabsCurrency,
name: string,
payment_identifier: string,
remaining_balance: string,
sort_order: integer
}
EkabsVatAmountTotal{
excl_vat: string,
incl_vat: string,
percentage: string,
vat: string,
property name*: any
}
{
excl_vat: string,
incl_vat: string,
percentage: string,
vat: string
}
EkabsHead{
id: string,
buyer: EkabsBuyer,
date: integer,
delivery_period_end: integer,
delivery_period_start: integer,
number: string,
seller: EkabsSeller,
property name*: any
}
{
id: string,
buyer: EkabsBuyer,
date: integer,
delivery_period_end: integer,
delivery_period_start: integer,
number: string,
seller: EkabsSeller
}
EkabsBuyer{
address: EkabsAddress,
customer_number: string,
name: string,
tax_number: string,
property name*: any
}
{
address: EkabsAddress,
customer_number: string,
name: string,
tax_number: string
}
EkabsSeller{
address: EkabsAddress,
name: string,
tax_exemption: boolean,
tax_exemption_note: string,
tax_number: string,
property name*: any
}
{
address: EkabsAddress,
name: string,
tax_exemption: boolean,
tax_exemption_note: string,
tax_number: string
}
EkabsMisc{
conformity_text: string,
footer_text: string,
property name*: any
}
{
conformity_text: string,
footer_text: string
}

fiskaly developer website: developer.fiskaly.com
fiskaly status page: status.fiskaly.com
fiskaly support website: support.fiskaly.com

You can contact our support at dev-support@fiskaly.com.