@mydoormot/app-types 1.7.24 → 1.7.26
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/.turbo/turbo-build.log +18 -18
- package/CHANGELOG.md +12 -0
- package/dist/index.d.cts +135 -1
- package/dist/index.d.ts +135 -1
- package/package.json +1 -1
- package/src/commerce.ts +142 -0
- package/src/index.ts +1 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
> @mydoormot/app-types@1.7.
|
|
3
|
-
> tsup src/index.ts --format esm,cjs --dts
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
1
|
+
|
|
2
|
+
> @mydoormot/app-types@1.7.25 build /Users/chuksben/Desktop/projects/microservices/mydoormot/packages/app-types
|
|
3
|
+
> tsup src/index.ts --format esm,cjs --dts
|
|
4
|
+
|
|
5
|
+
[34mCLI[39m Building entry: src/index.ts
|
|
6
|
+
[34mCLI[39m Using tsconfig: tsconfig.json
|
|
7
|
+
[34mCLI[39m tsup v7.3.0
|
|
8
|
+
[34mCLI[39m Target: es2021
|
|
9
|
+
[34mESM[39m Build start
|
|
10
|
+
[34mCJS[39m Build start
|
|
11
|
+
[32mESM[39m [1mdist/index.js [22m[32m7.18 KB[39m
|
|
12
|
+
[32mESM[39m ⚡️ Build success in 133ms
|
|
13
|
+
[32mCJS[39m [1mdist/index.cjs [22m[32m9.03 KB[39m
|
|
14
|
+
[32mCJS[39m ⚡️ Build success in 143ms
|
|
15
|
+
[34mDTS[39m Build start
|
|
16
|
+
[32mDTS[39m ⚡️ Build success in 683ms
|
|
17
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m26.30 KB[39m
|
|
18
|
+
[32mDTS[39m [1mdist/index.d.cts [22m[32m26.30 KB[39m
|
package/CHANGELOG.md
CHANGED
package/dist/index.d.cts
CHANGED
|
@@ -677,6 +677,140 @@ interface BusinessMember {
|
|
|
677
677
|
updatedAt: string | NullOrUndefined;
|
|
678
678
|
}
|
|
679
679
|
|
|
680
|
+
type ProductStatus = 'draft' | 'proposed' | 'published' | 'rejected';
|
|
681
|
+
interface ProductImage {
|
|
682
|
+
id: string;
|
|
683
|
+
url: string;
|
|
684
|
+
rank: number;
|
|
685
|
+
created_at?: string;
|
|
686
|
+
updated_at?: string;
|
|
687
|
+
deleted_at?: string | null;
|
|
688
|
+
metadata?: Record<string, unknown> | null;
|
|
689
|
+
}
|
|
690
|
+
interface ProductOptionValue {
|
|
691
|
+
id: string;
|
|
692
|
+
value: string;
|
|
693
|
+
option?: ProductOption | null;
|
|
694
|
+
option_id?: string | null;
|
|
695
|
+
metadata?: Record<string, unknown> | null;
|
|
696
|
+
created_at?: string;
|
|
697
|
+
updated_at?: string;
|
|
698
|
+
deleted_at?: string | null;
|
|
699
|
+
}
|
|
700
|
+
interface ProductOption {
|
|
701
|
+
id: string;
|
|
702
|
+
title: string;
|
|
703
|
+
product_id?: string | null;
|
|
704
|
+
values?: ProductOptionValue[];
|
|
705
|
+
metadata?: Record<string, unknown> | null;
|
|
706
|
+
created_at?: string;
|
|
707
|
+
updated_at?: string;
|
|
708
|
+
deleted_at?: string | null;
|
|
709
|
+
}
|
|
710
|
+
interface ProductVariant {
|
|
711
|
+
id: string;
|
|
712
|
+
title: string | null;
|
|
713
|
+
sku: string | null;
|
|
714
|
+
barcode: string | null;
|
|
715
|
+
ean: string | null;
|
|
716
|
+
upc: string | null;
|
|
717
|
+
allow_backorder: boolean | null;
|
|
718
|
+
manage_inventory: boolean | null;
|
|
719
|
+
inventory_quantity?: number;
|
|
720
|
+
hs_code: string | null;
|
|
721
|
+
origin_country: string | null;
|
|
722
|
+
mid_code: string | null;
|
|
723
|
+
material: string | null;
|
|
724
|
+
weight: number | null;
|
|
725
|
+
length: number | null;
|
|
726
|
+
height: number | null;
|
|
727
|
+
width: number | null;
|
|
728
|
+
variant_rank?: number | null;
|
|
729
|
+
options: ProductOptionValue[] | null;
|
|
730
|
+
prices: ProductVariantPrice[] | null;
|
|
731
|
+
product_id?: string;
|
|
732
|
+
created_at: string;
|
|
733
|
+
updated_at: string;
|
|
734
|
+
deleted_at: string | null;
|
|
735
|
+
metadata?: Record<string, unknown> | null;
|
|
736
|
+
}
|
|
737
|
+
interface ProductVariantPrice {
|
|
738
|
+
id: string;
|
|
739
|
+
currency_code: string;
|
|
740
|
+
amount: number;
|
|
741
|
+
min_quantity?: number | null;
|
|
742
|
+
max_quantity?: number | null;
|
|
743
|
+
created_at: string;
|
|
744
|
+
updated_at: string;
|
|
745
|
+
deleted_at: string | null;
|
|
746
|
+
}
|
|
747
|
+
interface Product {
|
|
748
|
+
id: string;
|
|
749
|
+
title: string;
|
|
750
|
+
handle: string;
|
|
751
|
+
subtitle: string | null;
|
|
752
|
+
description: string | null;
|
|
753
|
+
is_giftcard: boolean;
|
|
754
|
+
status: ProductStatus;
|
|
755
|
+
thumbnail: string | null;
|
|
756
|
+
width: number | null;
|
|
757
|
+
weight: number | null;
|
|
758
|
+
length: number | null;
|
|
759
|
+
height: number | null;
|
|
760
|
+
origin_country: string | null;
|
|
761
|
+
hs_code: string | null;
|
|
762
|
+
mid_code: string | null;
|
|
763
|
+
material: string | null;
|
|
764
|
+
collection_id: string | null;
|
|
765
|
+
collection?: Collection | null;
|
|
766
|
+
type_id: string | null;
|
|
767
|
+
discountable: boolean;
|
|
768
|
+
external_id: string | null;
|
|
769
|
+
variants: ProductVariant[] | null;
|
|
770
|
+
options: ProductOption[] | null;
|
|
771
|
+
images: ProductImage[] | null;
|
|
772
|
+
tags?: ProductTag[] | null;
|
|
773
|
+
categories?: ProductCategory[] | null;
|
|
774
|
+
created_at: string | null;
|
|
775
|
+
updated_at: string | null;
|
|
776
|
+
deleted_at: string | null;
|
|
777
|
+
metadata?: Record<string, unknown> | null;
|
|
778
|
+
}
|
|
779
|
+
interface Collection {
|
|
780
|
+
id: string;
|
|
781
|
+
title: string;
|
|
782
|
+
handle: string;
|
|
783
|
+
products?: Product[];
|
|
784
|
+
created_at: string;
|
|
785
|
+
updated_at: string;
|
|
786
|
+
deleted_at?: string | null;
|
|
787
|
+
metadata?: Record<string, unknown> | null;
|
|
788
|
+
}
|
|
789
|
+
interface ProductTag {
|
|
790
|
+
id: string;
|
|
791
|
+
value: string;
|
|
792
|
+
metadata?: Record<string, unknown> | null;
|
|
793
|
+
created_at?: string;
|
|
794
|
+
updated_at?: string;
|
|
795
|
+
deleted_at?: string | null;
|
|
796
|
+
}
|
|
797
|
+
interface ProductCategory {
|
|
798
|
+
id: string;
|
|
799
|
+
name: string;
|
|
800
|
+
handle: string;
|
|
801
|
+
description?: string;
|
|
802
|
+
is_active?: boolean;
|
|
803
|
+
is_internal?: boolean;
|
|
804
|
+
rank?: number;
|
|
805
|
+
parent_category_id?: string | null;
|
|
806
|
+
parent_category?: ProductCategory | null;
|
|
807
|
+
category_children?: ProductCategory[];
|
|
808
|
+
metadata?: Record<string, unknown> | null;
|
|
809
|
+
created_at?: string;
|
|
810
|
+
updated_at?: string;
|
|
811
|
+
deleted_at?: string | null;
|
|
812
|
+
}
|
|
813
|
+
|
|
680
814
|
type TransactionType = 'sale' | 'expense';
|
|
681
815
|
interface TransactionItem {
|
|
682
816
|
name: string;
|
|
@@ -894,4 +1028,4 @@ declare enum LinkDestination {
|
|
|
894
1028
|
}
|
|
895
1029
|
type NullOrUndefined = null | undefined;
|
|
896
1030
|
|
|
897
|
-
export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, BusinessCapability, type BusinessCategory, type BusinessMember, type BusinessPg, BusinessRole, type City, type Coupon, type Customer, type CustomerTransactionStats, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandDeliveryTiming, type ErrandPackagingQuality, type ErrandRating, type ErrandReview, type ErrandReviewLink, type ErrandRiderBehavior, ErrandStatus, type ErrandTimeline, GlobalRoles, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type MaintenanceItem, type MaintenancePartUsage, type MaintenanceRecord, type MaintenanceStats, type MaintenanceStatsSummary, type MaintenanceTopItem, MembershipStatus, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, RemittanceStatus, type Rider, type RiderPerformanceItem, type RiderPerformanceStats, type RiderPerformanceSummary, type RiderPerformanceTimeSeries, type RiderSettlement, RoleType, SettlementType, type State, type TraccarDevice, TraccarDeviceStatus, type TraccarPosition, type TrackerDevice, type Transaction, type TransactionCategory, type TransactionItem, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, type VehicleLogStatsSummary, VehicleLogType, type VehicleLogWithErrands, VehicleType, type VehicleWithRider, type Vendor, errandTimeline };
|
|
1031
|
+
export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, BusinessCapability, type BusinessCategory, type BusinessMember, type BusinessPg, BusinessRole, type City, type Collection, type Coupon, type Customer, type CustomerTransactionStats, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandDeliveryTiming, type ErrandPackagingQuality, type ErrandRating, type ErrandReview, type ErrandReviewLink, type ErrandRiderBehavior, ErrandStatus, type ErrandTimeline, GlobalRoles, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type MaintenanceItem, type MaintenancePartUsage, type MaintenanceRecord, type MaintenanceStats, type MaintenanceStatsSummary, type MaintenanceTopItem, MembershipStatus, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Product, type ProductCategory, type ProductImage, type ProductOption, type ProductOptionValue, type ProductStatus, type ProductTag, type ProductVariant, type ProductVariantPrice, RemittanceStatus, type Rider, type RiderPerformanceItem, type RiderPerformanceStats, type RiderPerformanceSummary, type RiderPerformanceTimeSeries, type RiderSettlement, RoleType, SettlementType, type State, type TraccarDevice, TraccarDeviceStatus, type TraccarPosition, type TrackerDevice, type Transaction, type TransactionCategory, type TransactionItem, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, type VehicleLogStatsSummary, VehicleLogType, type VehicleLogWithErrands, VehicleType, type VehicleWithRider, type Vendor, errandTimeline };
|
package/dist/index.d.ts
CHANGED
|
@@ -677,6 +677,140 @@ interface BusinessMember {
|
|
|
677
677
|
updatedAt: string | NullOrUndefined;
|
|
678
678
|
}
|
|
679
679
|
|
|
680
|
+
type ProductStatus = 'draft' | 'proposed' | 'published' | 'rejected';
|
|
681
|
+
interface ProductImage {
|
|
682
|
+
id: string;
|
|
683
|
+
url: string;
|
|
684
|
+
rank: number;
|
|
685
|
+
created_at?: string;
|
|
686
|
+
updated_at?: string;
|
|
687
|
+
deleted_at?: string | null;
|
|
688
|
+
metadata?: Record<string, unknown> | null;
|
|
689
|
+
}
|
|
690
|
+
interface ProductOptionValue {
|
|
691
|
+
id: string;
|
|
692
|
+
value: string;
|
|
693
|
+
option?: ProductOption | null;
|
|
694
|
+
option_id?: string | null;
|
|
695
|
+
metadata?: Record<string, unknown> | null;
|
|
696
|
+
created_at?: string;
|
|
697
|
+
updated_at?: string;
|
|
698
|
+
deleted_at?: string | null;
|
|
699
|
+
}
|
|
700
|
+
interface ProductOption {
|
|
701
|
+
id: string;
|
|
702
|
+
title: string;
|
|
703
|
+
product_id?: string | null;
|
|
704
|
+
values?: ProductOptionValue[];
|
|
705
|
+
metadata?: Record<string, unknown> | null;
|
|
706
|
+
created_at?: string;
|
|
707
|
+
updated_at?: string;
|
|
708
|
+
deleted_at?: string | null;
|
|
709
|
+
}
|
|
710
|
+
interface ProductVariant {
|
|
711
|
+
id: string;
|
|
712
|
+
title: string | null;
|
|
713
|
+
sku: string | null;
|
|
714
|
+
barcode: string | null;
|
|
715
|
+
ean: string | null;
|
|
716
|
+
upc: string | null;
|
|
717
|
+
allow_backorder: boolean | null;
|
|
718
|
+
manage_inventory: boolean | null;
|
|
719
|
+
inventory_quantity?: number;
|
|
720
|
+
hs_code: string | null;
|
|
721
|
+
origin_country: string | null;
|
|
722
|
+
mid_code: string | null;
|
|
723
|
+
material: string | null;
|
|
724
|
+
weight: number | null;
|
|
725
|
+
length: number | null;
|
|
726
|
+
height: number | null;
|
|
727
|
+
width: number | null;
|
|
728
|
+
variant_rank?: number | null;
|
|
729
|
+
options: ProductOptionValue[] | null;
|
|
730
|
+
prices: ProductVariantPrice[] | null;
|
|
731
|
+
product_id?: string;
|
|
732
|
+
created_at: string;
|
|
733
|
+
updated_at: string;
|
|
734
|
+
deleted_at: string | null;
|
|
735
|
+
metadata?: Record<string, unknown> | null;
|
|
736
|
+
}
|
|
737
|
+
interface ProductVariantPrice {
|
|
738
|
+
id: string;
|
|
739
|
+
currency_code: string;
|
|
740
|
+
amount: number;
|
|
741
|
+
min_quantity?: number | null;
|
|
742
|
+
max_quantity?: number | null;
|
|
743
|
+
created_at: string;
|
|
744
|
+
updated_at: string;
|
|
745
|
+
deleted_at: string | null;
|
|
746
|
+
}
|
|
747
|
+
interface Product {
|
|
748
|
+
id: string;
|
|
749
|
+
title: string;
|
|
750
|
+
handle: string;
|
|
751
|
+
subtitle: string | null;
|
|
752
|
+
description: string | null;
|
|
753
|
+
is_giftcard: boolean;
|
|
754
|
+
status: ProductStatus;
|
|
755
|
+
thumbnail: string | null;
|
|
756
|
+
width: number | null;
|
|
757
|
+
weight: number | null;
|
|
758
|
+
length: number | null;
|
|
759
|
+
height: number | null;
|
|
760
|
+
origin_country: string | null;
|
|
761
|
+
hs_code: string | null;
|
|
762
|
+
mid_code: string | null;
|
|
763
|
+
material: string | null;
|
|
764
|
+
collection_id: string | null;
|
|
765
|
+
collection?: Collection | null;
|
|
766
|
+
type_id: string | null;
|
|
767
|
+
discountable: boolean;
|
|
768
|
+
external_id: string | null;
|
|
769
|
+
variants: ProductVariant[] | null;
|
|
770
|
+
options: ProductOption[] | null;
|
|
771
|
+
images: ProductImage[] | null;
|
|
772
|
+
tags?: ProductTag[] | null;
|
|
773
|
+
categories?: ProductCategory[] | null;
|
|
774
|
+
created_at: string | null;
|
|
775
|
+
updated_at: string | null;
|
|
776
|
+
deleted_at: string | null;
|
|
777
|
+
metadata?: Record<string, unknown> | null;
|
|
778
|
+
}
|
|
779
|
+
interface Collection {
|
|
780
|
+
id: string;
|
|
781
|
+
title: string;
|
|
782
|
+
handle: string;
|
|
783
|
+
products?: Product[];
|
|
784
|
+
created_at: string;
|
|
785
|
+
updated_at: string;
|
|
786
|
+
deleted_at?: string | null;
|
|
787
|
+
metadata?: Record<string, unknown> | null;
|
|
788
|
+
}
|
|
789
|
+
interface ProductTag {
|
|
790
|
+
id: string;
|
|
791
|
+
value: string;
|
|
792
|
+
metadata?: Record<string, unknown> | null;
|
|
793
|
+
created_at?: string;
|
|
794
|
+
updated_at?: string;
|
|
795
|
+
deleted_at?: string | null;
|
|
796
|
+
}
|
|
797
|
+
interface ProductCategory {
|
|
798
|
+
id: string;
|
|
799
|
+
name: string;
|
|
800
|
+
handle: string;
|
|
801
|
+
description?: string;
|
|
802
|
+
is_active?: boolean;
|
|
803
|
+
is_internal?: boolean;
|
|
804
|
+
rank?: number;
|
|
805
|
+
parent_category_id?: string | null;
|
|
806
|
+
parent_category?: ProductCategory | null;
|
|
807
|
+
category_children?: ProductCategory[];
|
|
808
|
+
metadata?: Record<string, unknown> | null;
|
|
809
|
+
created_at?: string;
|
|
810
|
+
updated_at?: string;
|
|
811
|
+
deleted_at?: string | null;
|
|
812
|
+
}
|
|
813
|
+
|
|
680
814
|
type TransactionType = 'sale' | 'expense';
|
|
681
815
|
interface TransactionItem {
|
|
682
816
|
name: string;
|
|
@@ -894,4 +1028,4 @@ declare enum LinkDestination {
|
|
|
894
1028
|
}
|
|
895
1029
|
type NullOrUndefined = null | undefined;
|
|
896
1030
|
|
|
897
|
-
export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, BusinessCapability, type BusinessCategory, type BusinessMember, type BusinessPg, BusinessRole, type City, type Coupon, type Customer, type CustomerTransactionStats, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandDeliveryTiming, type ErrandPackagingQuality, type ErrandRating, type ErrandReview, type ErrandReviewLink, type ErrandRiderBehavior, ErrandStatus, type ErrandTimeline, GlobalRoles, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type MaintenanceItem, type MaintenancePartUsage, type MaintenanceRecord, type MaintenanceStats, type MaintenanceStatsSummary, type MaintenanceTopItem, MembershipStatus, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, RemittanceStatus, type Rider, type RiderPerformanceItem, type RiderPerformanceStats, type RiderPerformanceSummary, type RiderPerformanceTimeSeries, type RiderSettlement, RoleType, SettlementType, type State, type TraccarDevice, TraccarDeviceStatus, type TraccarPosition, type TrackerDevice, type Transaction, type TransactionCategory, type TransactionItem, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, type VehicleLogStatsSummary, VehicleLogType, type VehicleLogWithErrands, VehicleType, type VehicleWithRider, type Vendor, errandTimeline };
|
|
1031
|
+
export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, BusinessCapability, type BusinessCategory, type BusinessMember, type BusinessPg, BusinessRole, type City, type Collection, type Coupon, type Customer, type CustomerTransactionStats, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandDeliveryTiming, type ErrandPackagingQuality, type ErrandRating, type ErrandReview, type ErrandReviewLink, type ErrandRiderBehavior, ErrandStatus, type ErrandTimeline, GlobalRoles, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type MaintenanceItem, type MaintenancePartUsage, type MaintenanceRecord, type MaintenanceStats, type MaintenanceStatsSummary, type MaintenanceTopItem, MembershipStatus, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Product, type ProductCategory, type ProductImage, type ProductOption, type ProductOptionValue, type ProductStatus, type ProductTag, type ProductVariant, type ProductVariantPrice, RemittanceStatus, type Rider, type RiderPerformanceItem, type RiderPerformanceStats, type RiderPerformanceSummary, type RiderPerformanceTimeSeries, type RiderSettlement, RoleType, SettlementType, type State, type TraccarDevice, TraccarDeviceStatus, type TraccarPosition, type TrackerDevice, type Transaction, type TransactionCategory, type TransactionItem, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, type VehicleLogStatsSummary, VehicleLogType, type VehicleLogWithErrands, VehicleType, type VehicleWithRider, type Vendor, errandTimeline };
|
package/package.json
CHANGED
package/src/commerce.ts
ADDED
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
export type ProductStatus = 'draft' | 'proposed' | 'published' | 'rejected'; // status
|
|
2
|
+
|
|
3
|
+
export interface ProductImage {
|
|
4
|
+
id: string;
|
|
5
|
+
url: string;
|
|
6
|
+
rank: number;
|
|
7
|
+
created_at?: string;
|
|
8
|
+
updated_at?: string;
|
|
9
|
+
deleted_at?: string | null;
|
|
10
|
+
metadata?: Record<string, unknown> | null;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface ProductOptionValue {
|
|
14
|
+
id: string;
|
|
15
|
+
value: string;
|
|
16
|
+
option?: ProductOption | null;
|
|
17
|
+
option_id?: string | null;
|
|
18
|
+
metadata?: Record<string, unknown> | null;
|
|
19
|
+
created_at?: string;
|
|
20
|
+
updated_at?: string;
|
|
21
|
+
deleted_at?: string | null;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export interface ProductOption {
|
|
25
|
+
id: string;
|
|
26
|
+
title: string;
|
|
27
|
+
product_id?: string | null;
|
|
28
|
+
values?: ProductOptionValue[];
|
|
29
|
+
metadata?: Record<string, unknown> | null;
|
|
30
|
+
created_at?: string;
|
|
31
|
+
updated_at?: string;
|
|
32
|
+
deleted_at?: string | null;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export interface ProductVariant {
|
|
36
|
+
id: string;
|
|
37
|
+
title: string | null;
|
|
38
|
+
sku: string | null;
|
|
39
|
+
barcode: string | null;
|
|
40
|
+
ean: string | null;
|
|
41
|
+
upc: string | null;
|
|
42
|
+
allow_backorder: boolean | null;
|
|
43
|
+
manage_inventory: boolean | null;
|
|
44
|
+
inventory_quantity?: number;
|
|
45
|
+
hs_code: string | null;
|
|
46
|
+
origin_country: string | null;
|
|
47
|
+
mid_code: string | null;
|
|
48
|
+
material: string | null;
|
|
49
|
+
weight: number | null;
|
|
50
|
+
length: number | null;
|
|
51
|
+
height: number | null;
|
|
52
|
+
width: number | null;
|
|
53
|
+
variant_rank?: number | null;
|
|
54
|
+
options: ProductOptionValue[] | null;
|
|
55
|
+
prices: ProductVariantPrice[] | null;
|
|
56
|
+
product_id?: string;
|
|
57
|
+
created_at: string;
|
|
58
|
+
updated_at: string;
|
|
59
|
+
deleted_at: string | null;
|
|
60
|
+
metadata?: Record<string, unknown> | null;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export interface ProductVariantPrice {
|
|
64
|
+
id: string;
|
|
65
|
+
currency_code: string;
|
|
66
|
+
amount: number;
|
|
67
|
+
min_quantity?: number | null;
|
|
68
|
+
max_quantity?: number | null;
|
|
69
|
+
created_at: string;
|
|
70
|
+
updated_at: string;
|
|
71
|
+
deleted_at: string | null;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export interface Product {
|
|
75
|
+
id: string;
|
|
76
|
+
title: string;
|
|
77
|
+
handle: string;
|
|
78
|
+
subtitle: string | null;
|
|
79
|
+
description: string | null;
|
|
80
|
+
is_giftcard: boolean;
|
|
81
|
+
status: ProductStatus;
|
|
82
|
+
thumbnail: string | null;
|
|
83
|
+
width: number | null;
|
|
84
|
+
weight: number | null;
|
|
85
|
+
length: number | null;
|
|
86
|
+
height: number | null;
|
|
87
|
+
origin_country: string | null;
|
|
88
|
+
hs_code: string | null;
|
|
89
|
+
mid_code: string | null;
|
|
90
|
+
material: string | null;
|
|
91
|
+
collection_id: string | null;
|
|
92
|
+
collection?: Collection | null;
|
|
93
|
+
type_id: string | null;
|
|
94
|
+
discountable: boolean;
|
|
95
|
+
external_id: string | null;
|
|
96
|
+
variants: ProductVariant[] | null;
|
|
97
|
+
options: ProductOption[] | null;
|
|
98
|
+
images: ProductImage[] | null;
|
|
99
|
+
tags?: ProductTag[] | null;
|
|
100
|
+
categories?: ProductCategory[] | null;
|
|
101
|
+
created_at: string | null;
|
|
102
|
+
updated_at: string | null;
|
|
103
|
+
deleted_at: string | null;
|
|
104
|
+
metadata?: Record<string, unknown> | null;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export interface Collection {
|
|
108
|
+
id: string;
|
|
109
|
+
title: string;
|
|
110
|
+
handle: string;
|
|
111
|
+
products?: Product[];
|
|
112
|
+
created_at: string;
|
|
113
|
+
updated_at: string;
|
|
114
|
+
deleted_at?: string | null;
|
|
115
|
+
metadata?: Record<string, unknown> | null;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export interface ProductTag {
|
|
119
|
+
id: string;
|
|
120
|
+
value: string;
|
|
121
|
+
metadata?: Record<string, unknown> | null;
|
|
122
|
+
created_at?: string;
|
|
123
|
+
updated_at?: string;
|
|
124
|
+
deleted_at?: string | null;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export interface ProductCategory {
|
|
128
|
+
id: string;
|
|
129
|
+
name: string;
|
|
130
|
+
handle: string;
|
|
131
|
+
description?: string;
|
|
132
|
+
is_active?: boolean;
|
|
133
|
+
is_internal?: boolean;
|
|
134
|
+
rank?: number;
|
|
135
|
+
parent_category_id?: string | null;
|
|
136
|
+
parent_category?: ProductCategory | null;
|
|
137
|
+
category_children?: ProductCategory[];
|
|
138
|
+
metadata?: Record<string, unknown> | null;
|
|
139
|
+
created_at?: string;
|
|
140
|
+
updated_at?: string;
|
|
141
|
+
deleted_at?: string | null;
|
|
142
|
+
}
|
package/src/index.ts
CHANGED