File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -435,6 +435,10 @@ interface SetExtensionData {
435435 ( extensionData : RoktPartnerExtensionData < unknown > ) : void ;
436436}
437437
438+ interface OnShoppableAdsReady {
439+ ( callback : ( ) => void ) : void ;
440+ }
441+
438442export const endSession : EndSession ;
439443export const getAppName : GetAppName ;
440444export const getAppVersion : GetAppVersion ;
@@ -627,6 +631,7 @@ export namespace Rokt {
627631 const hashSha256 : HashSha256 ;
628632 const setExtensionData : SetExtensionData ;
629633 const use : Use ;
634+ const onShoppableAdsReady : OnShoppableAdsReady ;
630635}
631636
632637export interface IdentifyRequest {
@@ -681,6 +686,8 @@ export interface UserIdentities {
681686 twitter ?: string | null ;
682687 microsoft ?: string | null ;
683688 yahoo ?: string | null ;
689+ email_sha256 ?: string | null ;
690+ mobile_sha256 ?: string | null ;
684691}
685692
686693interface Cart {
@@ -903,6 +910,7 @@ declare class mParticleInstance {
903910 hashSha256 : HashSha256 ;
904911 setExtensionData : SetExtensionData ;
905912 use : Use ;
913+ onShoppableAdsReady : OnShoppableAdsReady ;
906914 } ;
907915 MPSideloadedKit : typeof MPSideloadedKit ;
908916 PromotionType : {
Original file line number Diff line number Diff line change 11{
22 "private" : true ,
33 "name" : " @types/mparticle__web-sdk" ,
4- "version" : " 2.58 .9999" ,
4+ "version" : " 2.66 .9999" ,
55 "projects" : [
66 " https://github.com/mParticle/mparticle-web-sdk"
77 ],
Original file line number Diff line number Diff line change @@ -496,6 +496,8 @@ const identifyIdentities: mParticle.IdentifyRequest = {
496496 twitter : "email" ,
497497 microsoft : "email" ,
498498 yahoo : "email" ,
499+ email_sha256 : "email" ,
500+ mobile_sha256 : "email" ,
499501 } ,
500502} ;
501503
@@ -824,6 +826,10 @@ mParticle.Rokt.setExtensionData({
824826 "personalization" : { variant : "A" } ,
825827} ) ;
826828
829+ mParticle . Rokt . onShoppableAdsReady ( ( ) => {
830+ console . log ( "Shoppable ads ready" ) ;
831+ } ) ;
832+
827833// Test with identifier
828834mParticle . Rokt . selectPlacements ( {
829835 attributes : {
Original file line number Diff line number Diff line change @@ -265,6 +265,10 @@ mParticle.Rokt.hashSha256(true);
265265mParticle . Rokt . hashSha256 ( undefined ) ;
266266mParticle . Rokt . hashSha256 ( null ) ;
267267
268+ mParticle . Rokt . onShoppableAdsReady ( ( ) => {
269+ // shoppable ads ready
270+ } ) ;
271+
268272mParticle . generateHash ( "test-string" ) ;
269273
270274mParticle . ready ( ( ) => {
@@ -558,6 +562,8 @@ const identifyIdentities: mParticle.IdentifyRequest = {
558562 twitter : "email" ,
559563 microsoft : "email" ,
560564 yahoo : "email" ,
565+ email_sha256 : "email" ,
566+ mobile_sha256 : "email" ,
561567 } ,
562568} ;
563569
You can’t perform that action at this time.
0 commit comments