Data for filtering (StorageQuery object)
JSON:
Receive all Sent Documents (“statuses”: 2,3)
{
"archive": false,
"statuses": [
2,
3
],
"type": [
{
"type": 0,
"title": "all",
"description": "all"
},
{
"type": 0,
"title": "all",
"description": "all"
}
],
"exchangeStatus": [],
"extraParams": [],
"tags": [],
"loadComments": true,
"loadTags": true,
"loadStatuses": true,
"direction": {
"type": "EQ",
"sender": [
"9864066822430"
],
"receiver": []
},
"family": 12
}
Receive all incoming documents (“statuses”: 4,5) from the specified sender/-s (sender:gln)
{
"archive": false,
"statuses": [
4,
5
],
"type": [
{
"type": 0,
"title": "all",
"description": "all"
},
{
"type": 0,
"title": "all",
"description": "all"
}
],
"exchangeStatus": [],
"extraParams": [],
"tags": [],
"loadComments": true,
"loadTags": true,
"loadStatuses": true,
"direction": {
"type": "EQ",
"sender": [
"9864067620417"
],
"receiver": [
"9864066822430"
]
},
"family": 12
}
Get all Archival documents. As incoming and sent documents become archived, all statuses are indicated, recipient / sender = own GLN
{
"archive": true,
"statuses": [
2,
3,
4,
5,
6
],
"type": [
{
"type": 0,
"title": "all",
"description": "all"
},
{
"type": 0,
"title": "all",
"description": "all"
}
],
"exchangeStatus": [],
"extraParams": [],
"tags": [],
"loadComments": true,
"loadTags": true,
"loadStatuses": true,
"direction": {
"type": "OR",
"sender": [
"9864066822430"
],
"receiver": [
"9864066822430"
]
},
"family": 12
}
Table 2 - Parameters description of object StorageQuery
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object StorageQuery |
|||
extraParams |
List<ExtraQueryParameters> |
array of objects; |
|
multiExtraParams |
List<ExtraQueryParameters> |
array of objects; |
|
type |
M |
List<XDocType> |
array of objects; document types list: 0 - all types, 1/2/3 … and more - specific document type |
statuses |
M |
List<Integer> |
array; a list of statuses (states) of documents according to which the selection will take place:
|
extraStatuses |
List<Integer> |
array; extrastatuses list |
|
tags |
List<Long> |
array; tag |
|
exchangeStatus |
O |
List<Integer> |
array; document flow status |
docs |
List<Long> |
array; documents |
|
docUUIDs |
List<UUID> |
array; unique document identifiers |
|
partners |
List<Long> |
array; counterparty identifiers |
|
families |
List<Integer> |
array; service attribute (family)
|
|
direction |
M |
object; document flow direction; specified Sender, Recipient and the connection between them in terms of document selection |
|
limit |
O |
object; selection filter (data output settings) |
|
orderBy |
O |
OrderBy |
filter document by it date or description |
groupBy |
O |
String |
united by chain / document id |
number |
O |
String |
document number |
family |
O |
int |
service
|
partnerId |
Long |
retail network id |
|
chainHash |
String |
the hash value obtained by chain processing |
|
docHash |
String |
the hash value obtained by document processing |
|
docDate |
O |
object; the date which is specified in the document (according to Kyiv time relative to UTC in UNIX-timestamp format) from / to |
|
docCreate |
O |
object; document creation date (according to Kyiv time relative to UTC in UNIX-timestamp format) from / to |
|
docRead |
O |
object; date of reading the document (according to Kyiv time relative to UTC in UNIX-timestamp format) from / to |
|
docChanged |
O |
object; the date of the last change of the document (according to Kyiv time relative to UTC in UNIX-timestamp format) from / to |
|
archive |
Boolean |
mark of an archival feature presence in a document |
|
important |
boolean |
important document mark |
|
visible |
boolean |
visibility mark |
|
loadBody |
boolean |
mark of the body presence in a document |
|
loadComments |
boolean |
mark of the comments presence in a document |
|
loadStatuses |
boolean |
mark of the statuses presence in a document |
|
loadTags |
boolean |
mark of the tags presence in a document |
|
loadChain |
boolean |
mark of the chains presence in a document |
|
loadAttachments |
boolean |
mark of the attachments presence in a document |
Table 3 - Parameters description of object ExtraQueryParameters
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object ExtraQueryParameters |
|||
operator |
enum (AND, OR) |
||
type |
M |
enum (EQUALS, EQUALS_UUID, EQUALS_MD5, LIKE, MORE, MORE_EQ, LESS, LESS_EQ, IN) |
|
String |
parameter name |
||
value |
String |
parameter id |
Table 4 - Parameters description of object Direction
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object Direction |
|||
type |
enum (EQ, OR, IN) |
sample type; possible values: EQ/OR/IN
|
|
sender |
О/Н |
List<String> |
array; senders; senders GLN - mandatory, but may be empty if the GLN receiver array is specified |
receiver |
О/Н |
List<String> |
array; receivers; receivers GLN - mandatory, but may be empty if the GLN sender array is specified |
Table 5 - Parameters description of object Limitation
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object Limitation |
|||
offset |
O |
int |
offset the first element of the list relative to the upper limit of the sample (by default 0) |
count |
O |
int |
sampling limit (amount) |
Table 6 - Parameters description of object DateTimeRange
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object DateTimeRange |
|||
startTimestamp |
long |
the beginning of the time range |
|
finishTimestamp |
long |
end of time range |
Table 7 - Parameters description of object XDocType
Parameter |
Mandatory/Optional |
Format |
Description |
---|---|---|---|
Object XDocType |
|||
type |
int |
document / ticket type id |
|
title |
String |
document / ticket name |
|
description |
String |
document / ticket description |
Table 8 - fieldName parameters description (object ExtraQueryParameters)
Parameter id |
Parameter name |
Mandatory/Optional |
Format |
Description |
---|---|---|---|---|
1 |
created_from |
UUID |
document or chain ID |
|
2 |
is_signed |
TINYINT |
signing mark
|
|
3 |
encrypted |
TINYINT |
encryption mark |
|
4 |
comdoc_reestr_id |
INT |
factoring Register id (on the basis of a commercial document) |
|
5 |
comdoc_reestr_is_active |
TINYINT |
activity note of the factoring agreement |
|
6 |
ftpex_file_name |
VARCHAR |
the name of the file sent via FTP |
|
7 |
ftpex_file_date |
INT |
the document date / time of sending via FTP |
|
8 |
inv_date |
INT |
invrpt document date (Inventory Report) |
|
9 |
inv_num |
VARCHAR |
invrpt document number (Inventory Report) |
|
11 |
sub_doc_type_id |
INT |
document subtype id ( subtype_description ) |
|
12 |
sub_status_id |
INT |
document status id (in more detail); characterizes the state of the document chain |
|
13 |
action |
VARCHAR |
status / state of the document according to the user’s actions; For EDI:
For Vilnyi:
For ETTN:
|
|
14 |
buyer_uuid |
VARCHAR |
sender of the document |
|
15 |
consignee_uuid |
VARCHAR |
consignee |
|
16 |
consignor_uuid |
VARCHAR |
consignor |
|
17 |
customer_uuid |
VARCHAR |
buyer |
|
18 |
performer_uuid |
VARCHAR |
performer |
|
19 |
supplier_uuid |
VARCHAR |
supplier |
|
20 |
delivery_place_uuid |
VARCHAR |
place of delivery |
|
21 |
contract_date |
VARCHAR |
date of contract |
|
22 |
contract_number |
VARCHAR |
contract number |
|
23 |
delivery_date |
O |
INT |
delivery date |
24 |
order_number |
O |
VARCHAR |
order number |
25 |
order_date |
INT |
order date |
|
26 |
return_date |
INT |
return date |
|
27 |
summ |
VARCHAR |
amount including VAT |
|
28 |
parent_chain_hash |
MD5 |
chain hash |
|
29 |
period |
VARCHAR |
deadline for signing the document |
|
31 |
trans_id |
VARCHAR |
transaction id |
|
32 |
ttn |
VARCHAR |
number of the consignment note |
|
33 |
doc_start_date |
VARCHAR |
the beginning of the document signing period |
|
34 |
doc_end_date |
VARCHAR |
the deadline for document signing |
|
35 |
delivery_note_number |
VARCHAR |
tax invoice number |
|
42 |
contract_gln |
VARCHAR |
delivery place GLN at the goods agreement (Agreem-> Comdoc) |
|
43 |
doc_date |
INT |
date from document |
|
44 |
delivery_agreement_number |
VARCHAR |
number of agreements |
|
45 |
delivery_agreement_date |
INT |
date of agreement |
|
46 |
varn |
VARCHAR |
legally significant document id |
|
47 |
other_info |
TEXT |
additional data |
|
48 |
sub_doc_date |
INT |
document subtype date |
|
49 |
sub_doc_number |
VARCHAR |
document subtype number |
|
50 |
doc_error |
TEXT |
working with the document error |
|
51 |
doc_info |
TEXT |
comment to the document |
|
52 |
old_doc_id |
INT |
document id |
|
53 |
sub_status_date |
INT |
document status date (document chain status) |
|
54 |
from_doc_id |
INT |
the serial number of the document in the chain |
|
56 |
doc_num |
VARCHAR |
document number |
|
57 |
sender |
VARCHAR |
sender GLN |
|
58 |
recipient |
VARCHAR |
recipient GLN |
|
59 |
file_name |
VARCHAR |
name of the attached file (attachment) |
|
60 |
xml_hash |
VARCHAR |
content hash of the document |
|
61 |
answer_doc_id |
INT |
COMDOC id which is sent in response |
|
80 |
identifier |
VARCHAR |
document ID in the client system |
|
82 |
compound_number |
VARCHAR |
component number |
|
85 |
doc_process |
TINYINT |
||
87 |
users |
VARCHAR |
||
88 |
basis_doc_subtype |
INT |
base document subtype |
|
89 |
basis_doc_number |
INT |
base document number |
|
90 |
basis_doc_date |
INT |
base document date |
|
summ_without_tax |
INT |
amount without VAT |
||
tax_summ |
INT |
VAT amount |
||
summ |
INT |
amount including VAT |
||
129 |
receiving_note_number |
VARCHAR |
Reception notification number (DOCUMENTINVOICE … ReceivingAdviceNumber) |
|
137 |
branch_uuid |
VARCHAR |
«branch supplies» uuid (АТБ COMDOC+DESADV) |
|
parent_doc_uuid |
VARCHAR |
uuid initial e-TTN (recorded when replacing the sent draft) |
||
139 |
format_version |
VARCHAR |
version number (field C_DOC_VER) from Tax Invoice (DECLAR) or Adjustment to Tax Invoice (DECLARj12) |
|
142 |
parent_docs_match |
INT |
0 - comdoc_007 with changed data for reconciliation by desadv; 1 - comdoc_007 with correct / unchanged data for reconciliation on desadv |
|
149 |
post_start_date |
[yyyy-MM-dd] |
eadline date for Metro 7a documents |
|
153 |
review_deadline_date |
[yyyy-MM-dd] |
deadline for review for Metro 7b documents (ReviewDeadlineDate) |
|
sign_hash |
VARCHAR |
signature hash |
||
draft_date_created |
INT |
draft creation date |
||
carrier_b_uuid |
BINARY |
carrier identifier |
||
consignee_b_uuid |
BINARY |
consignee identifier |
||
consignor_b_uuid |
BINARY |
shipper ID |
||
external_doc_id |
INT |
id TTN document in the Central Base |
Table 9 - DocType parameters description (object XDocType)
Type |
Name |
Description |
---|---|---|
0 |
all |
all |
1 |
invoice |
|
2 |
orders |
|
3 |
recadv |
|
4 |
desadv |
|
5 |
ordrsp |
|
6 |
pricat |
|
7 |
comdis |
|
10 |
declar |
|
11 |
insdes |
|
13 |
slsrpt |
|
14 |
invrpt |
|
15 |
coacsu |
|
17 |
iftmin |
|
18 |
retann |
|
19 |
iftmbf |
|
20 |
partin |
|
21 |
mscons |
|
25 |
retins |
|
28 |
comdoc |
|
29 |
declarj12 |
|
30 |
condra |
|
35 |
metro7a |
|
39 |
metro7b |
|
40 |
prodlist |
|
41 |
agreem |
|
42 |
iftmbc |
|
59 |
documentinvoice |
|
67 |
doccorinvoice |
|
98 |
quotes |
|
111 |
transhipment |
|
117 |
acceptance |
|
113 |
booking |
|
114 |
bookingconfirmation |
|
112 |
completion |
|
118 |
docinvoiceact |
|
119 |
discrepancy |
|
120 |
contrl |
|
121 |
ttn |
|
122 |
simple_doc |
Vilnyi service document |
123 |
reload |
|
124 |
disagreement |
|
125 |
adjustment |
Act of adjustment |
126 |
warehouse_change |
Act of change of destination |
127 |
unload_storage |
Act of unloading at the intermediate warehouse |
128 |
load_storage |
Act of loading in the intermediate warehouse |
129 |
ettn_stop |
Act of forced termination of TTN |
130 |
resealing |
The act of resealing |
131 |
load_reject |
Act of refusal to download |
132 |
ttn_ecmr |
ETTN (v3) |
133 |
reload_ecmr |
Act of overload (v3) |
134 |
disagreement_ecmr |
Act of disagreements (v3) |
135 |
consignee_change_ecmr |
Act of change of destination (v3) |
136 |
storage_delivery_ecmr |
Act of unloading at an intermediate warehouse (v3) |
137 |
adjustment_ecmr |
Act of adjustment (v3) |
138 |
storage_pickup_ecmr |
Act of loading in intermediate storage (v3) |
139 |
resealing_ecmr |
Act of resealing (v3) |
140 |
load_reject_ecmr |
Act of load rejection (v3) |
141 |
stop_ecmr |
Act of forced termination of e-ttn (v3) |
Table 10 - Description of COMDOC subtypes
Commercial document subtype |
sub_doc_type_id |
Name and description |
---|---|---|
005 |
5 |
|
006 |
6 |
|
007 |
7 |
|
008 |
8 |
|
009 |
9 |
Certificate of Nonconformity/Non-conformance Report (COMDOC_009) |
011 |
11 |
|
012 |
12 |
|
013 |
13 |
|
015 |
15 |
|
016 |
16 |
|
018 |
18 |
|
019 |
19 |
|
021 |
21 |
|
022 |
22 |
|
023 |
23 |
|
024 |
24 |
|
025 |
25 |
|
026 |
26 |
|
027 |
27 |
|
028 |
28 |
|
029 |
29 |
|
030 |
30 |
|
031 |
31 |
|
032 |
32 |
|
033 |
33 |
|
034 |
34 |
|
035 |
35 |
Act of acceptance of goods for the consignment note (COMDOC_035) |
036 |
36 |
|
Invoice subtipe (DOCUMENTINVOICE.DocumentFunctionCode) |
sub_doc_type_id |
Name and description |
TN |
0 |
Commodity invoice / Invoice by quantity (for Metro and Leroy Merlin) |
СTN |
1 |
|
TN |
1 |
|
PRN |
2 |
|
DRN |
3 |