vintrace-sdk 0.1.3 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -782,6 +782,150 @@ type ProductAnalysisResponse = z.infer<typeof ProductAnalysisResponseSchema>;
782
782
  type ProductAnalysisParams = z.infer<typeof ProductAnalysisParamsSchema>;
783
783
  type CompositionComponent = z.infer<typeof CompositionComponentSchema>;
784
784
  type ProductCompositionResponse = z.infer<typeof ProductCompositionResponseSchema>;
785
+ declare const BlockDataSchema: z.ZodObject<{
786
+ id: z.ZodNumber;
787
+ code: z.ZodOptional<z.ZodString>;
788
+ name: z.ZodString;
789
+ extId: z.ZodOptional<z.ZodString>;
790
+ inactive: z.ZodOptional<z.ZodBoolean>;
791
+ description: z.ZodOptional<z.ZodString>;
792
+ rowNumbers: z.ZodOptional<z.ZodString>;
793
+ estate: z.ZodOptional<z.ZodBoolean>;
794
+ grower: z.ZodOptional<z.ZodObject<{
795
+ id: z.ZodOptional<z.ZodNumber>;
796
+ extId: z.ZodOptional<z.ZodString>;
797
+ name: z.ZodOptional<z.ZodString>;
798
+ }, z.core.$strip>>;
799
+ vineyard: z.ZodOptional<z.ZodObject<{
800
+ id: z.ZodOptional<z.ZodNumber>;
801
+ name: z.ZodString;
802
+ grower: z.ZodObject<{
803
+ id: z.ZodOptional<z.ZodNumber>;
804
+ extId: z.ZodOptional<z.ZodString>;
805
+ name: z.ZodOptional<z.ZodString>;
806
+ }, z.core.$strip>;
807
+ }, z.core.$strip>>;
808
+ region: z.ZodOptional<z.ZodObject<{
809
+ id: z.ZodOptional<z.ZodNumber>;
810
+ name: z.ZodOptional<z.ZodString>;
811
+ }, z.core.$strip>>;
812
+ subRegion: z.ZodOptional<z.ZodObject<{
813
+ id: z.ZodOptional<z.ZodNumber>;
814
+ name: z.ZodOptional<z.ZodString>;
815
+ }, z.core.$strip>>;
816
+ variety: z.ZodOptional<z.ZodObject<{
817
+ id: z.ZodOptional<z.ZodNumber>;
818
+ name: z.ZodOptional<z.ZodString>;
819
+ }, z.core.$strip>>;
820
+ intendedUse: z.ZodOptional<z.ZodObject<{
821
+ id: z.ZodOptional<z.ZodNumber>;
822
+ name: z.ZodOptional<z.ZodString>;
823
+ }, z.core.$strip>>;
824
+ grading: z.ZodOptional<z.ZodNullable<z.ZodObject<{
825
+ id: z.ZodOptional<z.ZodNumber>;
826
+ value: z.ZodOptional<z.ZodString>;
827
+ scaleName: z.ZodOptional<z.ZodString>;
828
+ scaleId: z.ZodOptional<z.ZodNumber>;
829
+ }, z.core.$strip>>>;
830
+ fruitPlacement: z.ZodOptional<z.ZodObject<{
831
+ vintage: z.ZodOptional<z.ZodString>;
832
+ bulkStocks: z.ZodOptional<z.ZodArray<z.ZodObject<{
833
+ totalVolume: z.ZodOptional<z.ZodObject<{
834
+ value: z.ZodOptional<z.ZodNumber>;
835
+ unit: z.ZodOptional<z.ZodString>;
836
+ }, z.core.$strip>>;
837
+ equivalentVolume: z.ZodOptional<z.ZodObject<{
838
+ value: z.ZodOptional<z.ZodNumber>;
839
+ unit: z.ZodOptional<z.ZodString>;
840
+ }, z.core.$strip>>;
841
+ equivalentWeight: z.ZodOptional<z.ZodObject<{
842
+ value: z.ZodOptional<z.ZodNumber>;
843
+ unit: z.ZodOptional<z.ZodString>;
844
+ }, z.core.$strip>>;
845
+ compWeighting: z.ZodOptional<z.ZodNumber>;
846
+ percentageOfFruit: z.ZodOptional<z.ZodNumber>;
847
+ batchId: z.ZodOptional<z.ZodNumber>;
848
+ batchName: z.ZodOptional<z.ZodString>;
849
+ grading: z.ZodOptional<z.ZodNullable<z.ZodObject<{
850
+ id: z.ZodOptional<z.ZodNumber>;
851
+ value: z.ZodOptional<z.ZodString>;
852
+ scaleName: z.ZodOptional<z.ZodString>;
853
+ scaleId: z.ZodOptional<z.ZodNumber>;
854
+ }, z.core.$strip>>>;
855
+ }, z.core.$strip>>>;
856
+ }, z.core.$strip>>;
857
+ }, z.core.$strip>;
858
+ declare const BlockSchema: z.ZodObject<{
859
+ id: z.ZodOptional<z.ZodNumber>;
860
+ extId: z.ZodString;
861
+ name: z.ZodString;
862
+ estate: z.ZodOptional<z.ZodBoolean>;
863
+ vineyard: z.ZodObject<{
864
+ id: z.ZodOptional<z.ZodNumber>;
865
+ name: z.ZodString;
866
+ grower: z.ZodObject<{
867
+ id: z.ZodOptional<z.ZodNumber>;
868
+ extId: z.ZodOptional<z.ZodString>;
869
+ name: z.ZodOptional<z.ZodString>;
870
+ }, z.core.$strip>;
871
+ }, z.core.$strip>;
872
+ variety: z.ZodObject<{
873
+ id: z.ZodOptional<z.ZodNumber>;
874
+ name: z.ZodOptional<z.ZodString>;
875
+ }, z.core.$strip>;
876
+ countyCode: z.ZodOptional<z.ZodString>;
877
+ inactive: z.ZodOptional<z.ZodBoolean>;
878
+ noOfVines: z.ZodOptional<z.ZodNumber>;
879
+ area: z.ZodOptional<z.ZodNumber>;
880
+ rootStock: z.ZodOptional<z.ZodObject<{
881
+ id: z.ZodOptional<z.ZodNumber>;
882
+ name: z.ZodOptional<z.ZodString>;
883
+ }, z.core.$strip>>;
884
+ clone: z.ZodOptional<z.ZodObject<{
885
+ id: z.ZodOptional<z.ZodNumber>;
886
+ name: z.ZodOptional<z.ZodString>;
887
+ }, z.core.$strip>>;
888
+ vineSpacing: z.ZodOptional<z.ZodString>;
889
+ rowSpacing: z.ZodOptional<z.ZodString>;
890
+ soilProfile: z.ZodOptional<z.ZodString>;
891
+ trellis: z.ZodOptional<z.ZodObject<{
892
+ id: z.ZodOptional<z.ZodNumber>;
893
+ name: z.ZodOptional<z.ZodString>;
894
+ }, z.core.$strip>>;
895
+ aspect: z.ZodOptional<z.ZodString>;
896
+ plantedTime: z.ZodOptional<z.ZodNumber>;
897
+ pruningType: z.ZodOptional<z.ZodString>;
898
+ averageGradient: z.ZodOptional<z.ZodNumber>;
899
+ irrigationType: z.ZodOptional<z.ZodString>;
900
+ frostProtection: z.ZodOptional<z.ZodString>;
901
+ organic: z.ZodOptional<z.ZodBoolean>;
902
+ organicCertifiedTime: z.ZodOptional<z.ZodNumber>;
903
+ township: z.ZodOptional<z.ZodString>;
904
+ range: z.ZodOptional<z.ZodString>;
905
+ section: z.ZodOptional<z.ZodString>;
906
+ emitterRate: z.ZodOptional<z.ZodNumber>;
907
+ emitterSize: z.ZodOptional<z.ZodString>;
908
+ siteId: z.ZodOptional<z.ZodString>;
909
+ noOfRows: z.ZodOptional<z.ZodNumber>;
910
+ districtCode: z.ZodOptional<z.ZodString>;
911
+ regionalAdminCode: z.ZodOptional<z.ZodString>;
912
+ comments: z.ZodOptional<z.ZodString>;
913
+ code: z.ZodOptional<z.ZodString>;
914
+ defaultHarvestMethod: z.ZodOptional<z.ZodString>;
915
+ description: z.ZodOptional<z.ZodString>;
916
+ graftedDate: z.ZodOptional<z.ZodNumber>;
917
+ intendedUse: z.ZodOptional<z.ZodObject<{
918
+ id: z.ZodOptional<z.ZodNumber>;
919
+ name: z.ZodOptional<z.ZodString>;
920
+ }, z.core.$strip>>;
921
+ rowNumbers: z.ZodOptional<z.ZodString>;
922
+ vineStructure: z.ZodOptional<z.ZodObject<{
923
+ id: z.ZodOptional<z.ZodNumber>;
924
+ name: z.ZodOptional<z.ZodString>;
925
+ }, z.core.$strip>>;
926
+ }, z.core.$strip>;
927
+ type BlockData = z.infer<typeof BlockDataSchema>;
928
+ type Block = z.infer<typeof BlockSchema>;
785
929
  declare const GetBulkWineDetailsReportResponseSchema: z.ZodObject<{
786
930
  totalResults: z.ZodOptional<z.ZodNumber>;
787
931
  offset: z.ZodOptional<z.ZodNumber>;
@@ -802,10 +946,12 @@ declare const GetBulkWineDetailsReportResponseSchema: z.ZodObject<{
802
946
  }, z.core.$strip>>;
803
947
  beverageType: z.ZodOptional<z.ZodObject<{
804
948
  id: z.ZodOptional<z.ZodNumber>;
949
+ name: z.ZodOptional<z.ZodString>;
805
950
  }, z.core.$strip>>;
806
951
  owner: z.ZodOptional<z.ZodObject<{
807
952
  id: z.ZodOptional<z.ZodNumber>;
808
953
  extId: z.ZodOptional<z.ZodString>;
954
+ name: z.ZodOptional<z.ZodString>;
809
955
  }, z.core.$strip>>;
810
956
  winery: z.ZodOptional<z.ZodObject<{
811
957
  id: z.ZodOptional<z.ZodNumber>;
@@ -865,11 +1011,13 @@ declare const GetBulkWineDetailsReportResponseSchema: z.ZodObject<{
865
1011
  ttbDetails: z.ZodOptional<z.ZodObject<{
866
1012
  bond: z.ZodOptional<z.ZodObject<{
867
1013
  id: z.ZodOptional<z.ZodNumber>;
1014
+ name: z.ZodOptional<z.ZodString>;
868
1015
  }, z.core.$strip>>;
869
1016
  name: z.ZodOptional<z.ZodString>;
870
1017
  taxState: z.ZodOptional<z.ZodString>;
871
1018
  taxClass: z.ZodOptional<z.ZodObject<{
872
1019
  id: z.ZodOptional<z.ZodNumber>;
1020
+ name: z.ZodOptional<z.ZodString>;
873
1021
  }, z.core.$strip>>;
874
1022
  federalName: z.ZodOptional<z.ZodString>;
875
1023
  stateName: z.ZodOptional<z.ZodString>;
@@ -962,51 +1110,90 @@ declare const ProductJobResponseSchema: z.ZodObject<{
962
1110
  }, z.core.$strip>;
963
1111
  }, z.core.$strip>;
964
1112
  type ProductJobResponse = z.infer<typeof ProductJobResponseSchema>;
965
- declare const VineyardResponseSchema: z.ZodObject<{
966
- data: z.ZodOptional<z.ZodObject<{
1113
+ declare const TransactionDetailsSchema: z.ZodObject<{
1114
+ activityDate: z.ZodOptional<z.ZodNumber>;
1115
+ postedDate: z.ZodOptional<z.ZodNumber>;
1116
+ resultOfCorrection: z.ZodOptional<z.ZodBoolean>;
1117
+ activityId: z.ZodOptional<z.ZodString>;
1118
+ postedId: z.ZodOptional<z.ZodNumber>;
1119
+ activityType: z.ZodOptional<z.ZodString>;
1120
+ activitySummary: z.ZodOptional<z.ZodString>;
1121
+ primaryCostTarget: z.ZodOptional<z.ZodString>;
1122
+ secondaryCostTarget: z.ZodOptional<z.ZodString>;
1123
+ primaryWinery: z.ZodOptional<z.ZodObject<{
967
1124
  id: z.ZodOptional<z.ZodNumber>;
968
1125
  name: z.ZodOptional<z.ZodString>;
969
- grower: z.ZodOptional<z.ZodObject<{
970
- id: z.ZodOptional<z.ZodNumber>;
971
- extId: z.ZodOptional<z.ZodString>;
972
- }, z.core.$strip>>;
1126
+ businessUnit: z.ZodOptional<z.ZodString>;
973
1127
  }, z.core.$strip>>;
974
- }, z.core.$strip>;
975
- type VineyardResponse = z.infer<typeof VineyardResponseSchema>;
976
- declare const MaturitySampleResponseSchema: z.ZodObject<{
977
- data: z.ZodOptional<z.ZodObject<{
1128
+ secondaryWinery: z.ZodOptional<z.ZodObject<{
978
1129
  id: z.ZodOptional<z.ZodNumber>;
979
- sampleDate: z.ZodOptional<z.ZodNumber>;
980
- sampleDateAsText: z.ZodOptional<z.ZodString>;
981
- vineyard: z.ZodOptional<z.ZodString>;
982
- block: z.ZodOptional<z.ZodString>;
983
- varietal: z.ZodOptional<z.ZodString>;
984
- vintage: z.ZodOptional<z.ZodString>;
985
- brix: z.ZodOptional<z.ZodNumber>;
986
- ph: z.ZodOptional<z.ZodNumber>;
987
- ta: z.ZodOptional<z.ZodNumber>;
988
- grade: z.ZodOptional<z.ZodString>;
1130
+ name: z.ZodOptional<z.ZodString>;
1131
+ businessUnit: z.ZodOptional<z.ZodString>;
989
1132
  }, z.core.$strip>>;
990
- }, z.core.$strip>;
991
- type MaturitySampleResponse = z.infer<typeof MaturitySampleResponseSchema>;
992
- declare const PartyV7Schema: z.ZodObject<{
993
- id: z.ZodOptional<z.ZodNumber>;
994
- name: z.ZodOptional<z.ZodString>;
995
- primeName: z.ZodOptional<z.ZodString>;
996
- givenName: z.ZodNullable<z.ZodString>;
997
- phone: z.ZodNullable<z.ZodString>;
998
- email: z.ZodNullable<z.ZodString>;
999
- isOrganization: z.ZodOptional<z.ZodBoolean>;
1000
- address: z.ZodOptional<z.ZodObject<{
1001
- street1: z.ZodNullable<z.ZodString>;
1002
- street2: z.ZodNullable<z.ZodString>;
1003
- city: z.ZodNullable<z.ZodString>;
1004
- state: z.ZodNullable<z.ZodString>;
1005
- postalCode: z.ZodNullable<z.ZodString>;
1006
- country: z.ZodNullable<z.ZodString>;
1133
+ location: z.ZodOptional<z.ZodString>;
1134
+ vessel: z.ZodOptional<z.ZodString>;
1135
+ wineBatch: z.ZodOptional<z.ZodString>;
1136
+ productCategory: z.ZodOptional<z.ZodObject<{
1137
+ id: z.ZodOptional<z.ZodNumber>;
1138
+ code: z.ZodOptional<z.ZodString>;
1139
+ }, z.core.$strip>>;
1140
+ program: z.ZodOptional<z.ZodObject<{
1141
+ id: z.ZodOptional<z.ZodNumber>;
1142
+ code: z.ZodOptional<z.ZodString>;
1143
+ }, z.core.$strip>>;
1144
+ volumeDelta: z.ZodOptional<z.ZodObject<{
1145
+ value: z.ZodOptional<z.ZodNumber>;
1146
+ unit: z.ZodOptional<z.ZodString>;
1147
+ }, z.core.$strip>>;
1148
+ costDelta: z.ZodOptional<z.ZodObject<{
1149
+ total: z.ZodOptional<z.ZodNumber>;
1150
+ fruit: z.ZodOptional<z.ZodNumber>;
1151
+ overhead: z.ZodOptional<z.ZodNumber>;
1152
+ storage: z.ZodOptional<z.ZodNumber>;
1153
+ additive: z.ZodOptional<z.ZodNumber>;
1154
+ bulk: z.ZodOptional<z.ZodNumber>;
1155
+ packaging: z.ZodOptional<z.ZodNumber>;
1156
+ operation: z.ZodOptional<z.ZodNumber>;
1157
+ freight: z.ZodOptional<z.ZodNumber>;
1158
+ other: z.ZodOptional<z.ZodNumber>;
1159
+ }, z.core.$strip>>;
1160
+ otherWinery: z.ZodOptional<z.ZodObject<{
1161
+ id: z.ZodOptional<z.ZodNumber>;
1162
+ name: z.ZodOptional<z.ZodString>;
1163
+ businessUnit: z.ZodOptional<z.ZodString>;
1164
+ }, z.core.$strip>>;
1165
+ notes: z.ZodOptional<z.ZodString>;
1166
+ customer: z.ZodOptional<z.ZodObject<{
1167
+ id: z.ZodOptional<z.ZodNumber>;
1168
+ extId: z.ZodOptional<z.ZodString>;
1169
+ name: z.ZodOptional<z.ZodString>;
1170
+ }, z.core.$strip>>;
1171
+ vendor: z.ZodOptional<z.ZodObject<{
1172
+ id: z.ZodOptional<z.ZodNumber>;
1173
+ extId: z.ZodOptional<z.ZodString>;
1174
+ name: z.ZodOptional<z.ZodString>;
1175
+ }, z.core.$strip>>;
1176
+ lossReason: z.ZodOptional<z.ZodObject<{
1177
+ id: z.ZodOptional<z.ZodNumber>;
1178
+ name: z.ZodOptional<z.ZodString>;
1179
+ }, z.core.$strip>>;
1180
+ allocationDescription: z.ZodOptional<z.ZodString>;
1181
+ impactedAllocations: z.ZodOptional<z.ZodArray<z.ZodObject<{
1182
+ productName: z.ZodOptional<z.ZodString>;
1183
+ vintage: z.ZodOptional<z.ZodString>;
1184
+ itemCode: z.ZodOptional<z.ZodString>;
1185
+ name: z.ZodOptional<z.ZodString>;
1186
+ }, z.core.$strip>>>;
1187
+ references: z.ZodOptional<z.ZodObject<{
1188
+ bulkSalesOrder: z.ZodOptional<z.ZodString>;
1189
+ bulkPurchaseOrder: z.ZodOptional<z.ZodString>;
1190
+ externalWorkOrder: z.ZodOptional<z.ZodString>;
1191
+ workOrder: z.ZodOptional<z.ZodString>;
1192
+ jobNUmber: z.ZodOptional<z.ZodString>;
1193
+ billOfLadingNumber: z.ZodOptional<z.ZodString>;
1007
1194
  }, z.core.$strip>>;
1008
1195
  }, z.core.$strip>;
1009
- type PartyV7 = z.infer<typeof PartyV7Schema>;
1196
+ type TransactionDetails = z.infer<typeof TransactionDetailsSchema>;
1010
1197
  declare const CreateFruitIntakeSuccessResponseSchema: z.ZodObject<{
1011
1198
  data: z.ZodOptional<z.ZodObject<{
1012
1199
  id: z.ZodOptional<z.ZodNumber>;
@@ -1034,15 +1221,67 @@ declare const CreateFruitIntakeSuccessResponseSchema: z.ZodObject<{
1034
1221
  status: z.ZodOptional<z.ZodString>;
1035
1222
  }, z.core.$strip>>;
1036
1223
  }, z.core.$strip>;
1224
+ declare const UpdateFruitIntakePricingSchema: z.ZodObject<{
1225
+ gross: z.ZodOptional<z.ZodObject<{
1226
+ value: z.ZodOptional<z.ZodNumber>;
1227
+ unit: z.ZodOptional<z.ZodString>;
1228
+ }, z.core.$strip>>;
1229
+ tare: z.ZodOptional<z.ZodObject<{
1230
+ value: z.ZodOptional<z.ZodNumber>;
1231
+ unit: z.ZodOptional<z.ZodString>;
1232
+ }, z.core.$strip>>;
1233
+ net: z.ZodOptional<z.ZodObject<{
1234
+ value: z.ZodOptional<z.ZodNumber>;
1235
+ unit: z.ZodOptional<z.ZodString>;
1236
+ }, z.core.$strip>>;
1237
+ unitPrice: z.ZodOptional<z.ZodObject<{
1238
+ value: z.ZodOptional<z.ZodNumber>;
1239
+ unit: z.ZodOptional<z.ZodString>;
1240
+ }, z.core.$strip>>;
1241
+ }, z.core.$strip>;
1037
1242
  declare const UpdateFruitIntakePricingResponseSchema: z.ZodObject<{
1038
1243
  data: z.ZodOptional<z.ZodObject<{
1039
- pricePerTon: z.ZodOptional<z.ZodNumber>;
1040
- pricePerKg: z.ZodOptional<z.ZodNumber>;
1041
- bypassed: z.ZodOptional<z.ZodBoolean>;
1244
+ gross: z.ZodOptional<z.ZodObject<{
1245
+ value: z.ZodOptional<z.ZodNumber>;
1246
+ unit: z.ZodOptional<z.ZodString>;
1247
+ }, z.core.$strip>>;
1248
+ tare: z.ZodOptional<z.ZodObject<{
1249
+ value: z.ZodOptional<z.ZodNumber>;
1250
+ unit: z.ZodOptional<z.ZodString>;
1251
+ }, z.core.$strip>>;
1252
+ net: z.ZodOptional<z.ZodObject<{
1253
+ value: z.ZodOptional<z.ZodNumber>;
1254
+ unit: z.ZodOptional<z.ZodString>;
1255
+ }, z.core.$strip>>;
1256
+ unitPrice: z.ZodOptional<z.ZodObject<{
1257
+ value: z.ZodOptional<z.ZodNumber>;
1258
+ unit: z.ZodOptional<z.ZodString>;
1259
+ }, z.core.$strip>>;
1042
1260
  }, z.core.$strip>>;
1043
1261
  }, z.core.$strip>;
1044
1262
  type CreateFruitIntakeSuccessResponse = z.infer<typeof CreateFruitIntakeSuccessResponseSchema>;
1263
+ type UpdateFruitIntakePricing = z.infer<typeof UpdateFruitIntakePricingSchema>;
1045
1264
  type UpdateFruitIntakePricingResponse = z.infer<typeof UpdateFruitIntakePricingResponseSchema>;
1265
+ declare const UpdateMetricsSchema: z.ZodObject<{
1266
+ metrics: z.ZodOptional<z.ZodArray<z.ZodObject<{
1267
+ name: z.ZodString;
1268
+ value: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1269
+ interfaceMappedName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1270
+ nonNumericValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1271
+ }, z.core.$strip>>>;
1272
+ }, z.core.$strip>;
1273
+ declare const UpdateMetricsResponseSchema: z.ZodObject<{
1274
+ data: z.ZodOptional<z.ZodObject<{
1275
+ metrics: z.ZodOptional<z.ZodArray<z.ZodObject<{
1276
+ name: z.ZodString;
1277
+ value: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1278
+ interfaceMappedName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1279
+ nonNumericValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1280
+ }, z.core.$strip>>>;
1281
+ }, z.core.$strip>>;
1282
+ }, z.core.$strip>;
1283
+ type UpdateMetrics = z.infer<typeof UpdateMetricsSchema>;
1284
+ type UpdateMetricsResponse = z.infer<typeof UpdateMetricsResponseSchema>;
1046
1285
  declare const TirageSuccessResponseSchema: z.ZodObject<{
1047
1286
  data: z.ZodOptional<z.ZodObject<{
1048
1287
  id: z.ZodOptional<z.ZodNumber>;
@@ -1081,6 +1320,92 @@ declare const BarrelsMovementSchema: z.ZodObject<{
1081
1320
  status: z.ZodOptional<z.ZodString>;
1082
1321
  }, z.core.$strip>;
1083
1322
  type BarrelsMovement = z.infer<typeof BarrelsMovementSchema>;
1323
+ declare const PurchaseOrderLineSchema: z.ZodObject<{
1324
+ id: z.ZodNumber;
1325
+ type: z.ZodEnum<{
1326
+ GENERAL: "GENERAL";
1327
+ ADHOC: "ADHOC";
1328
+ WINE_BATCH: "WINE_BATCH";
1329
+ STOCK: "STOCK";
1330
+ }>;
1331
+ lineNumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1332
+ itemCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1333
+ vendorCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1334
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1335
+ itemName: z.ZodOptional<z.ZodString>;
1336
+ unitPrice: z.ZodOptional<z.ZodNumber>;
1337
+ totalPrice: z.ZodOptional<z.ZodNumber>;
1338
+ taxable: z.ZodOptional<z.ZodBoolean>;
1339
+ quantityOrdered: z.ZodOptional<z.ZodObject<{
1340
+ value: z.ZodOptional<z.ZodNumber>;
1341
+ unit: z.ZodOptional<z.ZodString>;
1342
+ }, z.core.$strip>>;
1343
+ quantityFulfilled: z.ZodOptional<z.ZodObject<{
1344
+ value: z.ZodOptional<z.ZodNumber>;
1345
+ unit: z.ZodOptional<z.ZodString>;
1346
+ }, z.core.$strip>>;
1347
+ }, z.core.$strip>;
1348
+ declare const PurchaseOrderSchema: z.ZodObject<{
1349
+ id: z.ZodNumber;
1350
+ name: z.ZodString;
1351
+ state: z.ZodOptional<z.ZodEnum<{
1352
+ NEW: "NEW";
1353
+ APPROVED: "APPROVED";
1354
+ }>>;
1355
+ fulfillment: z.ZodOptional<z.ZodEnum<{
1356
+ NOT_FULFILLED: "NOT_FULFILLED";
1357
+ PART_FULFILLED: "PART_FULFILLED";
1358
+ FULFILLED: "FULFILLED";
1359
+ OVER_FULFILLED: "OVER_FULFILLED";
1360
+ }>>;
1361
+ taxPolicy: z.ZodOptional<z.ZodEnum<{
1362
+ TAX_INCLUSIVE: "TAX_INCLUSIVE";
1363
+ TAX_EXCLUSIVE: "TAX_EXCLUSIVE";
1364
+ NO_TAX: "NO_TAX";
1365
+ }>>;
1366
+ freightCost: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1367
+ inactive: z.ZodOptional<z.ZodBoolean>;
1368
+ vendor: z.ZodOptional<z.ZodObject<{
1369
+ id: z.ZodOptional<z.ZodNumber>;
1370
+ extId: z.ZodOptional<z.ZodString>;
1371
+ name: z.ZodOptional<z.ZodString>;
1372
+ }, z.core.$strip>>;
1373
+ vendorReference: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1374
+ deliverBy: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1375
+ notes: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1376
+ winery: z.ZodOptional<z.ZodObject<{
1377
+ id: z.ZodOptional<z.ZodNumber>;
1378
+ name: z.ZodOptional<z.ZodString>;
1379
+ businessUnit: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1380
+ }, z.core.$strip>>;
1381
+ lines: z.ZodOptional<z.ZodArray<z.ZodObject<{
1382
+ id: z.ZodNumber;
1383
+ type: z.ZodEnum<{
1384
+ GENERAL: "GENERAL";
1385
+ ADHOC: "ADHOC";
1386
+ WINE_BATCH: "WINE_BATCH";
1387
+ STOCK: "STOCK";
1388
+ }>;
1389
+ lineNumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1390
+ itemCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1391
+ vendorCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1392
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1393
+ itemName: z.ZodOptional<z.ZodString>;
1394
+ unitPrice: z.ZodOptional<z.ZodNumber>;
1395
+ totalPrice: z.ZodOptional<z.ZodNumber>;
1396
+ taxable: z.ZodOptional<z.ZodBoolean>;
1397
+ quantityOrdered: z.ZodOptional<z.ZodObject<{
1398
+ value: z.ZodOptional<z.ZodNumber>;
1399
+ unit: z.ZodOptional<z.ZodString>;
1400
+ }, z.core.$strip>>;
1401
+ quantityFulfilled: z.ZodOptional<z.ZodObject<{
1402
+ value: z.ZodOptional<z.ZodNumber>;
1403
+ unit: z.ZodOptional<z.ZodString>;
1404
+ }, z.core.$strip>>;
1405
+ }, z.core.$strip>>>;
1406
+ }, z.core.$strip>;
1407
+ type PurchaseOrderLine = z.infer<typeof PurchaseOrderLineSchema>;
1408
+ type PurchaseOrder = z.infer<typeof PurchaseOrderSchema>;
1084
1409
 
1085
1410
  interface WorkOrderListParams {
1086
1411
  /**
@@ -1157,6 +1482,13 @@ interface VesselDetailsReportParams {
1157
1482
  wineryName?: string;
1158
1483
  vesselType?: 'TANK' | 'BIN' | 'BARREL' | 'BARREL_GROUP' | 'BIN_GROUP' | 'PRESS' | 'TANKER';
1159
1484
  }
1485
+ interface BlocksListParams {
1486
+ include?: string;
1487
+ vintage?: string;
1488
+ VintraceEntityIds?: string;
1489
+ limit?: number;
1490
+ offset?: number;
1491
+ }
1160
1492
  declare class VintraceClient {
1161
1493
  /**
1162
1494
  * The base URL of the Vintrace API.
@@ -1237,37 +1569,29 @@ declare class VintraceV7Api {
1237
1569
  private client;
1238
1570
  private _costs?;
1239
1571
  private _blocks?;
1240
- private _assessments?;
1241
- private _vineyards?;
1242
- private _maturitySamples?;
1243
- private _parties?;
1244
- private _shipments?;
1245
- private _barrelTreatments?;
1246
1572
  private _bookings?;
1247
1573
  private _fruitIntakes?;
1248
- private _bulkIntakes?;
1249
- private _trialBlends?;
1250
- private _workOrders?;
1251
1574
  private _tirage?;
1252
1575
  private _barrelsMovements?;
1253
1576
  private _vesselDetailsReport?;
1577
+ private _wineBatches?;
1578
+ private _documents?;
1579
+ private _stock?;
1580
+ private _vessels?;
1581
+ private _purchaseOrders?;
1254
1582
  constructor(client: VintraceClient);
1255
1583
  get costs(): CostsClient;
1256
1584
  get blocks(): BlocksClient;
1257
- get assessments(): AssessmentsClient;
1258
- get vineyards(): VineyardsClient;
1259
- get maturitySamples(): MaturitySamplesClient;
1260
- get parties(): PartiesV7Client;
1261
- get shipments(): ShipmentsClient;
1262
- get barrelTreatments(): BarrelTreatmentsClient;
1263
1585
  get bookings(): BookingsClient;
1264
1586
  get fruitIntakes(): FruitIntakesClient;
1265
- get bulkIntakes(): BulkIntakesClient;
1266
- get trialBlends(): TrialBlendsClient;
1267
- get workOrders(): WorkOrdersV7Client;
1268
1587
  get tirage(): TirageClient;
1269
1588
  get barrelsMovements(): BarrelsMovementsClient;
1270
1589
  get vesselDetailsReport(): VesselDetailsReportClient;
1590
+ get wineBatches(): WineBatchesClient;
1591
+ get documents(): DocumentsClient;
1592
+ get stock(): StockClient;
1593
+ get vessels(): VesselsClient;
1594
+ get purchaseOrders(): PurchaseOrdersClient;
1271
1595
  }
1272
1596
  declare class WorkOrdersClient {
1273
1597
  private client;
@@ -1366,11 +1690,21 @@ declare class BlocksClient {
1366
1690
  *
1367
1691
  * API consumer can use the include and vintage query params to request including more information in the response.
1368
1692
  */
1369
- getAll(params?: Record<string, unknown>): Promise<VintraceResult<unknown[]>>;
1370
- get(id: string): Promise<VintraceResult<unknown>>;
1371
- getMany(ids: string[]): Promise<VintraceResult<unknown[]>>;
1372
- post(data: unknown): Promise<VintraceResult<unknown>>;
1693
+ getAll(params?: BlocksListParams): Promise<VintraceResult<BlockData[]>>;
1694
+ /**
1695
+ * Upsert block data into system.
1696
+ *
1697
+ * Create or update block data in the system. Provide a Block object in `data`.
1698
+ * Example fields: `extId`, `name`, `estate`, `vineyard`, `variety`, `area`.
1699
+ */
1700
+ post(data: unknown): Promise<VintraceResult<Block>>;
1373
1701
  patch(id: string, data: unknown): Promise<VintraceResult<unknown>>;
1702
+ /**
1703
+ * Upsert assessment data for a block.
1704
+ *
1705
+ * Create or update assessment data for a block by its blockId.
1706
+ */
1707
+ createAssessment(blockId: string, data: unknown): Promise<VintraceResult<unknown>>;
1374
1708
  }
1375
1709
  declare class BookingsClient {
1376
1710
  private client;
@@ -1405,89 +1739,53 @@ declare class CostsClient {
1405
1739
  *
1406
1740
  * Returns business unit transaction details for cost movements within a date range.
1407
1741
  */
1408
- businessUnitTransactions(params: CostsBusinessUnitTransactionsParams): Promise<VintraceResult<unknown[]>>;
1742
+ businessUnitTransactions(params: CostsBusinessUnitTransactionsParams): Promise<VintraceResult<TransactionDetails[]>>;
1409
1743
  }
1410
- interface AssessmentsListParams {
1744
+ interface WineBatchesListParams {
1411
1745
  limit?: number;
1412
1746
  offset?: number;
1747
+ ids?: string;
1748
+ include?: string;
1413
1749
  }
1414
- declare class AssessmentsClient {
1415
- private client;
1416
- constructor(client: VintraceClient);
1417
- /**
1418
- * Get all assessments.
1419
- *
1420
- * Returns a paginated list of block assessments.
1421
- */
1422
- getAll(params?: AssessmentsListParams): Promise<VintraceResult<unknown[]>>;
1423
- }
1424
- declare class VineyardsClient {
1750
+ declare class WineBatchesClient {
1425
1751
  private client;
1426
1752
  constructor(client: VintraceClient);
1427
1753
  /**
1428
- * Create a vineyard.
1754
+ * Get a list of wine batches.
1429
1755
  *
1430
- * Creates a new vineyard in the system.
1756
+ * Returns a paginated list of wine batches.
1431
1757
  */
1432
- post(data: unknown): Promise<VintraceResult<VineyardResponse>>;
1433
- }
1434
- declare class MaturitySamplesClient {
1435
- private client;
1436
- constructor(client: VintraceClient);
1758
+ getAll(params?: WineBatchesListParams): Promise<VintraceResult<unknown[]>>;
1437
1759
  /**
1438
- * Create a maturity sample.
1439
- *
1440
- * Creates a new maturity sample in the system.
1760
+ * Create a wine batch.
1441
1761
  */
1442
- post(data: unknown): Promise<VintraceResult<MaturitySampleResponse>>;
1443
- }
1444
- interface PartiesV7ListParams {
1445
- limit?: number;
1446
- offset?: number;
1762
+ create(data: unknown): Promise<VintraceResult<unknown>>;
1447
1763
  }
1448
- declare class PartiesV7Client {
1764
+ declare class TirageClient {
1449
1765
  private client;
1450
1766
  constructor(client: VintraceClient);
1451
1767
  /**
1452
- * List all parties.
1453
- *
1454
- * Returns a paginated list of parties.
1455
- */
1456
- getAll(params?: PartiesV7ListParams): Promise<VintraceResult<unknown[]>>;
1457
- /**
1458
- * Upsert a party.
1768
+ * Get a tirage by operation ID.
1459
1769
  *
1460
- * Creates or updates a party.
1770
+ * Returns a single tirage by its operation ID.
1461
1771
  */
1462
- post(data: unknown): Promise<VintraceResult<PartyV7>>;
1463
- }
1464
- interface ShipmentsListParams {
1465
- limit?: number;
1466
- offset?: number;
1467
- }
1468
- declare class ShipmentsClient {
1469
- private client;
1470
- constructor(client: VintraceClient);
1772
+ get(operationId: string): Promise<VintraceResult<TirageSuccessResponse>>;
1471
1773
  /**
1472
- * List all shipments.
1774
+ * Patch a tirage.
1473
1775
  *
1474
- * Returns a paginated list of shipments.
1776
+ * Updates a tirage record.
1475
1777
  */
1476
- getAll(params?: ShipmentsListParams): Promise<VintraceResult<unknown[]>>;
1778
+ patch(operationId: string, data: unknown): Promise<VintraceResult<TirageSuccessResponse>>;
1477
1779
  }
1478
- interface BarrelTreatmentsListParams {
1479
- limit?: number;
1480
- offset?: number;
1481
- }
1482
- declare class BarrelTreatmentsClient {
1780
+ declare class BarrelsMovementsClient {
1483
1781
  private client;
1484
1782
  constructor(client: VintraceClient);
1485
1783
  /**
1486
- * List all barrel treatments.
1784
+ * Create a barrels movement.
1487
1785
  *
1488
- * Returns a paginated list of barrel treatments.
1786
+ * Creates a new barrels movement in the system.
1489
1787
  */
1490
- getAll(params?: BarrelTreatmentsListParams): Promise<VintraceResult<unknown[]>>;
1788
+ post(data: unknown): Promise<VintraceResult<BarrelsMovement>>;
1491
1789
  }
1492
1790
  declare class FruitIntakesClient {
1493
1791
  private client;
@@ -1495,101 +1793,73 @@ declare class FruitIntakesClient {
1495
1793
  /**
1496
1794
  * Create a fruit intake.
1497
1795
  *
1498
- * Creates a new fruit intake in the system.
1796
+ * Record a new fruit intake transaction.
1499
1797
  */
1500
- post(data: unknown): Promise<VintraceResult<CreateFruitIntakeSuccessResponse>>;
1798
+ create(data: unknown): Promise<VintraceResult<CreateFruitIntakeSuccessResponse>>;
1501
1799
  /**
1502
- * Update fruit intake pricing.
1800
+ * Update pricing for a fruit intake.
1503
1801
  *
1504
- * Updates pricing information for a fruit intake.
1802
+ * Update the pricing related data for this fruit intake record.
1505
1803
  */
1506
- updatePricing(fruitIntakeId: string, data: unknown): Promise<VintraceResult<UpdateFruitIntakePricingResponse>>;
1804
+ updatePricing(fruitIntakeId: string, data: UpdateFruitIntakePricing): Promise<VintraceResult<UpdateFruitIntakePricingResponse>>;
1507
1805
  /**
1508
- * Update fruit intake metrics.
1806
+ * Update metrics for a fruit intake.
1509
1807
  *
1510
- * Updates metrics for a fruit intake.
1808
+ * Update the metrics for this fruit intake record.
1511
1809
  */
1512
- updateMetrics(fruitIntakeId: string, data: unknown): Promise<VintraceResult<unknown>>;
1513
- }
1514
- interface BulkIntakesListParams {
1515
- limit?: number;
1516
- offset?: number;
1810
+ updateMetrics(fruitIntakeId: string, data: UpdateMetrics): Promise<VintraceResult<UpdateMetricsResponse>>;
1517
1811
  }
1518
- declare class BulkIntakesClient {
1812
+ declare class DocumentsClient {
1519
1813
  private client;
1520
1814
  constructor(client: VintraceClient);
1521
1815
  /**
1522
- * List all bulk intakes.
1523
- *
1524
- * Returns a paginated list of bulk intakes.
1525
- */
1526
- getAll(params?: BulkIntakesListParams): Promise<VintraceResult<unknown[]>>;
1527
- /**
1528
- * Create a bulk intake.
1816
+ * Upload a file to an operation.
1529
1817
  *
1530
- * Creates a new bulk intake in the system.
1818
+ * Attach documents to a specified operation.
1531
1819
  */
1532
- post(data: unknown): Promise<VintraceResult<unknown>>;
1533
- /**
1534
- * Partially update a bulk intake.
1535
- *
1536
- * Updates specific fields on a bulk intake.
1537
- */
1538
- patch(id: string, data: unknown): Promise<VintraceResult<unknown>>;
1820
+ attach(data: unknown): Promise<VintraceResult<unknown>>;
1539
1821
  }
1540
- interface TrialBlendsListParams {
1822
+ interface StockDispatchesListParams {
1541
1823
  limit?: number;
1542
1824
  offset?: number;
1543
1825
  }
1544
- declare class TrialBlendsClient {
1826
+ declare class StockClient {
1545
1827
  private client;
1546
1828
  constructor(client: VintraceClient);
1547
1829
  /**
1548
- * List all trial blends.
1830
+ * Receive stock.
1549
1831
  *
1550
- * Returns a paginated list of trial blends.
1832
+ * Perform a receive stock operation in the system.
1551
1833
  */
1552
- getAll(params?: TrialBlendsListParams): Promise<VintraceResult<unknown[]>>;
1553
- }
1554
- interface WorkOrdersV7ListParams {
1555
- limit?: number;
1556
- offset?: number;
1557
- }
1558
- declare class WorkOrdersV7Client {
1559
- private client;
1560
- constructor(client: VintraceClient);
1834
+ receive(data: unknown): Promise<VintraceResult<unknown>>;
1561
1835
  /**
1562
- * List all work orders.
1836
+ * Get all stock dispatches.
1563
1837
  *
1564
- * Returns a paginated list of work orders.
1838
+ * Returns a paginated list of stock dispatch actions.
1565
1839
  */
1566
- getAll(params?: WorkOrdersV7ListParams): Promise<VintraceResult<unknown[]>>;
1840
+ getDispatches(params?: StockDispatchesListParams): Promise<VintraceResult<unknown[]>>;
1567
1841
  }
1568
- declare class TirageClient {
1842
+ declare class VesselsClient {
1569
1843
  private client;
1570
1844
  constructor(client: VintraceClient);
1571
- /**
1572
- * Get a tirage by operation ID.
1573
- *
1574
- * Returns a single tirage by its operation ID.
1575
- */
1576
- get(operationId: string): Promise<VintraceResult<TirageSuccessResponse>>;
1577
- /**
1578
- * Patch a tirage.
1579
- *
1580
- * Updates a tirage record.
1581
- */
1582
- patch(operationId: string, data: unknown): Promise<VintraceResult<unknown>>;
1845
+ getBarrel(id: string): Promise<VintraceResult<unknown>>;
1846
+ getBarrelGroup(id: string): Promise<VintraceResult<unknown>>;
1847
+ createTank(data: unknown): Promise<VintraceResult<unknown>>;
1848
+ getTank(id: string): Promise<VintraceResult<unknown>>;
1849
+ getTanker(id: string): Promise<VintraceResult<unknown>>;
1850
+ getBin(id: string): Promise<VintraceResult<unknown>>;
1583
1851
  }
1584
- declare class BarrelsMovementsClient {
1852
+ declare class PurchaseOrdersClient {
1585
1853
  private client;
1586
1854
  constructor(client: VintraceClient);
1587
1855
  /**
1588
- * Create a barrels movement.
1589
- *
1590
- * Creates a new barrels movement in the system.
1856
+ * Create or update a purchase order.
1591
1857
  */
1592
- post(data: unknown): Promise<VintraceResult<BarrelsMovement>>;
1858
+ create(data: unknown): Promise<VintraceResult<unknown>>;
1859
+ /**
1860
+ * Get purchase order details by id.
1861
+ */
1862
+ get(id: string): Promise<VintraceResult<PurchaseOrder>>;
1593
1863
  }
1594
1864
  declare class TransactionsClient {
1595
1865
  private client;
@@ -1698,6 +1968,10 @@ declare class MrpStockClient {
1698
1968
  updateNote(id: string, noteId: string, data: unknown): Promise<VintraceResult<unknown>>;
1699
1969
  getBulkInfo(id: string): Promise<VintraceResult<unknown>>;
1700
1970
  }
1971
+ interface StockLookupParams {
1972
+ code?: string;
1973
+ id?: string;
1974
+ }
1701
1975
  declare class InventoryClient {
1702
1976
  private client;
1703
1977
  constructor(client: VintraceClient);
@@ -1707,6 +1981,12 @@ declare class InventoryClient {
1707
1981
  * Returns a list of all stock items.
1708
1982
  */
1709
1983
  getAll(params?: InventoryListParams): Promise<VintraceResult<unknown[]>>;
1984
+ /**
1985
+ * Get stock item by code or id.
1986
+ *
1987
+ * Returns a single stock item by code or id.
1988
+ */
1989
+ lookup(params?: StockLookupParams): Promise<VintraceResult<unknown>>;
1710
1990
  }
1711
1991
  declare class SearchClient {
1712
1992
  private client;
@@ -1793,4 +2073,4 @@ declare class VintraceValidationSchemaError extends VintraceError {
1793
2073
  declare function validateResponse<T>(schema: ZodType<T>, data: unknown, correlationId?: string): VintraceResult<T>;
1794
2074
  declare function validateRequest<T>(schema: ZodType<T>, data: unknown, correlationId?: string): VintraceResult<T>;
1795
2075
 
1796
- export { type AnalysisMeasurement, type AnalysisMetricData, type CompositionComponent, type CostsBusinessUnitTransactionsParams, DEFAULT_OPTIONS, type IntakeOperationSearchParams, type InventoryListParams, type MrpStockHistoryParams, type MrpStockNotesParams, type PaginatedResponse, type PaginationOptions, type PartyListParams, type ProductAnalysisParams, type ProductAnalysisResponse, type ProductCompositionResponse, type ProductListParams, type ProductMetricData, type RateOfChange, type RefundListParams, type RequestOptions, type SalesOrderListParams, type SampleOperationSearchParams, type SearchListParams, type TransactionSearchParams, type VesselDetailsReportParams, VintraceAggregateError, VintraceAuthenticationError, VintraceClient, type VintraceClientConfig, type VintraceClientOptions, VintraceError, VintraceFetchError, VintraceNotFoundError, VintraceRateLimitError, type VintraceResult, VintraceServerError, VintraceValidationError, VintraceValidationSchemaError, type WorkOrderListParams, batchGet, paginate, validateRequest, validateResponse, vintraceFetch };
2076
+ export { type AnalysisMeasurement, type AnalysisMetricData, type Block, type BlockData, type BlocksListParams, type CompositionComponent, type CostsBusinessUnitTransactionsParams, DEFAULT_OPTIONS, type IntakeOperationSearchParams, type InventoryListParams, type MrpStockHistoryParams, type MrpStockNotesParams, type PaginatedResponse, type PaginationOptions, type PartyListParams, type ProductAnalysisParams, type ProductAnalysisResponse, type ProductCompositionResponse, type ProductListParams, type ProductMetricData, type PurchaseOrder, type PurchaseOrderLine, type RateOfChange, type RefundListParams, type RequestOptions, type SalesOrderListParams, type SampleOperationSearchParams, type SearchListParams, type StockDispatchesListParams, type StockLookupParams, type TransactionSearchParams, type VesselDetailsReportParams, VintraceAggregateError, VintraceAuthenticationError, VintraceClient, type VintraceClientConfig, type VintraceClientOptions, VintraceError, VintraceFetchError, VintraceNotFoundError, VintraceRateLimitError, type VintraceResult, VintraceServerError, VintraceValidationError, VintraceValidationSchemaError, type WineBatchesListParams, type WorkOrderListParams, batchGet, paginate, validateRequest, validateResponse, vintraceFetch };