To query purchase and sales analysis via REST API, two endpoints are available, called using the GET method:
GET https://demo.flexibee.eu/c/demo/analyza-nakupu
GET https://demo.flexibee.eu/c/demo/analyza-prodeje
The {firma} segment in the address represents the company's database identifier. Supported output formats are selected via the .xml or .json extension.
Parameters
The parameters are, with minor differences, the same for both analyses. Only analyzovat is required.
Parameter | Description | Default value |
| Determines the target of the analysis being performed. See the values in the table below. | — |
| Specifies further breakdown of the analyzed data; accepts the same values as | No further breakdown. |
| Lower date limit for the analyzed documents. | No limit on the oldest document. |
| Upper date limit for the analyzed documents. | No limit on the newest document. |
| Determines whether the given dates are treated as posting dates. When set to |
|
| Determines whether non-accounting documents are also included in the analysis. |
|
| Sets whether monthly turnover summaries should be calculated. |
|
| Restricts the analysis to the selected division — ID or code. To specify multiple divisions, repeat the parameter. | All divisions, without restriction. |
| Includes non-catalog items in the analysis. Only relevant when analyzing by companies ( |
|
| Restricts the analysis to the selected price list item. Relevant when using | All price list items. |
| Restricts the analysis to the selected company. Relevant when using | All companies, without restriction. |
🚨 datumyUcetne=false cannot be combined with monthly summaries. If you want to analyze by issue date, you must also disable summaries at the same time — i.e., datumyUcetne=false&mesicniSumace=false. Otherwise the request will fail with error incompatible_param_values_exception — Parameter values [datumyUcetne, mesicniSumace] are mutually incompatible.
Values for the analyzovat and clenit parameters
Value | Meaning |
| Goods movement. |
| Movement summarized by goods groups. |
| By price list groups. |
| By manufacturer. |
| Warehouse turnovers. |
| Division turnovers. |
| Turnovers by order. |
| Turnovers by company. |
| Turnovers summarized by company groups. |
| By responsible person. |
| Turnovers by destination — sales analysis only. |
| Individual records without grouping. Only for |
Examples
Goods movement with no further restriction:
GET /c/demo/analyza-prodeje?analyzovat=cenik
Turnovers by company for the year 2012, by issue date — this requires disabling monthly summaries as well:
GET /c/demo/analyza-nakupu?analyzovat=adresar&datumOd=2012-01-01&datumDo=2012-12-31&datumyUcetne=false&mesicniSumace=false
Turnovers of company groups for two selected divisions:
GET /c/demo/analyza-prodeje?analyzovat=skupFir&nekatalogovePolozky=false&stredisko=code:A&stredisko=code:B
Sales of a single price list item, broken down by warehouse:
GET /c/demo/analyza-prodeje?analyzovat=cenik&clenit=sklad&cenik=code:KUFR
Error states
Situation | Response |
Missing parameter |
|
Unknown value for |
|
|
|
