@arascreative/erp-client 1.0.0 → 2.0.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.
@@ -177,6 +177,105 @@ export type SearchAddresses400 = {
177
177
  instance?: string;
178
178
  errors?: SearchAddresses400Errors;
179
179
  };
180
+ export type InitiateUploadBody = {
181
+ originalName: string;
182
+ mimeType: string;
183
+ sizeBytes: number;
184
+ checksum: string;
185
+ purpose: string;
186
+ expiresInSeconds?: number;
187
+ };
188
+ export type InitiateUpload201 = {
189
+ fileId: string;
190
+ storageKey: string;
191
+ presignedUploadUrl: string;
192
+ expiresInSeconds: number;
193
+ };
194
+ export type InitiateUpload400Errors = {
195
+ [key: string]: string[];
196
+ };
197
+ export type InitiateUpload400 = {
198
+ type: string;
199
+ title: string;
200
+ status: number;
201
+ detail?: string;
202
+ instance?: string;
203
+ errors?: InitiateUpload400Errors;
204
+ };
205
+ export type InitiateUpload413Errors = {
206
+ [key: string]: string[];
207
+ };
208
+ export type InitiateUpload413 = {
209
+ type: string;
210
+ title: string;
211
+ status: number;
212
+ detail?: string;
213
+ instance?: string;
214
+ errors?: InitiateUpload413Errors;
215
+ };
216
+ export type InitiateUpload422Errors = {
217
+ [key: string]: string[];
218
+ };
219
+ export type InitiateUpload422 = {
220
+ type: string;
221
+ title: string;
222
+ status: number;
223
+ detail?: string;
224
+ instance?: string;
225
+ errors?: InitiateUpload422Errors;
226
+ };
227
+ export type UploadFileBody = {
228
+ originalName: string;
229
+ mimeType: string;
230
+ contentBase64: string;
231
+ purpose: string;
232
+ uploadedBy?: string;
233
+ };
234
+ export type UploadFile201 = {
235
+ id: string;
236
+ originalName: string;
237
+ mimeType: string;
238
+ sizeBytes: number;
239
+ checksum: string;
240
+ status: string;
241
+ visibility: string;
242
+ purpose: string;
243
+ accessUrl: string;
244
+ expiresAt: string;
245
+ };
246
+ export type UploadFile400Errors = {
247
+ [key: string]: string[];
248
+ };
249
+ export type UploadFile400 = {
250
+ type: string;
251
+ title: string;
252
+ status: number;
253
+ detail?: string;
254
+ instance?: string;
255
+ errors?: UploadFile400Errors;
256
+ };
257
+ export type UploadFile413Errors = {
258
+ [key: string]: string[];
259
+ };
260
+ export type UploadFile413 = {
261
+ type: string;
262
+ title: string;
263
+ status: number;
264
+ detail?: string;
265
+ instance?: string;
266
+ errors?: UploadFile413Errors;
267
+ };
268
+ export type UploadFile422Errors = {
269
+ [key: string]: string[];
270
+ };
271
+ export type UploadFile422 = {
272
+ type: string;
273
+ title: string;
274
+ status: number;
275
+ detail?: string;
276
+ instance?: string;
277
+ errors?: UploadFile422Errors;
278
+ };
180
279
  export type ToggleWarehouseStatus200 = {
181
280
  isActive: boolean;
182
281
  };
@@ -219,6 +318,100 @@ export type ChangeStockItemStatus404 = {
219
318
  instance?: string;
220
319
  errors?: ChangeStockItemStatus404Errors;
221
320
  };
321
+ export type CompleteUploadBody = {
322
+ actualChecksum?: string;
323
+ };
324
+ export type CompleteUpload200 = {
325
+ id: string;
326
+ status: string;
327
+ activatedAt: string;
328
+ };
329
+ export type CompleteUpload400Errors = {
330
+ [key: string]: string[];
331
+ };
332
+ export type CompleteUpload400 = {
333
+ type: string;
334
+ title: string;
335
+ status: number;
336
+ detail?: string;
337
+ instance?: string;
338
+ errors?: CompleteUpload400Errors;
339
+ };
340
+ export type CompleteUpload404Errors = {
341
+ [key: string]: string[];
342
+ };
343
+ export type CompleteUpload404 = {
344
+ type: string;
345
+ title: string;
346
+ status: number;
347
+ detail?: string;
348
+ instance?: string;
349
+ errors?: CompleteUpload404Errors;
350
+ };
351
+ export type CompleteUpload422Errors = {
352
+ [key: string]: string[];
353
+ };
354
+ export type CompleteUpload422 = {
355
+ type: string;
356
+ title: string;
357
+ status: number;
358
+ detail?: string;
359
+ instance?: string;
360
+ errors?: CompleteUpload422Errors;
361
+ };
362
+ export type CompleteUpload500Errors = {
363
+ [key: string]: string[];
364
+ };
365
+ export type CompleteUpload500 = {
366
+ type: string;
367
+ title: string;
368
+ status: number;
369
+ detail?: string;
370
+ instance?: string;
371
+ errors?: CompleteUpload500Errors;
372
+ };
373
+ export type GetFileAccessUrlParams = {
374
+ expiresInSeconds?: number;
375
+ };
376
+ export type GetFileAccessUrl200 = {
377
+ fileId: string;
378
+ url: string;
379
+ isPublic: boolean;
380
+ expiresAt: string;
381
+ };
382
+ export type GetFileAccessUrl400Errors = {
383
+ [key: string]: string[];
384
+ };
385
+ export type GetFileAccessUrl400 = {
386
+ type: string;
387
+ title: string;
388
+ status: number;
389
+ detail?: string;
390
+ instance?: string;
391
+ errors?: GetFileAccessUrl400Errors;
392
+ };
393
+ export type GetFileAccessUrl404Errors = {
394
+ [key: string]: string[];
395
+ };
396
+ export type GetFileAccessUrl404 = {
397
+ type: string;
398
+ title: string;
399
+ status: number;
400
+ detail?: string;
401
+ instance?: string;
402
+ errors?: GetFileAccessUrl404Errors;
403
+ };
404
+ export type GetFileAccessUrl422Errors = {
405
+ [key: string]: string[];
406
+ };
407
+ export type GetFileAccessUrl422 = {
408
+ type: string;
409
+ title: string;
410
+ status: number;
411
+ detail?: string;
412
+ instance?: string;
413
+ errors?: GetFileAccessUrl422Errors;
414
+ };
222
415
  export type GetWarehouseById200Pic = {
223
416
  name: string;
224
417
  phone: string;
@@ -417,6 +610,77 @@ export type DeleteStockItem409 = {
417
610
  instance?: string;
418
611
  errors?: DeleteStockItem409Errors;
419
612
  };
613
+ export type GetStoredFileById200 = {
614
+ id: string;
615
+ originalName: string;
616
+ mimeType: string;
617
+ sizeBytes: number;
618
+ checksum: string;
619
+ storageKey: string;
620
+ status: string;
621
+ visibility: string;
622
+ purpose: string;
623
+ uploadedBy: string;
624
+ expiresAt: string;
625
+ createdAt: string;
626
+ activatedAt: string;
627
+ deletedAt: string;
628
+ };
629
+ export type GetStoredFileById400Errors = {
630
+ [key: string]: string[];
631
+ };
632
+ export type GetStoredFileById400 = {
633
+ type: string;
634
+ title: string;
635
+ status: number;
636
+ detail?: string;
637
+ instance?: string;
638
+ errors?: GetStoredFileById400Errors;
639
+ };
640
+ export type GetStoredFileById404Errors = {
641
+ [key: string]: string[];
642
+ };
643
+ export type GetStoredFileById404 = {
644
+ type: string;
645
+ title: string;
646
+ status: number;
647
+ detail?: string;
648
+ instance?: string;
649
+ errors?: GetStoredFileById404Errors;
650
+ };
651
+ export type DeleteStoredFile400Errors = {
652
+ [key: string]: string[];
653
+ };
654
+ export type DeleteStoredFile400 = {
655
+ type: string;
656
+ title: string;
657
+ status: number;
658
+ detail?: string;
659
+ instance?: string;
660
+ errors?: DeleteStoredFile400Errors;
661
+ };
662
+ export type DeleteStoredFile404Errors = {
663
+ [key: string]: string[];
664
+ };
665
+ export type DeleteStoredFile404 = {
666
+ type: string;
667
+ title: string;
668
+ status: number;
669
+ detail?: string;
670
+ instance?: string;
671
+ errors?: DeleteStoredFile404Errors;
672
+ };
673
+ export type DeleteStoredFile409Errors = {
674
+ [key: string]: string[];
675
+ };
676
+ export type DeleteStoredFile409 = {
677
+ type: string;
678
+ title: string;
679
+ status: number;
680
+ detail?: string;
681
+ instance?: string;
682
+ errors?: DeleteStoredFile409Errors;
683
+ };
420
684
  export type GetHealth200 = {
421
685
  status: string;
422
686
  timestamp: string;
@@ -491,39 +755,36 @@ export type ListWarehousesParams = {
491
755
  search?: string;
492
756
  isActive?: boolean;
493
757
  };
494
- export type ListWarehouses2000Pic = {
758
+ export type ListWarehouses200ItemPic = {
495
759
  name: string;
496
760
  phone: string;
497
761
  };
498
- export type ListWarehouses2000AddressDestinationCode = string | null;
499
- export type ListWarehouses2000AddressProvinceName = string | null;
500
- export type ListWarehouses2000AddressCityName = string | null;
501
- export type ListWarehouses2000AddressDistrictName = string | null;
502
- export type ListWarehouses2000AddressSubDistrictName = string | null;
503
- export type ListWarehouses2000AddressZipCode = string | null;
504
- export type ListWarehouses2000Address = {
762
+ export type ListWarehouses200ItemAddressDestinationCode = string | null;
763
+ export type ListWarehouses200ItemAddressProvinceName = string | null;
764
+ export type ListWarehouses200ItemAddressCityName = string | null;
765
+ export type ListWarehouses200ItemAddressDistrictName = string | null;
766
+ export type ListWarehouses200ItemAddressSubDistrictName = string | null;
767
+ export type ListWarehouses200ItemAddressZipCode = string | null;
768
+ export type ListWarehouses200ItemAddress = {
505
769
  addressId: string;
506
- destinationCode: ListWarehouses2000AddressDestinationCode;
507
- provinceName: ListWarehouses2000AddressProvinceName;
508
- cityName: ListWarehouses2000AddressCityName;
509
- districtName: ListWarehouses2000AddressDistrictName;
510
- subDistrictName: ListWarehouses2000AddressSubDistrictName;
511
- zipCode: ListWarehouses2000AddressZipCode;
512
- };
513
- export type ListWarehouses2000FullAddressText = string | null;
514
- export type ListWarehouses2000 = {
770
+ destinationCode: ListWarehouses200ItemAddressDestinationCode;
771
+ provinceName: ListWarehouses200ItemAddressProvinceName;
772
+ cityName: ListWarehouses200ItemAddressCityName;
773
+ districtName: ListWarehouses200ItemAddressDistrictName;
774
+ subDistrictName: ListWarehouses200ItemAddressSubDistrictName;
775
+ zipCode: ListWarehouses200ItemAddressZipCode;
776
+ };
777
+ export type ListWarehouses200ItemFullAddressText = string | null;
778
+ export type ListWarehouses200Item = {
515
779
  id: string;
516
780
  name: string;
517
- pic: ListWarehouses2000Pic;
518
- address: ListWarehouses2000Address;
519
- fullAddressText: ListWarehouses2000FullAddressText;
781
+ pic: ListWarehouses200ItemPic;
782
+ address: ListWarehouses200ItemAddress;
783
+ fullAddressText: ListWarehouses200ItemFullAddressText;
520
784
  isActive: boolean;
521
785
  createdAt: string;
522
786
  updatedAt: string;
523
787
  };
524
- export type ListWarehouses200 = {
525
- '0': ListWarehouses2000;
526
- };
527
788
  export type ListStockMovementsParams = {
528
789
  itemId?: string;
529
790
  batchId?: string;
@@ -969,6 +1230,108 @@ export declare function useSearchAddresses<TData = Awaited<ReturnType<typeof sea
969
1230
  }, queryClient?: QueryClient): UseQueryResult<TData, TError> & {
970
1231
  queryKey: DataTag<QueryKey, TData, TError>;
971
1232
  };
1233
+ /**
1234
+ * Creates a pending file metadata record and generates a presigned S3 upload URL for direct client-to-storage upload.
1235
+ * @summary Initiate direct file upload to storage
1236
+ */
1237
+ export type initiateUploadResponse201 = {
1238
+ data: InitiateUpload201;
1239
+ status: 201;
1240
+ };
1241
+ export type initiateUploadResponse400 = {
1242
+ data: InitiateUpload400;
1243
+ status: 400;
1244
+ };
1245
+ export type initiateUploadResponse413 = {
1246
+ data: InitiateUpload413;
1247
+ status: 413;
1248
+ };
1249
+ export type initiateUploadResponse422 = {
1250
+ data: InitiateUpload422;
1251
+ status: 422;
1252
+ };
1253
+ export type initiateUploadResponseSuccess = (initiateUploadResponse201) & {
1254
+ headers: Headers;
1255
+ };
1256
+ export type initiateUploadResponseError = (initiateUploadResponse400 | initiateUploadResponse413 | initiateUploadResponse422) & {
1257
+ headers: Headers;
1258
+ };
1259
+ export type initiateUploadResponse = (initiateUploadResponseSuccess | initiateUploadResponseError);
1260
+ export declare const getInitiateUploadUrl: () => string;
1261
+ export declare const initiateUpload: (initiateUploadBody: InitiateUploadBody, options?: RequestInit) => Promise<initiateUploadResponse>;
1262
+ export declare const getInitiateUploadMutationOptions: <TError = InitiateUpload400 | InitiateUpload413 | InitiateUpload422, TContext = unknown>(options?: {
1263
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof initiateUpload>>, TError, {
1264
+ data: InitiateUploadBody;
1265
+ }, TContext>;
1266
+ fetch?: RequestInit;
1267
+ }) => UseMutationOptions<Awaited<ReturnType<typeof initiateUpload>>, TError, {
1268
+ data: InitiateUploadBody;
1269
+ }, TContext>;
1270
+ export type InitiateUploadMutationResult = NonNullable<Awaited<ReturnType<typeof initiateUpload>>>;
1271
+ export type InitiateUploadMutationBody = InitiateUploadBody;
1272
+ export type InitiateUploadMutationError = InitiateUpload400 | InitiateUpload413 | InitiateUpload422;
1273
+ /**
1274
+ * @summary Initiate direct file upload to storage
1275
+ */
1276
+ export declare const useInitiateUpload: <TError = InitiateUpload400 | InitiateUpload413 | InitiateUpload422, TContext = unknown>(options?: {
1277
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof initiateUpload>>, TError, {
1278
+ data: InitiateUploadBody;
1279
+ }, TContext>;
1280
+ fetch?: RequestInit;
1281
+ }, queryClient?: QueryClient) => UseMutationResult<Awaited<ReturnType<typeof initiateUpload>>, TError, {
1282
+ data: InitiateUploadBody;
1283
+ }, TContext>;
1284
+ /**
1285
+ * Uploads a file directly with base64 encoded content, verifies against purpose policy, stores to S3, and activates immediately.
1286
+ * @summary Direct upload file
1287
+ */
1288
+ export type uploadFileResponse201 = {
1289
+ data: UploadFile201;
1290
+ status: 201;
1291
+ };
1292
+ export type uploadFileResponse400 = {
1293
+ data: UploadFile400;
1294
+ status: 400;
1295
+ };
1296
+ export type uploadFileResponse413 = {
1297
+ data: UploadFile413;
1298
+ status: 413;
1299
+ };
1300
+ export type uploadFileResponse422 = {
1301
+ data: UploadFile422;
1302
+ status: 422;
1303
+ };
1304
+ export type uploadFileResponseSuccess = (uploadFileResponse201) & {
1305
+ headers: Headers;
1306
+ };
1307
+ export type uploadFileResponseError = (uploadFileResponse400 | uploadFileResponse413 | uploadFileResponse422) & {
1308
+ headers: Headers;
1309
+ };
1310
+ export type uploadFileResponse = (uploadFileResponseSuccess | uploadFileResponseError);
1311
+ export declare const getUploadFileUrl: () => string;
1312
+ export declare const uploadFile: (uploadFileBody: UploadFileBody, options?: RequestInit) => Promise<uploadFileResponse>;
1313
+ export declare const getUploadFileMutationOptions: <TError = UploadFile400 | UploadFile413 | UploadFile422, TContext = unknown>(options?: {
1314
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof uploadFile>>, TError, {
1315
+ data: UploadFileBody;
1316
+ }, TContext>;
1317
+ fetch?: RequestInit;
1318
+ }) => UseMutationOptions<Awaited<ReturnType<typeof uploadFile>>, TError, {
1319
+ data: UploadFileBody;
1320
+ }, TContext>;
1321
+ export type UploadFileMutationResult = NonNullable<Awaited<ReturnType<typeof uploadFile>>>;
1322
+ export type UploadFileMutationBody = UploadFileBody;
1323
+ export type UploadFileMutationError = UploadFile400 | UploadFile413 | UploadFile422;
1324
+ /**
1325
+ * @summary Direct upload file
1326
+ */
1327
+ export declare const useUploadFile: <TError = UploadFile400 | UploadFile413 | UploadFile422, TContext = unknown>(options?: {
1328
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof uploadFile>>, TError, {
1329
+ data: UploadFileBody;
1330
+ }, TContext>;
1331
+ fetch?: RequestInit;
1332
+ }, queryClient?: QueryClient) => UseMutationResult<Awaited<ReturnType<typeof uploadFile>>, TError, {
1333
+ data: UploadFileBody;
1334
+ }, TContext>;
972
1335
  /**
973
1336
  * Toggles the active state of a warehouse. Soft-deleted warehouses cannot be toggled.
974
1337
  * @summary Toggle warehouse active status
@@ -1062,6 +1425,121 @@ export declare const useChangeStockItemStatus: <TError = ChangeStockItemStatus40
1062
1425
  id: string;
1063
1426
  data: ChangeStockItemStatusBody;
1064
1427
  }, TContext>;
1428
+ /**
1429
+ * Verifies that physical object was written to storage provider, verifies checksum, and transitions file to ACTIVE.
1430
+ * @summary Complete direct file upload
1431
+ */
1432
+ export type completeUploadResponse200 = {
1433
+ data: CompleteUpload200;
1434
+ status: 200;
1435
+ };
1436
+ export type completeUploadResponse400 = {
1437
+ data: CompleteUpload400;
1438
+ status: 400;
1439
+ };
1440
+ export type completeUploadResponse404 = {
1441
+ data: CompleteUpload404;
1442
+ status: 404;
1443
+ };
1444
+ export type completeUploadResponse422 = {
1445
+ data: CompleteUpload422;
1446
+ status: 422;
1447
+ };
1448
+ export type completeUploadResponse500 = {
1449
+ data: CompleteUpload500;
1450
+ status: 500;
1451
+ };
1452
+ export type completeUploadResponseSuccess = (completeUploadResponse200) & {
1453
+ headers: Headers;
1454
+ };
1455
+ export type completeUploadResponseError = (completeUploadResponse400 | completeUploadResponse404 | completeUploadResponse422 | completeUploadResponse500) & {
1456
+ headers: Headers;
1457
+ };
1458
+ export type completeUploadResponse = (completeUploadResponseSuccess | completeUploadResponseError);
1459
+ export declare const getCompleteUploadUrl: (id: string) => string;
1460
+ export declare const completeUpload: (id: string, completeUploadBody: CompleteUploadBody, options?: RequestInit) => Promise<completeUploadResponse>;
1461
+ export declare const getCompleteUploadMutationOptions: <TError = CompleteUpload400 | CompleteUpload404 | CompleteUpload422 | CompleteUpload500, TContext = unknown>(options?: {
1462
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof completeUpload>>, TError, {
1463
+ id: string;
1464
+ data: CompleteUploadBody;
1465
+ }, TContext>;
1466
+ fetch?: RequestInit;
1467
+ }) => UseMutationOptions<Awaited<ReturnType<typeof completeUpload>>, TError, {
1468
+ id: string;
1469
+ data: CompleteUploadBody;
1470
+ }, TContext>;
1471
+ export type CompleteUploadMutationResult = NonNullable<Awaited<ReturnType<typeof completeUpload>>>;
1472
+ export type CompleteUploadMutationBody = CompleteUploadBody;
1473
+ export type CompleteUploadMutationError = CompleteUpload400 | CompleteUpload404 | CompleteUpload422 | CompleteUpload500;
1474
+ /**
1475
+ * @summary Complete direct file upload
1476
+ */
1477
+ export declare const useCompleteUpload: <TError = CompleteUpload400 | CompleteUpload404 | CompleteUpload422 | CompleteUpload500, TContext = unknown>(options?: {
1478
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof completeUpload>>, TError, {
1479
+ id: string;
1480
+ data: CompleteUploadBody;
1481
+ }, TContext>;
1482
+ fetch?: RequestInit;
1483
+ }, queryClient?: QueryClient) => UseMutationResult<Awaited<ReturnType<typeof completeUpload>>, TError, {
1484
+ id: string;
1485
+ data: CompleteUploadBody;
1486
+ }, TContext>;
1487
+ /**
1488
+ * Generates a public CDN URL (for public files) or a time-limited signed download URL (for private files).
1489
+ * @summary Get file download or CDN access URL
1490
+ */
1491
+ export type getFileAccessUrlResponse200 = {
1492
+ data: GetFileAccessUrl200;
1493
+ status: 200;
1494
+ };
1495
+ export type getFileAccessUrlResponse400 = {
1496
+ data: GetFileAccessUrl400;
1497
+ status: 400;
1498
+ };
1499
+ export type getFileAccessUrlResponse404 = {
1500
+ data: GetFileAccessUrl404;
1501
+ status: 404;
1502
+ };
1503
+ export type getFileAccessUrlResponse422 = {
1504
+ data: GetFileAccessUrl422;
1505
+ status: 422;
1506
+ };
1507
+ export type getFileAccessUrlResponseSuccess = (getFileAccessUrlResponse200) & {
1508
+ headers: Headers;
1509
+ };
1510
+ export type getFileAccessUrlResponseError = (getFileAccessUrlResponse400 | getFileAccessUrlResponse404 | getFileAccessUrlResponse422) & {
1511
+ headers: Headers;
1512
+ };
1513
+ export type getFileAccessUrlResponse = (getFileAccessUrlResponseSuccess | getFileAccessUrlResponseError);
1514
+ export declare const getGetFileAccessUrlUrl: (id: string, params?: GetFileAccessUrlParams) => string;
1515
+ export declare const getFileAccessUrl: (id: string, params?: GetFileAccessUrlParams, options?: RequestInit) => Promise<getFileAccessUrlResponse>;
1516
+ export declare const getGetFileAccessUrlQueryKey: (id?: string, params?: GetFileAccessUrlParams) => readonly [`/files/${string}/access-url`, ...GetFileAccessUrlParams[]];
1517
+ export declare const getGetFileAccessUrlQueryOptions: <TData = Awaited<ReturnType<typeof getFileAccessUrl>>, TError = GetFileAccessUrl400 | GetFileAccessUrl404 | GetFileAccessUrl422>(id: string, params?: GetFileAccessUrlParams, options?: {
1518
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, TData>>;
1519
+ fetch?: RequestInit;
1520
+ }) => UseQueryOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, TData> & {
1521
+ queryKey: DataTag<QueryKey, TData, TError>;
1522
+ };
1523
+ export type GetFileAccessUrlQueryResult = NonNullable<Awaited<ReturnType<typeof getFileAccessUrl>>>;
1524
+ export type GetFileAccessUrlQueryError = GetFileAccessUrl400 | GetFileAccessUrl404 | GetFileAccessUrl422;
1525
+ export declare function useGetFileAccessUrl<TData = Awaited<ReturnType<typeof getFileAccessUrl>>, TError = GetFileAccessUrl400 | GetFileAccessUrl404 | GetFileAccessUrl422>(id: string, params: undefined | GetFileAccessUrlParams, options: {
1526
+ query: Partial<UseQueryOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, Awaited<ReturnType<typeof getFileAccessUrl>>>, 'initialData'>;
1527
+ fetch?: RequestInit;
1528
+ }, queryClient?: QueryClient): DefinedUseQueryResult<TData, TError> & {
1529
+ queryKey: DataTag<QueryKey, TData, TError>;
1530
+ };
1531
+ export declare function useGetFileAccessUrl<TData = Awaited<ReturnType<typeof getFileAccessUrl>>, TError = GetFileAccessUrl400 | GetFileAccessUrl404 | GetFileAccessUrl422>(id: string, params?: GetFileAccessUrlParams, options?: {
1532
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, Awaited<ReturnType<typeof getFileAccessUrl>>>, 'initialData'>;
1533
+ fetch?: RequestInit;
1534
+ }, queryClient?: QueryClient): UseQueryResult<TData, TError> & {
1535
+ queryKey: DataTag<QueryKey, TData, TError>;
1536
+ };
1537
+ export declare function useGetFileAccessUrl<TData = Awaited<ReturnType<typeof getFileAccessUrl>>, TError = GetFileAccessUrl400 | GetFileAccessUrl404 | GetFileAccessUrl422>(id: string, params?: GetFileAccessUrlParams, options?: {
1538
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getFileAccessUrl>>, TError, TData>>;
1539
+ fetch?: RequestInit;
1540
+ }, queryClient?: QueryClient): UseQueryResult<TData, TError> & {
1541
+ queryKey: DataTag<QueryKey, TData, TError>;
1542
+ };
1065
1543
  /**
1066
1544
  * Retrieves warehouse details by its identifier. Returns 404 if not found or soft-deleted.
1067
1545
  * @summary Get warehouse by ID
@@ -1296,6 +1774,101 @@ export declare const useDeleteStockItem: <TError = DeleteStockItem400 | DeleteSt
1296
1774
  }, queryClient?: QueryClient) => UseMutationResult<Awaited<ReturnType<typeof deleteStockItem>>, TError, {
1297
1775
  id: string;
1298
1776
  }, TContext>;
1777
+ /**
1778
+ * Retrieves active stored file metadata by its ID.
1779
+ * @summary Get stored file by ID
1780
+ */
1781
+ export type getStoredFileByIdResponse200 = {
1782
+ data: GetStoredFileById200;
1783
+ status: 200;
1784
+ };
1785
+ export type getStoredFileByIdResponse400 = {
1786
+ data: GetStoredFileById400;
1787
+ status: 400;
1788
+ };
1789
+ export type getStoredFileByIdResponse404 = {
1790
+ data: GetStoredFileById404;
1791
+ status: 404;
1792
+ };
1793
+ export type getStoredFileByIdResponseSuccess = (getStoredFileByIdResponse200) & {
1794
+ headers: Headers;
1795
+ };
1796
+ export type getStoredFileByIdResponseError = (getStoredFileByIdResponse400 | getStoredFileByIdResponse404) & {
1797
+ headers: Headers;
1798
+ };
1799
+ export type getStoredFileByIdResponse = (getStoredFileByIdResponseSuccess | getStoredFileByIdResponseError);
1800
+ export declare const getGetStoredFileByIdUrl: (id: string) => string;
1801
+ export declare const getStoredFileById: (id: string, options?: RequestInit) => Promise<getStoredFileByIdResponse>;
1802
+ export declare const getGetStoredFileByIdQueryKey: (id?: string) => readonly [`/files/${string}`];
1803
+ export declare const getGetStoredFileByIdQueryOptions: <TData = Awaited<ReturnType<typeof getStoredFileById>>, TError = GetStoredFileById400 | GetStoredFileById404>(id: string, options?: {
1804
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, TData>>;
1805
+ fetch?: RequestInit;
1806
+ }) => UseQueryOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, TData> & {
1807
+ queryKey: DataTag<QueryKey, TData, TError>;
1808
+ };
1809
+ export type GetStoredFileByIdQueryResult = NonNullable<Awaited<ReturnType<typeof getStoredFileById>>>;
1810
+ export type GetStoredFileByIdQueryError = GetStoredFileById400 | GetStoredFileById404;
1811
+ export declare function useGetStoredFileById<TData = Awaited<ReturnType<typeof getStoredFileById>>, TError = GetStoredFileById400 | GetStoredFileById404>(id: string, options: {
1812
+ query: Partial<UseQueryOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, Awaited<ReturnType<typeof getStoredFileById>>>, 'initialData'>;
1813
+ fetch?: RequestInit;
1814
+ }, queryClient?: QueryClient): DefinedUseQueryResult<TData, TError> & {
1815
+ queryKey: DataTag<QueryKey, TData, TError>;
1816
+ };
1817
+ export declare function useGetStoredFileById<TData = Awaited<ReturnType<typeof getStoredFileById>>, TError = GetStoredFileById400 | GetStoredFileById404>(id: string, options?: {
1818
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, Awaited<ReturnType<typeof getStoredFileById>>>, 'initialData'>;
1819
+ fetch?: RequestInit;
1820
+ }, queryClient?: QueryClient): UseQueryResult<TData, TError> & {
1821
+ queryKey: DataTag<QueryKey, TData, TError>;
1822
+ };
1823
+ export declare function useGetStoredFileById<TData = Awaited<ReturnType<typeof getStoredFileById>>, TError = GetStoredFileById400 | GetStoredFileById404>(id: string, options?: {
1824
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getStoredFileById>>, TError, TData>>;
1825
+ fetch?: RequestInit;
1826
+ }, queryClient?: QueryClient): UseQueryResult<TData, TError> & {
1827
+ queryKey: DataTag<QueryKey, TData, TError>;
1828
+ };
1829
+ /**
1830
+ * Marks a stored file as DELETED. Files in active use by other modules cannot be deleted.
1831
+ * @summary Soft delete stored file
1832
+ */
1833
+ export type deleteStoredFileResponse400 = {
1834
+ data: DeleteStoredFile400;
1835
+ status: 400;
1836
+ };
1837
+ export type deleteStoredFileResponse404 = {
1838
+ data: DeleteStoredFile404;
1839
+ status: 404;
1840
+ };
1841
+ export type deleteStoredFileResponse409 = {
1842
+ data: DeleteStoredFile409;
1843
+ status: 409;
1844
+ };
1845
+ export type deleteStoredFileResponseError = (deleteStoredFileResponse400 | deleteStoredFileResponse404 | deleteStoredFileResponse409) & {
1846
+ headers: Headers;
1847
+ };
1848
+ export type deleteStoredFileResponse = (deleteStoredFileResponseError);
1849
+ export declare const getDeleteStoredFileUrl: (id: string) => string;
1850
+ export declare const deleteStoredFile: (id: string, options?: RequestInit) => Promise<deleteStoredFileResponse>;
1851
+ export declare const getDeleteStoredFileMutationOptions: <TError = DeleteStoredFile400 | DeleteStoredFile404 | DeleteStoredFile409, TContext = unknown>(options?: {
1852
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof deleteStoredFile>>, TError, {
1853
+ id: string;
1854
+ }, TContext>;
1855
+ fetch?: RequestInit;
1856
+ }) => UseMutationOptions<Awaited<ReturnType<typeof deleteStoredFile>>, TError, {
1857
+ id: string;
1858
+ }, TContext>;
1859
+ export type DeleteStoredFileMutationResult = NonNullable<Awaited<ReturnType<typeof deleteStoredFile>>>;
1860
+ export type DeleteStoredFileMutationError = DeleteStoredFile400 | DeleteStoredFile404 | DeleteStoredFile409;
1861
+ /**
1862
+ * @summary Soft delete stored file
1863
+ */
1864
+ export declare const useDeleteStoredFile: <TError = DeleteStoredFile400 | DeleteStoredFile404 | DeleteStoredFile409, TContext = unknown>(options?: {
1865
+ mutation?: UseMutationOptions<Awaited<ReturnType<typeof deleteStoredFile>>, TError, {
1866
+ id: string;
1867
+ }, TContext>;
1868
+ fetch?: RequestInit;
1869
+ }, queryClient?: QueryClient) => UseMutationResult<Awaited<ReturnType<typeof deleteStoredFile>>, TError, {
1870
+ id: string;
1871
+ }, TContext>;
1299
1872
  /**
1300
1873
  * @summary Health check
1301
1874
  */
@@ -1440,7 +2013,7 @@ export declare const useCreateWarehouse: <TError = CreateWarehouse400 | CreateWa
1440
2013
  * @summary List all warehouses
1441
2014
  */
1442
2015
  export type listWarehousesResponse200 = {
1443
- data: ListWarehouses200;
2016
+ data: ListWarehouses200Item[];
1444
2017
  status: 200;
1445
2018
  };
1446
2019
  export type listWarehousesResponseSuccess = (listWarehousesResponse200) & {