login - първо се извиква функция за вход която връща сесия.
URL:https://v5.icash.bg/clientapi/v1/login
array (
'api_key' => 'df6mswkb29ambswqxd71sv0w3tcm5vtm',
'nonce' => 1713456218,
'signature' => '3F98B59B5B8EFDCA523D78AAD8274B474F93DBC8F7AF65972E22F51CE062EA4D',
'WareHouseID' => '11318',
'UserID' => '2',
)'{"nonce":"1713456218","status":0,"error_message":"Authentication Error"}'
Добавяне на артикул
URL:https://v5.icash.bg/clientapi/v1/add-sale-item
array (
'api_key' => 'df6mswkb29ambswqxd71sv0w3tcm5vtm',
'nonce' => 1713456219,
'signature' => 'BC90C255C6A58B4DA2B651A4E08BFCC49C95EF1E86E975F6BB8F6D66CAB45A69',
'WareHouseID' => '11318',
'UserID' => '2',
'ses' => NULL,
'SaleItemBarcode' => '11223',
'SaleItemInventoryID' => '11223',
'SaleItemName' => 'Мед от сребро номер 11223',
'SaleItemType' => 'PRODUCT',
'SaleItemCashRegisterName' => 'Мед от злато номер 11223',
'SaleItemPrimaryMeasureUnitID' => '1',
'SaleItemTaxGroupID' => '1',
'SaleItemSellPrice' => '2.00',
)'{"nonce":"1713456219","status":0,"error_message":"Missing value for ses"}'
Добавяне на контрагент
URL:https://v5.icash.bg/clientapi/v1/add-contragent
array (
'api_key' => 'df6mswkb29ambswqxd71sv0w3tcm5vtm',
'nonce' => 1713456220,
'signature' => '9AD8F434FCBE87E826DCBB89D28828FB19C6B5D163D73BA3D6A2AF25B68FDF43',
'WareHouseID' => '11318',
'UserID' => '2',
'ses' => NULL,
'ContragentName' => 'Иван Иванов',
'ContragentType' => 'CLIENT',
'ContragentCountryCode' => 'BG',
'ContragentCityName' => 'София',
'ContragentTaxNum' => 'BG131047312',
'ContragentVatRegistered' => '1',
'ContragentAddress' => 'София',
'ContragentPhone' => '0889447481',
)'{"nonce":"1713456220","status":0,"error_message":"Missing value for ses"}'
Създаване на нова операция
URL:https://v5.icash.bg/clientapi/v1/new-operation
array (
'api_key' => 'df6mswkb29ambswqxd71sv0w3tcm5vtm',
'nonce' => 1713456221,
'signature' => 'E1916CEC5FBA8A3304AC7CFF2A5D8CFB03DE38704D0266ECC52A535F1E58D35B',
'WareHouseID' => '11318',
'UserID' => '2',
'ses' => NULL,
'ImportSource' => 'Lotarry',
'ImportRefID' => '112232',
'OperationType' => 'Sell',
'CashRegisterID' => '2',
'StoreID' => '1',
'ContragentID' => 0,
)'{"nonce":"1713456221","status":0,"error_message":"Missing value for ses"}'
Добавяне на артикул към операцията
Плащане на операцията
URL:https://v5.icash.bg/clientapi/v1/add-operation-payment
array (
'api_key' => 'df6mswkb29ambswqxd71sv0w3tcm5vtm',
'nonce' => 1713456222,
'signature' => '7B971E3CF26F5442830823653DAC054F4F4446E7EDF00FC715F9B1D4004EB8FB',
'WareHouseID' => '11318',
'UserID' => '2',
'ses' => NULL,
'OperationID' => NULL,
'PayTypeID' => 1,
'PaymentSum' => 2,
)'{"nonce":"1713456222","status":0,"error_message":"Missing value for ses"}'
Приключване на операцията