TISS API


Introduction

TISS API is an interface for securing communication between the TISS system and other systems. The API is available at: http://www.tiss.sk/api. You will get the relevant address together with other information needed to work with the API.

The API was launched in the test mode - it contains only some of the methods/actions, which will be added in the future, based on the need.

Each call requires certain input parameters. The input parameters are sent in the JSON format as a value of a single “data” input attribute, which is sent using the GET or POST method.

The call result is also in the JSON format.

Universal parameters

Universal Input Parameters

These paramenters are mandatory for all calls.

Token [varchar] You can get the Token from the Tiss system administrator. It identifies the company, for which communication is used. It also authenticates and authorizes the use of the API.
Action [varchar] It contains the name of the called method/Action. You can find the list of the supported actions below.


Universal Output Parameter

Result [varchar] Each result contains the Result parameter. If the content is “OK”, the call is completed without error. Otherwise, it contains a description of the error.

Product

productNew/productEdit

It is used to create or edit products. If the call doesn't contain ProductID, then the system will create a new product. If the call contains ProductID, then the product with the provided ID will be edited. If ProductID doesn't exist,"Product was not found" will be the returned result.

Example: The ProductID of the product isn't provided. The API returns the product ID, which was created.

Description of the Input Parameters >
ProductID [int]

ID of the product to be edited. If this attribute is not provided, a new product will be created.

Name [varchar] Contains the name of the product.
ProductCategoryID [int] Contains id of the product category. Mandatory field.
Hidden [int] 1 = hidden, 0 = not hidden.
Price [int] Price without VAT.
Vat [int] VAT [%].
Barcode [int] Product barcode (does not have to be EAN).
Group [int] Product group number. This number is the same for different variants of the same product.
Description [text] Product description.
Priority [int] Priority number.
Storing [int] Type of the product. 0 = service, 1 = stored product (default), 2 = not stored product. Please, contact helpdesk for more information.

Description of Output Parameters
ProductID [int] ID of the created product.

Example of a call
An array of the input parameters:


Array
(
    [Token] => 12345678901234567890
    [Action] => productEdit
    [Name] => test
    [Barcode] => 12345
    [ProductCategoryID] => 3
    [Price] => 11.125
    [Vat] => 20


)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"productNew","Name":"test","barcode":"12345","ProductCategoryID":"3"Price":"11.125","Vat":"20"}
Result example:
{"Result":"OK","ProductID":"285"}


productSearch

It is used to determine the unique product identifier based on the parameters and their values entered at the input.

Example: The barcode of the product 12345678 is entered at the input. The API returns the product ID found in the database associated with the given barcode.

Description of the Input Parameters
Attributes [array]

Contains an array of arrays with two attributes - Key ["string"] a Value ["string"]. Key contains the name of the column according to which we want to search and Value contains the searched value.

Added parameter of an array Attributes – Type array.
If it is not filled or it contains "0", the search is done by using the "=" operator – meaning exact equality.
If the value “1” is entered, the search is done by using LIKE "%["needle"]%".
If the value “2” is entered, then the search is done by using != (not equal)".

Operand [varchar] Optional parameter. The only valid value is "OR". If it is filled, the particular conditions in the Attributes will be searched using the OR operand. Otherwise, AND operand will be used.

Description of Output Parameters
ProductID [int] ID of the found product. Products [array] Contains an array of arrays with the Name and ProductID attributes of all the found products. If needed, it is possible to add other product attributes.

Example of a call
An array of the input parameters:
Array
(
    [Token] => 12345678901234567890
    [Action] => productSearch
    [Attributes] => Array
        (
            [0] => Array
                (
                    [Key] => barcode
                    ["value"] => 12345678
                )

        )

)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"productSearch","Attributes":[{"Key":"barcode","Value":"12345678"}]}
Result example:
{"Result":"OK","ProductID":"285"}


productRemove

It is used to determine the unique product identifier based on the ProductID entered at the input.

Example: The product ID of the product 12345 is entered at the input. API removes the product with the defined ID.

Description of the Input Parameters
ProductID [int] ID of product. Mandatory pamameter.

Description of the Output Parameters It has no output parameters.
Example of a call
An array of the input parameters:
Array
(
    [Token] => 12345678901234567890
    [Action] => productRemove
    [ProductID] => 12345
        

)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":productRemove,"ProductID":"12345"}]}
Result example:
{"Result":"OK"}


getProduct

It is used to find the complete product/products information. Example: Category identifier is entered at the input. The API returns the complete information about all the products in the category.

Description of the Input Parameters
Attributes [array] Contains an array of arrays with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column, according to which we want to search and Value contains the searched value. It is possible to get the specific columns after an agreement with the administrator.

Description of the Output Parameters
Data [array] An array with product arrays. The following part describes the array elements:
ProductID [int] Product ID.
ProductCategoryID [int] Product category ID.
ProductCategoryIDTop [int] Main product category ID.
Name [varchar] Product name.
Price [float] Product price excl. VAT.
Vat [int] VAT level in percentage.
Barcode [varchar] Product barcode (does not have to be EAN).
Hidden [int] Product is hidden. 0 = not hidden, 1 = is hidden.
Group [int] Product group number. This number is the same for different variants of the same product.
Priorirty [int] Priority number.
Description ["text"] Product description.
Stock [float] Current total stock (after taking reservations into account) for all branches.
StockCentral [float] Current stock (after taking reservations into account) at the central.
StockX [float] Current stock (after taking reservations into account) at a specific shop (X marks shop ID).
Files [array] An array of arrays of files (and pictures) of the product. The following part describes the array elements:
Small [varchar] Link to a small image size.
Big [varchar] Link to a large image size.
File [varchar] A link to a file in a non-image format.
Name [varchar] Text description of the file.
Type [varchar] Text description of the way of using the image.
Priority [int] File order.

Example of a call
An array of the input parameters:
        Array
(
    [Token] => 12345678901234567890
    [Action] => getProduct
    [Attributes] => Array
        (
            [0] => Array
                (
                    [Key] => id_product_category_sub
                    ["value"] => 1
                )

        )

)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"getProduct","Attributes":[{"Key":"id_product_category_sub","Value":"1"}]}
Result example:
{"Result":"OK","Data":[{"ProductID":"2","ProductCategoryID":"1","Name":"Nazov produktu","Price":"99.167","Vat":"20","Barcode":"010057","Description":"Popis produktu.","Stock":12}]}


productCategoryNew/productCategoryEdit

It is used to create/edit product categories.

Description of the input parameters

Name [varchar] Category name.
ParentProductCategoryID [int] Parent category ID.
Hidden [int] Category is hidden. 0 = not hidden, 1 = is hidden. Warning! If the category is hidden, particular products in the category do not have to have the Hidden value equal to 1 or vice versa.
Priority [int] Category order.
ProductCategoryID [int] Product category ID. If ProductCategoryID is provided, category will be updated, otherwise it will be created.
ParentProductCategoryID [int] Parent category ID. Parameter is mandatory for creating a new category.

Description of the output parameters

ProductCategoryID [int] ID of the created product category.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => getProductCategory
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"productCategoryEdit"}
Result example:
{"Result":"OK","Data":[{"Name":"Kategoria 1","ProductCategoryID":"3","ParentProductCategoryID":"0","Priority":"3"},{"Name":"Kategoria 2","ProductCategoryID":"4","ParentProductCategoryID":"0","Priority":"1"}]}


getProductCategory

It is used to determine the complete structure of the product categories. Each category can contain other categories. Therefore, each category is assigned ID of the parent category.

Description of the Input Parameters

Does not have own input parameters.

Description of the output parameters

Data [array] An array of arrays of product categories. The following part describes the array elements:
ProductCategoryID [int] Product category ID.
ParentProductCategoryID [int] Parent category ID category.
Hidden [int] Category is hidden. 0 = not hidden, 1 = is hidden. Warning! If the category is hidden, individual products in the category do not have to have the Hidden value equal to 1 or vice versa.
Name [varchar] Category name.
Priority [int] Order within the parent category.
Files [array] An array of arrays of files (and pictures) of the product. The following part describes the array elements:
Small [varchar] Link to a small image size.
Big [varchar] Link to a large image size.
File [varchar] Link to a file in a non - image format.
Name [varchar] Text description of the file.
Type [varchar] Text description of the way of image use.
Priority [int] File order.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => getProductCategory
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"getProductCategory"}
Result example:
{"Result":"OK","Data":[{"Name":"Kategoria 1","ProductCategoryID":"3","ParentProductCategoryID":"0","Priority":"3"},{"Name":"Kategoria 2","ProductCategoryID":"4","ParentProductCategoryID":"0","Priority":"1"}]}


productCAtegoryRemove

It is used to determine the unique product identifier based on the ProductCategoryID entered at the input.

Example: The ProductCategoryID of the product 12 is entered at the input. The API removes the product category with the defined ID.

Description of the Input Parameters
ProductCategoryID [int] ID of the product category. Mandatory pamameter.

Description of the Output Parameters It has no output parameters.
Example of a call
An array of the input parameters:
Array
(
    [Token] => 12345678901234567890
    [Action] => productCategoryRemove
    [ProductCategoryID] => 12
        

)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":productCategoryRemove,"ProductID":"12"}]}
Result example:
{"Result":"OK"}


productParameterSearch

Lists product parameters.

Description of the input parameters

Does not have any input parameters.

Description of the output parameters

ProductParameterId [int] ID of the Product parameter.
Name [varchar] Name of the Product parameter.
MachineName [varchar] Machine name of the Product parameter as used in getProduct/productSearch.
UsedForVariants [bool] True if parameter is used for grouping variants of the same product.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => productParameterSearch
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"productParameterSearch"}
Result example:
{"Result":"OK","Data":[{"ProductParameterId":"81","Name":"Farba","MachineName":"farba"},{"ProductParameterId":"83","Name":"Rozmer","MachineName":"rozmer"}]}

Client / Supplier

clientSearch / supplierSearch

It is used to determine the unique client/supplier identificator based on the parameters and their values entered at the input.
Example: Client ID 12345678 is entered at the input. The API returns client ID found in the database with the given ID.

This method returns one result at the most!

Description of the input parameters

Attributes [array] Contains an array of arrays with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column, according to which we want to search and Value contains the searched value.
Allowed attributes for searching: Ico, Dic, IcDph, Name, Email, ClientId
Multiple names of attribute can be separated by comma. Logical operand OR will be applied, so record matching ANY of the attributes will be returned.

Description of the output parameters

Data [array] Client data array. The following part describes the array elements:
ClientId [int] / SupplierId [int] ID of the client / supplier found.
Name [varchar] The name of the client / supplier found.
FirstName [varchar] The first name of the client / supplier found.
Surname [varchar] The surname of the client / supplier found .
Street [varchar] The address of the client / supplier found.
City [varchar] The city of the residence of the client / supplier found.
ZIP [varchar] ZIP code of the residence of the client / supplier found.
Country [varchar] The country of the residence of the client / supplier found.
Phone [varchar] The phone number of the client / supplier found.
Ico [varchar] ID of the client / supplier found.
Dic [varchar] Tax ID of the client / supplier found.
IcDph [varchar] VAT ID of the client / supplier found.
Parameter_X [varchar] Own parameters. Based on specific settings.

Example of a call

An array of the input parameters:
Array
    (
        [Token] => 12345678901234567890
        [Action] => clientSearch
        [Attributes] => Array
            (
                [0] => Array
                    (
                        [Key] => Ico
                        ["value"] => 12345678
                    )

            )

    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"clientSearch","Attributes":[{"Key":"Ico","Value":"12345678"}]}
Result example:
{"Result":"OK","Data":[{"ClientId":"12345","Name":"Názov firmy","Street":"Nezábudková 34","City":"Bratislava","Ico":"12345678","Dic":"234567890","IcDph":"SK234567890"}]}


clientNew

It is used to create/modify a client in Tiss.

Description of the input parameters

ClientId [int] Contains client ID.
If entered, client data will be modified. If not entered, a client is created.
Name [varchar] (optional if ClientID is entered) Contains the client's name.
FirstName [varchar] Contains the first name of the client.
Surname [varchar] Contains the surname of the client.
Title [varchar] Contains the title of the client - e.g MA
Street [varchar] Contains the street and the street number of the client’s residence.
City [varchar] Contains the city/town of the client’s residence.
ZIP [varchar] Contains ZIP code of the client’s residence.
Country [varchar] Contains the country of the client’s residence.
Phone [varchar] Contains the phone number of the client.
Fax [varchar] Contains the fax number of the client.
Email [varchar] Contains the e-mail of the client.
Web [varchar] Contains the web page of the client.
ICO [varchar] Contains ID of the client.
DIC [varchar] Contains Tax ID of the client.
ICDPH [varchar] Contains VAT ID of the client.
ClientTag [int] Contains ID of Client Tag.
Attributes [array] Contains an array of arrays of client's additional attributes with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column and Value contains the value. You can get the list of the specific attributes from the administrator of the Tiss system, as it is dynamic.

Description of the input parameters

ClientId [int] Client ID.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => clientNew
        ["name"] => Firma, s.r.o.
        [FirstName] => Jozef
        ["surname"] => Mrkva
        ["title"] => Ing.
        ["street"] => Veselá 10
        ["city"] => Košice
        ["zip"] => 04001
        ["country"] => Slovensko
        ["phone"] => 055 123 567
        ["fax"] => 055 123 789
        ["email"] => firma@example.com
        [Web] => www.example.com
        ["ico"] => 99999999
        ["dic"] => 888888888
        [ICDPH] => SK888888888
        [Attributes] => Array
            (
                [0] => Array
                    (
                        [Key] => velkost_topanok
                        ["value"] => 9
                    )

            )

    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"clientNew","Name":"Firma, s.r.o.","FirstName":"Jozef","Surname":"Mrkva","Title":"Ing.","Street":"Vesel\u00e1 10","City":"Ko\u0161ice","ZIP":"04001","Country":"Slovensko","Phone":"055 123 567","Fax":"055 123 789","Email":"firma@example.com","Web":"www.example.com","ICO":"99999999","DIC":"888888888","ICDPH":"SK888888888","Attributes":[{"Key":"velkost_topanok","Value":"9"}]}
Result example:
{"Result":"OK","ClientId":"123"}

Order

Order = a situation, when a customer buys a product/service from our company. It is used to place an order in the TISS. The currency is always the EURO – it is not necessary to send it in any way.

orderNew

Description of the input parameters

ClientId [int] Contains client ID obtained by the clientSearch method. If entered, these attributes are ignored: ClientName, ClientFirstName, ClientSurname, ClientTitle, ClientStreet, ClientCity, ClientZIP, ClientCountry, ClientPhone, ClientFax, ClientEmail, ClientWeb, ClientICO, ClientDIC, ClientICDPH, ClientAttributes.
ClientName [varchar] (optional if ClientID is entered) Contains the name of the client.
ClientFirstName [varchar] Contains the first name of the client.
ClientSurname [varchar] Contains the surname of the client.
ClientTitle [varchar] Contains the title of the client - e.g. MA.
ClientStreet [varchar] Contains the street and the street name of the client’s residence.
ClientCity [varchar] Contains the city/town of the client’s residence.
ClientZIP [varchar] Contains ZIP code of the client’s residence.
ClientCountry [varchar] Contains the country of the client’s residence.
ClientPhone [varchar] Contains the phone number of the client.
ClientFax [varchar] Contains the fax number of the client.
ClientEmail [varchar] Contains the e-mail of the client.
ClientWeb [varchar] Contains the web page of the client.
ClientICO [varchar] Contains ID of the client.
ClientDIC [varchar] Contains Tax ID of the client.
ClientICDPH [varchar] Contains VAT ID of the client.
DeliveryStreet [varchar] Delivery address - street and street number.
DeliveryCity [varchar] Delivery address - city.
DeliveryCountry [varchar] Delivery address - state.
DeliveryZIP [varchar] Delivery address - ZIP code.
DeliveryPerson [varchar] Delivery address - contact person.
DeliveryPhone [varchar] Delivery address - phone.
Discount [float] Contains a percentage discount on the total order. Item prices are listed BEFORE the discount.
Language [string] Contains the language code. Slovak: sk, English: en. Please, consult the administator about other language codes.
Items [array] Contains an array of order items. The parameters of the array elements: ItemProductID [int] - product ID (can be used "-1" for a descriptive item), ItemName [varchar] - the name of the item, ItemPrice [float] - unit price of the item without VAT before discounts ItemPriceBuy [float] - unit purchase price of the item without VAT ItemVAT [int] - percentage value of VAT, ItemPieces [float] - quantity, ItemDiscount [float] - percentage discount of the item. Item price is always BEFORE the discount.
OrderAttributes [array] Contains an array of arrays of additional attributes of the order with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column and Value contains the value. You will get the list of the specific attributes from the Tiss system administrator, as it is dynamic.
ClientAttributes [array] Contains an array of arrays of client additional attributes with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column and Value contains the value. You will get the list of the specific attributes from the Tiss system administrator, as it is dynamic.
Note [varchar] Contains order notes.
UserId [int] Contains user ID, to whom order should be assigned. You will get a specific value from the TISS system administrator.
Shipping [varchar] Contains text description of the shipping method.
Payment [int] Contains a specification of the payment method from the code list:
0: Cash
1: Money transfer
2: Collection
3: Cash on delivery
4: Meal vouchers
5: Payment/credit card
6: PayPal
7: Installments
8: Credit
9: Electronic payment
10: Advance invoice
DoNotReserve [bool] FALSE or not filled in: the item in the order will be reserved.
TRUE: the item in the order will NOT be reserved.
Currency [varchar] Currency with respect to ISO 4217 - eg. "EUR", "CZK", "HUF", "RON", etc. If it is not sent, EUR is set as a currency.
CurrencyRate [varchar] Exchange rate in the company's currency. If the order currency is the same as the company's currency, a value of "1" can be sent. If no value is sent, it is set to "1" automatically.
SavePK [bool] Contains information whether it is necessary to save an order card for glasses/contact lenses production. If it is false, all the other attributes are ignored.
We apologize for the chaotic Slovak-English terminology. Attributes used for glasses are d_r_*, d_l_*, b_r_*, b_l_*. For contact lenses kontakt_*. Note is common for both.
note_pk ["text"] Note. Common for glasses and contact lenses.
kontaktne_sosovky [int] Contains information whether it is glasses or contact lens.
0 = Glasses,
1 = Contact lens.
Other values are invalid.
d_r_sd [varchar] Distance, right eye: Spherical diopter.
d_r_c [varchar] Distance, right eye: Cylindrical diopter.
d_r_o [varchar] Distance, right eye: Ax.
d_r_pd [varchar] Distance, right eye: PD.
d_r_v [varchar] Distance, right eye: Height.
d_r_p1 [varchar] Distance, right eye: Prisma 1.
d_r_b1 [varchar] Distance, right eye: Basis 1.
d_r_p2 [varchar] Distance, right eye: Prisma 2.
d_r_b2 [varchar] Distance, right eye: Basis 2.
d_r_ad [varchar] Distance, right eye: Addition.
d_r_priemer [varchar] Distance, right eye: Diameter.
d_l_sd [varchar] Distance, left eye: Spherical diopter.
d_l_c [varchar] Distance, left eye: Cylindrical diopter.
d_l_o [varchar] Distance, left eye: Ax.
d_l_pd [varchar] Distance, left eye: PD.
d_l_v [varchar] Distance, left eye: Height.
d_l_p1 [varchar] Distance, left eye: Prisma 1.
d_l_b1 [varchar] Distance, left eye: Basis 1.
d_l_p2 [varchar] Distance, left eye: Prisma 2.
d_l_b2 [varchar] Distance, left eye: Basis 2.
d_l_ad [varchar] Distance, left eye: Addition.
d_l_priemer [varchar] Distance, left eye: Diameter.
b_r_sd [varchar] Reading, left eye: Spherical diopter.
b_r_c [varchar] Reading, left eye: Cylindrical diopter.
b_r_o [varchar] Reading, left eye: Ax.
b_r_pd [varchar] Reading, left eye: PD.
b_r_v [varchar] Reading, left eye: Height.
b_r_p1 [varchar] Reading, right eye: Prisma 1.
b_r_b1 [varchar] Reading, right eye: Basis 1.
b_r_p2 [varchar] Reading, right eye: Prisma 2.
b_r_b2 [varchar] Reading, right eye: basis 2.
b_r_ad [varchar] Reading, right eye: Addition.
b_r_priemer [varchar] Reading, right eye: Diameter.
b_l_sd [varchar] Reading, left eye: Spherical diopter.
b_l_c [varchar] Reading, left eye: Cylindrical diopter.
b_l_o [varchar] Reading, left eye: Ax.
b_l_pd [varchar] Reading, left eye: PD.
b_l_v [varchar] Reading, left eye: Height.
b_l_p1 [varchar] Reading, left eye: Prisma 1.
b_l_b1 [varchar] Reading, left eye: Basis 1.
b_l_p2 [varchar] Reading, left eye: Prisma 2.
b_l_b2 [varchar] Reading, left eye: Basis 2.
b_l_ad [varchar] Reading, left eye: Addition.
b_l_priemer [varchar] Reading, left eye: Diameter.
kontakt_p_sph [varchar] Right eye: Spherical diopter.
kontakt_p_cyl [varchar] Right eye: Cylindrical diopter.
kontakt_p_os [varchar] Right eye: Ax.
kontakt_p_add [varchar] Right eye: Addition.
kontakt_p_typ [varchar] Right eye: Type.
kontakt_p_bc [varchar] Right eye: BC.
kontakt_p_dia [varchar] Right eye: Diameter.
kontakt_l_sph [varchar] Left eye: Spherical diopterv.
kontakt_l_cyl [varchar] Left eye: Cylindrical diopter.
kontakt_l_os [varchar] Left eye: Ax.
kontakt_l_add [varchar] Left eye: Addition.
kontakt_l_typ [varchar] Left eye: Type.
kontakt_l_bc [varchar] Left eye: BC.
kontakt_l_dia [varchar] Left eye: Diameter.
SaveMultiplePK [array] Contains an array of order cards. Each array item contains separate order card for the very same order. All attributes of each order card are the same as mentioned above: d_r_*, d_l_*, b_r_*, b_l_*. For contact lenses kontakt_*.
This feature doesn't affect the old "SavePK" option and both ways can be used simultaneously.

Description of the output parameters

OrderNumber [varchar] Order number, which was assigned.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => orderNew
        [ClientName] => Firma, s.r.o.
        [ClientFirstName] => Jozef
        [ClientSurname] => Mrkva
        [ClientTitle] => Ing.
        [ClientStreet] => Veselá 10
        [ClientCity] => Košice
        [ClientZIP] => 04001
        [ClientCountry] => Slovensko
        [ClientPhone] => 055 123 567
        [ClientFax] => 055 123 789
        [ClientEmail] => firma@example.com
        [ClientWeb] => www.example.com
        [ClientICO] => 99999999
        [ClientDIC] => 888888888
        [ClientICDPH] => SK888888888
        [Discount] => 12
        [OrderAttributes] => Array
            (
                [0] => Array
                    (
                        [Key] => cislo_balika
                        ["value"] => 87653720286
                    )

            )

        [ClientAttributes] => Array
            (
                [0] => Array
                    (
                        [Key] => velkost_topanok
                        ["value"] => 9
                    )

            )

        [Items] => Array
            (
                [0] => Array
                    (
                        [ItemProductID] => 262
                        [ItemName] => Položka 1
                        [ItemPrice] => 99
                        [ItemPriceBuy] => 69
                        [ItemVAT] => 20
                        [ItemPieces] => 3
                        [ItemDiscount] => 20
                    )

                [1] => Array
                    (
                        [ItemProductID] => -1
                        [ItemName] => Položka 2
                        [ItemPrice] => 12.99
                        [ItemPriceBuy] => 9
                        [ItemVAT] => 20
                        [ItemPieces] => 2
                        [ItemDiscount] => 20
                    )

            )

    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"orderNew","ClientName":"Firma, s.r.o.","ClientFirstName":"Jozef","ClientSurname":"Mrkva","ClientTitle":"Ing.","ClientStreet":"Vesel\u00e1 10","ClientCity":"Ko\u0161ice","ClientZIP":"04001","ClientCountry":"Slovensko","ClientPhone":"055 123 567","ClientFax":"055 123 789","ClientEmail":"firma@example.com","ClientWeb":"www.example.com","ClientICO":"99999999","ClientDIC":"888888888","ClientICDPH":"SK888888888","Discount":"12","OrderAttributes":[{"Key":"cislo_balika","Value":"87653720286"}],"ClientAttributes":[{"Key":"velkost_topanok","Value":"9"}],"Items":[{"ItemProductID":"262","ItemName":"Polo\u017eka 1","ItemPrice":"99","ItemPriceBuy":"69","ItemVAT":"20","ItemPieces":"3","ItemDiscount":"20"},{"ItemProductID":"-1","ItemName":"Polo\u017eka 2","ItemPrice":"12.99","ItemPriceBuy":"9","ItemVAT":"20","ItemPieces":"2","ItemDiscount":"20"}]}
Result example:
{"Result":"OK","OrderNumber":"API201700767"}
    


orderEdit

Edits an existing order.

Description of the input parameters

OrderNumber [varchar] Contains order number (may also contain letters).
ClientId [int] ID of the client / supplier.
BranchId [int] Contains Branch ID.
Discount [float] Contains a percentage discount of the total order. Item prices are listed BEFORE the discount.
Phase [int] Order phase. If not entered, it will not change.
Confirmed [bool] Attribute whether the order was confirmed. This attribute is returned only if the result of the query is just one order. If the result is several orders, this attribute is assigned to the particular orders.
Dispatched [bool] Attribute whether the order was sent.
Delivered [bool] Attribute whether the order was delivered.
Completed [bool] Attribute whether the order was completed.
PaidCreditCard [bool] Marks whether the order was paid by credit/payment card. It shows the icon in the order list.
PaymentType [int] Contains a specification of the payment method from the code list:
0: Cash
1: Money transfer
2: Collection
3: Cash on delivery
4: Meal vouchers
5: Payment/credit card
6: PayPal
7: Installments.
Shipping [varchar] Contains text description of the shipping method.
Note [varchar] Contains order notes.
DeliveryStreet [varchar] Delivery address - street and street number.
DeliveryCity [varchar] Delivery address - city.
DeliveryCountry [varchar] Delivery address - state.
DeliveryZIP [varchar] Delivery address - ZIP code.
DeliveryPerson [varchar] Delivery address - contact person.
DeliveryPhone [varchar] Delivery address - phone.
UserId [int] Contains user ID, to whom order should be assigned. You will get a specific value from the TISS system administrator.
ProductReservation [bool] Attribute whether the items in the order are reserved.
Unstored [bool] Attribute whether the order was unstored.
OrderAttributes [array] Contains an array of arrays of additional attributes of the order with two attributes - Key ["string"] and Value ["string"]. Key contains the name of the column and Value contains the value. You will get the list of the specific attributes from the Tiss system administrator, as it is dynamic.
ReplaceItems If it is set to value 1, then all the existing items of the order will be deleted and replaced by the new ones.
Items [array] Contains an array of order items. The parameters of the array elements: ItemProductID [int] - product ID (can be used "-1" for a descriptive item), ItemName [varchar] - the name of the item, ItemPrice [float] - unit price of the item without VAT before discounts, ItemPriceBuy [float] - unit purchase price of the item without VAT ItemVAT [int] - percentage value of VAT, ItemPieces [float] - quantity, ItemDiscount [float] - percentage discount on the item. Item price is always BEFORE the discount.

Description of the output parameters

It has no output parameters.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => orderEdit
        [OrderNumber] => 20201234567
        [PaidCreditCard] => 1
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"orderEdit","OrderNumber":"20201234567","PaidCreditCard":"1"}
Result example:
{"Result":"OK"}


orderSearch

It is used to determine the selected order attributes based on its number.
Example: Order number 12345678 is entered at the input. The API returns values of the selected order attributes.

Description of the input parameters

OrderNumber [varchar] Contains order number (may also contain letters).
OrderNumber or ClientId is filled.
ClientId [int] Contains client ID.
OrderNumber or ClientId is filled.
BranchId [int] Contains Branch ID.
Returns only orders belonging to the selected Branch.
DateFrom [date] Date of the beginning of the required time interval.
DateTo [date] Date of the end of the required time interval.

Description of the output parameters

Orders [array] An array of arrays of orders. The following part describes the array elements:
OrderNumber [varchar] Order number.
ClientId [int] Client ID.
BranchId [int] Our Branch ID.
DateCreated ["date"] Order creation date.
TimeCreated ["time"] Order creation time.
DateTimeCreated ["datetime"] Order creation date and time.
PaymentType [int] Contains a specification of the payment method from the code list:
0: Cash
1: Money transfer
2: Collection
3: Cash on delivery
4: Meal vouchers
5: Payment/credit card
6: PayPal
7: Installments
Currency [varchar] 3 digit currency code.
CurrencyRate [float] Currency exchange rate related to home currency of the company.
PaidCreditCard [bool] An attribute whether the card payment was completed successfully.
Shipping [varchar] Contains text description of the shipping method.
Note [varchar] Contains order notes.
Phase [int] Order phase.
Confirmed [bool] An attribute whether the order was confirmed. This attribute is returned only if the result of the query is just one order. If the result is several orders, this attribute is assigned to the particular orders.
ProductReservation [bool] An attribute whether the items in the order are reserved. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
Unstored [bool] An attribute whether the order was unstored. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
Cancelled [bool] An attribute whether the order was cancelled. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
Dispatched [bool] An attribute whether the order was sent. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
Delivered [bool] An attribute whether the order was delivered. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
Completed [bool] An attribute whether the order was completed. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
SumPaid [float] An attribute whether the order was completed. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
TotalNetto [float] Total order price excl. VAT
TotalBrutto [float] Total order price incl. VAT
IsPaid [bool] An attribute whether the order was paid. This attribute is returned only if the result of the query is one order. If the result is several orders, this attribute is assigned to the particular orders.
DeliveryStreet [varchar] Delivery address - street and street number.
DeliveryCountry [varchar] Delivery address - state.
DeliveryZIP [varchar] Delivery address - ZIP code.
DeliveryPerson [varchar] Delivery address - contact person.
DeliveryPhone [varchar] Delivery address - phone.
InvoiceLink [varchar] Link to the HTML version of the invoice, if it is issued.
Parameter_* [varchar] If there are any custom order parameters, their name will be in the form of "Parameter_*", where * is the system name of the parameter.
Items [array] Contains an array of the items.
Name [varchar] The name of the item.
ProductId [int] Product ID.
Price [float] item unit price, excl. VAT.
PriceBuy [float] item unit purchase price, excl. VAT.
Price [float] item unit price, incl. VAT.
TotalPriceVat [float] Item price incl. VAT.
VAT [float] VAT percentage rate.
Pieces [float] Quantity.
DiscountTotal [float] The absolute value of the discount per item.
Discount [float] Percentage value of the discount per item.
UZP [float] The amount of compensation by the health insurance company.
TotalPriceVat [float] Total price of the order incl. VAT.
SavePK
...
kontakt_l_dia
All the parameters of the order card are identical to orderNew.
Parcels [array] Contains arrays of parcels for the order.
PackageId [varchar] ID (number) of package provided by the courier company.
State [varchar] Created, Ready for shipment, Shipped
Datetime ["datetime"] Datetime of creating the package.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => orderSearch
        [OrderNumber] => 12345678
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"orderSearch","OrderNumber":"12345678"}
Result example:
    {"Result":"OK","Confirmed":"false","Dispatched":"false","Delivered":"false","Orders":[{"OrderNumber":"202000001","ClientId":"3364","DateCreated":"2020-07-15","TimeCreated":"09:58:41","DateTimeCreated":"2020-07-15 09:58:41","PaymentType":"","Shipping":"","Note":"","Confirmed":"false","Dispatched":"false","Delivered":"false", "Items":[{"Name":"Polozka 1 UV","Price":44.55,"PriceVat":49,"TotalPriceVat":98,"DiscountTotal":0,"VAT":10,"Pieces":2,"UZP":0,"Discount":0},{"Name":"Polozka 2","Price":30, "PriceVat":30,"TotalPriceVat":30,"DiscountTotal":0,"VAT":0,"Pieces":1,"UZP":0, "Discount":0}],"TotalPriceVat":128,"SavePK":"true","note_pk":"ZPoznamka","kontaktne_sosovky":"0","d_r_sd":"-1,00","d_r_c":"-0,25", "d_r_o":"60","d_r_pd":"31","d_r_v":"","d_r_p1":"","d_r_b1":"","d_r_p2":"","d_r_b2":"","d_r_ad":"","d_r_priemer":"","d_l_sd":"-1,50", "d_l_c":"-0,25","d_l_o":"75","d_l_pd":"32","d_l_v":"","d_l_p1":"","d_l_b1":"","d_l_p2":"","d_l_b2":"","d_l_ad":"","d_l_priemer":"", "b_r_sd":"","b_r_c":"","b_r_o":"","b_r_pd":"","b_r_v":"","b_r_p1":"","b_r_b1":"","b_r_p2":"","b_r_b2":"","b_r_ad":"","b_r_priemer":"", "b_l_sd":"","b_l_c":"","b_l_o":"","b_l_pd":"","b_l_v":"","b_l_p1":"","b_l_b1":"","b_l_p2":"","b_l_b2":"","b_l_ad":"","b_l_priemer":"", "kontakt_p_sph":"","kontakt_p_cyl":"","kontakt_p_os":"","kontakt_p_add":"","kontakt_p_typ":"","kontakt_p_bc":"","kontakt_p_dia":"","kontakt_l_sph":"","kontakt_l_cyl":"", "kontakt_l_os":"","kontakt_l_add":"","kontakt_l_typ":"","kontakt_l_bc":"","kontakt_l_dia":""}]}
    

Purchase

It is used to create purchase orders in Tiss. Purchase = situation/act, when our company buys a product from a supplier. The currency is always EUROS - it is not necessary to send it in any way.

purchaseNew

Description of the input parameters

BranchId [int] Contains Branch ID.
SupplierId [int] Contains supplier ID acquired by using the SupplierSearch method.
If entered, the following attributes will be ignored: SupplierName, SupplierStreet, SupplierCity, SupplierZIP, SupplierCountry, SupplierPhone, SupplierFax, SupplierEmail, SupplierWeb, SupplierICO, SupplierDIC, SupplierICDPH, SupplierAttributes.
SupplierName [varchar] (optional if SupplierID is entered) Contains a name of the supplier.
SupplierStreet [varchar] Contains the street and the street number of the residence of the supplier.
SupplierCity [varchar] Contains the city/town of the residence of the supplier.
SupplierZIP [varchar] Contains a ZIP code of the residence of the supplier.
SupplierCountry [varchar] Contains the country of the residence of the supplier.
SupplierPhone [varchar] Contains the phone number of the supplier.
SupplierFax [varchar] Contains the fax number of the supplier.
SupplierEmail [varchar] Contains the e-mail of the supplier.
SupplierWeb [varchar] Contains the web page of the supplier.
SupplierICO [varchar] Contains ID of the supplier.
SupplierDIC [varchar] Contains Tax ID of the supplier.
SupplierICDPH [varchar] Contains VAT ID of the supplier.
Discount [float] Contains a percentage discount for the total order. Item prices are listed BEFORE the discount.
Items [array] Contains an array of arrays of the purchase. The parameters of the array items are: ItemProductID [int] - product ID (may be used "-1" for a descriptive item), ItemName [varchar] - item name, ItemPrice [float] - item unit price excl. VAT before discount, ItemVAT [int] - VAT percentage value, ItemPieces [float] - Quantity, ItemDiscount [float] - percentage discount per item. Price of the item is always BEFORE discount
InvoiceNumber [varchar] Contains an invoice number.
VS [varchar] Contains the variable symbol.
KS [varchar] Contains the constant symbol.
DateDelivery ["date"] Contains delivery date - tax fulfillment. In the form YYYY-MM-DD.
DateIssue ["date"] Contains the date the tax document was issued. In the form YYYY-MM-DD.
DateDue ["date"] Contains the due date. In the form YYYY-MM-DD.
PaymentType [int] Contains a specification of payment method from the code list:
0: Cash
1: Money transfer
2: Collection
3: Cash on delivery
4: Meal vouchers
5: Payment/credit card
6: PayPal
7: Installments
UserId [int] Contains a user ID, to whom the purchase should be assigned. You will get a specific value from the TISS system administrator.

Description of the output parameters

PurchaseNumber [varchar] Purchase number that was assigned.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => purchaseNew
        [SupplierName] => Firma, s.r.o.
        [SupplierStreet] => Veselá 10
        [SupplierCity] => Košice
        [SupplierZIP] => 04001
        [SupplierCountry] => Slovensko
        [SupplierPhone] => 055 123 567
        [SupplierFax] => 055 123 789
        [SupplierEmail] => firma@example.com
        [SupplierWeb] => www.example.com
        [SupplierICO] => 99999999
        [SupplierDIC] => 888888888
        [SupplierICDPH] => SK888888888
        [Discount] => 12
        [Items] => Array
            (
                [0] => Array
                    (
                        [ItemProductID] => 262
                        [ItemName] => Položka 1
                        [ItemPrice] => 99
                        [ItemVAT] => 20
                        [ItemPieces] => 3
                        [ItemDiscount] => 20
                    )

                [1] => Array
                    (
                        [ItemProductID] => -1
                        [ItemName] => Položka 2
                        [ItemPrice] => 12.99
                        [ItemVAT] => 20
                        [ItemPieces] => 2
                        [ItemDiscount] => 20
                    )

            )

    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"purchaseNew","SupplierName":"Firma, s.r.o.","SupplierStreet":"Vesel\u00e1 10","SupplierCity":"Ko\u0161ice","SupplierZIP":"04001","SupplierCountry":"Slovensko","SupplierPhone":"055 123 567","SupplierFax":"055 123 789","SupplierEmail":"firma@example.com","SupplierWeb":"www.example.com","SupplierICO":"99999999","SupplierDIC":"888888888","SupplierICDPH":"SK888888888","Discount":"12","Items":[{"ItemProductID":"262","ItemName":"Polo\u017eka 1","ItemPrice":"99","ItemVAT":"20","ItemPieces":"3","ItemDiscount":"20"},{"ItemProductID":"-1","ItemName":"Polo\u017eka 2","ItemPrice":"12.99","ItemVAT":"20","ItemPieces":"2","ItemDiscount":"20"}]}
Result example:
{"Result":"OK","PurchaseNumber":"P201700001"}

purchaseEdit

Description of the input parameters

PurchaseNumber [int] There must be a valid number of the purchase. If there is not entered the valid number, an error occurs as a returned result with the following statement = "No valid PurchaseNumber provided"
BranchId [int] Contains ID of the company branch.
Discount [float] Contains a percentage discount for the total order. Item prices are listed BEFORE the discount.
InvoiceNumber [varchar] Contains an invoice number.
VS [varchar] Contains the variable symbol.
KS [varchar] Contains the constant symbol.
DateDelivery ["date"] Contains delivery date - tax fulfillment. In the form YYYY-MM-DD.
DateIssue ["date"] Contains the date of issuing the tax document. In the form YYYY-MM-DD.
DateDue ["date"] Contains the due date. In the form YYYY-MM-DD.
PaymentType [int] Contains a specification of the payment method from the code list:
0: Cash
1: Money transfer
2: Collection
3: Cash on delivery
4: Meal vouchers
5: Payment/credit card
6: PayPal
7: Installments
UserId [int] Contains a user ID, to whom the purchase should be assigned. You will get a specific value from the TISS system administrator.
Note [varchar] Contains a note.
Unstored [bool] Attribute whether the order was unstored.
ReplaceItems [array] If it is set to value 1, then all the existing items of the order will be deleted and replaced by the new ones.
Items [array] Contains an array of arrays of the purchase. The parameters of the array items are: ItemProductID [int] - product ID (may be used "-1" for a descriptive item), ItemName [varchar] - item name, ItemPrice [float] - item unit price excl. VAT before discount, ItemVAT [int] - VAT percentage value, ItemPieces [float] - Quantity, ItemDiscount [float] - percentage discount per item. Price of the item is always BEFORE the discount

Description of the output parameters

It has no output parameters.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => purchaseNew
        [PurchaseNumber] => 12345
        [Discount] => 12
        [ReplaceItems] => 1
        [Items] => Array
            (
                [0] => Array
                    (
                        [ItemProductID] => 262
                        [ItemName] => Položka 1
                        [ItemPrice] => 99
                        [ItemVAT] => 20
                        [ItemPieces] => 3
                        [ItemDiscount] => 20
                    )

                [1] => Array
                    (
                        [ItemProductID] => -1
                        [ItemName] => Položka 2
                        [ItemPrice] => 12.99
                        [ItemVAT] => 20
                        [ItemPieces] => 2
                        [ItemDiscount] => 20
                    )

            )

    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"purchaseEdit","PurchaseNumber":12345","Discount":"12","Items":[{"ItemProductID":"262","ItemName":"Polo\u017eka 1","ItemPrice":"99","ItemVAT":"20","ItemPieces":"3","ItemDiscount":"20"},{"ItemProductID":"-1","ItemName":"Polo\u017eka 2","ItemPrice":"12.99","ItemVAT":"20","ItemPieces":"2","ItemDiscount":"20"}]}
Result example:
{"Result":"OK","PurchaseNumber":"P201700001"}

purchaseSearch

It is used to determine the selected purchase attributes based on its number.
Example: Order number 12345678 is entered at the input. The API returns values of the selected order attributes.

Description of the input parameters

InternalNumber [varchar] Contains purchase number (may also contain letters).
InternalNumber or SupplierId is filled.
SupplierId [int] Contains supplier ID.
InternalNumber or SupplierId is filled.
BranchId [int] Contains Branch ID.
Returns only purchases belonging to the selected Branch.
Type [varchar] Type of the Purchase.
DateFrom [date] Date of the beginning of the required time interval. Applied to date of taxation, not date of creating the purchase in Tiss.
DateTo [date] Date of the end of the required time interval. Applied to date of taxation, not date of creating the purchase in Tiss.
CreatedDateFrom [date] Date of the beginning of the required time interval. Applied to date of creating the purchase in Tiss.
CreatedDateTo [date] Date of the end of the required time interval. Applied to date of creating the purchase in Tiss.

Description of the output parameters

Purchases [array] An array of arrays of purchases. The following part describes the array elements:
InternalNumber [varchar] Purchase internal number.
SupplierId [int] Supplier ID.
BranchId [int] Our Branch ID.
DateCreated ["date"] Purchase creation date.
TimeCreated ["time"] Purchase creation time.
Date ["date"] Date of taxation (dátum zdaniteľného plnenia).
Type [varchar] Type of the Purchase.
Currency [varchar] 3 digit currency code.
CurrencyRate [float] Currency exchange rate related to home currency of the company.
Note [varchar] Contains order notes.
SumPaid [float] Total paid mount for this purchase.
TotalNetto [float] Total purchase price excl. VAT
TotalBrutto [float] Total purchase price incl. VAT
Parameter_* [varchar] If there are any custom order/purchase parameters, their name will be in the form of "Parameter_*", where * is the system name of the parameter.
Items [array] Contains an array of the items.
Name [varchar] The name of the item.
ProductId [int] Product ID.
Price [float] item unit price, excl. VAT.
PriceBuy [float] item unit purchase price, excl. VAT.
Price [float] item unit price, incl. VAT.
TotalPriceVat [float] Item price incl. VAT.
VAT [float] VAT percentage rate.
Pieces [float] Quantity.
DiscountTotal [float] The absolute value of the discount per item.
Discount [float] Percentage value of the discount per item.
PreAccount [varchar] Abbreviation of item type. Not mandatory.
TotalPriceVat [float] Total price of the order incl. VAT.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => purchaseSearch
        [InternalNumber] => P12345678
    )
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"purchaseSearch","InternalNumber":"P12345678"}
Result example:
{"Result":"OK","Purchases":[{"InternalNumber":"P12345678","SupplierId":"25961","BranchID":"3","CreatedDate":"2023-09-06","CreatedTime":"11:34:34","Date":"2023-09-06","Note":"","Currency":"CZK","CurrencyRate":"24.161","Items":[{"Name":"Item 1","ProductId":"1232","PriceBuy":1.51,"Price":36.52,"PriceVat":36.52,"TotalPriceVat":182.6,"DiscountTotal":0,"VAT":0,"Pieces":5,"Discount":0},{"Name":"Item 2","ProductId":"1233","PriceBuy":2.3,"Price":55.57,"PriceVat":55.57,"TotalPriceVat":1389.25,"DiscountTotal":0,"VAT":0,"Pieces":25,"Discount":0},{"Name":"Item 3","ProductId":"1234","PriceBuy":2.29,"Price":55.29,"PriceVat":55.29,"TotalPriceVat":1105.8,"DiscountTotal":0,"VAT":0,"Pieces":20,"Discount":0},{"Name":"Item 4","ProductId":"1235","PriceBuy":2.29,"Price":55.28,"PriceVat":55.28,"TotalPriceVat":276.4,"DiscountTotal":0,"VAT":0,"Pieces":5,"Discount":0},{"Name":"Item 5","ProductId":"1238","PriceBuy":1.54,"Price":37.11,"PriceVat":37.11,"TotalPriceVat":556.65,"DiscountTotal":0,"VAT":0,"Pieces":15,"Discount":0}],"TotalPriceVat":3510.7,"Files":[]}]}

Receipt

Serves for loading receipts for printing.

getReceipt

Description of input parameters

cashRegister [varchar] Contains a specification of the cash register and/or card payment terminal. This value is set by the TISS system administrator while installing the cash register. This data is then entered into the cash register application, from where it is sent here.

Description of the output parameters

Type [varchar] May be "deposit", "full", "invoice", "terminalPayment", "openDrawer", "XReport", "ZReport", "printDuplicate", "resetPrinter", "cashIn", "cashOut", "setPayments", "updatePrinterFirmware", "XReportTerminal", "ZReportTerminal", "resetTerminal", "printDuplicateTerminal".

"deposit" – ONLY the deposit is printed
"full" – all the items and deposits, if there are any, are printed
"invoice" – the payment of the invoice is printed
"terminalPayment" – the card terminal payment
"openDrawer", "XReport", "ZReport", "printDuplicate", "resetPrinter", "cashIn", "cashOut", "setPayments" - action to be performed (cash register)
"XReportTerminal", "ZReportTerminal", "resetTerminal", "printDuplicateTerminal" - action to be performed (card terminal)
OrderID [int] For "full" and "deposit": Unique order ID. It is necessary for calling the setReceipt method later.
For "invoice": Unique cash flow ID. WARNING - OrderID may have identical values for orders and for cash flows (based on Type)
OrderNumber [int] Only for "full" and "deposit". Order number, based on which the order can be looked up in TISS.
OpenDrawer [int] If it has a value of "1", a fiscal printer opens the cash drawer.
Deposit [float] or DepositToReturn [float] The amount of the deposit incl. VAT. "Deposit" for "deposit" Type, "DepositToReturn" for "full" Type.
Discount [float] Percentage value of the discount.
DiscountTotal [float] Absolute value of the discount.
Items [array] An array containing order items. Only for "full" and "invoice" Type. The following is a description of the array items:
Name [varchar] Item name.
Price [float] Item unit price excl. VAT (before the total percentage discount per order).
PriceVat [float] Item unit price incl. VAT (before total percentage discount per order).
TotalPriceVat [float] Total item price incl. VAT (before total percentage discount per order).
VAT [int] VAT rate in %.
Pieces [float] Item quantity.
UZP [float] The amount of compensation by the health insurance company in EUROS incl. VAT per one unit.
Discount [float] Percentage discount per item. The price is always BEFORE the discount.
Payments [array] An array containing order payments. Only for "full" and "deposit" Type. The following is a description of the array items:
Type [int] Type of payment. (0 = "Cash", 4 = "Vouchers", 5 = "Card", 9 = "Electronic payment")
Name [varchar] Name of the payment type.
Amount [float] The amount of payment.
InvoiceNumber [varchar] Invoice number. Only for "invoice".
Amount [float] Invoice payment amount. Only for "invoice", "cashIn", "cashOut" and "terminalPayment".
VS [varchar] Variable symbol. Only for "cashIn", "cashOut" and "terminalPayment".
payment5Name [varchar] Name of the number 5 payment. Only for "setPayments".
PaymentType [varchar] Type of payment: "deposit" or "paragon". Only for "terminalPayment".
PaymentID [int] Unique payment ID. Required for setPayment method. Only for "terminalPayment".

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => getReceipt
        [cashRegister] => str1
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"getReceipt","cashRegister":"str1"}
Result example:
{"Result":"OK","Type":"full","OrderID":947,"OrderNumber":"201900704","Discount":0,"Items":[{"Name":"cartier 652 c1","Price":375.83,"PriceVat":451,"TotalPriceVat":451,"DiscountTotal":67.65,"VAT":20,"Pieces":1,"UZP":0,"Discount":15}],"Payments":[{"Type":0,"Name":"Hotovos\u0165","Amount":383.35}]}


setReceipt

It is used to mark a receipt as printed.

Description of the input parameters

OrderID [int] Order ID.
Type [varchar] May be "deposit", "full" or "invoice". "deposit" – ONLY the deposit is printed. "full" – all the items and deposits, if there are any, are printed. "invoice" – the payment of the invoice is printed.
ReceiptID [int] Sequence number of the receipt generated by the cash register. Both for "deposit" and "full".

Description of the output parameters

Contains only the Result universal output parameter.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => setReceipt
        [OrderID] => 109062
        ["type"] => full
        [ReceiptID] => 29
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"setReceipt","OrderID":"109062","Type":"full","ReceiptID":"29"}
Result example:
{"Result":"OK"}

setPayment

It is used to mark a card payment as finished.

Description of the input parameters

0 = OK, 1 = Error. Mandatory.
PaymentID [int] Payment ID received from getReceipt.
Result [int]
ResultMessage [varchar] Text error response. Mandatory for Result = 1.

Description of the output parameters

Contains only the Result universal output parameter.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => setPayment
        [PaymentID] => 123
        [Result] => 0
        [ResultMessage] => ""
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"setPayment","PaymentID":"123","Result":"0","ResultMessage":""}
Result example:
{"Result":"OK"}

setECRInfo

It is used to receive service information about the cash register.

Description of the input parameters

cashRegister [varchar] Contains a specification of the cash register. This value is set by the TISS system administrator while installing the cash register. This data is then entered into the cash register application, from where it is sent here.
serviceTime [varchar] Contains date and time of nearest service required. Can be in the future or in the past.
batteryTime [varchar] Contains date and time of end of battery life. Can be in the future or in the past.
DKP [varchar] Contains DKP code.
COMport [int] Contains COM port number.
updateTime [varchar] Contains date and time of requested firmware update time by the cash register.

Description of the output parameters

Contains only the Result universal output parameter.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => setECRInfo
        [cashRegister] => str1
        [serviceTime] => "2024-01-01 01:00:00"
        [batteryTime] => "2024-01-01 01:00:00"
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"setECRInfo","cashRegister":"str1","serviceTime":"2024-01-01 01:00:00","batteryTime":"2024-01-01 01:00:00"}
Result example:
{"Result":"OK"}

getECRInfo

It is used to set information about the cash register.

Description of the input parameters

cashRegister [varchar] Contains a specification of the cash register. This value is set by the TISS system administrator while installing the cash register. This data is then entered into the cash register application, from where it is sent here.

Description of the output parameters

printerType [varchar] 0 = Efox, 1 = FT4000/FT5000
comPort [int] Number of COM port.
comSpeed [int] COM port speed.
isSerial [bool] true = Serial, false = USB.
comLinkAddr [int] Link address.
isThermal [bool] true = thermal printer, false = dot matrix printer
payment5Name [varchar] Name of payment number 5.
doLogs [int] 0 = no logs
1 = standard logs
2 = full logs
urlAPI [varchar] URL of Tiss API - example: "www14.tiss.sk/api/"
urlPing [varchar] URL of Tiss pinging service - example: "source.tiss.sk/"
forceUpdateAndRestart [bool] true = the app will update and restart immediately.
LANIP [varchar] IP address of the printer (only for FT4000/FT5000).
LANPort [varchar] Port number of the printer (only for FT4000/FT5000).
language [varchar] The language used.
currency [varchar] The default currency used.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => getECRInfo
        [cashRegister] => str1
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"getECRInfo","cashRegister":"str1"}
Result example:
{"Result":"OK","printerType":"0","comPort":"0","comSpeed":"0","isSerial":false,"comLinkAdr":"0","isThermal":"true","payment5Name":"","doLogs":true,"urlAPI":"","urlPing":"","forceUpdateAndRestart":false,"LANIP":"","LANPort":"","language":"cz","currency":"CZK"}

addECRLog

It is used to create new ECR log entry.

Description of the input parameters

cashRegister [varchar] Contains a specification of the cash register. This value is set by the TISS system administrator while installing the cash register. This data is then entered into the cash register application, from where it is sent here.
time [varchar] Contains timestamp.
message [varchar] Log entry content.

Description of the output parameters

Contains only the Result universal output parameter.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => addECRLog
        [cashRegister] => str1
        [time] => "2024-01-01 01:00:00"
        [message] => "Connection successful."
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"addECRLog","cashRegister":"str1","time":"2024-01-01 01:00:00","message":"Connection successful."}
Result example:
{"Result":"OK"}

setECRActionResult

It is used to add ECR action result.

Description of the input parameters

cashRegister [varchar] Contains a specification of the cash register. This value is set by the TISS system administrator while installing the cash register. This data is then entered into the cash register application, from where it is sent here.
type [varchar] Type of the action.

Description of the output parameters

Contains only the Result universal output parameter.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => setECRActionResult
        [cashRegister] => str1
        [type] => "openDrawer"
    )
    
Full call:

http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"setECRActionResult","cashRegister":"str1","type":"openDrawer"}
Result example:
{"Result":"OK"}

Voucher

Returns a complete list of the discount coupons.

getVoucher

Description of the input parameters

code [varchar] Contains a code of the voucher. This parameter is not mandatory. If not set, all the vouchers are returned.

Description of the output parameters

Code [varchar] Coupon code.
Value [float] Value - if the coupon is a percentage, the value is a percentage. If it is absolute, the value is absolute.
Reusable [bool] Defines whether the coupon may be used more than once. 1 = reusable. 0 = usable only once. setVoucher has to be called to mark a coupon as used. The getVoucher method will not change the Used value (or any other value) on its own.
Sold [bool] Marks whether a coupon was sold to a customer.
1 = sold,
0 = not sold.
Used [bool] Marks whether a coupon was used.
1 = used - invalid,
0 = not used - valid.
ValidFrom ["datetime"] Date and time the validity starts.
ValidTo ["datetime"] Date and time the validity ends.
Type ["text"] May be "number" or "percent".
"number" - absolute discount (e.g. in EUROS)
"percent" - percentage discount (%)
Note ["text"] Note.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => getVoucher
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"getVoucher"}
Result example:
{"Result":"OK","Data":[{"Code":"123","Value":"20","Reusable":"0","Used":"0","ValidFrom":"2020-07-01 00:00:00","ValidTo":"2020-07-10 00:00:00","Type":"percent"}]}


setVoucher

Sets if the coupon was used or sold.

Description of the input parameters

Code [varchar] Coupon code.
Used [bool] Marks whether a coupon was used.
1 = used - invalid,
0 = not used - valid.
Sold [bool] Marks whether a coupon was sold to a customer.
1 = sold,
0 = not sold.

Description of the output parameters

It does not have any output parameters.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => setVoucher
        ["code"] => 123
        [Used] => 1
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"setVoucher","Code":"123","Used":"1"}
Result example:
{"Result":"OK"}

Workplace

Lists workplaces.

workplaceSearch

Description of the input parameters

It does not have any input parameters.

Description of the output parameters

WorkplaceId [int] ID of Workplace.
Name [varchar] Name of the Workplace.
Email [varchar] E-mail of the Workplace.
ReservationTime [int] Number of minutes for every reservation.
MondayTimes [varchar]
TuesdayTimes [varchar]
WednesdayTimess [varchar]
ThursdayTimess [varchar]
FridayTimess [varchar]
SaturdayTimess [varchar]
SundayTimess [varchar]
Available starts of events during the day and ProductId separated by comma - in this formar:
[DatetimeStart1]/[ProductId1],[DatetimeStart2]/[ProductId2],etc...
Example:
10:00/123,11:00/123,etc...

This structure can be different for a different project!

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => workplaceSearch
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"workplaceSearch"}
Result example:
{"Result":"OK","Data":[{"WorkplaceId":"1","Name":"Shop1","Email":"example@example.com","ReservationTime":"90","MondayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824,16:00\/2824,17:30\/2824","TuesdayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824,16:00\/2824,17:30\/2824","WednesdayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824,16:00\/2824,17:30\/2824","ThursdayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824,16:00\/2824,17:30\/2824","FridayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824,16:00\/2824,17:30\/2824","SaturdayTimes":"9:00\/2824,10:30\/2824,13:00\/2824,14:30\/2824","SundayTimes":""},{"WorkplaceId":"2","Name":"Shop2","Email":"example@example.com","ReservationTime":"90","MondayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408,16:00\/1408,17:30\/1408","TuesdayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408,16:00\/1408,17:30\/1408","WednesdayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408,16:00\/1408,17:30\/1408","ThursdayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408,16:00\/1408,17:30\/1408","FridayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408,16:00\/1408,17:30\/1408","SaturdayTimes":"9:00\/1408,10:30\/1408,13:00\/1408,14:30\/1408","SundayTimes":""}]}
    

Event

Lists events with matching parameters. Maximal number of the result is 100.

eventSearch

Description of the input parameters

StartFrom ["datetime"] Start date and time of the returned events must be equal or greater than the date and time provided.
EndTo ["datetime"] Start date and time of the returned events must be equal or smaller than the date and time provided.
ClientId [int] Only events of the provided Client will be returned.
WorkplaceId [int] Only events of the provided Workplace will be returned.

Description of the output parameters

EventId [int] ID of Event.
ProductId [int] ID of the Product (usually service) for this event.
ClientId [int] ID of the Client.
ClientId2 [int] ID of the secondary Client.
WorkplaceId [int] ID of the Workplace where the event takes place.
DatetimeStart ["datetime"] Date and time of the start.
DatetimeEnd ["datetime"] Date and time of the end.
Text ["text"] Text comment/name of the Event.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => eventSearch
        [StartFrom] => 2021-01-01 00:00:00
        [EndTo] => 2021-01-02 20:00:00
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"eventSearch","StartFrom":"2021-01-01 00:00:00","EndTo":"2021-01-02 20:00:00"}
Result example:
{"Result":"OK","Data":[{"EventId":"50","ProductId":null,"ClientId":"1184","WorkplaceId":"1","DatetimeStart":"2021-01-01 14:00:00","DatetimeEnd":"2021-01-01 15:00:00","Text":""},{"EventId":"51","ProductId":null,"ClientId":"1186","WorkplaceId":"1","DatetimeStart":"2021-01-01 18:00:00","DatetimeEnd":"2021-01-01 19:00:00","Text":""}]}
    


eventNew

Creates a new event or updates the existing one.

Description of the input parameters

StartFrom ["datetime"] Start date and time of the returned events must be equal or greater than the date and time provided.
EndTo ["datetime"] Start date and time of the returned events must be equal or smaller than the date and time provided.
ClientId [int] Only events of the provided Client will be returned.
ClientId2 [int] Only events of the provided secondary Client will be returned.
WorkplaceId [int] Only events of the provided Workplace will be returned.

Description of the output parameters

EventId [int] ID of the created Event.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => eventNew
        [DatetimeStart] => 2021-01-01 10:00:00
        [DatetimeEnd] => 2021-01-01 11:00:00
        [ProductId] => 12
        [ClientId] => 138
        [ClientId2] => 118
        [WorkplaceId] => 1
        ["text"] => note goes here
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"eventNew","DatetimeStart":"2021-01-01 10:00:00","DatetimeEnd":"2021-01-01 11:00:00","ProductId":"12","ClientId":"138","ClientId2":"118","WorkplaceId":"1","Text":"note goes here"}
Result example:
{"Result":"OK","EventId":"123"}


eventRemove

Removes the existing event.

Description of the input parameters

EventId [int] EventId is mandatory.

Description of the output parameters

It does not have any output parameters.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => eventRemove
        [EventId] => 123
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"eventRemove","EventId":"123"}
Result example:
{"Result":"OK"}

GDPRAgreement

Lists GDPR Agreements with the matching parameters. Maximal number of the result is 100.

GDPRAgreementSearch

Description of the input parameters

StartFrom ["datetime"] Start date and time of the returned events must be equal or greater than the date and time provided.
EndTo ["datetime"] Start date and time of the returned events must be equal or smaller than the date and time provided.
ClientId [int] Only events of the provided Client will be returned.
WorkplaceId [int] Only events of the provided Workplace will be returned.

Description of the output parameters

EventId [int] ID of the Event.
ProductId [int] ID of the Product (usually service) for this event.
ClientId [int] ID of the Client.
WorkplaceId [int] ID of Workplace where the event takes place.
DatetimeStart ["datetime"] Date and time of the start.
DatetimeEnd ["datetime"] Date and time of the end.
Text ["text"] Text comment/name of the Event.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => eventSearch
        [StartFrom] => 2021-01-01 00:00:00
        [EndTo] => 2021-01-02 20:00:00
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"eventSearch","StartFrom":"2021-01-01 00:00:00","EndTo":"2021-01-02 20:00:00"}
Result example:
{"Result":"OK","Data":[{"EventId":"50","ProductId":null,"ClientId":"1184","WorkplaceId":"1","DatetimeStart":"2021-01-01 14:00:00","DatetimeEnd":"2021-01-01 15:00:00","Text":""},{"EventId":"51","ProductId":null,"ClientId":"1186","WorkplaceId":"1","DatetimeStart":"2021-01-01 18:00:00","DatetimeEnd":"2021-01-01 19:00:00","Text":""}]}


GDPRAgreementTypeSearch

Lists GDPR Agreement Types.

Description of the input parameters

It does not have any input parameters.

Description of the output parameters

GDPRAgreementTypeId [int] ID of the GDPR Agreement Type.
Name [varchar] Name of the GDPR Agreement Type.
Validity [int] Number of the default validity days.
Text [varchar] Full text of the GDPR agreement.
UsedForOrders [bool] If the GDPR Agreement Type is used for Orders.
UsedForGlassesCards [bool] If the GDPR Agreement Type is used for Glasses Cards.
UsedForExamCards [bool] If the GDPR Agreement Type is used for the Exam Cards.
UsedForAppointments [bool] If the GDPR Agreement Type is used for Appointments/Events..
UsedForOrderPickup [bool] If the GDPR Agreement Type is used for Order pick up.

Example of a call

An array of the input parameters:
        Array
    (
        [Token] => 12345678901234567890
        [Action] => GDPRAgreementTypeSearch
    )
    
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"GDPRAgreementTypeSearch"}
Result example:
{"Result":"OK","Data":[{"GDPRAgreementTypeId":"1","Name":"S\u00fahlas pre okuliare","Validity":"120","Text":"","UsedForOrders":true,"UsedForGlassesCards":false,"UsedForExamCards":false,"UsedForAppointments":false}]}
    


GDPRAgreementNew

Adds a new GDPR agreement for a client.

Description of the input parameters

ClientId [int] ID of the Client (from clientSearch).
GDPRAgreementTypeId [int] ID of the GDPR Agreement type (from GDPRAgreementTypeSearch).
DatetimeStart ["datetime"] Date and time of the validity start of GDPR Agreement.
DatetimeEnd ["datetime"] Date and time of the validity end of GDPR Agreement.
EventId [int] ID of the Event if applicable.
OrderId [int] ID of the Order if applicable.
PKId [int] ID of the Order Card if applicable.
RKId [int] ID of the Examination Card if applicable.

Example of a call

An array of the input parameters:
Array
(
[Token] => 12345678901234567890
[Action] => GDPRAgreementNew
[ClientId] => 123
[DatetimeStart] => 2000-01-01 00:00:00
[DatetimeEnd] => 2002-12-31 23:59:59
[EventId] => 123
)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"GDPRAgreementTypeSearch","ClientId":"123","ClientId":"123","DatetimeStart":"2000-01-01 00:00:00","DatetimeEnd":"2002-12-31 23:59:59","EventId":"123"}
Result example:
{"Result":"OK"}


GDPRAgreementRemove

DeletesGDPR agreement of a client.

Description of the input parameters

GDPRAgreementId [int] ID of GDPR Agreement.

Example of a call

An array of the input parameters:
Array
(
[Token] => 12345678901234567890
[Action] => GDPRAgreementNew
[GDPRAgreementId] => 123
)
Full call:
http://www.tiss.sk/api/?data={"Token":"12345678901234567890","Action":"GDPRAgreementRemove","GDPRAgreementId":"123"}
Result example:
{"Result":"OK"}

If you have any questions, please, feel free to write to us at macmike@macmike.sk