arky-sdk 0.7.44 → 0.7.47
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-CkyDsYWA.d.ts → index-BCAQZOwm.d.cts} +3 -2
- package/dist/{index-BzBZVueX.d.cts → index-DTg5d847.d.ts} +3 -2
- package/dist/index.cjs +15 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -5
- package/dist/index.d.ts +6 -5
- package/dist/index.js +15 -9
- package/dist/index.js.map +1 -1
- package/dist/types.cjs +0 -9
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +247 -84
- package/dist/types.d.ts +247 -84
- package/dist/types.js +1 -9
- package/dist/types.js.map +1 -1
- package/dist/utils.cjs.map +1 -1
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js.map +1 -1
- package/package.json +1 -1
package/dist/types.d.ts
CHANGED
|
@@ -1,12 +1,88 @@
|
|
|
1
|
-
|
|
1
|
+
declare enum PaymentMethodType {
|
|
2
|
+
Cash = "cash",
|
|
3
|
+
CreditCard = "credit_card"
|
|
4
|
+
}
|
|
5
|
+
interface PaymentTaxLine {
|
|
6
|
+
rateBps: number;
|
|
7
|
+
amount: number;
|
|
8
|
+
label?: string;
|
|
9
|
+
scope?: string;
|
|
10
|
+
}
|
|
11
|
+
interface BookingPaymentTax {
|
|
12
|
+
amount: number;
|
|
13
|
+
modeSnapshot?: string;
|
|
14
|
+
rateBps: number;
|
|
15
|
+
lines: BookingPaymentTaxLine[];
|
|
16
|
+
}
|
|
17
|
+
interface BookingPaymentTaxLine {
|
|
18
|
+
rateBps: number;
|
|
19
|
+
amount: number;
|
|
20
|
+
label?: string;
|
|
21
|
+
scope?: string;
|
|
22
|
+
}
|
|
23
|
+
interface BookingPaymentPromoCode {
|
|
24
|
+
id: string;
|
|
25
|
+
code: string;
|
|
26
|
+
type: string;
|
|
27
|
+
value: number;
|
|
28
|
+
}
|
|
29
|
+
type BookingPaymentProvider = {
|
|
30
|
+
type: 'stripe';
|
|
31
|
+
customerId: string;
|
|
32
|
+
paymentIntentId?: string;
|
|
33
|
+
};
|
|
34
|
+
interface BookingPaymentRefund {
|
|
35
|
+
id: string;
|
|
36
|
+
total: number;
|
|
37
|
+
providerRefundId?: string;
|
|
38
|
+
status: string;
|
|
39
|
+
createdAt: number;
|
|
40
|
+
}
|
|
41
|
+
interface BookingPayment {
|
|
42
|
+
currency: string;
|
|
43
|
+
market: string;
|
|
44
|
+
subtotal: number;
|
|
45
|
+
discount: number;
|
|
46
|
+
total: number;
|
|
47
|
+
paid: number;
|
|
48
|
+
tax?: BookingPaymentTax;
|
|
49
|
+
promoCode?: BookingPaymentPromoCode;
|
|
50
|
+
provider?: BookingPaymentProvider;
|
|
51
|
+
refunds: BookingPaymentRefund[];
|
|
52
|
+
paymentMethodId?: string;
|
|
53
|
+
methodType: PaymentMethodType;
|
|
54
|
+
}
|
|
55
|
+
interface OrderPaymentTax {
|
|
56
|
+
amount: number;
|
|
57
|
+
modeSnapshot?: string;
|
|
58
|
+
rateBps: number;
|
|
59
|
+
lines: OrderPaymentTaxLine[];
|
|
60
|
+
}
|
|
61
|
+
interface OrderPaymentTaxLine {
|
|
62
|
+
rateBps: number;
|
|
63
|
+
amount: number;
|
|
64
|
+
label?: string;
|
|
65
|
+
scope?: string;
|
|
66
|
+
}
|
|
67
|
+
interface OrderPaymentPromoCode {
|
|
68
|
+
id: string;
|
|
69
|
+
code: string;
|
|
70
|
+
type: string;
|
|
71
|
+
value: number;
|
|
72
|
+
}
|
|
73
|
+
type OrderPaymentProvider = {
|
|
74
|
+
type: 'stripe';
|
|
75
|
+
customerId: string;
|
|
76
|
+
paymentIntentId?: string;
|
|
77
|
+
};
|
|
78
|
+
interface OrderPaymentRefund {
|
|
2
79
|
id: string;
|
|
3
|
-
entity: string;
|
|
4
80
|
total: number;
|
|
5
81
|
providerRefundId?: string;
|
|
6
82
|
status: string;
|
|
7
83
|
createdAt: number;
|
|
8
84
|
}
|
|
9
|
-
interface
|
|
85
|
+
interface OrderPayment {
|
|
10
86
|
currency: string;
|
|
11
87
|
market: string;
|
|
12
88
|
subtotal: number;
|
|
@@ -14,38 +90,14 @@ interface Payment {
|
|
|
14
90
|
discount: number;
|
|
15
91
|
total: number;
|
|
16
92
|
paid: number;
|
|
17
|
-
tax?:
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
lines: Array<{
|
|
22
|
-
rateBps: number;
|
|
23
|
-
amount: number;
|
|
24
|
-
label?: string;
|
|
25
|
-
scope?: string;
|
|
26
|
-
}>;
|
|
27
|
-
};
|
|
28
|
-
promoCode?: {
|
|
29
|
-
id: string;
|
|
30
|
-
code: string;
|
|
31
|
-
type: string;
|
|
32
|
-
value: number;
|
|
33
|
-
};
|
|
34
|
-
type: PaymentMethodType;
|
|
35
|
-
provider?: {
|
|
36
|
-
customerId: string;
|
|
37
|
-
paymentIntentId?: string;
|
|
38
|
-
subscriptionId?: string;
|
|
39
|
-
priceId?: string;
|
|
40
|
-
};
|
|
41
|
-
refunds: PaymentRefund[];
|
|
93
|
+
tax?: OrderPaymentTax;
|
|
94
|
+
promoCode?: OrderPaymentPromoCode;
|
|
95
|
+
provider?: OrderPaymentProvider;
|
|
96
|
+
refunds: OrderPaymentRefund[];
|
|
42
97
|
zoneId?: string;
|
|
43
98
|
paymentMethodId?: string;
|
|
44
99
|
shippingMethodId?: string;
|
|
45
|
-
|
|
46
|
-
declare enum PaymentMethodType {
|
|
47
|
-
Cash = "cash",
|
|
48
|
-
CreditCard = "credit_card"
|
|
100
|
+
methodType: PaymentMethodType;
|
|
49
101
|
}
|
|
50
102
|
interface PromoCodeValidation {
|
|
51
103
|
promoCodeId: string;
|
|
@@ -53,7 +105,22 @@ interface PromoCodeValidation {
|
|
|
53
105
|
discounts: any[];
|
|
54
106
|
conditions: any[];
|
|
55
107
|
}
|
|
56
|
-
interface
|
|
108
|
+
interface BookingQuote {
|
|
109
|
+
market: string;
|
|
110
|
+
zone: Zone | null;
|
|
111
|
+
subtotal: number;
|
|
112
|
+
discount: number;
|
|
113
|
+
tax: number;
|
|
114
|
+
total: number;
|
|
115
|
+
paymentMethod: PaymentMethod | null;
|
|
116
|
+
paymentMethods: PaymentMethod[];
|
|
117
|
+
promoCode: PromoCodeValidation | null;
|
|
118
|
+
payment: BookingPayment;
|
|
119
|
+
chargeAmount: number;
|
|
120
|
+
id?: string;
|
|
121
|
+
expiresAt?: number;
|
|
122
|
+
}
|
|
123
|
+
interface OrderQuote {
|
|
57
124
|
market: string;
|
|
58
125
|
zone: Zone | null;
|
|
59
126
|
subtotal: number;
|
|
@@ -65,7 +132,7 @@ interface Quote {
|
|
|
65
132
|
paymentMethod: PaymentMethod | null;
|
|
66
133
|
paymentMethods: PaymentMethod[];
|
|
67
134
|
promoCode: PromoCodeValidation | null;
|
|
68
|
-
payment:
|
|
135
|
+
payment: OrderPayment;
|
|
69
136
|
chargeAmount: number;
|
|
70
137
|
id?: string;
|
|
71
138
|
expiresAt?: number;
|
|
@@ -480,15 +547,59 @@ interface Webhook {
|
|
|
480
547
|
createdAt: number;
|
|
481
548
|
updatedAt: number;
|
|
482
549
|
}
|
|
483
|
-
|
|
550
|
+
type BusinessSubscriptionStatus = 'pending' | 'active' | 'cancellation_scheduled' | 'cancelled' | 'expired';
|
|
551
|
+
type BusinessSubscriptionSource = 'signup' | 'admin' | 'import';
|
|
552
|
+
type BusinessSubscriptionProvider = {
|
|
553
|
+
type: 'stripe';
|
|
554
|
+
customerId: string;
|
|
555
|
+
subscriptionId?: string;
|
|
556
|
+
priceId?: string;
|
|
557
|
+
};
|
|
558
|
+
interface BusinessSubscriptionPayment {
|
|
559
|
+
currency: string;
|
|
560
|
+
market: string;
|
|
561
|
+
provider?: BusinessSubscriptionProvider;
|
|
562
|
+
}
|
|
563
|
+
interface BusinessSubscription {
|
|
484
564
|
id: string;
|
|
485
565
|
target: string;
|
|
486
566
|
planId: string;
|
|
487
567
|
pendingPlanId: string | null;
|
|
488
|
-
payment:
|
|
489
|
-
status:
|
|
568
|
+
payment: BusinessSubscriptionPayment;
|
|
569
|
+
status: BusinessSubscriptionStatus;
|
|
570
|
+
startDate: number;
|
|
571
|
+
endDate: number;
|
|
572
|
+
token: string;
|
|
573
|
+
source: BusinessSubscriptionSource;
|
|
574
|
+
}
|
|
575
|
+
type AudienceSubscriptionStatus = 'pending' | 'active' | 'cancellation_scheduled' | 'cancelled' | 'expired';
|
|
576
|
+
type AudienceSubscriptionSource = 'signup' | 'admin' | 'import';
|
|
577
|
+
type AudienceSubscriptionProvider = {
|
|
578
|
+
type: 'stripe';
|
|
579
|
+
customerId: string;
|
|
580
|
+
subscriptionId?: string;
|
|
581
|
+
priceId?: string;
|
|
582
|
+
};
|
|
583
|
+
interface AudienceSubscriptionPayment {
|
|
584
|
+
currency: string;
|
|
585
|
+
market: string;
|
|
586
|
+
provider?: AudienceSubscriptionProvider;
|
|
587
|
+
}
|
|
588
|
+
interface AudienceSubscription {
|
|
589
|
+
id: string;
|
|
590
|
+
businessId: string;
|
|
591
|
+
customerId: string;
|
|
592
|
+
audienceId: string;
|
|
593
|
+
planId: string;
|
|
594
|
+
pendingPlanId: string | null;
|
|
595
|
+
payment: AudienceSubscriptionPayment;
|
|
596
|
+
status: AudienceSubscriptionStatus;
|
|
597
|
+
startDate: number;
|
|
490
598
|
endDate: number;
|
|
491
599
|
token: string;
|
|
600
|
+
source: AudienceSubscriptionSource;
|
|
601
|
+
createdAt: number;
|
|
602
|
+
updatedAt: number;
|
|
492
603
|
}
|
|
493
604
|
interface Business {
|
|
494
605
|
id: string;
|
|
@@ -496,7 +607,7 @@ interface Business {
|
|
|
496
607
|
timezone: string;
|
|
497
608
|
languages?: Language[];
|
|
498
609
|
emails?: BusinessEmails;
|
|
499
|
-
subscription?:
|
|
610
|
+
subscription?: BusinessSubscription;
|
|
500
611
|
counts?: Record<string, number>;
|
|
501
612
|
}
|
|
502
613
|
interface EshopStoreState {
|
|
@@ -651,9 +762,23 @@ interface BookingStoreState {
|
|
|
651
762
|
enabled: boolean;
|
|
652
763
|
};
|
|
653
764
|
}
|
|
654
|
-
type
|
|
655
|
-
type
|
|
656
|
-
type
|
|
765
|
+
type OrderStatus = 'active' | 'draft' | 'archived';
|
|
766
|
+
type BookingStatus = 'active' | 'draft' | 'archived';
|
|
767
|
+
type BookingServiceStatus = 'active' | 'draft' | 'archived';
|
|
768
|
+
type BookingProviderStatus = 'active' | 'draft' | 'archived';
|
|
769
|
+
type ProductStatus = 'active' | 'draft' | 'archived';
|
|
770
|
+
type CustomerStatus = 'active' | 'draft' | 'archived';
|
|
771
|
+
type AudienceStatus = 'active' | 'draft' | 'archived';
|
|
772
|
+
type AgentChatStatus = 'active' | 'draft' | 'archived';
|
|
773
|
+
type WorkflowStatus = 'active' | 'draft' | 'archived';
|
|
774
|
+
type PromoCodeStatus = 'active' | 'draft' | 'archived';
|
|
775
|
+
type NodeStatus = 'active' | 'draft' | 'archived';
|
|
776
|
+
type EmailTemplateStatus = 'active' | 'draft' | 'archived';
|
|
777
|
+
type FormStatus = 'active' | 'draft' | 'archived';
|
|
778
|
+
type TaxonomyStatus = 'active' | 'draft' | 'archived';
|
|
779
|
+
type BookingCancellationReason = 'admin_rejected' | 'customer_cancelled' | 'payment_failed' | 'expired' | 'no_show_auto' | 'other';
|
|
780
|
+
type OrderCancellationReason = 'admin_rejected' | 'customer_cancelled' | 'payment_failed' | 'expired' | 'other';
|
|
781
|
+
type BookingItemStatus = {
|
|
657
782
|
status: 'pending';
|
|
658
783
|
at: number;
|
|
659
784
|
expires_at: number;
|
|
@@ -661,21 +786,66 @@ type OrderWorkflowStatus = {
|
|
|
661
786
|
status: 'confirmed';
|
|
662
787
|
at: number;
|
|
663
788
|
} | {
|
|
664
|
-
status: '
|
|
789
|
+
status: 'cancelled';
|
|
790
|
+
at: number;
|
|
791
|
+
reason: BookingCancellationReason;
|
|
792
|
+
} | {
|
|
793
|
+
status: 'fulfilled';
|
|
794
|
+
at: number;
|
|
795
|
+
} | {
|
|
796
|
+
status: 'no_show';
|
|
665
797
|
at: number;
|
|
666
798
|
};
|
|
667
|
-
type
|
|
668
|
-
type BookingWorkflowStatus = {
|
|
799
|
+
type OrderItemStatus = {
|
|
669
800
|
status: 'pending';
|
|
801
|
+
at: number;
|
|
670
802
|
expires_at: number;
|
|
671
803
|
} | {
|
|
672
804
|
status: 'confirmed';
|
|
673
805
|
at: number;
|
|
674
806
|
} | {
|
|
675
|
-
status: '
|
|
807
|
+
status: 'cancelled';
|
|
808
|
+
at: number;
|
|
809
|
+
reason: OrderCancellationReason;
|
|
810
|
+
} | {
|
|
811
|
+
status: 'fulfilled';
|
|
676
812
|
at: number;
|
|
813
|
+
} | {
|
|
814
|
+
status: 'returned';
|
|
815
|
+
at: number;
|
|
816
|
+
};
|
|
817
|
+
type BookingPaymentStatus = {
|
|
818
|
+
status: 'pending';
|
|
819
|
+
at: number;
|
|
820
|
+
} | {
|
|
821
|
+
status: 'authorized';
|
|
822
|
+
at: number;
|
|
823
|
+
amount: number;
|
|
824
|
+
} | {
|
|
825
|
+
status: 'captured';
|
|
826
|
+
at: number;
|
|
827
|
+
amount: number;
|
|
828
|
+
} | {
|
|
829
|
+
status: 'failed';
|
|
830
|
+
at: number;
|
|
831
|
+
reason?: string;
|
|
832
|
+
};
|
|
833
|
+
type OrderPaymentStatus = {
|
|
834
|
+
status: 'pending';
|
|
835
|
+
at: number;
|
|
836
|
+
} | {
|
|
837
|
+
status: 'authorized';
|
|
838
|
+
at: number;
|
|
839
|
+
amount: number;
|
|
840
|
+
} | {
|
|
841
|
+
status: 'captured';
|
|
842
|
+
at: number;
|
|
843
|
+
amount: number;
|
|
844
|
+
} | {
|
|
845
|
+
status: 'failed';
|
|
846
|
+
at: number;
|
|
847
|
+
reason?: string;
|
|
677
848
|
};
|
|
678
|
-
type SubscriptionStatus = 'pending' | 'active' | 'cancellation_scheduled' | 'cancelled' | 'expired';
|
|
679
849
|
interface BookingItemSnapshot {
|
|
680
850
|
serviceKey: string;
|
|
681
851
|
providerKey: string;
|
|
@@ -685,7 +855,6 @@ interface TimeRange {
|
|
|
685
855
|
from: number;
|
|
686
856
|
to: number;
|
|
687
857
|
}
|
|
688
|
-
type BookingItemStatus = 'active' | 'cancelled' | 'no_show';
|
|
689
858
|
interface BookingItem {
|
|
690
859
|
id: string;
|
|
691
860
|
serviceId: string;
|
|
@@ -697,7 +866,6 @@ interface BookingItem {
|
|
|
697
866
|
forms: FormEntry[];
|
|
698
867
|
snapshot: BookingItemSnapshot;
|
|
699
868
|
status: BookingItemStatus;
|
|
700
|
-
cancelledAt?: number;
|
|
701
869
|
}
|
|
702
870
|
interface Booking {
|
|
703
871
|
id: string;
|
|
@@ -707,10 +875,9 @@ interface Booking {
|
|
|
707
875
|
forms: FormEntry[];
|
|
708
876
|
businessId: string;
|
|
709
877
|
status: BookingStatus;
|
|
710
|
-
workflowStatus: BookingWorkflowStatus;
|
|
711
878
|
serviceIds: string[];
|
|
712
879
|
providerIds: string[];
|
|
713
|
-
payment:
|
|
880
|
+
payment: BookingPayment;
|
|
714
881
|
business?: Business;
|
|
715
882
|
account?: any;
|
|
716
883
|
items: BookingItem[];
|
|
@@ -730,7 +897,7 @@ interface Node {
|
|
|
730
897
|
parentId?: string | null;
|
|
731
898
|
blocks: Block[];
|
|
732
899
|
taxonomies: TaxonomyEntry[];
|
|
733
|
-
status:
|
|
900
|
+
status: NodeStatus;
|
|
734
901
|
slug: Record<string, string>;
|
|
735
902
|
children: Node[];
|
|
736
903
|
createdAt: number;
|
|
@@ -746,7 +913,7 @@ interface EmailTemplate {
|
|
|
746
913
|
fromEmail: string;
|
|
747
914
|
replyTo?: string;
|
|
748
915
|
preheader?: string;
|
|
749
|
-
status:
|
|
916
|
+
status: EmailTemplateStatus;
|
|
750
917
|
createdAt: number;
|
|
751
918
|
updatedAt: number;
|
|
752
919
|
}
|
|
@@ -755,7 +922,7 @@ interface Form {
|
|
|
755
922
|
key: string;
|
|
756
923
|
businessId: string;
|
|
757
924
|
schema: FormSchema[];
|
|
758
|
-
status:
|
|
925
|
+
status: FormStatus;
|
|
759
926
|
createdAt: number;
|
|
760
927
|
updatedAt: number;
|
|
761
928
|
}
|
|
@@ -772,7 +939,7 @@ interface Taxonomy {
|
|
|
772
939
|
businessId: string;
|
|
773
940
|
parentId?: string | null;
|
|
774
941
|
schema?: TaxonomySchema[];
|
|
775
|
-
status:
|
|
942
|
+
status: TaxonomyStatus;
|
|
776
943
|
createdAt: number;
|
|
777
944
|
updatedAt: number;
|
|
778
945
|
}
|
|
@@ -818,7 +985,7 @@ interface Service {
|
|
|
818
985
|
taxonomies: TaxonomyEntry[];
|
|
819
986
|
createdAt: number;
|
|
820
987
|
updatedAt: number;
|
|
821
|
-
status:
|
|
988
|
+
status: BookingServiceStatus;
|
|
822
989
|
}
|
|
823
990
|
interface ProviderTimelinePoint {
|
|
824
991
|
timestamp: number;
|
|
@@ -829,7 +996,7 @@ interface Provider {
|
|
|
829
996
|
key: string;
|
|
830
997
|
slug: Record<string, string>;
|
|
831
998
|
businessId: string;
|
|
832
|
-
status:
|
|
999
|
+
status: BookingProviderStatus;
|
|
833
1000
|
audienceIds: string[];
|
|
834
1001
|
blocks: Block[];
|
|
835
1002
|
taxonomies: TaxonomyEntry[];
|
|
@@ -846,7 +1013,7 @@ interface Workflow {
|
|
|
846
1013
|
key: string;
|
|
847
1014
|
businessId: string;
|
|
848
1015
|
secret: string;
|
|
849
|
-
status:
|
|
1016
|
+
status: WorkflowStatus;
|
|
850
1017
|
nodes: Record<string, WorkflowNode>;
|
|
851
1018
|
schedule?: string;
|
|
852
1019
|
createdAt: number;
|
|
@@ -933,16 +1100,16 @@ interface Audience {
|
|
|
933
1100
|
id: string;
|
|
934
1101
|
businessId: string;
|
|
935
1102
|
key: string;
|
|
936
|
-
status:
|
|
1103
|
+
status: AudienceStatus;
|
|
937
1104
|
type: AudienceType;
|
|
938
1105
|
}
|
|
939
1106
|
interface AudienceAccessResponse {
|
|
940
1107
|
hasAccess: boolean;
|
|
941
|
-
subscription?:
|
|
1108
|
+
subscription?: AudienceSubscription;
|
|
942
1109
|
}
|
|
943
1110
|
interface AudienceSubscribeResponse {
|
|
944
1111
|
checkoutUrl?: string;
|
|
945
|
-
subscription?:
|
|
1112
|
+
subscription?: AudienceSubscription;
|
|
946
1113
|
}
|
|
947
1114
|
type EventAction = {
|
|
948
1115
|
action: 'order_created';
|
|
@@ -1421,7 +1588,7 @@ interface ProviderWithTimeline {
|
|
|
1421
1588
|
key: string;
|
|
1422
1589
|
businessId: string;
|
|
1423
1590
|
seo: any;
|
|
1424
|
-
status:
|
|
1591
|
+
status: BookingProviderStatus;
|
|
1425
1592
|
audienceIds: string[];
|
|
1426
1593
|
blocks: Block[];
|
|
1427
1594
|
createdAt: number;
|
|
@@ -1465,7 +1632,7 @@ interface UpdatePromoCodeParams {
|
|
|
1465
1632
|
code: string;
|
|
1466
1633
|
discounts: Discount[];
|
|
1467
1634
|
conditions: Condition[];
|
|
1468
|
-
status?:
|
|
1635
|
+
status?: PromoCodeStatus;
|
|
1469
1636
|
}
|
|
1470
1637
|
interface DeletePromoCodeParams {
|
|
1471
1638
|
id: string;
|
|
@@ -1561,7 +1728,6 @@ interface GetOrderParams {
|
|
|
1561
1728
|
}
|
|
1562
1729
|
interface GetOrdersParams {
|
|
1563
1730
|
statuses?: string[] | null;
|
|
1564
|
-
workflowStatus?: string;
|
|
1565
1731
|
productIds?: string[];
|
|
1566
1732
|
verified?: boolean;
|
|
1567
1733
|
query?: string | null;
|
|
@@ -1579,7 +1745,7 @@ interface UpdateOrderParams {
|
|
|
1579
1745
|
items: any[];
|
|
1580
1746
|
address?: any | null;
|
|
1581
1747
|
billingAddress?: any | null;
|
|
1582
|
-
payment?:
|
|
1748
|
+
payment?: Partial<OrderPayment> | null;
|
|
1583
1749
|
confirm?: boolean;
|
|
1584
1750
|
cancel?: boolean;
|
|
1585
1751
|
}
|
|
@@ -1597,7 +1763,7 @@ interface UpdateBookingParams {
|
|
|
1597
1763
|
cancel?: boolean;
|
|
1598
1764
|
forms?: any;
|
|
1599
1765
|
items?: any;
|
|
1600
|
-
payment?:
|
|
1766
|
+
payment?: Partial<BookingPayment> | null;
|
|
1601
1767
|
[key: string]: any;
|
|
1602
1768
|
}
|
|
1603
1769
|
interface CreateProviderParams {
|
|
@@ -1606,7 +1772,7 @@ interface CreateProviderParams {
|
|
|
1606
1772
|
audienceIds?: string[];
|
|
1607
1773
|
blocks?: any[];
|
|
1608
1774
|
taxonomies?: any[];
|
|
1609
|
-
status?:
|
|
1775
|
+
status?: BookingProviderStatus;
|
|
1610
1776
|
[key: string]: any;
|
|
1611
1777
|
}
|
|
1612
1778
|
interface UpdateProviderParams {
|
|
@@ -1616,7 +1782,7 @@ interface UpdateProviderParams {
|
|
|
1616
1782
|
audienceIds?: string[];
|
|
1617
1783
|
blocks?: any[];
|
|
1618
1784
|
taxonomies?: any[];
|
|
1619
|
-
status?:
|
|
1785
|
+
status?: BookingProviderStatus;
|
|
1620
1786
|
[key: string]: any;
|
|
1621
1787
|
}
|
|
1622
1788
|
interface DeleteProviderParams {
|
|
@@ -1637,7 +1803,7 @@ interface CreateServiceParams {
|
|
|
1637
1803
|
key: string;
|
|
1638
1804
|
blocks?: any[];
|
|
1639
1805
|
taxonomies?: any[];
|
|
1640
|
-
status?:
|
|
1806
|
+
status?: BookingServiceStatus;
|
|
1641
1807
|
[key: string]: any;
|
|
1642
1808
|
}
|
|
1643
1809
|
interface UpdateServiceParams {
|
|
@@ -1646,7 +1812,7 @@ interface UpdateServiceParams {
|
|
|
1646
1812
|
key?: string;
|
|
1647
1813
|
blocks?: any[];
|
|
1648
1814
|
taxonomies?: any[];
|
|
1649
|
-
status?:
|
|
1815
|
+
status?: BookingServiceStatus;
|
|
1650
1816
|
[key: string]: any;
|
|
1651
1817
|
}
|
|
1652
1818
|
interface CreateServiceProviderParams {
|
|
@@ -1727,7 +1893,6 @@ interface SearchBookingsParams {
|
|
|
1727
1893
|
from?: number;
|
|
1728
1894
|
to?: number;
|
|
1729
1895
|
status?: string;
|
|
1730
|
-
workflowStatus?: string;
|
|
1731
1896
|
verified?: boolean;
|
|
1732
1897
|
limit?: number;
|
|
1733
1898
|
cursor?: string;
|
|
@@ -1939,9 +2104,12 @@ interface DeleteProductParams {
|
|
|
1939
2104
|
interface DeleteProductParams {
|
|
1940
2105
|
id: string;
|
|
1941
2106
|
}
|
|
1942
|
-
interface
|
|
2107
|
+
interface ProcessBookingRefundParams {
|
|
2108
|
+
id: string;
|
|
2109
|
+
amount: number;
|
|
2110
|
+
}
|
|
2111
|
+
interface ProcessOrderRefundParams {
|
|
1943
2112
|
id: string;
|
|
1944
|
-
entity: string;
|
|
1945
2113
|
amount: number;
|
|
1946
2114
|
}
|
|
1947
2115
|
type SystemTemplateKey = "system:booking-business-update" | "system:booking-customer-update" | "system:user-invitation" | "system:order-status-update" | "system:user-confirmation" | "system:forgot-password";
|
|
@@ -1981,14 +2149,14 @@ interface Slot {
|
|
|
1981
2149
|
interface CreateWorkflowParams {
|
|
1982
2150
|
businessId?: string;
|
|
1983
2151
|
key: string;
|
|
1984
|
-
status?:
|
|
2152
|
+
status?: WorkflowStatus;
|
|
1985
2153
|
nodes: Record<string, WorkflowNode>;
|
|
1986
2154
|
schedule?: string;
|
|
1987
2155
|
}
|
|
1988
2156
|
interface UpdateWorkflowParams {
|
|
1989
2157
|
id: string;
|
|
1990
2158
|
key: string;
|
|
1991
|
-
status?:
|
|
2159
|
+
status?: WorkflowStatus;
|
|
1992
2160
|
nodes: Record<string, WorkflowNode>;
|
|
1993
2161
|
schedule?: string;
|
|
1994
2162
|
}
|
|
@@ -2034,7 +2202,7 @@ interface CreateAudienceParams {
|
|
|
2034
2202
|
interface UpdateAudienceParams {
|
|
2035
2203
|
id: string;
|
|
2036
2204
|
key?: string;
|
|
2037
|
-
status?:
|
|
2205
|
+
status?: AudienceStatus;
|
|
2038
2206
|
confirmTemplateId?: string;
|
|
2039
2207
|
}
|
|
2040
2208
|
interface GetAudienceParams {
|
|
@@ -2064,17 +2232,12 @@ interface GetAudienceSubscribersParams {
|
|
|
2064
2232
|
limit?: number;
|
|
2065
2233
|
cursor?: string;
|
|
2066
2234
|
}
|
|
2067
|
-
declare enum SubscriptionSource {
|
|
2068
|
-
Signup = "signup",
|
|
2069
|
-
Admin = "admin",
|
|
2070
|
-
Import = "import"
|
|
2071
|
-
}
|
|
2072
2235
|
interface AudienceSubscriber {
|
|
2073
2236
|
customerId: string;
|
|
2074
2237
|
email: string;
|
|
2075
2238
|
subscribedAt?: number;
|
|
2076
|
-
source?:
|
|
2077
|
-
status?:
|
|
2239
|
+
source?: AudienceSubscriptionSource;
|
|
2240
|
+
status?: AudienceSubscriptionStatus;
|
|
2078
2241
|
}
|
|
2079
2242
|
interface RemoveAudienceSubscriberParams {
|
|
2080
2243
|
id: string;
|
|
@@ -2162,7 +2325,7 @@ interface ShipParams {
|
|
|
2162
2325
|
locationId: string;
|
|
2163
2326
|
lines: ShipmentLine[];
|
|
2164
2327
|
}
|
|
2165
|
-
type AgentStatus = 'active' | '
|
|
2328
|
+
type AgentStatus = 'active' | 'draft' | 'archived';
|
|
2166
2329
|
interface CreateAgentParams {
|
|
2167
2330
|
businessId?: string;
|
|
2168
2331
|
key: string;
|
|
@@ -2312,4 +2475,4 @@ interface MergeCustomersParams {
|
|
|
2312
2475
|
businessId?: string;
|
|
2313
2476
|
}
|
|
2314
2477
|
|
|
2315
|
-
export { type Access, type AddAudienceSubscriberParams, type AddAudienceSubscriberResponse, type Address, type AgentStatus, type ApiResponse, type Audience, type AudienceAccessResponse, type AudienceSubscribeResponse, type AudienceSubscriber, type AudienceType, type AuthToken, type AvailabilityResponse, type AvailabilitySlot, type Block, type BlockType, type Booking, type BookingCartItem, type BookingCheckoutParams, type BookingItem, type BookingItemSnapshot, type BookingItemStatus, type BookingQuoteItem, type
|
|
2478
|
+
export { type Access, type AddAudienceSubscriberParams, type AddAudienceSubscriberResponse, type Address, type AgentChatStatus, type AgentStatus, type ApiResponse, type Audience, type AudienceAccessResponse, type AudienceStatus, type AudienceSubscribeResponse, type AudienceSubscriber, type AudienceSubscription, type AudienceSubscriptionPayment, type AudienceSubscriptionProvider, type AudienceSubscriptionSource, type AudienceSubscriptionStatus, type AudienceType, type AuthToken, type AvailabilityResponse, type AvailabilitySlot, type Block, type BlockType, type Booking, type BookingCancellationReason, type BookingCartItem, type BookingCheckoutParams, type BookingItem, type BookingItemSnapshot, type BookingItemStatus, type BookingPayment, type BookingPaymentPromoCode, type BookingPaymentProvider, type BookingPaymentRefund, type BookingPaymentStatus, type BookingPaymentTax, type BookingPaymentTaxLine, type BookingProviderStatus, type BookingQuote, type BookingQuoteItem, type BookingServiceStatus, type BookingStatus, type BookingStoreState, type Business, type BusinessEmails, type BusinessRole, type BusinessSubscription, type BusinessSubscriptionPayment, type BusinessSubscriptionProvider, type BusinessSubscriptionSource, type BusinessSubscriptionStatus, type CancelBookingItemParams, type CancellationRule$1 as CancellationRule, type Condition, type ConnectCustomerParams, type CreateAgentParams, type CreateAudienceParams, type CreateBookingParams, type CreateBusinessParams, type CreateCustomerParams, type CreateEmailTemplateParams, type CreateFormParams, type CreateIntegrationParams, type CreateLocationParams, type CreateMarketParams, type CreateNodeParams, type CreateOrderParams, type CreatePortalSessionParams, type CreateProductParams, type CreatePromoCodeParams, type CreateProviderParams, type CreateServiceParams, type CreateServiceProviderParams, type CreateTaxonomyParams, type CreateWebhookParams, type CreateWorkflowParams, type Customer, type CustomerAuthToken, type CustomerInfo, type CustomerStatus, type CustomerVerificationCode, type CustomsDeclaration, type CustomsItem, type DaySlots, type DeleteAccountParams, type DeleteAgentParams, type DeleteAudienceParams, type DeleteBusinessMediaParams, type DeleteBusinessParams, type DeleteEmailTemplateParams, type DeleteFormParams, type DeleteIntegrationParams, type DeleteLocationParams, type DeleteMarketParams, type DeleteNodeParams, type DeleteProductParams, type DeletePromoCodeParams, type DeleteProviderParams, type DeleteServiceParams, type DeleteServiceProviderParams, type DeleteTaxonomyParams, type DeleteWebhookParams, type DeleteWorkflowParams, type Discount, type EmailTemplate, type EmailTemplateStatus, type EshopCartItem, type EshopItem, type EshopStoreState, type Event, type EventAction, type ExecutionStatus, type FindCustomersParams, type FindServiceProvidersParams, type Form, type FormEntry, type FormField, type FormFieldType, type FormSchema, type FormSchemaType, type FormStatus, type FormSubmission, type GeoLocation, type GeoLocationBlock, type GeoLocationBlockProperties, type GeoLocationValue, type GetAgentChatParams, type GetAgentChatsParams, type GetAgentParams, type GetAgentsParams, type GetAnalyticsHealthParams, type GetAnalyticsParams, type GetAudienceParams, type GetAudienceSubscribersParams, type GetAudiencesParams, type GetAvailabilityParams, type GetBookingParams, type GetBookingQuoteParams, type GetBusinessChatsParams, type GetBusinessMediaParams, type GetBusinessMediaParams2, type GetBusinessParams, type GetBusinessesParams, type GetCustomerParams, type GetDeliveryStatsParams, type GetEmailTemplateParams, type GetEmailTemplatesParams, type GetFormParams, type GetFormSubmissionParams, type GetFormSubmissionsParams, type GetFormsParams, type GetIntegrationParams, type GetMeParams, type GetMediaParams, type GetNodeChildrenParams, type GetNodeParams, type GetNodesParams, type GetOrderParams, type GetOrdersParams, type GetProductParams, type GetProductsParams, type GetPromoCodeParams, type GetPromoCodesParams, type GetProviderParams, type GetProvidersParams, type GetQuoteParams, type GetServiceParams, type GetServicesParams, type GetShippingRatesParams, type GetSubscriptionPlansParams, type GetTaxonomiesParams, type GetTaxonomyChildrenParams, type GetTaxonomyParams, type GetWorkflowExecutionParams, type GetWorkflowExecutionsParams, type GetWorkflowParams, type GetWorkflowsParams, type HandleInvitationParams, type Integration, type IntegrationProvider, type IntervalPeriod, type InventoryLevel, type InviteUserParams, type Language, type ListIntegrationsParams, type ListWebhooksParams, type Location, type LoginAccountParams, type LogoutParams, type MagicLinkRequestParams, type MagicLinkVerifyParams, type Market, type Media, type MediaResolution, type MergeCustomersParams, type Node, type NodeResult, type NodeStatus, type OAuthConnectParams, type OAuthDisconnectParams, type OrderCancellationReason, type OrderCheckoutParams, type OrderItemStatus, type OrderPayment, type OrderPaymentPromoCode, type OrderPaymentProvider, type OrderPaymentRefund, type OrderPaymentStatus, type OrderPaymentTax, type OrderPaymentTaxLine, type OrderQuote, type OrderShipping, type OrderStatus, type PaginatedResponse, type Parcel, type PaymentMethod, PaymentMethodType, type PaymentTaxLine, type Price, type PriceProvider, type ProcessBookingRefundParams, type ProcessOrderRefundParams, type ProductStatus, type PromoCodeStatus, type PromoCodeValidation, type PromoUsage, type Provider, type ProviderAvailability, type ProviderTimelinePoint, type ProviderWithTimeline, type PurchaseLabelResult, type RateAgentChatParams, type RemoveAudienceSubscriberParams, type RemoveMemberParams, type RequestOptions, type RunAgentParams, type SearchAccountsParams, type SearchBookingsParams, type Service, type ServiceDuration, type ServiceProvider, type ServiceProviderInput, type SetupAnalyticsParams, type ShipParams, type ShipResult, type Shipment, type ShipmentLine, type ShippingAddress, type ShippingMethod, type ShippingRate, type ShippingStatus, type ShippingWeightTier, type Slot, type SlotRange, type SpecificDate, type SubmitFormParams, type SubscribeAudienceParams, type SubscribeParams, type SubscriptionInterval, type SubscriptionPrice, type SystemTemplateKey, type Taxonomy, type TaxonomyEntry, type TaxonomyField, type TaxonomyFieldQuery, type TaxonomyQuery, type TaxonomySchema, type TaxonomySchemaType, type TaxonomyStatus, type TestWebhookParams, type TimeRange, type TimelinePoint, type TrackEmailOpenParams, type TriggerNotificationParams, type TriggerWorkflowParams, type UpdateAccountProfileParams, type UpdateAgentChatParams, type UpdateAgentParams, type UpdateAudienceParams, type UpdateBookingParams, type UpdateBusinessParams, type UpdateCustomerParams, type UpdateEmailTemplateParams, type UpdateFormParams, type UpdateFormSubmissionParams, type UpdateIntegrationParams, type UpdateLocationParams, type UpdateMarketParams, type UpdateMediaParams, type UpdateNodeParams, type UpdateOrderParams, type UpdateProductParams, type UpdatePromoCodeParams, type UpdateProviderParams, type UpdateServiceParams, type UpdateServiceProviderParams, type UpdateTaxonomyParams, type UpdateWebhookParams, type UpdateWorkflowParams, type UploadBusinessMediaParams, type Webhook, type WebhookEventSubscription, type Workflow, type WorkflowConnection, type WorkflowExecution, type WorkflowHttpMethod, type WorkflowHttpNode, type WorkflowLoopNode, type WorkflowNode, type WorkflowStatus, type WorkflowSwitchNode, type WorkflowSwitchRule, type WorkflowTransformNode, type WorkflowTriggerNode, type WorkingDay, type WorkingHour, type Zone, type ZoneLocation };
|
package/dist/types.js
CHANGED
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
// src/types/api.ts
|
|
2
|
-
var SubscriptionSource = /* @__PURE__ */ ((SubscriptionSource2) => {
|
|
3
|
-
SubscriptionSource2["Signup"] = "signup";
|
|
4
|
-
SubscriptionSource2["Admin"] = "admin";
|
|
5
|
-
SubscriptionSource2["Import"] = "import";
|
|
6
|
-
return SubscriptionSource2;
|
|
7
|
-
})(SubscriptionSource || {});
|
|
8
|
-
|
|
9
1
|
// src/types/index.ts
|
|
10
2
|
var PaymentMethodType = /* @__PURE__ */ ((PaymentMethodType2) => {
|
|
11
3
|
PaymentMethodType2["Cash"] = "cash";
|
|
@@ -13,6 +5,6 @@ var PaymentMethodType = /* @__PURE__ */ ((PaymentMethodType2) => {
|
|
|
13
5
|
return PaymentMethodType2;
|
|
14
6
|
})(PaymentMethodType || {});
|
|
15
7
|
|
|
16
|
-
export { PaymentMethodType
|
|
8
|
+
export { PaymentMethodType };
|
|
17
9
|
//# sourceMappingURL=types.js.map
|
|
18
10
|
//# sourceMappingURL=types.js.map
|