@spiffcommerce/core 0.10.233 → 0.10.235

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/types.d.ts CHANGED
@@ -567,6 +567,8 @@ export interface DesignCreationMessage {
567
567
  weight?: number;
568
568
  designProductId?: string;
569
569
  designProductVariantId?: string;
570
+ externalCartProductId?: string;
571
+ externalCartProductVariantId?: string;
570
572
  event: string;
571
573
  exportedData: ExportedData;
572
574
  lineItemImageUrl: string;
@@ -643,13 +645,25 @@ export interface Transaction {
643
645
  * to this transaction, null unless the createDesignProduct flag was set
644
646
  * and the design was finalized using createDesign operation.
645
647
  */
648
+ /**@deprecated use externalCartProductVariantId instead of this moving forward */
646
649
  externalDesignProductVariantId?: string;
647
650
  /**
648
651
  * The external product id representing the design product related
649
652
  * to this transaction, null unless the createDesignProduct flag was set
650
653
  * and the design was finalized using createDesign operation.
651
654
  */
655
+ /**@deprecated use externalCartProductId instead of this moving forward. */
652
656
  externalDesignProductId?: string;
657
+ /**
658
+ * The external product id representing the product related to the transaction.
659
+ * This value can hold any type of transaction such as design and standard products.
660
+ */
661
+ externalCartProductId?: string;
662
+ /**
663
+ * The external product variant id representing the product related to the transaction.
664
+ * This value can hold any type of transaction such as design and standard products.
665
+ */
666
+ externalCartProductVariantId?: string;
653
667
  priceModifierTotal?: number;
654
668
  /**
655
669
  * The amount of variations associated with this transaction.
@@ -791,6 +805,10 @@ interface Product {
791
805
  * Configuration for bulk creations
792
806
  */
793
807
  bulkConfiguration?: BulkConfiguration;
808
+ /**
809
+ * Configuration for conversion. Optional.
810
+ */
811
+ conversionConfiguration?: ConversionConfiguration;
794
812
  }
795
813
  interface ColorOption {
796
814
  id?: string;
@@ -884,6 +902,42 @@ interface BulkConfiguration {
884
902
  maxVariations: number;
885
903
  pricingStrategy: BulkPriceCalculationStrategy;
886
904
  }
905
+ /**
906
+ * Defines the locations at which a conversion attempt can take place.
907
+ */
908
+ export enum ConversionLocation {
909
+ /**
910
+ * The client should expose a flow for allowing the user to optionally input details at any point.
911
+ */
912
+ Manual = "Manual",
913
+ /**
914
+ * The client should show the conversion flow at the beginning of a workflow.
915
+ */
916
+ OnStart = "OnStart",
917
+ /**
918
+ * The client should allow the user to input details just before quiting the experience.
919
+ */
920
+ OnQuit = "OnQuit",
921
+ /**
922
+ * The client should ask the user for details prior to adding to cart.
923
+ */
924
+ OnEnd = "OnEnd"
925
+ }
926
+ /**
927
+ * The data configured to be requested.
928
+ */
929
+ export enum ConversionData {
930
+ Email = "Email"
931
+ }
932
+ /**
933
+ * The configuration for conversion, exposed on products currently.
934
+ */
935
+ export interface ConversionConfiguration {
936
+ id: string;
937
+ name?: string;
938
+ locations: ConversionLocation[];
939
+ requestedData: ConversionData[];
940
+ }
887
941
  interface StorageService {
888
942
  /**
889
943
  * Get a value.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spiffcommerce/core",
3
- "version": "0.10.233",
3
+ "version": "0.10.235",
4
4
  "description": "Core client API for interacting with the Spiff Commerce backend.",
5
5
  "source": "src/index.ts",
6
6
  "main": "dist/main.js",