Version 46.1 by Robin Huisman on 2024/04/10 15:33

Hide last authors
Roelof Zwaan 9.2 1 = Creating a Delivery file and binding them to a customer =
2
Luca de Laat 43.3 3 This chapter contains the information needed to understand the lab delivery file. A Lab delivery file only has to be updated when there are changes. Otherwise, TerraIndex will always show the last imported file.
Roelof Zwaan 9.2 4
Robin Huisman 11.1 5 {{warning}}
Robin Huisman 16.1 6 Latest version can be found here: [[https:~~/~~/www.sikb.nl/datastandaarden/sikb0101-bodembeheer>>url:https://www.sikb.nl/datastandaarden/sikb0101-bodembeheer]]
Robin Huisman 11.1 7 {{/warning}}
8
Robin Huisman 43.1 9 == What is a lab delivery file? ==
Roelof Zwaan 9.2 10
Luca de Laat 43.3 11 A lab delivery file contains the Customer code of the customer that will be sending the lab assignment. It also contains the analyses that can be requested from the lab by the customer. A Lab delivery file needs to be custom for every user and needs to be a XML file. This file will be available for the customer to choose their options for requesting and ordering an analysis at the lab. It's the Menu-card of the Lab, the user can choose from.
Roelof Zwaan 9.2 12
Robin Huisman 21.1 13 **Example files**:  [[attach:Labdeliveryfile.xml||rel="noopener noreferrer" target="_blank"]]
Roelof Zwaan 9.2 14
Robin Huisman 21.1 15 **XSD**:  [[attach:LabDelivery_v14.8.0.xsd||rel="noopener noreferrer" target="_blank"]]
Robin Huisman 16.1 16
17 **Domaintable files**:  [[immetingen lookup v14.8.0.xml>>url:https://wiki.terraindex.com/bin/download/Implementation%20documentation/Setting%20up%20Lab%20communication%20by%20REST%20services%20with%20TerraIndex/Lab%20assignment%20file/WebHome/immetingen%20lookup%20v14.8.0.xml?rev=1.2]]   [[imsikb0101 lookup v14.8.0.xml>>url:https://wiki.terraindex.com/bin/download/Implementation%20documentation/Setting%20up%20Lab%20communication%20by%20REST%20services%20with%20TerraIndex/Lab%20assignment%20file/WebHome/imsikb0101%20lookup%20v14.8.0.xml?rev=1.1]]
Robin Huisman 45.1 18 extracted from: **[[https:~~/~~/codes.sikb.nl>>url:https://codes.sikb.nl/]] 
Robin Huisman 46.1 19 \\Translations English to dutch:  **[[attach:LabdeliveryFile_14.8.0_ENG_NL.xslt||rel="noopener noreferrer" target="_blank"]]
Robin Huisman 16.1 20
Robin Huisman 46.1 21
Robin Huisman 33.1 22 {{toc/}}
Robin Huisman 16.1 23
Robin Huisman 33.1 24
Nico Lemaire 43.2 25 ~==> nle Add field Certification (screen 1 of labassignment)
26
Roelof Zwaan 9.2 27 == File structure ==
28
29 In the image below the main structure of the XML file is shown. Every table is described in more detail later on in this chapter.
Nico Lemaire 43.2 30
31 ~==> nle Dutch text in screenshot
Robin Huisman 21.1 32 [[image:1712158795900-531.png||height="604" width="391"]]
Roelof Zwaan 9.2 33
34 (% class="table-hover" %)
35 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 16.1 36 |(% colspan="1" rowspan="1" %)**version**|(% colspan="1" rowspan="1" %)SIKB version. This must be: **14.8.0**|(% colspan="1" rowspan="1" %)string
37 |(% colspan="1" %)**versionDeliveryData**|(% colspan="1" %)A lab indication of the version of the delivered data for this user. Could be a generation date with version: '12-7-2024' or a version 'v12.1'|(% colspan="1" %)string
38 |(% colspan="1" rowspan="1" %)**laboratory**|(% colspan="1" rowspan="1" %)A number given by SIKB/TerraIndex to the lab when requesting to connect to TerraIndex
39 [[Domaintable: Meetinstantie>>https://codes.sikb.nl/tablet/domain-table-details/4e270f0a-cefe-446e-9d4d-6666c91180a8]]|(% colspan="1" rowspan="1" %)integer
40 |(% colspan="1" rowspan="1" %)**language**|(% colspan="1" rowspan="1" %)(((
41 The language of the Delivery file content, like the package names, urgencies etc, in a three-letter ISO-639-2 code:
Roelof Zwaan 9.2 42
43 - dut = Dutch
44 - eng = English
Robin Huisman 16.1 45 - fra = French
46 - spa = Spanish
47 - ita = Italian
48 - deu = German
Roelof Zwaan 9.2 49 )))|(% colspan="1" rowspan="1" %)string
Robin Huisman 16.1 50 |(% colspan="1" rowspan="1" %)**Links**|(% colspan="1" rowspan="1" %)A table to connect the “AnalysisSet” and the “Clients”|(% colspan="1" rowspan="1" %)-
51 |(% colspan="1" rowspan="1" %)**AnalysisSets**|(% colspan="1" rowspan="1" %)A table containing the name and lab code of analysis set|(% colspan="1" rowspan="1" %)-
52 |(% colspan="1" rowspan="1" %)**Categories**|(% colspan="1" rowspan="1" %)A table containing all the possible lab categories|(% colspan="1" rowspan="1" %)-
53 |(% colspan="1" rowspan="1" %)**AnalysisLinks**|(% colspan="1" rowspan="1" %)A table containing all the analyses for an analysis set|(% colspan="1" rowspan="1" %)-
54 |(% colspan="1" rowspan="1" %)**Clients**|(% colspan="1" rowspan="1" %)A table of all the customer codes that are available for the company|(% colspan="1" rowspan="1" %)-
55 |(% colspan="1" rowspan="1" %)**LabSampleMatrices**|(% colspan="1" rowspan="1" %)A table of all the Lab sample Matrices a lab would like to have selectable.|(% colspan="1" rowspan="1" %)-
56 |(% colspan="1" rowspan="1" %)**SpecialAppointments**|(% colspan="1" rowspan="1" %)A table of all the special price agreements besides the default quote.|(% colspan="1" %)-
57 |(% colspan="1" rowspan="1" %)**Urgencies**|(% colspan="1" rowspan="1" %)A table containing a list of time frames in which the lab results need to be returned|(% colspan="1" %)-
Robin Huisman 38.1 58 |(% colspan="1" rowspan="1" %)//StoragePeriods//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
59 |(% colspan="1" rowspan="1" %)//Reports//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
60 |(% colspan="1" rowspan="1" %)//FractionLinks//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
Roelof Zwaan 9.2 61
Robin Huisman 33.1 62 == Structure explanation AnalysisSets ==
Roelof Zwaan 9.2 63
Robin Huisman 33.1 64 This table contains all the analyses sets or packages that your lab supports. The “AnalysisSetId” is your own identification code for the analysis packages.
Roelof Zwaan 9.2 65
Robin Huisman 33.1 66 It will be the chosen analysis and name, showed in the interface of TerraIndex:
67 \\[[image:1712163759805-731.png]]
Roelof Zwaan 9.2 68
Robin Huisman 38.1 69 [[image:1712163688142-709.png||height="443" width="599"]]
Robin Huisman 33.1 70
Roelof Zwaan 9.2 71 (% class="table-hover" %)
72 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 33.1 73 |(% colspan="1" rowspan="1" %)**AnalysisSetId**|(% colspan="1" rowspan="1" %)The identification code of the lab for the analyses Set or package|(% colspan="1" rowspan="1" %)string
74 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name/description of the analysis content of the set (This will also be shown in the user interface)|(% colspan="1" rowspan="1" %)string
Robin Huisman 38.1 75 |(% colspan="1" rowspan="1" %)//Sequence//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)string
76 |(% colspan="1" rowspan="1" %)//MinimalDeliveryTime//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)string
Roelof Zwaan 9.2 77
Robin Huisman 33.1 78 == Structure explanation Categories ==
Roelof Zwaan 9.2 79
Robin Huisman 33.1 80 “Category” does not need a lot of explanation. A category is a group defined by the lab where certain values in the “koppeltabel” can be grouped under. A category is determined by the lab and can be used in the “Links”.
Roelof Zwaan 9.2 81
Luca de Laat 43.3 82 In TerraIndex, it will be shown as Header/Group:
Robin Huisman 33.1 83 [[image:1712162927138-349.png]]
Roelof Zwaan 9.2 84
Robin Huisman 33.1 85
Robin Huisman 38.1 86 [[image:1712162765631-966.png||height="504" width="609"]]
Robin Huisman 33.1 87
88
Roelof Zwaan 9.2 89 (% class="table-hover" %)
90 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 33.1 91 |(% colspan="1" rowspan="1" %)**CategorieId**|(% colspan="1" rowspan="1" %)The code/Id of the category or group given by the lab|(% colspan="1" rowspan="1" %)string
92 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name/description of the category (This will also be shown in the user interface)|(% colspan="1" rowspan="1" %)string
93 |(% colspan="1" rowspan="1" %)**Sequence**|(% colspan="1" rowspan="1" %)Field is redundant and does not have to be filled|(% colspan="1" rowspan="1" %)integer
Roelof Zwaan 9.2 94
Robin Huisman 33.1 95 == Structure explanation AnalysisLink and Analysis ==
Roelof Zwaan 9.2 96
Luca de Laat 43.3 97 This table contains all the analyses that an analysis package can contain. Be sure the “analysepakketcode” corresponds to a code in the table: “analysepakketten”. The analysecode is your own identification code for the analyses.
Robin Huisman 33.1 98 \\[[image:1712163145392-331.png]]
Robin Huisman 38.1 99 \\[[image:1712163459761-326.png||height="488" width="799"]]
Roelof Zwaan 9.2 100
Robin Huisman 33.1 101 (% class="table-hover" %)
102 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Luca de Laat 43.3 103 |(% colspan="1" rowspan="1" %)**AnalysisSetId**|(% colspan="1" rowspan="1" %)The analysis set code that corresponds to a code in the “//AnalysisSets//”|(% colspan="1" rowspan="1" %)string
104 |(% colspan="1" rowspan="1" %)**Analysis**|(% colspan="1" rowspan="1" %)A table containing all the analyses that should be in this analysis set or package|(% colspan="1" rowspan="1" %)-
Roelof Zwaan 9.2 105
Robin Huisman 33.1 106 === __Analysis__ ===
107
Roelof Zwaan 9.2 108 (% class="table-hover" %)
109 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 33.1 110 |(% colspan="1" rowspan="1" %)**AnalysisId**|(% colspan="1" rowspan="1" %)The identification code of the lab for the analyses|(% colspan="1" rowspan="1" %)string
111 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name/description of the analysis content of the set (This will also be shown in the user interface)|(% colspan="1" rowspan="1" %)string
Robin Huisman 38.1 112 |(% colspan="1" rowspan="1" %)//MinimalDeliveryTime//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)string
113 |(% colspan="1" rowspan="1" %)//Observation//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
Roelof Zwaan 9.2 114
Robin Huisman 33.1 115 == Structure explanation Clients ==
Roelof Zwaan 9.2 116
Luca de Laat 43.3 117 A customer can have multiple “clients”. There always needs to be one “client” so that a lab assignment can be sent. But for example, when there is a price agreement for a certain project, a new “Client” can be added. Or when a company has multiple offices, every office can have its own “Client”.
Robin Huisman 33.1 118 \\It will be shown in the interface of TerraIndex, and needs to be chosen before selecting analysis sets:
119 [[image:1712163957735-690.png]]
Robin Huisman 38.1 120 \\[[image:1712163986350-364.png||height="409" width="544"]]
Roelof Zwaan 9.2 121
122 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 33.1 123 |(% colspan="1" rowspan="1" %)**ClientId**|(% colspan="1" rowspan="1" %)The customer identification code(s) for the company or office|(% colspan="1" rowspan="1" %)string
Luca de Laat 43.3 124 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name\description of the customer code, as shown in the interface, and will be invoiced.|(% colspan="1" rowspan="1" %)string
Roelof Zwaan 9.2 125
Robin Huisman 33.1 126 == Structure explanation LabSampleMatrices ==
127
Luca de Laat 43.3 128 The “LabSampleMatrices” is an important section of the XML. The “matrix” defines the main type of sample for the lab, and can contain multiple or predefined additional pretreatments of preservatives. Without a sample type in this table, a customer will not be able to send in lab assignments to the laboratory.
Robin Huisman 33.1 129
130 It needs to be chosen in the interface of TerraIndex, before any analysis set can be chosen:
131 \\[[image:1712164314258-543.png]]
132
133
Robin Huisman 38.1 134 [[image:1712164255757-638.png||height="556" width="716"]]
Robin Huisman 33.1 135
136 (% class="table-hover" %)
137 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**unit**
Luca de Laat 43.3 138 |(% colspan="1" rowspan="1" %)**CompartimentId**|(% colspan="1" rowspan="1" %)An SIKB ID that determines to which matrix the analyses belongs.
Robin Huisman 33.1 139 Domaintable: [[Compartment/Matrix>>https://codes.sikb.nl/tablet/domain-table-details/6134f3bb-6048-431d-a130-01290d84172c]]|(% colspan="1" rowspan="1" %)int
Robin Huisman 38.1 140 |(% colspan="1" rowspan="1" %)//CompartimentCode//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
Luca de Laat 43.3 141 |(% colspan="1" rowspan="1" %)**LabSampleMatrixCode**|(% colspan="1" rowspan="1" %)The laboratory matrix- or compartment-code of the lab, that will be also be sent in the Labassignment to the lab|(% colspan="1" %)string
Robin Huisman 36.3 142 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name\description of the matrix or compartment of the lab, as shown in the interface.|(% colspan="1" rowspan="1" %)string
Robin Huisman 33.1 143
Robin Huisman 36.2 144 == Structure explanation SpecialAppointment ==
Robin Huisman 33.1 145
Luca de Laat 43.3 146 The “SpecialAppointment" contains the names of the price catalogs, the default quote or the special project quote. This way, extra discount options are possible. It will be sent in the labassignment to the lab.
Robin Huisman 36.2 147
Robin Huisman 36.3 148 It needs to be chosen in the interface of TerraIndex, before any analysis set can be chosen, and empty means 'default quote':
Robin Huisman 36.2 149
150 [[image:1712164853683-202.png]]
151
Robin Huisman 38.1 152 [[image:1712165258813-987.png||height="619" width="697"]]
Robin Huisman 36.2 153
154
Robin Huisman 36.3 155 (% class="table-hover" %)
156 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**unit**
Luca de Laat 43.4 157 |(% colspan="1" rowspan="1" %)**SpecialAppointmentId**|(% colspan="1" rowspan="1" %)An identification code from the lab that will be sent in the Labassignment to the lab.|(% colspan="1" rowspan="1" %)string
Robin Huisman 36.3 158 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name\description of the matrix or compartment of the lab, as shown in the interface.|(% colspan="1" rowspan="1" %)string
Robin Huisman 38.1 159 |(% colspan="1" rowspan="1" %)//startdate//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
160 |(% colspan="1" rowspan="1" %)//finaldate//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)
Luca de Laat 43.4 161 |(% colspan="1" rowspan="1" %)**AppointmentTypeCode**|(% colspan="1" rowspan="1" %)The type of appointment, like: total pricelist, default quotation or special project agreement.
Robin Huisman 37.1 162 Domaintable: [[PriceAgreement Type>>https://codes.sikb.nl/tablet/domain-table-details/60028a8a-f386-47bf-bf2e-f46af49b7b56]]|(% colspan="1" rowspan="1" %)int
Robin Huisman 36.2 163
Robin Huisman 21.1 164 == Structure explanation Links ==
Roelof Zwaan 9.2 165
Luca de Laat 43.4 166 The “Links” is one of the most important sections of the XML. The “Link” defines the combination of Analysespackages, customer/clientcode, categories and sampletype. Without a combination in this table, a customer will not be able to send in lab assignments to the laboratory.
Robin Huisman 21.1 167 [[image:1712158823685-514.png||height="563" width="531"]]
168
Roelof Zwaan 9.2 169
170 (% class="table-hover" %)
171 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**unit**
Robin Huisman 38.1 172 |(% colspan="1" rowspan="1" %)**AnalysisSetId**|(% colspan="1" rowspan="1" %)The AnalysisSet code that corresponds to a code in the AnalysisSets table|(% colspan="1" rowspan="1" %)string
173 |(% colspan="1" rowspan="1" %)**ClientId**|(% colspan="1" rowspan="1" %)The code that corresponds to a code in Clients table|(% colspan="1" rowspan="1" %)string
174 |(% colspan="1" %)**SpecialAppointmentId**|(% colspan="1" %)The code that corresponds to a code in SpecialAppointments table|(% colspan="1" %)
175 |(% colspan="1" rowspan="1" %)**LabSampleMatrixCode**|(% colspan="1" rowspan="1" %)The code that corresponds to a code in LabSampleMatrix table|(% colspan="1" rowspan="1" %)(((
Roelof Zwaan 9.2 176 integer
177
178
179 )))
Robin Huisman 38.1 180 |(% colspan="1" %)Price|(% colspan="1" %)The optional Price indication for this combination of the Analysis|(% colspan="1" %)decimal
181 |(% colspan="1" %)CertificationId|(% colspan="1" %)The optional code that corresponds to the way of Sample and analysis handling as described in a certification.
Luca de Laat 43.4 182 Some other labs have this arranged by the LabSampleMatrix types.
Robin Huisman 38.1 183 Domaintable: [[CertificeringsCode >>https://codes.sikb.nl/tablet/domain-table-details/df7ffd7c-192c-44f7-ae9f-0461d9266b30]]|(% colspan="1" %)int
184 |(% colspan="1" rowspan="1" %)**CategoryId**|(% colspan="1" rowspan="1" %)The code that corresponds to a category code in Categories table|(% colspan="1" rowspan="1" %)string
185 |(% colspan="1" rowspan="1" %)//Accredited//|(% colspan="1" rowspan="1" %)-not in use-|(% colspan="1" rowspan="1" %)bool
Roelof Zwaan 9.2 186
Robin Huisman 41.1 187 == Structure explanation Urgencies ==
Roelof Zwaan 9.2 188
Luca de Laat 43.4 189 This table contains a list with different delivery times for analyses results. For example, 5 work days, overnight, within 48 hours and so on. The “UrgencyId” is a code given by the lab.
Roelof Zwaan 9.2 190
Robin Huisman 41.1 191 [[image:1712324236054-772.png||height="372" width="511"]]
Roelof Zwaan 9.2 192
193 (% class="table-hover" %)
194 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
Robin Huisman 41.1 195 |(% colspan="1" rowspan="1" %)**UrgencyId**|(% colspan="1" rowspan="1" %)The code of the lab for when the analysis results need to be returned to the customer|(% colspan="1" rowspan="1" %)string
196 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name/ description of the urgency, to show in the interface.|(% colspan="1" rowspan="1" %)string
Roelof Zwaan 9.2 197
Robin Huisman 41.1 198 == Structure explanation StoragePeriods ==
Robin Huisman 33.1 199
Luca de Laat 43.4 200 This table contains a list with different storage periods for the storage of the delivered Samples and its containers. For example, '1 month', '5 weeks', 'customer agreement' and so on. The “StoragePeriodId” is a code given by the lab.
Robin Huisman 41.1 201
202 [[image:1712324393233-546.png||height="359" width="519"]]
203
204 (% class="table-hover" %)
205 |(% colspan="1" rowspan="1" %)**Attribute name**|(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)**Unit**
206 |(% colspan="1" rowspan="1" %)**StoragePeriodId**|(% colspan="1" rowspan="1" %)The code of the lab for when the analysis results need to be returned to the customer|(% colspan="1" rowspan="1" %)string
207 |(% colspan="1" rowspan="1" %)**Description**|(% colspan="1" rowspan="1" %)The name/ description of the Storage Period, to show in the interface.|(% colspan="1" rowspan="1" %)string