@rebuy/rebuy 3.43.0 → 3.44.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.cjs +17 -7
- package/dist/index.mjs +17 -7
- package/dist/pricing/postPurchaseDisplayPrice.d.ts +2 -0
- package/dist/schema/postPurchaseDisplayPrice.d.ts +4 -3
- package/dist/schema/postPurchaseProductCollectionView.d.ts +365 -3
- package/dist/schema/postPurchaseProductView.d.ts +367 -4
- package/dist/schema/postPurchaseTransition.d.ts +80 -3
- package/dist/server/index.cjs +74 -34
- package/dist/server/index.d.ts +1 -0
- package/dist/server/index.mjs +74 -34
- package/dist/server/postPurchaseCardSections.d.ts +12 -0
- package/dist/server/postPurchaseProductEligibility.d.ts +1 -1
- package/dist/server/postPurchaseReviewData.d.ts +5 -1
- package/dist/server/postPurchaseSubscriptionEligibility.d.ts +1 -1
- package/dist/server/postPurchaseUnavailableChoice.d.ts +12 -0
- package/dist/server/preparePostPurchaseAdmissionView.d.ts +125 -2
- package/dist/server/preparePostPurchaseCollectionGroup.d.ts +130 -4
- package/dist/server/preparePostPurchaseCollectionView.d.ts +125 -2
- package/dist/server/preparePostPurchaseGroupAdmissionView.d.ts +125 -2
- package/dist/server/preparePostPurchaseGroupDefault.d.ts +125 -2
- package/dist/server/preparePostPurchaseGroupView.d.ts +125 -2
- package/dist/server/preparePostPurchaseMemberView.d.ts +375 -6
- package/dist/server/preparePostPurchaseQuantityAdmissionView.d.ts +125 -2
- package/dist/server/preparePostPurchaseQuantityView.d.ts +125 -2
- package/dist/server/preparePostPurchaseView.d.ts +4 -1
- package/package.json +1 -1
|
@@ -4,7 +4,8 @@ import { z } from 'zod';
|
|
|
4
4
|
* description wins the precedence — `description: null` with the standard-shape `descriptionDocument`.
|
|
5
5
|
* Only a prepared view may carry `changeset`: the unsigned changeset the server derived from this very
|
|
6
6
|
* preparation (the one admission later rebuilds and signs), ready for Shopify's `calculateChangeset`, and
|
|
7
|
-
* `displayPrice`: the display pricing worked out from that same preparation.
|
|
7
|
+
* `displayPrice`: the display pricing worked out from that same preparation. `preparation.status` discriminates
|
|
8
|
+
* the two; an unprepared view may carry a tree too.
|
|
8
9
|
*/
|
|
9
10
|
export declare const PostPurchaseProductView: z.ZodUnion<readonly [z.ZodObject<{
|
|
10
11
|
changeset: z.ZodOptional<z.ZodObject<{
|
|
@@ -47,10 +48,10 @@ export declare const PostPurchaseProductView: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
47
48
|
}, z.core.$strip>>;
|
|
48
49
|
displayPrice: z.ZodOptional<z.ZodObject<{
|
|
49
50
|
currencyCode: z.ZodString;
|
|
50
|
-
savingFormat: z.ZodEnum<{
|
|
51
|
+
savingFormat: z.ZodNullable<z.ZodEnum<{
|
|
51
52
|
amount: "amount";
|
|
52
53
|
percent: "percent";
|
|
53
|
-
}
|
|
54
|
+
}>>;
|
|
54
55
|
savingMinor: z.ZodNumber;
|
|
55
56
|
savingPercent: z.ZodNumber;
|
|
56
57
|
subscriptionUnit: z.ZodOptional<z.ZodObject<{
|
|
@@ -759,7 +760,369 @@ export declare const PostPurchaseProductView: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
759
760
|
dropdown: "dropdown";
|
|
760
761
|
}>>>;
|
|
761
762
|
}, z.core.$strip>>;
|
|
762
|
-
sections: z.
|
|
763
|
+
sections: z.ZodNullable<z.ZodObject<{
|
|
764
|
+
alignment: z.ZodDefault<z.ZodObject<{
|
|
765
|
+
horizontal: z.ZodDefault<z.ZodEnum<{
|
|
766
|
+
start: "start";
|
|
767
|
+
center: "center";
|
|
768
|
+
end: "end";
|
|
769
|
+
}>>;
|
|
770
|
+
vertical: z.ZodDefault<z.ZodEnum<{
|
|
771
|
+
top: "top";
|
|
772
|
+
middle: "middle";
|
|
773
|
+
bottom: "bottom";
|
|
774
|
+
}>>;
|
|
775
|
+
}, z.core.$strip>>;
|
|
776
|
+
border: z.ZodLazy<z.ZodDefault<z.ZodObject<{
|
|
777
|
+
radius: z.ZodDefault<z.ZodEnum<{
|
|
778
|
+
small: "small";
|
|
779
|
+
none: "none";
|
|
780
|
+
base: "base";
|
|
781
|
+
large: "large";
|
|
782
|
+
fullyRounded: "fullyRounded";
|
|
783
|
+
}>>;
|
|
784
|
+
style: z.ZodDefault<z.ZodEnum<{
|
|
785
|
+
none: "none";
|
|
786
|
+
base: "base";
|
|
787
|
+
dotted: "dotted";
|
|
788
|
+
dashed: "dashed";
|
|
789
|
+
}>>;
|
|
790
|
+
width: z.ZodDefault<z.ZodEnum<{
|
|
791
|
+
base: "base";
|
|
792
|
+
medium: "medium";
|
|
793
|
+
thick: "thick";
|
|
794
|
+
}>>;
|
|
795
|
+
}, z.core.$strip>>>;
|
|
796
|
+
buttonField: z.ZodOptional<z.ZodEnum<{
|
|
797
|
+
declineAllOffers: "declineAllOffers";
|
|
798
|
+
declineOffer: "declineOffer";
|
|
799
|
+
removeFromOrder: "removeFromOrder";
|
|
800
|
+
undoAddToOrder: "undoAddToOrder";
|
|
801
|
+
activePage: "activePage";
|
|
802
|
+
addedToCart: "addedToCart";
|
|
803
|
+
addingToCart: "addingToCart";
|
|
804
|
+
addToCart: "addToCart";
|
|
805
|
+
buttonLabel: "buttonLabel";
|
|
806
|
+
destinationUrl: "destinationUrl";
|
|
807
|
+
inactivePage: "inactivePage";
|
|
808
|
+
overlayContent: "overlayContent";
|
|
809
|
+
payNow: "payNow";
|
|
810
|
+
progressReached: "progressReached";
|
|
811
|
+
progressRemaining: "progressRemaining";
|
|
812
|
+
redirectToCheckout: "redirectToCheckout";
|
|
813
|
+
showVariant: "showVariant";
|
|
814
|
+
showVariants: "showVariants";
|
|
815
|
+
soldOut: "soldOut";
|
|
816
|
+
subscriptionOption: "subscriptionOption";
|
|
817
|
+
switchToOneTimePurchase: "switchToOneTimePurchase";
|
|
818
|
+
switchToSubscriptionNoDiscount: "switchToSubscriptionNoDiscount";
|
|
819
|
+
switchToSubscriptionWithDiscount: "switchToSubscriptionWithDiscount";
|
|
820
|
+
}>>;
|
|
821
|
+
direction: z.ZodDefault<z.ZodEnum<{
|
|
822
|
+
columns: "columns";
|
|
823
|
+
rows: "rows";
|
|
824
|
+
grid: "grid";
|
|
825
|
+
}>>;
|
|
826
|
+
frame: z.ZodOptional<z.ZodEnum<{
|
|
827
|
+
callout: "callout";
|
|
828
|
+
"offer-content": "offer-content";
|
|
829
|
+
}>>;
|
|
830
|
+
grid: z.ZodOptional<z.ZodDefault<z.ZodObject<{
|
|
831
|
+
columns: z.ZodDefault<z.ZodUnion<readonly [z.ZodArray<z.ZodUnion<readonly [z.ZodLiteral<"auto">, z.ZodLiteral<"fill">, z.ZodString, z.ZodNumber]>>, z.ZodUndefined]>>;
|
|
832
|
+
rows: z.ZodDefault<z.ZodUnion<readonly [z.ZodArray<z.ZodUnion<readonly [z.ZodLiteral<"auto">, z.ZodLiteral<"fill">, z.ZodString, z.ZodNumber]>>, z.ZodUndefined]>>;
|
|
833
|
+
}, z.core.$strip>>>;
|
|
834
|
+
name: z.ZodOptional<z.ZodString>;
|
|
835
|
+
padding: z.ZodDefault<z.ZodEnum<{
|
|
836
|
+
none: "none";
|
|
837
|
+
base: "base";
|
|
838
|
+
extraTight: "extraTight";
|
|
839
|
+
tight: "tight";
|
|
840
|
+
loose: "loose";
|
|
841
|
+
extraLoose: "extraLoose";
|
|
842
|
+
}>>;
|
|
843
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
844
|
+
sections: z.ZodDefault<z.ZodUnion<readonly [z.ZodArray<z.ZodLazy<z.ZodType<import(".").CABSection, unknown, z.core.$ZodTypeInternals<import(".").CABSection, unknown>>>>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
845
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"layout">>;
|
|
846
|
+
spacing: z.ZodDefault<z.ZodEnum<{
|
|
847
|
+
none: "none";
|
|
848
|
+
base: "base";
|
|
849
|
+
extraTight: "extraTight";
|
|
850
|
+
tight: "tight";
|
|
851
|
+
loose: "loose";
|
|
852
|
+
extraLoose: "extraLoose";
|
|
853
|
+
}>>;
|
|
854
|
+
viewUrl: z.ZodOptional<z.ZodString>;
|
|
855
|
+
width: z.ZodDefault<z.ZodNumber>;
|
|
856
|
+
wrapping: z.ZodOptional<z.ZodObject<{
|
|
857
|
+
breakAt: z.ZodNumber;
|
|
858
|
+
maxPerLine: z.ZodNumber;
|
|
859
|
+
}, z.core.$strip>>;
|
|
860
|
+
mutators: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
861
|
+
effect: z.ZodDefault<z.ZodEnum<{
|
|
862
|
+
set_false: "set_false";
|
|
863
|
+
set_true: "set_true";
|
|
864
|
+
toggle: "toggle";
|
|
865
|
+
}>>;
|
|
866
|
+
variable: z.ZodString;
|
|
867
|
+
when: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
868
|
+
operator: z.ZodDefault<z.ZodEnum<{
|
|
869
|
+
is_empty: "is_empty";
|
|
870
|
+
is_not_empty: "is_not_empty";
|
|
871
|
+
}>>;
|
|
872
|
+
type: z.ZodLiteral<"content">;
|
|
873
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
874
|
+
event: z.ZodEnum<{
|
|
875
|
+
item_added: "item_added";
|
|
876
|
+
quantity_changed: "quantity_changed";
|
|
877
|
+
variant_selected: "variant_selected";
|
|
878
|
+
}>;
|
|
879
|
+
type: z.ZodLiteral<"event">;
|
|
880
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
881
|
+
operator: z.ZodDefault<z.ZodEnum<{
|
|
882
|
+
equals: "equals";
|
|
883
|
+
greater_than: "greater_than";
|
|
884
|
+
less_than: "less_than";
|
|
885
|
+
}>>;
|
|
886
|
+
type: z.ZodLiteral<"result_count">;
|
|
887
|
+
value: z.ZodDefault<z.ZodNumber>;
|
|
888
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
889
|
+
operator: z.ZodDefault<z.ZodEnum<{
|
|
890
|
+
contains: "contains";
|
|
891
|
+
does_not_contain: "does_not_contain";
|
|
892
|
+
}>>;
|
|
893
|
+
type: z.ZodLiteral<"result_tag">;
|
|
894
|
+
value: z.ZodString;
|
|
895
|
+
}, z.core.$strip>], "type">;
|
|
896
|
+
}, z.core.$strip>>>;
|
|
897
|
+
variables: z.ZodOptional<z.ZodArray<z.ZodPipe<z.ZodUnion<readonly [z.ZodObject<{
|
|
898
|
+
defaultValue: z.ZodString;
|
|
899
|
+
name: z.ZodString;
|
|
900
|
+
seed: z.ZodOptional<z.ZodNever>;
|
|
901
|
+
type: z.ZodLiteral<"text">;
|
|
902
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
903
|
+
defaultValue: z.ZodNumber;
|
|
904
|
+
name: z.ZodString;
|
|
905
|
+
seed: z.ZodOptional<z.ZodNever>;
|
|
906
|
+
type: z.ZodLiteral<"number">;
|
|
907
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
908
|
+
defaultValue: z.ZodOptional<z.ZodBoolean>;
|
|
909
|
+
name: z.ZodString;
|
|
910
|
+
seed: z.ZodOptional<z.ZodObject<{
|
|
911
|
+
dataSourceId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
912
|
+
ruleset: z.ZodDefault<z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
|
|
913
|
+
exitIfMatched: z.ZodDefault<z.ZodBoolean>;
|
|
914
|
+
logic: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
915
|
+
rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
916
|
+
operator: z.ZodDefault<z.ZodEnum<{
|
|
917
|
+
equals: "equals";
|
|
918
|
+
greater_than: "greater_than";
|
|
919
|
+
less_than: "less_than";
|
|
920
|
+
contains: "contains";
|
|
921
|
+
does_not_contain: "does_not_contain";
|
|
922
|
+
after: "after";
|
|
923
|
+
anything: "anything";
|
|
924
|
+
before: "before";
|
|
925
|
+
contains_any: "contains_any";
|
|
926
|
+
does_not_contain_any: "does_not_contain_any";
|
|
927
|
+
does_not_equal: "does_not_equal";
|
|
928
|
+
}>>;
|
|
929
|
+
products: z.ZodDefault<z.ZodUnion<readonly [z.ZodArray<z.ZodUnknown>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
930
|
+
type: z.ZodDefault<z.ZodEnum<{
|
|
931
|
+
product: "product";
|
|
932
|
+
date: "date";
|
|
933
|
+
cart: "cart";
|
|
934
|
+
cart_count: "cart_count";
|
|
935
|
+
cart_item_count: "cart_item_count";
|
|
936
|
+
cart_line_count: "cart_line_count";
|
|
937
|
+
cart_subtotal: "cart_subtotal";
|
|
938
|
+
collection: "collection";
|
|
939
|
+
customer: "customer";
|
|
940
|
+
customer_order_count: "customer_order_count";
|
|
941
|
+
customer_tag: "customer_tag";
|
|
942
|
+
customer_total_spent: "customer_total_spent";
|
|
943
|
+
product_tag: "product_tag";
|
|
944
|
+
product_title: "product_title";
|
|
945
|
+
product_type: "product_type";
|
|
946
|
+
product_vendor: "product_vendor";
|
|
947
|
+
}>>;
|
|
948
|
+
value: z.ZodDefault<z.ZodCoercedString<unknown>>;
|
|
949
|
+
}, z.core.$strip>>>;
|
|
950
|
+
}, z.core.$strip>>>;
|
|
951
|
+
output: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
952
|
+
key: z.ZodDefault<z.ZodString>;
|
|
953
|
+
type: z.ZodDefault<z.ZodLiteral<"data_json">>;
|
|
954
|
+
value: z.ZodDefault<z.ZodString>;
|
|
955
|
+
}, z.core.$strip>>>;
|
|
956
|
+
}, z.core.$strip>>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<{
|
|
957
|
+
exitIfMatched: boolean;
|
|
958
|
+
logic: {
|
|
959
|
+
rules: {
|
|
960
|
+
operator: "equals" | "greater_than" | "less_than" | "contains" | "does_not_contain" | "after" | "anything" | "before" | "contains_any" | "does_not_contain_any" | "does_not_equal";
|
|
961
|
+
products: never[] | unknown[];
|
|
962
|
+
type: "product" | "date" | "cart" | "cart_count" | "cart_item_count" | "cart_line_count" | "cart_subtotal" | "collection" | "customer" | "customer_order_count" | "customer_tag" | "customer_total_spent" | "product_tag" | "product_title" | "product_type" | "product_vendor";
|
|
963
|
+
value: string;
|
|
964
|
+
}[];
|
|
965
|
+
}[];
|
|
966
|
+
output: {
|
|
967
|
+
key: string;
|
|
968
|
+
type: "data_json";
|
|
969
|
+
value: string;
|
|
970
|
+
}[];
|
|
971
|
+
}[], Record<string, never>>>]>>;
|
|
972
|
+
}, z.core.$strip>>;
|
|
973
|
+
type: z.ZodDefault<z.ZodLiteral<"boolean">>;
|
|
974
|
+
}, z.core.$strip>]>, z.ZodTransform<{
|
|
975
|
+
defaultValue: string;
|
|
976
|
+
name: string;
|
|
977
|
+
type: "text";
|
|
978
|
+
seed?: undefined;
|
|
979
|
+
} | {
|
|
980
|
+
defaultValue: number;
|
|
981
|
+
name: string;
|
|
982
|
+
type: "number";
|
|
983
|
+
seed?: undefined;
|
|
984
|
+
} | {
|
|
985
|
+
defaultValue: boolean;
|
|
986
|
+
name: string;
|
|
987
|
+
type: "boolean";
|
|
988
|
+
seed?: {
|
|
989
|
+
dataSourceId: number | null;
|
|
990
|
+
ruleset: {
|
|
991
|
+
exitIfMatched: boolean;
|
|
992
|
+
logic: {
|
|
993
|
+
rules: {
|
|
994
|
+
operator: "equals" | "greater_than" | "less_than" | "contains" | "does_not_contain" | "after" | "anything" | "before" | "contains_any" | "does_not_contain_any" | "does_not_equal";
|
|
995
|
+
products: never[] | unknown[];
|
|
996
|
+
type: "product" | "date" | "cart" | "cart_count" | "cart_item_count" | "cart_line_count" | "cart_subtotal" | "collection" | "customer" | "customer_order_count" | "customer_tag" | "customer_total_spent" | "product_tag" | "product_title" | "product_type" | "product_vendor";
|
|
997
|
+
value: string;
|
|
998
|
+
}[];
|
|
999
|
+
}[];
|
|
1000
|
+
output: {
|
|
1001
|
+
key: string;
|
|
1002
|
+
type: "data_json";
|
|
1003
|
+
value: string;
|
|
1004
|
+
}[];
|
|
1005
|
+
}[];
|
|
1006
|
+
} | undefined;
|
|
1007
|
+
}, {
|
|
1008
|
+
name: string;
|
|
1009
|
+
type: "boolean";
|
|
1010
|
+
defaultValue?: boolean | undefined;
|
|
1011
|
+
seed?: {
|
|
1012
|
+
dataSourceId: number | null;
|
|
1013
|
+
ruleset: {
|
|
1014
|
+
exitIfMatched: boolean;
|
|
1015
|
+
logic: {
|
|
1016
|
+
rules: {
|
|
1017
|
+
operator: "equals" | "greater_than" | "less_than" | "contains" | "does_not_contain" | "after" | "anything" | "before" | "contains_any" | "does_not_contain_any" | "does_not_equal";
|
|
1018
|
+
products: never[] | unknown[];
|
|
1019
|
+
type: "product" | "date" | "cart" | "cart_count" | "cart_item_count" | "cart_line_count" | "cart_subtotal" | "collection" | "customer" | "customer_order_count" | "customer_tag" | "customer_total_spent" | "product_tag" | "product_title" | "product_type" | "product_vendor";
|
|
1020
|
+
value: string;
|
|
1021
|
+
}[];
|
|
1022
|
+
}[];
|
|
1023
|
+
output: {
|
|
1024
|
+
key: string;
|
|
1025
|
+
type: "data_json";
|
|
1026
|
+
value: string;
|
|
1027
|
+
}[];
|
|
1028
|
+
}[];
|
|
1029
|
+
} | undefined;
|
|
1030
|
+
} | {
|
|
1031
|
+
defaultValue: string;
|
|
1032
|
+
name: string;
|
|
1033
|
+
type: "text";
|
|
1034
|
+
seed?: undefined;
|
|
1035
|
+
} | {
|
|
1036
|
+
defaultValue: number;
|
|
1037
|
+
name: string;
|
|
1038
|
+
type: "number";
|
|
1039
|
+
seed?: undefined;
|
|
1040
|
+
}>>>>;
|
|
1041
|
+
visibility: z.ZodOptional<z.ZodObject<{
|
|
1042
|
+
variable: z.ZodString;
|
|
1043
|
+
visibleWhen: z.ZodDefault<z.ZodBoolean>;
|
|
1044
|
+
}, z.core.$strip>>;
|
|
1045
|
+
editorMode: z.ZodDefault<z.ZodEnum<{
|
|
1046
|
+
checkoutExtension: "checkoutExtension";
|
|
1047
|
+
postPurchaseOffer: "postPurchaseOffer";
|
|
1048
|
+
thankYouPage: "thankYouPage";
|
|
1049
|
+
orderStatusPage: "orderStatusPage";
|
|
1050
|
+
ordersIndexPage: "ordersIndexPage";
|
|
1051
|
+
customerProfilePage: "customerProfilePage";
|
|
1052
|
+
}>>;
|
|
1053
|
+
experiment: z.ZodOptional<z.ZodObject<{
|
|
1054
|
+
elementId: z.ZodNumber;
|
|
1055
|
+
experimentId: z.ZodNumber;
|
|
1056
|
+
experimentType: z.ZodString;
|
|
1057
|
+
selectedId: z.ZodNumber;
|
|
1058
|
+
}, z.core.$strip>>;
|
|
1059
|
+
previewMode: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, z.ZodTransform<boolean, boolean | null | undefined>>;
|
|
1060
|
+
storeId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
1061
|
+
targetArea: z.ZodNullable<z.ZodDefault<z.ZodObject<{
|
|
1062
|
+
fill: z.ZodOptional<z.ZodBoolean>;
|
|
1063
|
+
flip: z.ZodOptional<z.ZodEnum<{
|
|
1064
|
+
vertical: "vertical";
|
|
1065
|
+
horizontal: "horizontal";
|
|
1066
|
+
both: "both";
|
|
1067
|
+
}>>;
|
|
1068
|
+
icon: z.ZodString;
|
|
1069
|
+
label: z.ZodString;
|
|
1070
|
+
width: z.ZodString;
|
|
1071
|
+
}, z.core.$strip>>>;
|
|
1072
|
+
tracking: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1073
|
+
enableAttribution: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, z.ZodTransform<boolean, boolean | null | undefined>>;
|
|
1074
|
+
enableSource: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, z.ZodTransform<boolean, boolean | null | undefined>>;
|
|
1075
|
+
enableWidget: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, z.ZodTransform<boolean, boolean | null | undefined>>;
|
|
1076
|
+
}, z.core.$strip>>>, z.ZodTransform<{
|
|
1077
|
+
enableAttribution: boolean;
|
|
1078
|
+
enableSource: boolean;
|
|
1079
|
+
enableWidget: boolean;
|
|
1080
|
+
}, {
|
|
1081
|
+
enableAttribution: boolean;
|
|
1082
|
+
enableSource: boolean;
|
|
1083
|
+
enableWidget: boolean;
|
|
1084
|
+
} | null | undefined>>;
|
|
1085
|
+
type: z.ZodDefault<z.ZodEnum<{
|
|
1086
|
+
product: "product";
|
|
1087
|
+
bundle_builder: "bundle_builder";
|
|
1088
|
+
cart: "cart";
|
|
1089
|
+
cart_subscription: "cart_subscription";
|
|
1090
|
+
dynamic_bundle: "dynamic_bundle";
|
|
1091
|
+
gift_with_purchase: "gift_with_purchase";
|
|
1092
|
+
placeholder: "placeholder";
|
|
1093
|
+
pre_purchase: "pre_purchase";
|
|
1094
|
+
product_addon: "product_addon";
|
|
1095
|
+
product_upsell: "product_upsell";
|
|
1096
|
+
recharge_checkout: "recharge_checkout";
|
|
1097
|
+
recharge_customer_portal: "recharge_customer_portal";
|
|
1098
|
+
recharge_post_purchase: "recharge_post_purchase";
|
|
1099
|
+
shopify_checkout: "shopify_checkout";
|
|
1100
|
+
shopify_checkout_extension: "shopify_checkout_extension";
|
|
1101
|
+
shopify_post_purchase: "shopify_post_purchase";
|
|
1102
|
+
shopify_post_purchase_extension: "shopify_post_purchase_extension";
|
|
1103
|
+
switch_to_subscription: "switch_to_subscription";
|
|
1104
|
+
ui_extension_ad: "ui_extension_ad";
|
|
1105
|
+
ui_extension_button: "ui_extension_button";
|
|
1106
|
+
ui_extension_content_block: "ui_extension_content_block";
|
|
1107
|
+
ui_extension_line_item_editor: "ui_extension_line_item_editor";
|
|
1108
|
+
ui_extension_progress_bar: "ui_extension_progress_bar";
|
|
1109
|
+
}>>;
|
|
1110
|
+
uiLabels: z.ZodDefault<z.ZodObject<{
|
|
1111
|
+
currentPage: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1112
|
+
guest: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1113
|
+
loadingOptions: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1114
|
+
nextPage: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1115
|
+
offerCarousel: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1116
|
+
offerDialog: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1117
|
+
page: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1118
|
+
previousPage: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1119
|
+
selected: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1120
|
+
subscriptionOptions: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1121
|
+
updating: z.ZodPipe<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>, z.ZodTransform<Record<string, string>, Record<string, string>>>;
|
|
1122
|
+
}, z.core.$strip>>;
|
|
1123
|
+
version: z.ZodDefault<z.ZodLiteral<2>>;
|
|
1124
|
+
widgetId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
1125
|
+
}, z.core.$strip>>;
|
|
763
1126
|
variantCatalog: z.ZodOptional<z.ZodObject<{
|
|
764
1127
|
displayMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
765
1128
|
single: "single";
|
|
@@ -6,8 +6,23 @@ export declare const OfferTransitionRequestSchema: z.ZodObject<{
|
|
|
6
6
|
progressRevision: z.ZodNumber;
|
|
7
7
|
}, z.core.$strict>;
|
|
8
8
|
export type OfferTransitionRequest = z.infer<typeof OfferTransitionRequestSchema>;
|
|
9
|
+
/**
|
|
10
|
+
* Why a transition Ended: the Offer has no next child (`no-child`), only nodes with nothing to offer remain
|
|
11
|
+
* along the decline path (`no-products`), or the three-accept cap is reached or Shopify reports no changeset
|
|
12
|
+
* applications left (`accept-cap`). `unavailable` is not an End: the next Offer could not be read.
|
|
13
|
+
*/
|
|
14
|
+
export declare const PostPurchaseEndReasonSchema: z.ZodEnum<{
|
|
15
|
+
"no-child": "no-child";
|
|
16
|
+
"no-products": "no-products";
|
|
17
|
+
"accept-cap": "accept-cap";
|
|
18
|
+
}>;
|
|
19
|
+
export type PostPurchaseEndReason = z.infer<typeof PostPurchaseEndReasonSchema>;
|
|
20
|
+
/**
|
|
21
|
+
* An End keeps its `no-child` status and names its reason in `endReason`, so a reply from before the field
|
|
22
|
+
* existed still parses, and an older reader strips it. A `no-child` reply without `endReason` reads as `no-child`.
|
|
23
|
+
*/
|
|
9
24
|
export declare const OfferTransitionResponseSchema: z.ZodObject<{
|
|
10
|
-
data: z.ZodObject<{
|
|
25
|
+
data: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
11
26
|
attemptedSkips: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
12
27
|
entry: z.ZodObject<{
|
|
13
28
|
blockId: z.ZodNumber;
|
|
@@ -66,8 +81,70 @@ export declare const OfferTransitionResponseSchema: z.ZodObject<{
|
|
|
66
81
|
status: z.ZodEnum<{
|
|
67
82
|
unavailable: "unavailable";
|
|
68
83
|
advanced: "advanced";
|
|
69
|
-
"no-child": "no-child";
|
|
70
84
|
}>;
|
|
71
|
-
}, z.core.$strip
|
|
85
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
86
|
+
attemptedSkips: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
87
|
+
entry: z.ZodObject<{
|
|
88
|
+
blockId: z.ZodNumber;
|
|
89
|
+
blockIndex: z.ZodString;
|
|
90
|
+
blockParentIndex: z.ZodString;
|
|
91
|
+
flowId: z.ZodNumber;
|
|
92
|
+
sectionId: z.ZodNumber;
|
|
93
|
+
widgetId: z.ZodNumber;
|
|
94
|
+
widgetTraffic: z.ZodNumber;
|
|
95
|
+
}, z.core.$strip>;
|
|
96
|
+
reason: z.ZodEnum<{
|
|
97
|
+
empty: "empty";
|
|
98
|
+
"no-eligible-subscription": "no-eligible-subscription";
|
|
99
|
+
}>;
|
|
100
|
+
}, z.core.$strip>>>;
|
|
101
|
+
progress: z.ZodObject<{
|
|
102
|
+
closedAt: z.ZodNullable<z.ZodNumber>;
|
|
103
|
+
deadline: z.ZodNumber;
|
|
104
|
+
entry: z.ZodObject<{
|
|
105
|
+
blockId: z.ZodNumber;
|
|
106
|
+
blockIndex: z.ZodString;
|
|
107
|
+
blockParentIndex: z.ZodString;
|
|
108
|
+
flowId: z.ZodNumber;
|
|
109
|
+
sectionId: z.ZodNumber;
|
|
110
|
+
widgetId: z.ZodNumber;
|
|
111
|
+
widgetTraffic: z.ZodNumber;
|
|
112
|
+
}, z.core.$strip>;
|
|
113
|
+
entryRevision: z.ZodNumber;
|
|
114
|
+
members: z.ZodArray<z.ZodObject<{
|
|
115
|
+
productId: z.ZodNumber;
|
|
116
|
+
productIndex: z.ZodNumber;
|
|
117
|
+
declineDelivery: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
118
|
+
attemptedAt: z.ZodNumber;
|
|
119
|
+
status: z.ZodEnum<{
|
|
120
|
+
attempted: "attempted";
|
|
121
|
+
unavailable: "unavailable";
|
|
122
|
+
}>;
|
|
123
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
124
|
+
attemptedAt: z.ZodNumber;
|
|
125
|
+
finishedAt: z.ZodNumber;
|
|
126
|
+
status: z.ZodEnum<{
|
|
127
|
+
unknown: "unknown";
|
|
128
|
+
acknowledged: "acknowledged";
|
|
129
|
+
rejected: "rejected";
|
|
130
|
+
skipped: "skipped";
|
|
131
|
+
}>;
|
|
132
|
+
}, z.core.$strict>]>>;
|
|
133
|
+
status: z.ZodEnum<{
|
|
134
|
+
unhandled: "unhandled";
|
|
135
|
+
accepted: "accepted";
|
|
136
|
+
declined: "declined";
|
|
137
|
+
}>;
|
|
138
|
+
}, z.core.$strict>>;
|
|
139
|
+
revision: z.ZodNumber;
|
|
140
|
+
}, z.core.$strict>;
|
|
141
|
+
endReason: z.ZodOptional<z.ZodEnum<{
|
|
142
|
+
"no-child": "no-child";
|
|
143
|
+
"no-products": "no-products";
|
|
144
|
+
"accept-cap": "accept-cap";
|
|
145
|
+
}>>;
|
|
146
|
+
status: z.ZodLiteral<"no-child">;
|
|
147
|
+
}, z.core.$strip>], "status">;
|
|
72
148
|
successful: z.ZodLiteral<true>;
|
|
73
149
|
}, z.core.$strip>;
|
|
150
|
+
export type OfferTransitionResponse = z.infer<typeof OfferTransitionResponseSchema>;
|