1"use strict";(self.webpackChunkweb_flexOffers_ui=self.webpackChunkweb_flexOffers_ui||[]).push([[4704],{161:function(e,r,t){t.d(r,{$:function(){return a}});t(9950);var n=t(44414),a=function(e){var r=e.children;return(0,n.jsx)("div",{className:"table-tabs",children:r})}},14704:function(e,r,t){t.d(r,{A:function(){return De}});var n=t(89379),a=t(23029),o=t(92901),i=t(53895),s=t(85501),l=t(9950),c=t(2105),d=t(84142),u=t(5544),m=t(39287),p=t(82053),h=t(25333),g=t(96583),x=t(28170),v=t(58535),f=t(43754),A=t(37885),j=t(33722),b=t(14857),y=t(10300),k=t(40635),N=t(99320),T=t(98786),I=t(34144),w=t(75348),C=t(6882),S=t(98713),E=t(98516),_=t(72217),F=t(44414),O=function(e){var r=e.activeStep,t=e.programs,n=e.programName,a=e.handleProgramChange,o=e.handleNextPage,i=e.handleBackPage,s=e.isNewAdvertiserSetup,c=(0,w.$)(function(e){e.preventDefault(),o()},{}),d=c.errors,u=c.handleChange,m=c.onFormSubmit,p=c.values,h=c.register,g=c.handleUpdateValue;(0,l.useEffect)(function(){h({programName:{required:!0}})},[n]);var x={programName:n};return(0,l.useEffect)(function(){var e=(0,T.D)(t);(null===e||void 0===e?void 0:e.length)<2&&e[0]?(g({programName:e[0].programName}),a(e[0].programName)):g(x)},[n,t]),(0,F.jsxs)(I.g,{onSubmit:m,children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 conversion-subtitle",children:(0,F.jsx)(E.A,{variant:"subtitle1",children:"First, select the program you would like to test from the dropdown menu below:"})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-sm-12 mob_m_b_0",children:(0,F.jsx)(C.A,{required:!0,sortable:!0,options:(0,T.D)(t)||[],label:"Program",name:"programName",dataKey:"programName",disabled:s,onChange:function(e){a(e.target.value),u(e)},value:p.programName,error:d.programName})})}),(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{disabled:0===r,onClick:i,buttonText:"Back",variant:"outlined",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{disabled:2===r,type:"submit",buttonText:"Next",endIcon:(0,F.jsx)(k.A,{})})]})]})},P=t(89043),B=t(95189),D=t.n(B),M="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAAWCAYAAAAinad/AAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAADeSURBVHgB7ZThDYIwEIVfCQM4AhvACI6AE8gIbECcwBUcgQ3ADdxANtAN6js9EqxFQPvL+CUvTbje9fVy1IBYaxMuJZVimo7aGWO6l4gUos52GRc18ERM5ZQETnIidcV7KmqtNyldZwc9rcAMuC/X/S08znwJcnpGrTzh/lvKfQ2GPXSdcd3b5dx7GDuOkkEfNpjun1BQW8lzr5noeqTtGjOgAWixLEJA/sV+rVg/mHOen8li/XDK5Df4goiT3uLx63QIiT6Uo4/fSE6lObUv2NjPKMbc1QuKyC1KhOYGLqBD42LTyN4AAAAASUVORK5CYII=",U=t(10226),L=function(e){var r=e.activeStep,t=e.handleBackPage,n=e.handleNextPage,a=e.trackingId,o=(0,l.useState)(!1),i=(0,u.A)(o,2),s=i[0],c=i[1],d=(0,l.useState)(""),m=(0,u.A)(d,2),p=m[0],h=m[1];(0,l.useEffect)(function(){h(localStorage.getItem("AppDomainUrl"))},[p]);var g='<script>\n !function(){\n var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];\n if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");\n else{e.invoked=!0,e.methods=["init","getClick","track"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);\n return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r)\n {var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="'.concat(p,'/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}();\n AdvertiserMaxTrack.init("').concat(a,'");\n AdvertiserMaxTrack.getClick();\n <\/script>');return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mb-1",children:(0,F.jsx)(E.A,{variant:"h6",children:"Entry Page Code"})})}),(0,F.jsx)("div",{className:"row mb-4",children:(0,F.jsxs)("div",{className:"col-lg-12 mob_m_b_0",children:[(0,F.jsxs)(E.A,{variant:"body1",className:"mb-2",children:["Please add this
1script into ",(0,F.jsx)("b",{children:"all entry pages of your site."})]}),(0,F.jsx)(E.A,{variant:"body1",children:"We recommend using a backend template or theme to help inject the call into the footer or header of every page of your site. That way, no matter which page or product the user first lands on, they will always have their session stored."})]})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:(0,F.jsxs)(P.A,{className:"shadow border-0 bg-dark text-white card",children:[(0,F.jsx)("pre",{style:{color:"white"},children:g}),(0,F.jsx)(D(),{text:g,onCopy:function(){c(!0),setTimeout(function(){c(!1)},2e3)},children:(0,F.jsx)(U.A,{variant:"contained",style:{position:"absolute",bottom:"18px",right:"10px",zIndex:1,fontSize:"12px",backgroundColor:"transparent",color:"white",border:"0px solid white",boxShadow:"none"},buttonText:"",children:(0,F.jsx)("img",{src:M,title:s?"Copied!":"Copy",alt:s?"Copied!":"Copy"})})})]})})}),(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{disabled:0===r,onClick:t,variant:"outlined",buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{disabled:2===r,onClick:n,buttonText:"Next",endIcon:(0,F.jsx)(k.A,{})})]})]})},V=t(18905),R=t(87677),G=t(2046),W="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAFgSURBVHgB1VTNUYNAFH5LkskkJzpI7MAS8EYCM9KBWIF0IFZgCcEK5EB+jrECYwfbgXjMJGH9doOMoC6E8ZI3s7x9f9++n3kQ/TMxnVHYtkWGYVXUnC0W0cmAwnEewYI/zBGbz28bAwrPM2m3ez8K4qFkNIw76Ew6HC7YasWrsd0CRJZHNFbCdmsiUN5SyrJyEGNSvgQPELPJdSlbLuMiw1JGbSnPuChZuG6IUq7V60Ty5bcaiBGOhcOR4RNLkvCHh5hOQwxDSF4DJn195es4s+96QxtkWaaYTDzJlWzbPs5YF6MFpOEwwHCeaTDw0RKPOp0Zzn17wC9izMS0zSauzQBPoHMHxAbkN17osuxDF9LVGanXi2i/5/gRqLXCpFPq99etAVkcywzjQk6SmGqoCshzfoMNGNXEeuorxEspiaoXgF7puM9NaIO2XOWV/A6oQF3XQvPHOiRsEEcL1lX1J/BLfJIZexc6AAAAAElFTkSuQmCC",q=function(e){var r=(0,l.useState)("{{order_number}}"),t=(0,u.A)(r,2),n=t[0],a=t[1],o=(0,l.useState)("{{order_amount}}"),i=(0,u.A)(o,2),s=i[0],c=i[1],d=(0,l.useState)("{{coupon}}"),m=(0,u.A)(d,2),p=m[0],h=m[1],g=(0,l.useState)("{{currency}}"),x=(0,u.A)(g,2),v=x[0],f=x[1],A=(0,l.useState)("{{geo}}"),j=(0,u.A)(A,2),b=j[0],y=j[1],T=(0,l.useState)("{{commissionId}}"),I=(0,u.A)(T,2),w=I[0],C=I[1],O=(0,V.Zp)(),D=(0,l.useState)(""),L=(0,u.A)(D,2),q=L[0],z=L[1],J=(0,l.useState)(""),K=(0,u.A)(J,2),Q=K[0],X=K[1],Y=e.activeStep,Z=e.trackingId,H=e.isNewAdvertiserSetup,$=e.handleContinueButton,ee=e.handleClose,re=e.calledFrom,te=(0,l.useState)(!1),ne=(0,u.A)(te,2),ae=ne[0],oe=ne[1],ie=(0,l.useState)(!1),se=(0,u.A)(ie,2),le=se[0],ce=se[1],de=(0,l.useState)(!1),ue=(0,u.A)(de,2),me=ue[0],pe=ue[1],he=(0,l.useState)(!1),ge=(0,u.A)(he,2),xe=ge[0],ve=ge[1],fe=(0,l.useState)(!1),Ae=(0,u.A)(fe,2),je=Ae[0],be=Ae[1],ye=(0,l.useState)(!1),ke=(0,u.A)(ye,2),Ne=ke[0],Te=ke[1],Ie=function(e){switch(e){case"coupon":pe(!me);break;case"commission":Te(!Ne);break;case"currency":ve(!xe);break;case"geoLoc":be(!je)}ce(!le)};(0,l.useEffect)(function(){z(localStorage.getItem("AppDomainUrl")),X(localStorage.getItem("TrackUrl"))},[q]);var we='<script>\n !function(){var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");else{e.invoked=!0,e.methods=["init","getClick","track"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r){var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="'.concat(q,'/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}();\n AdvertiserMaxTrack.init("').concat(Z,'");\n\n !(async function (){\n\n var fp = "";\n try {\n await import("').concat(Q,'flexfp.js");\n fp = await window.FlexFP.getFingerprint({ timeoutMs: 5000 });\n } catch (error) {\n console.log(error)\n }\n\n AdvertiserMaxTrack.track({\n order_number: ').concat(n,",\n order_amount: ").concat(s,",")+"".concat(me?"":"\n\t\t\torder_coupon: '".concat(p,"',"))+"".concat(xe?"":"\n\t\t\torder_currency: '".concat(v,"',"))+"".concat(je?"":"\n\t\t\torder_geo: '".concat(b,"',"))+"".concat(Ne?"":"\n\t\t\torder_commissionid: '".concat(w,"',"))+'\n\t\t\torder_items: [\n { "sku": "SKU1", "amount": 20,"commissionid":"C101", "quantity": 2, "order_coupon": "COU3","order_discount":[6],"order_category":[2,3] },\n { "sku": "SKU2", "amount": 12,"commissionid":"C102", "quantity": 0, "order_coupon": "COU2","order_discount":[6,10],"order_category":[3] },\n { "sku": "SKU3", "amount": 10, "quantity": 1, "order_coupon": "COU1","order_category":[10,11] }\n ],\n order_fp: fp,\n order_platform: "Javascript"\n });\n }());\n \n <\/script>\n ';return(0,F.jsxs)(l.Fragment,{children:[(0,F.jsx)("div",{className:"row mb-2",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:(0,F.jsx)(E.A,{variant:"h6",children:"Confirmation Page"})})}),(0,F.jsx)("div",{className:"row mb-2",children:(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsxs)(E.A,{variant:"body1",children:["Please add this
1script to your ",(0,F.jsx)("b",{children:"confirmation page"})]})})}),(0,F.jsxs)("div",{className:"row",children:[(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:Z,type:"text",label:"Advertiser ID",fullWidth:!0})}),(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:s,type:"text",name:"orderamount",label:"Order Amount",onChange:function(e){c(e.target.value)},fullWidth:!0})})]}),(0,F.jsxs)("div",{className:"row mt-2",children:[(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:n,name:"ordernumber",onChange:function(e){a(e.target.value)},type:"text",label:"Order Number",fullWidth:!0})}),!me&&(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:p,name:"coupon",onChange:function(e){h(e.target.value)},type:"text",label:"Coupon",inputProps:{endAdornment:(0,F.jsx)(G.A,{position:"end",children:(0,F.jsx)(U.A,{variant:"contained",onClick:function(){return Ie("coupon")},style:{background:"rgba(249, 228, 228, 1)",padding:"15px",boxShadow:"none",right:"-11px"},children:(0,F.jsx)("img",{src:W,style:{height:"20px",width:"20px"}})})})},fullWidth:!0})}),!xe&&(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:v,name:"currency",onChange:function(e){f(e.target.value)},type:"text",label:"Currency",inputProps:{endAdornment:(0,F.jsx)(G.A,{position:"end",children:(0,F.jsx)(U.A,{variant:"contained",onClick:function(){return Ie("currency")},style:{background:"rgba(249, 228, 228, 1)",padding:"15px",boxShadow:"none",right:"-11px"},children:(0,F.jsx)("img",{src:W,style:{height:"20px",width:"20px"}})})})},fullWidth:!0})}),!je&&(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:b,name:"geo",onChange:function(e){y(e.target.value)},type:"text",label:"Geo Location",inputProps:{endAdornment:(0,F.jsx)(G.A,{position:"end",children:(0,F.jsx)(U.A,{variant:"contained",onClick:function(){return Ie("geoLoc")},style:{background:"rgba(249, 228, 228, 1)",padding:"15px",boxShadow:"none",right:"-11px"},children:(0,F.jsx)("img",{src:W,style:{height:"20px",width:"20px"}})})})},fullWidth:!0})}),!Ne&&(0,F.jsx)("div",{className:"col-lg-6",children:(0,F.jsx)(R.A,{value:w,name:"commissionID",onChange:function(e){C(e.target.value)},type:"text",label:"Commission ID",inputProps:{endAdornment:(0,F.jsx)(G.A,{position:"end",children:(0,F.jsx)(U.A,{variant:"contained",onClick:function(){return Ie("commission")},style:{background:"rgba(249, 228, 228, 1)",padding:"15px",boxShadow:"none",right:"-11px"},children:(0,F.jsx)("img",{src:W,style:{height:"20px",width:"20px"}})})})},fullWidth:!0})})]}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_15",children:(0,F.jsxs)(E.A,{variant:"body1",gutterBottom:!0,children:[(0,F.jsx)("b",{children:"Action Data:"})," You can use our JavaScript code to send action data, product data, and promotional data to FlexOffers.",(0,F.jsx)("br",{}),(0,F.jsxs)("ul",{className:"mobpadleft",children:[(0,F.jsx)("li",{children:"Advertiser ID = Unique account ID (provided by FlexOffers)"}),(0,F.jsx)("li",{children:"Order Amount = Sale amount parameter"}),(0,F.jsx)("li",{children:"Order Number = Order ID parameter"}),!me&&(0,F.jsx)("li",{children:"Coupon = Coupon parameter (optional)"}),!xe&&(0,F.jsxs)("li",{children:["Currency = Currency parameter (optional)",(0,F.jsx)("ul",{className:"mobpadleft",children:(0,F.jsx)("li",{children:"Use the ISO 4217 currency code (e.g., USD, EUR, GBP)"})})]}),!je&&(0,F.jsxs)("li",{children:["Geo = Geographical location (optional)",(0,F.jsx)("ul",{className:"mobpadleft",children:(0,F.jsx)("li",{children:"Use the ISO 3166 country code (e.g., USA, DEU, GBR)"})})]}),!Ne&&(0,F.jsx)("li",{children:"CommissionID = Advanced commission ID (optional)"})]}),(0,F.jsx)("b",{children:"Product Data (optional):"})," This section represents individual products that were purchased.",(0,F.jsx)("br",{}),(0,F.jsxs)("ul",{className:"mobpadleft",children:[(0,F.jsx)("li",{children:"SKU = The product ID or SKU"}),(0,F.jsx)("li",{children:"Amount = The price of the product"}),(0,F.jsx)("li",{children:"Quantity = The total number of items ordered"}),(0,F.jsx)("li",{children:"Commission ID = Advanced commission ID (optional)"}),(0,F.jsx)("li",{children:"Order Coupon = The coupon code associated with a product"}),(0,F.jsx)("li",{children:"Discount = The discount amount associated with a product"}),(0,F.jsx)("li",{children:"Order Category = The category ID associated with a product"})]}),"* A parameter is a variable piece of code that will dynamically populate the required information (order ID and amount) into the following code when a transaction takes place."]})})}),(0,F.jsx)("div",{className:"row mb-2",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_15",children:(0,F.jsxs)(P.A,{className:"shadow border-0 bg-dark text-white card",children:[(0,F.jsx)("pre",{style:{color:"white"},children:we}),(0,F.jsx)(B.CopyToClipboard,{text:we,onCopy:function(){oe(!0),setTimeout(function(){oe(!1)},2e3)},children:(0,F.jsx)(U.A,{variant:"contained",style:{position:"absolute",bottom:"18px",right:"10px",zIndex:1,fontSize:"12px",backgroundColor:"transparent",color:"white",border:"0px solid white",boxShadow:"none"},buttonText:"",children:(0,F.jsx)("img",{src:M,title:ae?"Copied!":"Copy",alt:ae?"Copied!":"Copy"})})})]})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:"Once the script has been installed on your website, please proceed to the next step to create a test transaction using the FlexOffers Tracking Diagnosis Tool."})}),(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{disabled:0===Y,onClick:e.handleBackPage,variant:"outlined",buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{onClick:H?"New Program"==re?ee:$:function(){O("/app/support/tracking-diagnosis")},buttonText:"Next",endIcon:(0,F.jsx)(k.A,{})})]})]})},z=t(36685),J=t(40514),K=t(36080),Q={exportFormatVersion:2,exportTime:"2026-02-18 19:23:14",containerVersion:{path:"accounts/6066616115/containers/98988393/versions/11",accountId:"6066616115",containerId:"98988393",containerVersionId:"11",name:"GTM Wix 2026",container:{path:"accounts/6066616115/containers/98988393",accountId:"6066616115",containerId:"98988393",name:"FlexOffers.com",publicId:"FlexOffers.com",usageContext:["WEB"],fingerprint:"1671457578523",tagManagerUrl:"https://tagmanager.google.com/#/container/accounts/6066616115/containers/98988393/workspaces?apiLink=container",features:{supportUserPermissions:!0,supportEnvironments:!0,supportWorkspaces:!0,supportGtagConfigs:!1,supportBuiltInVariables:!0,supportClients:!1,supportFolders:!0,supportTags:!0,supportTemplates:!0,supportTriggers:!0,supportVariables:!0,supportVersions:!0,supportZones:!0,supportTransformations:!1},tagIds:["FlexOffers.com"]},tag:[{accountId:"6066616115",containerId:"98988393",tagId:"69",name:"Entry Page Code",type:"html",parameter:[{type:"TEMPLATE",key:"html",value:'<script>\n !function(){\n var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];\n if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");\n else{e.invoked=!0,e.methods=["init","getClick","track","setGTM"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);\n return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r)\n {var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="<#AppDomainUrl#>/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}();\n AdvertiserMaxTrack.init("{{advertiser_tracking_ID}}");\n AdvertiserMaxTrack.getClick();\n AdvertiserMaxTrack.setGTM("{{advertiser_tracking_ID}}", "Wix");\n <\/script>'},{type:"BOOLEAN",key:"supportDocumentWrite",value:"false"}],fingerprint:"1771442415607",firingTriggerId:["2147479553"],parentFolderId:"64",tagFiringOption:"ONCE_PER_EVENT",monitoringMetadata:{type:"MAP"},consentSettings:{consentStatus:"NOT_SET"}}
1,{accountId:"6066616115",containerId:"98988393",tagId:"73",name:"Conversion Tracking Code",type:"html",parameter:[{type:"TEMPLATE",key:"html",value:'"<script> !function(){var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");else{e.invoked=!0,e.methods=["init","getClick","track"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r){var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="<#AppDomainUrl#>/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}();\n AdvertiserMaxTrack.init("{{advertiser_tracking_ID}}"); (function () {\n\n var fp = "";\n\n function sendTrack() {\n AdvertiserMaxTrack.track({\n order_number: {{order_number}},\n order_amount: {{order_amount}},\n order_coupon: {{coupon}},\n order_fp: fp,\n order_platform: "WIXGTM"\n });\n }\n\n try {\n var script = document.createElement("script");\n script.src = "<#TrackUrl#>flexfp.js";\n script.async = true;\n\n script.onload = function () {\n if (window.FlexFP && window.FlexFP.getFingerprint) {\n window.FlexFP.getFingerprint({ timeoutMs: 5000 })\n .then(function(result) {\n fp = result;\n sendTrack();\n })\n .catch(function() {\n sendTrack();\n });\n } else {\n sendTrack();\n }\n };\n\n script.onerror = function () {\n sendTrack();\n };\n\n document.head.appendChild(script);\n\n } catch (e) {\n console.log(e);\n sendTrack();\n }\n })(); <\/script>"'},{type:"BOOLEAN",key:"supportDocumentWrite",value:"false"}],fingerprint:"1771441390704",firingTriggerId:["65"],setupTag:[{tagName:"Entry Page Code"}],parentFolderId:"64",tagFiringOption:"ONCE_PER_EVENT",monitoringMetadata:{type:"MAP"},consentSettings:{consentStatus:"NOT_NEEDED"}}],trigger:[{accountId:"6066616115",containerId:"98988393",triggerId:"65",name:"Confirmation Page",type:"CUSTOM_EVENT",customEventFilter:[{type:"EQUALS",parameter:[{type:"TEMPLATE",key:"arg0",value:"{{_event}}"},{type:"TEMPLATE",key:"arg1",value:"purchase"}]}],fingerprint:"1672946355564",parentFolderId:"64"}],variable:[{accountId:"6066616115",containerId:"98988393",variableId:"66",name:"advertiser_tracking_ID",type:"c",parameter:[{type:"TEMPLATE",key:"value",value:"<#TrackingId#>"}],fingerprint:"1672946355565",parentFolderId:"64",formatValue:{}},{accountId:"6066616115",containerId:"98988393",variableId:"67",name:"coupon",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.purchase.actionField.coupon"}],fingerprint:"1672946355565",parentFolderId:"64",formatValue:{}},{accountId:"6066616115",containerId:"98988393",variableId:"68",name:"tax",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.purchase.actionField.tax"}],fingerprint:"1771439826955",parentFolderId:"64",formatValue:{convertNullToValue:{type:"TEMPLATE",value:"0.00"}
1,convertUndefinedToValue:{type:"TEMPLATE",value:"0.00"}}},{accountId:"6066616115",containerId:"98988393",variableId:"70",name:"revenue",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.purchase.actionField.revenue"}],fingerprint:"1771439958305",parentFolderId:"64",formatValue:{convertNullToValue:{type:"TEMPLATE",value:"0.00"},convertUndefinedToValue:{type:"TEMPLATE",value:"0.00"}}},{accountId:"6066616115",containerId:"98988393",variableId:"71",name:"order_amount",type:"jsm",parameter:[{type:"TEMPLATE",key:"javascript",value:"function() {\n return {{revenue}} - {{tax}} - {{shipping}};\n} "}],fingerprint:"1771440020140",parentFolderId:"64",formatValue:{}},{accountId:"6066616115",containerId:"98988393",variableId:"72",name:"order_number",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.purchase.actionField.id"}],fingerprint:"1672946355566",parentFolderId:"64",formatValue:{}},{accountId:"6066616115",containerId:"98988393",variableId:"74",name:"currency",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.currencyCode"}],fingerprint:"1771440554630",parentFolderId:"64",formatValue:{}},{accountId:"6066616115",containerId:"98988393",variableId:"75",name:"shipping",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.purchase.actionField.shipping"}],fingerprint:"1771440554630",parentFolderId:"64",formatValue:{convertNullToValue:{type:"TEMPLATE",value:"0.00"},convertUndefinedToValue:{type:"TEMPLATE",value:"0.00"}}}],folder:[{accountId:"6066616115",containerId:"98988393",folderId:"64",name:"FlexOffers Conversion Tracking",fingerprint:"1672946355564"}],fingerprint:"1771442583497",tagManagerUrl:"https://tagmanager.google.com/#/versions/accounts/6066616115/containers/98988393/versions/11?apiLink=version"}},X=function(e){var r=e.activeStep,t=e.handleBackPage,n=e.trackingId;return(0,F.jsxs)(l.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsxs)(E.A,{variant:"body1",className:"mb-2",children:["In order to integrate conversion tracking in Wix, you will need a Premium Wix account with a connected domain, a Google Tag Manager account, and the FlexOffers Wix GTM container. Please download the container file :"," ",(0,F.jsx)(K.A,{href:"#",onClick:function(e){!function(e){var r=JSON.stringify(Q);r=(r=(r=r.replaceAll("<#TrackingId#>",n)).replaceAll("<#AppDomainUrl#>",localStorage.getItem("AppDomainUrl"))).replaceAll("<#TrackUrl#>",localStorage.getItem("TrackUrl"));var t=new Blob([r],{type:"text/plain"}),a=URL.createObjectURL(t);e.target.download=n+".json",e.target.href=a}(e)},className:"mb-4 mt-4",children:"Download here "})]})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:(0,F.jsxs)(E.A,{variant:"body1",children:["Once you have successfully downloaded and saved the file,"," ",(0,F.jsx)(K.A,{target:"_blank",href:"https://support.flexoffers.com/hc/en-us/articles/11747796016020-Wix-Conversion-Tracking-With-Google-Tag-Manager",children:"click here"})," ","for step by step instructions."]})})}),(0,F.jsx)("div",{className:"row mt-4",children:(0,F.jsx)("div",{className:"col-lg-12 text-center",children:(0,F.jsx)(S.A,{disabled:0===r,onClick:t,variant:"outlined",buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})})})})]})},Y=t(98069),Z={exportFormatVersion:2,exportTime:"2023-12-07 21:42:03",containerVersion:{path:"accounts/6066616115/containers/165797786/versions/7",accountId:"6066616115",containerId:"165797786",containerVersionId:"7",container:{path:"accounts/6066616115/containers/165797786",accountId:"6066616115",containerId:"165797786",name:"FlexOffers.com",publicId:"FlexOffers.com",usageContext:["WEB"],fingerprint:"1694634343387",tagManagerUrl:"https://tagmanager.google.com/#/container/accounts/6066616115/containers/165797786/workspaces?apiLink=container",features:{supportUserPermissions:!0,supportEnvironments:!0,supportWorkspaces:!0,supportGtagConfigs:!1,supportBuiltInVariables:!0,supportClients:!1,supportFolders:!0,supportTags:!0,supportTemplates:!0,supportTriggers:!0,supportVariables:!0,supportVersions:!0,supportZones:!0,supportTransformations:!1},tagIds:["FlexOffers.com"]},tag:[{accountId:"6066616115",containerId:"165797786",tagId:"12",name:"Entry Page Code",type:"html",parameter:[{type:"TEMPLATE",key:"html",value:'<script>\n !function(){\n var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];\n if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");\n else{e.invoked=!0,e.methods=["init","getClick","track", "setGTM"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);\n return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r)\n {var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="<#AppDomainUrl#>/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}();\n AdvertiserMaxTrack.init("{{advertiser_tracking_ID}}");\n AdvertiserMaxTrack.getClick();\n AdvertiserMaxTrack.setGTM("{{advertiser_tracking_ID}}", "Gtm");\n<\/script>'},{type:"BOOLEAN",key:"supportDocumentWrite",value:"false"}],fingerprint:"1694635048495",firingTriggerId:["2147479553"],parentFolderId:"4",tagFiringOption:"ONCE_PER_EVENT",monitoringMetadata:{type:"MAP"},consentSettings:{consentStatus:"NOT_SET"}},{accountId:"6066616115",containerId:"165797786",tagId:"13",name:"Conversion Tracking Code",type:"html",parameter:[{type:"TEMPLATE",key:"html",value:'"<script> !function(){var e=window.AdvertiserMaxTrack=window.AdvertiserMaxTrack||[];if(e.invoked)window.console&&console.error&&console.error("FlexOffers library was included more than once.");else{e.invoked=!0,e.methods=["init","getClick","track"],e.factory=function(r){return function(){var t=Array.prototype.slice.call(arguments);return t.unshift(r),e.push(t),e}};for(var r=0;r<e.methods.length;r++){var t=e.methods[r];e[t]=e.factory(t)}e.init=function(r){var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="<#AppDomainUrl#>/vendors/advertisermax/advertisermax.tracking.lib.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(t,n),e.advertiserId=r}}}(); AdvertiserMaxTrack.init("{{advertiser_tracking_ID}}"); (function () {\n\n var fp = ""; \n\n function sendTrack() {\n AdvertiserMaxTrack.track({\n order_number: {{order_number}},\n order_amount: {{order_amount}},\n order_coupon: {{coupon}},\n order_currency: {{currency}},\n order_fp: fp,\n order_platform: "GTM"\n });\n }\n\n try {\n var script = document.createElement("script");\n script.src = "<#TrackUrl#>flexfp.js";\n script.async = true;\n\n script.onload = function () {\n if (window.FlexFP && window.FlexFP.getFingerprint) {\n window.FlexFP.getFingerprint({ timeoutMs: 5000 })\n .then(function(result) {\n fp = result;\n sendTrack();\n }
1)\n .catch(function() {\n sendTrack();\n });\n } else {\n sendTrack();\n }\n };\n\n script.onerror = function () {\n sendTrack();\n };\n\n document.head.appendChild(script);\n } catch (e) {\n console.log(e);\n sendTrack();\n }\n})(); <\/script>"'},{type:"BOOLEAN",key:"supportDocumentWrite",value:"false"}],fingerprint:"1694640028768",firingTriggerId:["7"],setupTag:[{tagName:"Entry Page Code"}],parentFolderId:"4",tagFiringOption:"ONCE_PER_EVENT",monitoringMetadata:{type:"MAP"},consentSettings:{consentStatus:"NOT_NEEDED"}}],trigger:[{accountId:"6066616115",containerId:"165797786",triggerId:"7",name:"Confirmation Page",type:"CUSTOM_EVENT",customEventFilter:[{type:"EQUALS",parameter:[{type:"TEMPLATE",key:"arg0",value:"{{_event}}"},{type:"TEMPLATE",key:"arg1",value:"purchase"}]}],fingerprint:"1694635048493",parentFolderId:"4"}],variable:[{accountId:"6066616115",containerId:"165797786",variableId:"5",name:"currency",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.currency"}],fingerprint:"1695307993881",parentFolderId:"4",formatValue:{}},{accountId:"6066616115",containerId:"165797786",variableId:"6",name:"order_number",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.transaction_id"}],fingerprint:"1695307977158",parentFolderId:"4",formatValue:{}},{accountId:"6066616115",containerId:"165797786",variableId:"9",name:"order_amount",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.value"}],fingerprint:"1695307965375",parentFolderId:"4",formatValue:{}},{accountId:"6066616115",containerId:"165797786",variableId:"10",name:"coupon",type:"v",parameter:[{type:"INTEGER",key:"dataLayerVersion",value:"2"},{type:"BOOLEAN",key:"setDefaultValue",value:"false"},{type:"TEMPLATE",key:"name",value:"ecommerce.coupon"}],fingerprint:"1695308002186",parentFolderId:"4",formatValue:{}},{accountId:"6066616115",containerId:"165797786",variableId:"11",name:"advertiser_tracking_ID",type:"c",parameter:[{type:"TEMPLATE",key:"value",value:"<#TrackingId#>"}],fingerprint:"1695309826803",parentFolderId:"4",formatValue:{}}],folder:[{accountId:"6066616115",containerId:"165797786",folderId:"4",name:"FlexOffers Conversion Tracking",fingerprint:"1694635048491"}],fingerprint:"1695309835942",tagManagerUrl:"https://tagmanager.google.com/#/versions/accounts/6066616115/containers/165797786/versions/7?apiLink=version"}},H=function(e){var r=e.activeStep,t=e.handleBackPage,n=e.trackingId;return(0,F.jsxs)(l.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsxs)(E.A,{variant:"body1",className:"mb-2",children:["To set up conversion tracking with Google Tag Manager, your website needs to be connected to a Google Tag Manager account, and you will need to download the FlexOffers GTM Container file."," ",(0,F.jsx)(K.A,{href:"#",onClick:function(e){!function(e){var r=JSON.stringify(Z);r=(r=(r=r.replaceAll("<#TrackingId#>",n)).replaceAll("<#AppDomainUrl#>",localStorage.getItem("AppDomainUrl"))).replaceAll("<#TrackUrl#>",localStorage.getItem("TrackUrl"));var t=new Blob([r],{type:"text/plain"}),a=URL.createObjectURL(t);e.target.download=n+".json",e.target.href=a}(e)},className:"mb-4 mt-4",children:"Download here "})]})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsxs)(E.A,{variant:"body1",children:["Once you have successfully downloaded and saved the file,"," ",(0,F.jsx)(K.A,{target:"_blank",href:"https://support.flexoffers.com/hc/en-us/articles/21670197454996",children:"click here"})," ","for step by step instructions."]})})}),(0,F.jsx)("div",{className:"row mt-4",children:(0,F.jsx)("div",{className:"col-lg-12 text-center",children:(0,F.jsx)(S.A,{disabled:0===r,onClick:t,variant:"outlined",buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})})})})]})};function $(e,r){switch(e){case 0:return(0,F.jsx)(O,(0,n.A)({},r));case 1:return!0===r.isWixClicked?(0,F.jsx)(X,(0,n.A)({},r)):!0===r.isGtmClicked?(0,F.jsx)(H,(0,n.A)({},r)):(0,F.jsx)(L,(0,n.A)({},r));case 2:return(0,F.jsx)(q,(0,n.A)({},r));default:return(0,F.jsx)(F.Fragment,{})}}var ee={getAllPrograms:J.pF},re=(0,y.Ng)(function(e){return{programs:e.data.programs}},ee)(function(e){var r=e.props,t=e.programs,a=e.getAllPrograms,o=e.isNewAdvertiserSetup,i=e.handleContinueButton,s=e.isWixClicked,c=e.isGtmClicked,d=e.handleClose,m=e.calledFrom,p=e.progName,h=e.programRefId,g=(0,l.useState)(0),x=(0,u.A)(g,2),y=x[0],k=x[1],N=(0,l.useState)(""),T=(0,u.A)(N,2),I=T[0],w=T[1],C=(0,l.useState)(""),S=(0,u.A)(C,2),E=S[0],_=S[1],O=(0,l.useState)(""),P=(0,u.A)(O,2),B=P[0],D=P[1],M=(0,l.useState)(0),U=(0,u.A)(M,2),L=U[0],V=U[1];(0,l.useEffect)(function(){if(0===t.length&&a(),!(0,Y.wo)(p)||h>0){var e=h>0?null===t||void 0===t?void 0:t.find(function(e){return e.programId===h}):null===t||void 0===t?void 0:t.find(function(e){return e.programName===p});_(null===e||void 0===e?void 0:e.programName),(null===e||void 0===e?void 0:e.programId)>0?V(null===e||void 0===e?void 0:e.programId):(w(""),D(""))}},[t,p,h]);var R=function(e){return!0===e.isWixClicked||!0===e.isGtmClicked?["Select a Program","Implementation"]:["Select a Program","Implementation","Integration"]}((0,n.A)((0,n.A)({},r),{}
1,{isWixClicked:s,isGtmClicked:c}));(0,l.useEffect)(function(){L>0&&(0,z.Lw)(L).then(function(e){w(null===e||void 0===e?void 0:e.trackingID),D(e.trackingURL)})},[L]);var G=(0,b.A)();(0,j.A)(G.breakpoints.down("sm"));return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-sm-12 pt-4 steper-col mobilestepper",children:(0,F.jsx)(v.A,{alternativeLabel:!1,activeStep:y,className:"conversion-tracking-steps",children:R.map(function(e,r){return(0,F.jsx)(f.A,(0,n.A)((0,n.A)({},{}),{},{children:(0,F.jsx)(A.A,(0,n.A)((0,n.A)({},{}),{},{children:e}))}),e)})})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 no-margin",children:$(y,(0,n.A)((0,n.A)({},r),{},{isNewAdvertiserSetup:o,programs:t,activeStep:y,programName:E,trackingId:I,trackingURL:B,handleProgramChange:function(e){var r,n=(null===t||void 0===t||null===(r=t.find(function(r){return r.programName===e}))||void 0===r?void 0:r.programId)||0;_(e),p=e,n>0?V(n):(w(""),D(""))},handleNextPage:function(){k(function(e){return e+1})},handleBackPage:function(){k(function(e){return e-1})},handleContinueButton:i,isWixClicked:s,isGtmClicked:c,handleClose:d,calledFrom:m}))})})]})}),te=t(40033),ne=t(86835),ae=(0,m.A)(function(e){return{root:{borderBottom:"1px solid ".concat(e.palette.divider),margin:0,padding:2*e.spacing.unit},closeButton:{position:"absolute",right:e.spacing.unit,top:e.spacing.unit,color:e.palette.grey[500]}}})(function(e){var r=e.children,t=e.classes,n=e.onClose;return(0,F.jsxs)(te.A,{disableTypography:!0,className:t.root,children:[(0,F.jsx)(p.A,{variant:"h6",children:r}),n?(0,F.jsx)(h.A,{"aria-label":"Close",className:t.closeButton,onClick:n,children:(0,F.jsx)(ne.A,{})}):null]})}),oe=function(e){var r=e.isNewAdvertiserSetup,t=e.handleContinueButton,n=e.calledFrom,a=e.programName,o=e.programId,i=(0,l.useState)(!1),s=(0,u.A)(i,2),c=s[0],d=s[1];return(0,F.jsxs)(l.Fragment,{children:[c?(0,F.jsxs)(g.A,{open:c,maxWidth:"md",onClose:function(e,r){r&&"backdropClick"==r||d(!1)},disableEscapeKeyDown:!0,className:"conversion-dialog",children:[(0,F.jsxs)(ae,{children:["Conversion Tracking",(0,F.jsx)(h.A,{"aria-label":"close",onClick:function(){return d(!1)},sx:{position:"absolute",right:8,top:8,color:function(e){return e.palette.grey[500]}},children:(0,F.jsx)(ne.A,{})})]}),(0,F.jsx)(x.A,{className:"conversion-dialog-content",children:(0,F.jsx)(re,{handleContinueButton:t,isNewAdvertiserSetup:r,handleClose:function(){"New Program"==n?(d(!1),t()):d(!1)},calledFrom:n,progName:a,programRefId:o})})]}):null,(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_15",children:(0,F.jsx)(E.A,{variant:"h6",className:"mobileheadingfont",children:"Getting Started With JavaScript"})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_0",children:(0,F.jsxs)(E.A,{variant:"body1",gutterBottom:!0,children:["FlexOffers JavaScript code offers client-side functionality for session storage and conversions to Advertisers. By utilizing our JavaScript, you'll have the accuracy of server-side postbacks with the setup effort of client-side pixel tracking. We will walk you through the steps of adding the JavaScript to a page to start and store sessions, and then post a conversion.",(0,F.jsx)("br",{}),(0,F.jsx)("br",{}),"Our tracking technology provides accurate, actionable and accessible analytics that will enable you to quickly make data-driven decisions that offset your big-picture customer acquisition costs.",(0,F.jsx)("br",{}),(0,F.jsx)("br",{}),"Click the button below to get started."]})})}),(0,F.jsx)("div",{className:"two-row-action",children:(0,F.jsx)(_.M,{children:(0,F.jsx)(S.A,{onClick:function(){return d(!0)},buttonText:"GET JAVASCRIPT"})})})]})},ie=t(61913),se=function(e){var r=e.activeStep,t=e.programs,n=e.programName,a=e.handleProgramChange,o=e.handleNextPage,i=e.handleBackPage,s=e.isNewAdvertiserSetup,c=(0,w.$)(function(e){e.preventDefault(),o()},{}),d=c.errors,u=c.handleChange,m=c.onFormSubmit,p=c.values,h=c.register,g=c.handleUpdateValue;(0,l.useEffect)(function(){h({programName:{required:!0}})},[n]);var x={programName:n};(0,l.useEffect)(function(){var e=(0,T.D)(t);(null===e||void 0===e?void 0:e.length)<2&&e[0]?(g({programName:e[0].programName}),a(e[0].programName)):g(x)},[n,t]);return(0,F.jsxs)(I.g,{onSubmit:m,children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 conversion-subtitle",children:(0,F.jsx)(E.A,{variant:"subtitle1",children:"First, select the program you would like to test from the dropdown menu below:"})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-sm-12 mob_m_b_0",children:(0,F.jsx)(C.A,{required:!0,sortable:!0,options:(0,T.D)(t)||[],label:"Program",name:"programName",dataKey:"programName",onChange:function(e){u(e),a(e.target.value)},value:p.programName||n,error:d.programName,disabled:s})})}),(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{disabled:0===r,onClick:i,variant:"outlined",buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{disabled:2===r,type:"submit",buttonText:"Next",endIcon:(0,F.jsx)(k.A,{})})]})]})},le=t(70693),ce=t(15769),de=t(69780),ue=t(9213),me=t(21671),pe=t(34075),he=JSON.parse('[{"ParameterName":"clickid","Description":"FlexOffers unique sub-tracking click identifier","Example":"clickid=142873070F0F30068429691312640"},{"ParameterName":"ordernumber","Description":"Order number or unique sale ID","Ex
1ample":"ordernumber=26584"},{"ParameterName":"orderamount","Description":"Total sale amount (before taxes and shipping cost)","Example":"orderamount=25.50"},{"ParameterName":"coupon","Description":"Coupon code (optional): Maximum of 300 characters","Example":"coupon=SALE20OFF"},{"ParameterName":"currency","Description":"Currency (optional): Use the ISO 4217 currency code (e.g.,USD, EUR, GBP)","Example":"currency=USD"},{"ParameterName":"geo","Description":"Geographical location (optional): Use the ISO 3166 country code (e.g., USA, DEU, GBR)","Example":"geo=USA"},{"ParameterName":"commissionid","Description":"Advanced commission ID (optional)","Example":"commissionid=Test101"}]'),ge=JSON.parse('[{"ParameterName":"sku","Description":" Unique product ID or SKU ID (optional)","Example":"sku : SKUItem1"},{"ParameterName":"amount","Description":"Product price","Example":"amount : 75"},{"ParameterName":"quantity","Description":"Number of items","Example":"quantity : 1"},{"ParameterName":"order_coupon","Description":"Order coupon","Example":"order_coupon : ABC"},{"ParameterName":"commissionid","Description":"Order commission ID","Example":"commissionid : TEST101"}]'),xe=t(1404),ve=t(65429),fe=function(e){var r=e.activeStep,t=e.trackingId,n=(e.trackingURL,e.programId),a=e.isNewAdvertiserSetup,o=e.handleContinueButton,i=e.handleBackPage,s=e.handleClose,c=e.calledFrom,d=(0,l.useState)(""),m=(0,u.A)(d,2),p=m[0],h=m[1],g=(0,l.useState)(!1),x=(0,u.A)(g,2),v=x[0],f=x[1],A=(0,l.useState)(""),j=(0,u.A)(A,2),b=j[0],y=j[1],T=(0,l.useState)({showMessage:!1,success:!1,message:""}),C=(0,u.A)(T,2),O=C[0],B=C[1],D=(0,V.Zp)();(0,l.useEffect)(function(){(0,z.c2)(n).then(function(e){h(e)})},[]);var M=O.success,U=O.showMessage,L=O.message,G=(0,w.$)(function(e){e.preventDefault(),f(!0),(0,z.rO)(n,p).then(function(e){f(!1),e.errorMessage||e.message||e.isAxiosError?B({showMessage:!0,message:e.response.data.errorMessage,success:!1}):B({showMessage:!0,message:"Successfully Updated",success:!0})})},{}),W=G.errors,q=G.handleChange,J=G.onFormSubmit,K=G.values,Q=G.register,X=G.handleUpdateValue,Y={subTrackingVariable:p};return(0,l.useEffect)(function(){X(Y)},[p]),(0,l.useEffect)(function(){Q({subTrackingVariable:{required:!0}})},[]),(0,l.useEffect)(function(){y(localStorage.getItem("TrackUrl"))},[b]),(0,F.jsxs)(l.Fragment,{children:[v?(0,F.jsx)(xe.A,{loading:v}):null,(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12",children:(0,F.jsx)(R.A,{value:"".concat(b,"da.ashx?advertiserid=").concat(t,"&clickid=&orderamount=&ordernumber=&coupon=¤cy=&geo=&commissionid=&platform=S2S"),type:"text",label:"Postback URL",fullWidth:!0,margin:"normal"})})}),(0,F.jsxs)(I.g,{onSubmit:J,children:[(0,F.jsxs)("div",{className:"row ",children:[(0,F.jsx)("div",{className:"col-lg-8 col-sm-12",children:(0,F.jsx)(R.A,{required:!0,name:"subTrackingVariable",value:K.subTrackingVariable,onChange:function(e){!function(e){q(e),h(e.target.value)}(e)},error:W.subTrackingVariable,placeholder:"Add your Subtracking Variable here",label:"Subtracking Variable",fullWidth:!0})}),(0,F.jsx)("div",{className:"col-lg-2 col-sm-12",children:(0,F.jsx)(S.A,{fullWidth:!0,size:"large",type:"submit",buttonText:"Update"})}),(0,F.jsx)("div",{className:"col-lg-2 col-sm-12",children:(0,F.jsx)(S.A,{fullWidth:!0,size:"large",variant:"outlined",onClick:function(){f(!0),(0,z.rO)(n).then(function(e){f(!1),h(""),e.errorMessage||e.message||e.isAxiosError?B({showMessage:!0,message:"Something went wrong, please contact support.",success:!1}):B({showMessage:!0,message:"Removed Successfully",success:!0})})},buttonText:"Remove"})})]}),U?(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsxs)(ve.A,{severity:M?"success":"warning",children:[(0,F.jsx)("b",{children:M?"Success":"Failed"}),(0,F.jsx)("br",{}),L]})})}):null,(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsxs)(ve.A,{severity:"warning",children:["If you do not specify a Subtracking Variable, we will pass our click identifier in"," ",(0,F.jsx)("strong",{children:(0,F.jsx)("i",{children:"refid"})}),".",(0,F.jsx)("br",{}),"Enter only the Subtracking Variable name,"," ",(0,F.jsx)("strong",{children:"no ampersands (&) or equal (=) signs"}),"."]})})}),(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsx)(E.A,{variant:"subtitle2",children:"Provide these variables when making a post request to the URL provided above:"})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsxs)("div",{className:"col-lg-12",children:[(0,F.jsx)(le.A,{className:"table-responsive-material ",children:(0,F.jsxs)(ce.A,{children:[(0,F.jsx)(de.A,{children:(0,F.jsxs)(ue.A,{children:[(0,F.jsx)(me.A,{children:"Parameter Name"}),(0,F.jsx)(me.A,{children:"Description"}),(0,F.jsx)(me.A,{children:"Example"})]})}),(0,F.jsx)(pe.A,{children:he.map(function(e,r){return(0,F.jsxs)(ue.A,{children:[(0,F.jsx)(me.A,{children:e.ParameterName}),(0,F.jsx)(me.A,{children:e.Description}),(0,F.jsx)(me.A,{children:e.Example})]},r)})})]})}),(0,F.jsxs)("div",{className:"pt-4",children:[(0,F.jsx)("b",{children:"Product Data (optional):"})," This section represents individual products that were purchased. Please make sure to pass the data in the body of the post request in JSON format."]})]})}),(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsx)(P.A,{className:"shadow border-0 bg-dark text-white card",children:(0,F.jsx)("pre",{style:{color:"white"},children:' \n [\n { "sku": "SKU_1", "amount": 5, "quantity": 1, "order_coupon": "A1","order_discount":[5,10],"order_category":[10,20], "commissionid": "C101" },\n { "sku": "SKU_2", "amount": 15, "quantity": 3, "order_coupon": "B2","order_discount":[
110], "commissionid": "C102" }\n ] \n '})})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12",children:(0,F.jsx)(le.A,{className:"table-responsive-material",children:(0,F.jsxs)(ce.A,{children:[(0,F.jsx)(de.A,{children:(0,F.jsxs)(ue.A,{children:[(0,F.jsx)(me.A,{children:"Parameter Name"}),(0,F.jsx)(me.A,{children:"Description"}),(0,F.jsx)(me.A,{children:"Example"})]})}),(0,F.jsx)(pe.A,{children:ge.map(function(e,r){return(0,F.jsxs)(ue.A,{children:[(0,F.jsx)(me.A,{children:e.ParameterName}),(0,F.jsx)(me.A,{children:e.Description}),(0,F.jsx)(me.A,{children:e.Example})]},r)})})]})})})}),(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:"Once the code has been implemented on your website, please proceed to the next step to create a test transaction using the FlexOffers Tracking Diagnosis Tool."})}),(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{disabled:0===r,onClick:i,buttonText:"Back",variant:"outlined",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{onClick:a?"New Program"==c?s:o:function(){D("/app/support/tracking-diagnosis")},buttonText:"Next",endIcon:(0,F.jsx)(k.A,{})})]})]})]})};function Ae(e,r){switch(e){case 0:return(0,F.jsx)(se,(0,n.A)({},r));case 1:return(0,F.jsx)(fe,(0,n.A)({},r));default:return(0,F.jsx)(F.Fragment,{})}}var je={getAllPrograms:J.pF},be=(0,y.Ng)(function(e){return{programs:e.data.programs}},je)(function(e){var r=e.props,t=e.programs,a=e.getAllPrograms,o=e.isNewAdvertiserSetup,i=e.handleContinueButton,s=e.handleClose,c=e.calledFrom,d=e.progName,m=e.programRefId,p=(0,b.A)(),h=((0,j.A)(p.breakpoints.down("sm")),(0,l.useState)(0)),g=(0,u.A)(h,2),x=g[0],y=g[1],k=(0,l.useState)(0),N=(0,u.A)(k,2),T=N[0],I=N[1],w=(0,l.useState)(""),C=(0,u.A)(w,2),S=C[0],E=C[1],_=(0,l.useState)(""),O=(0,u.A)(_,2),P=O[0],B=O[1],D=(0,l.useState)(""),M=(0,u.A)(D,2),U=M[0],L=M[1],V=(0,l.useState)(0),R=(0,u.A)(V,2),G=R[0],W=R[1];function q(e){W(e)}(0,l.useEffect)(function(){if(0===t.length&&a(),void 0!==d){var e=null===t||void 0===t?void 0:t.find(function(e){return e.programName===d});E(null===e||void 0===e?void 0:e.programName),I(null===e||void 0===e?void 0:e.programId),q(null===e||void 0===e?void 0:e.programId)}if(m>0){var r=null===t||void 0===t?void 0:t.find(function(e){return e.programId===m});E(null===r||void 0===r?void 0:r.programName),I(null===r||void 0===r?void 0:r.programId),q(m)}},[t,m]);var J=["Select a Program","Implementation"];return(0,l.useEffect)(function(){G>0&&(0,z.Lw)(G).then(function(e){B(null===e||void 0===e?void 0:e.trackingID),L(e.trackingURL)})},[G]),(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-sm-12 pt-4 steper-col mobilestepper",children:(0,F.jsx)(v.A,{alternativeLabel:!1,activeStep:x,className:"conversion-tracking-steps",children:J.map(function(e,r){return(0,F.jsx)(f.A,(0,n.A)((0,n.A)({},{}),{},{children:(0,F.jsx)(A.A,(0,n.A)((0,n.A)({},{}),{},{children:e}))}),e)})})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 no-margin",children:Ae(x,(0,n.A)((0,n.A)({},r),{},{isNewAdvertiserSetup:o,programs:t,activeStep:x,programId:T,programName:S,trackingId:P,trackingURL:U,handleProgramChange:function(e){var r,n=(null===t||void 0===t||null===(r=t.find(function(r){return r.programName===e}))||void 0===r?void 0:r.programId)||0;I(n),E(e),n>0?W(n):(B(""),L(""))},handleNextPage:function(){y(function(e){return e+1})},handleBackPage:function(){y(function(e){return e-1})},handleContinueButton:i,handleClose:s,calledFrom:c}))})})]})}),ye=(0,m.A)(function(e){return{root:{borderBottom:"1px solid ".concat(e.palette.divider),margin:0,padding:2*e.spacing.unit},closeButton:{position:"absolute",right:e.spacing.unit,top:e.spacing.unit,color:e.palette.grey[500]}}})(function(e){var r=e.children,t=e.classes,n=e.onClose;return(0,F.jsxs)(te.A,{disableTypography:!0,className:t.root,children:[(0,F.jsx)(p.A,{variant:"h6",children:r}),n?(0,F.jsx)(h.A,{"aria-label":"Close",className:t.closeButton,onClick:n,children:(0,F.jsx)(ne.A,{})}):null]})});var ke={displaySuccessMessage:ie.T0},Ne=(0,y.Ng)(null,ke)(function(e){var r=e.isNewAdvertiserSetup,t=e.handleContinueButton,n=e.calledFrom,a=e.programName,o=e.programId,i=(0,l.useState)(!1),s=(0,u.A)(i,2),c=s[0],d=s[1];return(0,F.jsxs)(F.Fragment,{children:[c?(0,F.jsxs)(g.A,{open:c,onClose:function(e,r){r&&"backdropClick"==r||d(!1)},maxWidth:"md",disableEscapeKeyDown:!0,className:"conversion-dialog",children:[(0,F.jsxs)(ye,{children:["Conversion Tracking",(0,F.jsx)(h.A,{"aria-label":"close",onClick:function(){return d(!1)}
1,sx:{position:"absolute",right:8,top:8,color:function(e){return e.palette.grey[500]}},children:(0,F.jsx)(ne.A,{})})]}),(0,F.jsx)(x.A,{className:"conversion-dialog-content",children:(0,F.jsx)(be,{handleContinueButton:t,isNewAdvertiserSetup:r,handleClose:function(){"New Program"==n?(t(),d(!1)):d(!1)},calledFrom:n,progName:a,programRefId:o})})]}):null,(0,F.jsx)("div",{className:"row mb-2 mob_m_b_0",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_15",children:(0,F.jsx)(E.A,{variant:"h6",children:"Getting Started With Server-to-Server Tracking"})})}),(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 mob_m_b_0",children:(0,F.jsxs)(E.A,{variant:"body1",children:["Server-to-server tracking (S2S), also known as postback URL tracking or server-side tracking, is the method of tracking conversions that uses the advertiser's server rather than the user's browser (as pixel-based tracking does). It uses an offer provider's servers to track sessions generated on clicks to attribute conversions. A S2S Postback URL is a special URL that uses tokens to pass the information on conversion and other information to FlexOffers.",(0,F.jsx)("br",{}),(0,F.jsx)("br",{}),'We generally recommend using server-to-server tracking for advertisers whose website\'s software can send a signal back to FlexOffers in the code (aka "fire a postback"). That is more reliable than using any other tracking method.']})})}),(0,F.jsx)("div",{className:"two-row-action",children:(0,F.jsx)(_.M,{children:(0,F.jsx)(S.A,{onClick:function(){return d(!0)},variant:"contained",color:"primary",buttonText:"GET SERVER 2 SERVER"})})})]})}),Te=(0,m.A)(function(e){return{root:{borderBottom:"1px solid ".concat(e.palette.divider),margin:0,padding:2*e.spacing.unit},closeButton:{position:"absolute",right:e.spacing.unit,top:e.spacing.unit,color:e.palette.grey[500]}}})(function(e){var r=e.children,t=e.classes,n=e.onClose;return(0,F.jsxs)(te.A,{disableTypography:!0,className:t.root,children:[(0,F.jsx)(p.A,{variant:"h6",children:r}),n?(0,F.jsx)(h.A,{"aria-label":"Close",className:t.closeButton,onClick:n,children:(0,F.jsx)(ne.A,{})}):null]})}),Ie=(0,m.A)(function(e){return{link:{margin:e.spacing.unit}}})(function(e){var r=e.classes,t=e.isNewAdvertiserSetup,n=e.handleContinueButton,a=e.calledFrom,o=e.programName,i=e.programId,s=(0,l.useState)(!1),c=(0,u.A)(s,2),d=c[0],m=c[1],p=(0,l.useState)(!1),v=(0,u.A)(p,2),f=v[0],A=v[1],j=(0,l.useState)(!1),b=(0,u.A)(j,2),y=b[0],k=b[1],N=function(e,r){e.preventDefault(),"backdropClick"===r?m(!1):"Wix"===r?(A(!0),m(!d)):"GTM"===r?(k(!0),m(!d)):A(!1)};return(0,F.jsxs)(l.Fragment,{children:[d?(0,F.jsxs)(g.A,{open:d,maxWidth:"md",onClose:N,children:[(0,F.jsxs)(Te,{children:["Conversion Tracking",(0,F.jsx)(h.A,{"aria-label":"close",onClick:function(){return m(!1)},sx:{position:"absolute",right:8,top:8,color:function(e){return e.palette.grey[500]}},children:(0,F.jsx)(ne.A,{})})]}),(0,F.jsx)(x.A,{children:(0,F.jsx)(re,{handleContinueButton:n,isNewAdvertiserSetup:t,isWixClicked:f,isGtmClicked:y,calledFrom:a,progName:o,programRefId:i})})]}):null,(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_15",children:(0,F.jsx)(E.A,{variant:"h6",children:"Getting Started With Ecommerce Plugins"})})}),(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_0",children:(0,F.jsxs)(E.A,{component:"span",variant:"body1",gutterBottom:!0,children:["FlexOffers provides numerous tracking options to meet your brand demands. Our conversion tracking solutions give you the foundation you need to obtain visibility into an infinite number of data points across your partnership program.",(0,F.jsx)("br",{}),(0,F.jsx)("br",{}),"Please click on a tracking solution below to be redirected to the relevant implementation guide.",(0,F.jsx)("br",{}),(0,F.jsx)("br",{}),(0,F.jsxs)("ul",{children:[(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{target:"_blank",href:"https://apps.shopify.com/flexoffers-affiliate-marketing",className:r.link,children:"Shopify"})}),(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{href:"#",onClick:function(e){return N(e,"Wix")},className:r.link,children:"WIX"})}),(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{target:"_blank",href:"https://www.bigcommerce.com/apps/flexoffers-affiliate-marketing/",className:r.link,children:"BigCommerce"})}),(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{target:"_blank",href:"https://wordpress.org/plugins/flexoffers-conversion-tracking/",className:r.link,children:"WooCommerce in WordPress"})}),(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{target:"_blank",href:" https://supportbeta.flexoffers.com/knowledge/affiliate-marketing-conversion-tracking-for-magento",className:r.link,children:"Magento"})}),(0,F.jsx)("li",{children:(0,F.jsx)(K.A,{href:"#",onClick:function(e){return N(e,"GTM")},className:r.link,children:"Google Tag Manager"})})]})]})})})]})}),we=t(42768),Ce=t(30541),Se=t(161),Ee=t(26910),_e=t(52107),Fe=t(18464);function Oe(e){var r=e.data;return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(p.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:"Body Parameters"}),(0,F.jsx)("div",{className:"reconTable",style:{marginTop:"8px"},children:(0,F.jsxs)("table",{className:"table table-bordered",children:[(0,F.jsx)("thead",{children:(0,F.jsxs)("tr",{children:[(0,F.jsx)("th",{children:"Field Name"}),(0,F.jsx)("th",{children:"Required"}),(0,F.jsx)("th",{children:"Type"}),(0,F.jsx)("th",{children:"Description"})]})}),(0,F.jsx)("tbody",{children:null===r||void 0===r?void 0:r.map(function(e,r){return(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:e.name}),(0,F.jsx)("td",{children:e.required?"true":"false"}),(0,F.jsx)("td",{children:e.type}),(0,F.jsx)("td",{children:e.description})]},r)})})]})}),(0,F.jsx)(p.A,{variant:"body2",fontWeight:"bold",color:"text.primary",style:{paddingTop:"6px"},children:"Items Body Parameters (optional)"}),(0,F.jsx)("div",{className:"reconTable last",style:{marginTop:"8px"},children:(0,F.jsxs)("table",{className:"table table-bordered",children:[(0,F.jsx)("thead",{children:(0,F.jsxs)("tr",{children:[(0,F.jsx)("th",{children:"Field Name"}),(0,F.jsx)("th",{children:"Description"}),(0,F.jsx)("th",{children:"Example"})]})}),(0,F.jsxs)("tbody",{children:[(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:"sku"}),(0,F.jsx)("td",{children:"Unique product ID or SKU ID (optional) "}),(0,F.jsx)("td",{children:"sku: SKUItem1"})]}),(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:"amount"}),(0,F.jsx)("td",{children:"Product price (optional)"}),(0,F.jsx)("td",{children:"amount: 75"})]}),(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:"quantity"}),(0,F.jsx)("td",{children:"Number of items (optional)"}),(0,F.jsx)("td",{children:"quantity: 1"})]}),(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:"order_coupon "}),(0,F.jsx)("td",{children:"Order coupon (optional)"}),(0,F.jsx)("td",{children:"order_coupon: ABC"})]}),(0,F.jsxs)("tr",{children:[(0,F.jsx)("td",{children:"commissionid"}),(0,F.jsx)("td",{children:"Order commission ID (optional)"}),(0,F.jsx)("td",{children:"commissionid: TEST101"})]})]})]})}),(0,F.jsxs)("div",{className:"col-lg-12 mb-0 pl-0 pr-0",children:[(0,F.jsx)(p.A,{variant:"body2",fontWeight:"bold",color:"text.primary",style:{marginBottom:"8px",paddingTop:"6px"},children:"Items Body Parameters Example"}),(0,F.jsx)(le.A,{variant:"outlined",sx:{mt:1,borderRadius:2,overflow:"hidden",
1width:"100%"},children:(0,F.jsx)(Fe.A,{sx:{fontFamily:"monospace",fontSize:"0.875rem",px:2,py:1.5,bgcolor:"#fafafa",whiteSpace:"nowrap",overflowX:"auto",WebkitOverflowScrolling:"touch"},children:(0,F.jsx)("pre",{style:{marginBottom:"0px"},children:' \n [\n { "sku": "SKU_1", "amount": 5, "quantity": 1, "order_coupon": "A1", "commissionid": "C101" },\n { "sku": "SKU_2", "amount": 15, "quantity": 3, "order_coupon": "B2", "commissionid": "C102" }\n ] \n '})})})]})]})}var Pe=function(){return(0,F.jsxs)(l.Fragment,{children:[(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_0",children:(0,F.jsx)(E.A,{component:"span",variant:"body1",gutterBottom:!0,children:(0,F.jsx)("b",{children:"This service receives and registers batches of orders in the\n FlexOffers system. The API allows you to send authenticated\n transactions from your server to FlexOffers' server."})})})}),(0,F.jsx)("div",{className:"row ",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_0",children:(0,F.jsx)(_e.A,{source:"API",sampleRequestBody:[{AdvertiserTrackingId:"A123BCDE4-FGA5-6B78-912C-DE3456F7G89A_sample",ClickId:"24.0000000000000123.456A78B9C0D12E3A.12345678901234567_sample",OrderNumber:"PRODSKUCONV_09102025_11",OrderAmount:"1000",Coupon:"",CommissionId:"",Currency:"",Geo:"",Items:[]},{AdvertiserTrackingId:"12a34b56-cd78-90ef-ga12-b34c5d67e890_sample",ClickId:"24.123456.1234567FOF89012345678901234_sample",OrderNumber:"PROMOCONV091025_11",OrderAmount:"200",Coupon:"",CommissionId:"",Currency:"USD",Geo:"US",Items:[{sku:"123456",amount:100,quantity:2}]}],jsonResponse:{result:[{advertiserTrackingId:"A123BCDE4-FGA5-6B78-912C-DE3456F7G89A_sample",clickId:"24.0000000000000123.456A78B9C0D12E3A.12345678901234567_sample",orderAmount:1e3,message:"Sales successfully processed.",isValid:!0,saleId:301049},{advertiserTrackingId:"12a34b56-cd78-90ef-ga12-b34c5d67e890_sample",clickId:"24.123456.1234567FOF89012345678901234_sample",orderAmount:200,message:"Sales successfully processed.",isValid:!0,saleId:34275606}],errorMessage:null,timeGenerated:"2025-09-10T17:31:44.8392768Z"},apiEndPath:"api/SalesApiTracking",fields:(0,F.jsx)(Oe,{data:[{name:"AdvertiserTrackingId",required:!0,type:"String",description:"Advertiser Tracking ID. Example: advertiserid=A123BCDE4-FGA5-6B78-912C-DE3456F7G89A"},{name:"ClickId",required:!0,type:"Number",description:"The parameter FlexOffers adds to the landing page URL to identify the source of the click. Example: refid=24.215214.1234567FOF89021871564196739"},{name:"OrderNumber",required:!0,type:"Number",description:"The reference ID for your conversion or order. Example: OrderNumber=TestOrder123"},{name:"OrderAmount",required:!0,type:"Number",description:"Total sale amount (before taxes and shipping cost). Example: OrderAmount=1000"},{name:"Coupon",required:!1,type:"String",description:"The coupon code used in the transaction (optional). Example: Coupon=10_OFF"},{name:"CommissionId",required:!1,type:"String",description:"Advanced commission ID (optional). Example: CommissionId=NewCustomer"},{name:"Currency",required:!1,type:"String",description:"The ISO currency code of the currency (optional). Example: Currency=USD"},{name:"Geo",required:!1,type:"String",description:"Geographical location (optional): Use the ISO 3166 country code (e.g., USA, DEU, GBR). Example: Geo=US"},{name:"Items",required:!1,type:"Array",description:"Optional product data. Please refer to the Items Body Parameters chart. Example: Items=[{sku: SKUItem1}]."}]}),apiTrigger:"true"})})})]})},Be=function(e){function r(e){var t;return(0,a.A)(this,r),(t=(0,i.A)(this,r,[e])).handleTabChange=function(e,r){t.props.handleTabChange?t.props.handleTabChange(e,r):t.setState({activeTab:r})},t.state={activeTab:0,plateform:!1},t}return(0,s.A)(r,e),(0,o.A)(r,[{key:"componentDidMount",value:function(){var e=this;Ee.A.get("/api/advertiserId/programs/GetProgramDetailsOnAdvetiserSetup").then(function(r){var t,a,o,i,s,l=(null===r||void 0===r||null===(t=r.data)||void 0===t?void 0:t.result)||{},c=(null===l||void 0===l||null===(a=l.platform)||void 0===a||null===(o=a.toLowerCase)||void 0===o||null===(i=(s=o.call(a)).trim)||void 0===i?void 0:i.call(s))||"",d=["magento","wix","woocommerce","bigcommerce","shopify","wordpress.org"].includes(c);e.setState((0,n.A)({plateform:d}
1,void 0===e.props.activeTab&&{activeTab:d?2:0}))}).catch(function(e){console.error("Error fetching advertiser setup details:",e)})}},{key:"render",value:function(){var e=this.props,r=e.handleBackButton,t=e.handleContinueButton,n=e.isNewAdvertiserSetup,a=e.calledFrom,o=e.programName,i=e.programId,s=void 0!==this.props.activeTab?this.props.activeTab:this.state.activeTab;return(0,F.jsx)(Ce.j,{card:"New Program"!==a,children:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)("div",{className:"row",children:(0,F.jsx)("div",{className:"col-lg-12 col-sm-12 mob_m_b_0 settabWidth",children:(0,F.jsx)(Se.$,{children:(0,F.jsxs)(c.A,{value:s,onChange:this.handleTabChange,indicatorColor:"primary",textColor:"primary",variant:"scrollable",allowScrollButtonsMobile:!0,scrollButtons:!0,children:[(0,F.jsx)(d.A,{value:0,label:"JavaScript"}),(0,F.jsx)(d.A,{value:1,label:"Server 2 Server"}),(0,F.jsx)(d.A,{value:2,label:"Ecommerce plugins"}),(0,F.jsx)(d.A,{value:3,label:"API",className:"tabwidth80"})]})})})}),(0,F.jsx)(we.A,{value:s,index:0,children:(0,F.jsx)(oe,{isNewAdvertiserSetup:n,handleContinueButton:t,calledFrom:a,programName:o,programId:i})}),(0,F.jsx)(we.A,{value:s,index:1,children:(0,F.jsx)(Ne,{isNewAdvertiserSetup:n,handleContinueButton:t,calledFrom:a,programName:o,programId:i})}),(0,F.jsx)(we.A,{value:s,index:2,children:(0,F.jsx)(Ie,{isNewAdvertiserSetup:n,handleContinueButton:t,calledFrom:a,programName:o,programId:i})}),(0,F.jsx)(we.A,{value:s,index:3,children:(0,F.jsx)(Pe,{})}),n&&0!==s&&1!==s&&(0,F.jsxs)(_.M,{children:[(0,F.jsx)(S.A,{variant:"outlined",color:"default",onClick:function(){r()},buttonText:"Back",startIcon:(0,F.jsx)(N.A,{})}),(0,F.jsx)(S.A,{variant:"contained",color:"primary",onClick:function(){return t()},buttonText:"Continue",endIcon:(0,F.jsx)(k.A,{})})]})]})})}}])}(l.Component),De=(0,m.A)(function(e){return{tab:{minWidth:890,height:530,minHeight:530,width:890},tableWidth:{minWidth:1e3},buttonWrapper:{display:"flex",justifyContent:"center",paddingTop:"20px"},button:{margin:e.spacing.unit}}})(Be)},52107:function(e,r,t){var n=t(91212),a=t(10467),o=t(5544),i=t(9950),s=t(49939),l=t(82053),c=t(70693),d=t(18464),u=t(83274),m=t(25333),p=t(10300),h=t(40514),g=t(6882),x=t(98786),v=(t(87677),t(28345)),f=t(98713),A=t(1404),j=t(36080),b=t(26910),y=t(69850),k=t(44414),N={getAllPrograms:h.pF};r.A=(0,p.Ng)(function(e){return{programs:e.data.programs}},N)(function(e){var r=e.jsonResponse,t=e.sampleRequestBody,p=e.apiEndPath,h=e.fields,N=e.programs,T=e.getAllPrograms,I=e.source,w=(0,i.useState)(null),C=(0,o.A)(w,2),S=C[0],E=C[1],_=(0,i.useState)(0),F=(0,o.A)(_,2),O=(F[0],F[1]),P=(0,i.useState)(""),B=(0,o.A)(P,2),D=B[0],M=B[1],U=(0,i.useState)(!1),L=(0,o.A)(U,2),V=L[0],R=L[1],G=(0,i.useState)(""),W=(0,o.A)(G,2),q=W[0],z=W[1],J=(0,i.useState)({advertiserTrackingId:""}),K=(0,o.A)(J,2),Q=K[0],X=K[1],Y=(0,i.useState)(null),Z=(0,o.A)(Y,2),H=Z[0],$=Z[1],ee=localStorage.getItem("AppDomainUrl"),re="".concat(ee,"/").concat(p);(0,i.useEffect)(function(){z("undefined"===localStorage.getItem("apiToken")||void 0===localStorage.getItem("apiToken")||"null"===localStorage.getItem("apiToken")||null===localStorage.getItem("apiToken")||""===localStorage.getItem("apiToken")?"Please generate token. Click Generate Token button.":"Bearer ".concat(localStorage.getItem("apiToken")))},[localStorage.getItem("apiToken")]);var te=function(){var e=(0,a.A)((0,n.A)().m(function e(r){var t;return(0,n.A)().w(function(e){for(;;)switch(e.p=e.n){case 0:return e.p=0,e.n=1,navigator.clipboard.writeText(r);case 1:E(r),setTimeout(function(){return E(null)},2e3),e.n=3;break;case 2:e.p=2,t=e.v,console.error("Failed to copy: ",t);case 3:return e.a(2)}},e,null,[[0,2]])}));return function(r){return e.apply(this,arguments)}}(),ne=function(){var e=(0,a.A)((0,n.A)().m(function e(){return(0,n.A)().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,b.A.get("/api/account/GetApiTokenWithOutPassword?email=".concat(localStorage.getItem("email"))).then(function(e){z(e.data),localStorage.setItem("apiToken",e.data)}).catch(function(e){return e});case 1:return e.a(2,e.v)}},e)}));return function(){return e.apply(this,arguments)}}();(0,i.useEffect)(function(){0===N.length&&T()},[N]);var ae=function(e,r){""!==e&&r>
10&&(R(!0),(0,v.Jq)(e,r).then(function(e){R(!1),X(e)}))},oe=[{trackingId:Q.advertiserTrackingId}];return(0,k.jsxs)("div",{className:"row",children:[V&&(0,k.jsx)(A.A,{loading:V}),(0,k.jsxs)("div",{className:"col-lg-12 col-sm-12",children:[(0,k.jsx)(l.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:"Endpoint"}),(0,k.jsxs)(c.A,{variant:"outlined",sx:{mt:1,borderRadius:2,overflow:"hidden",width:"100%"},children:[(0,k.jsxs)(d.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:2,py:1,bgcolor:"#f5f5f5",borderBottom:"1px solid #ddd"},children:[(0,k.jsx)(l.A,{variant:"body2",color:"text.secondary",children:"Endpoint (POST)"}),(0,k.jsx)(u.A,{title:S===re?"Copied!":"Copy",children:(0,k.jsx)(m.A,{size:"small",onClick:function(){return te(re)},children:(0,k.jsx)(s.A,{fontSize:"small"})})})]}),(0,k.jsx)(d.A,{sx:{fontFamily:"monospace",fontSize:"0.875rem",px:2,py:1.5,bgcolor:"#fafafa",whiteSpace:"nowrap",overflowX:"auto",WebkitOverflowScrolling:"touch"},children:re})]})]}),(0,k.jsxs)("div",{className:"col-lg-12 col-sm-12",children:[(0,k.jsxs)(l.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:["Authentication",(0,k.jsx)(f.A,{onClick:function(){ne()},disabled:0===(null===N||void 0===N?void 0:N.length),buttonText:"undefined"===localStorage.getItem("apiToken")||void 0===localStorage.getItem("apiToken")||"null"===localStorage.getItem("apiToken")||null===localStorage.getItem("apiToken")||""===localStorage.getItem("apiToken")?"Generate Token":"Regenerate Token",style:{float:"right",marginBottom:"10px"}})]}),(0,k.jsxs)(c.A,{variant:"outlined",sx:{mt:1,borderRadius:2,overflow:"hidden",width:"100%"},children:[(0,k.jsxs)(d.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:2,py:1,bgcolor:"#f5f5f5",borderBottom:"1px solid #ddd"},children:[(0,k.jsx)(l.A,{variant:"body2",color:"text.secondary",children:(0,k.jsx)("b",{children:"Key: Authorization, Type: Bearer"})}),(0,k.jsx)(u.A,{title:S===q?"Copied!":"Copy",children:(0,k.jsx)(m.A,{size:"small",onClick:function(){return te(q)},children:(0,k.jsx)(s.A,{fontSize:"small"})})})]}),(0,k.jsx)(d.A,{sx:{fontFamily:"monospace",fontSize:"0.875rem",px:2,py:1.5,bgcolor:"#fafafa",whiteSpace:"nowrap",overflowX:"auto",WebkitOverflowScrolling:"touch"},children:q})]})]}),(0,k.jsx)("div",{className:"col-lg-12 col-sm-12",children:h}),(0,k.jsxs)("div",{className:"col-lg-12 col-sm-12",children:[(0,k.jsx)(l.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:"Sample Request Body"}),(0,k.jsxs)(c.A,{variant:"outlined",sx:{mt:1,borderRadius:2,overflow:"hidden",width:"100%"},children:[(0,k.jsxs)(d.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:2,py:1,bgcolor:"#f5f5f5",borderBottom:"1px solid #ddd"},children:[(0,k.jsx)(l.A,{variant:"body2",color:"text.secondary",children:"JSON"}),(0,k.jsx)(u.A,{title:S===JSON.stringify(t)?"Copied!":"Copy",children:(0,k.jsx)(m.A,{size:"small",onClick:function(){return te(JSON.stringify(t))},children:(0,k.jsx)(s.A,{fontSize:"small"})})})]}),(0,k.jsx)(d.A,{sx:{fontFamily:"monospace",fontSize:"0.875rem",px:2,py:1.5,bgcolor:"#fafafa",whiteSpace:"pre-wrap"},children:(0,k.jsx)("pre",{children:JSON.stringify(t,null,2)})})]})]}),(0,k.jsxs)("div",{className:"col-lg-12 col-sm-12",children:[(0,k.jsx)(l.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:"Response"}),(0,k.jsxs)("div",{style:{padding:"15px",border:"1px solid #ddd",borderRadius:"8px",marginTop:"10px"},children:[(0,k.jsx)("div",{className:"reconTable",style:{marginBottom:"15px"},children:(0,k.jsxs)("table",{className:"table table-bordered",style:{marginBottom:"0px"},children:[(0,k.jsx)("thead",{children:(0,k.jsxs)("tr",{children:[(0,k.jsx)("th",{width:"20%",children:"Response Code"}),(0,k.jsx)("th",{children:"Description"})]})}),(0,k.jsxs)("tbody",{children:[(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"200"}),(0,k.jsx)("td",{children:"Successful operation."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"204"}),(0,k.jsx)("td",{children:"The URI requested is valid, but no content is available."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"400"}),(0,k.jsx)("td",{children:"Invalid status value."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"401"}),(0,k.jsx)("td",{children:"Unauthorized! You must authenticate with a valid API key."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"403"}),(0,k.jsx)("td",{children:"Request forbidden. This is most likely because the request limit has been reached."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"404"}
1),(0,k.jsx)("td",{children:"The URI requested is invalid or the resource requested, such as a user, does not exist. Also returned when the requested format is not supported."})]}),(0,k.jsxs)("tr",{children:[(0,k.jsx)("td",{children:"500"}),(0,k.jsx)("td",{children:"Something is broken. Please contact [email protected] so that the team can investigate."})]})]})]})}),(0,k.jsx)(l.A,{variant:"body2",fontWeight:"bold",color:"text.primary",children:"Example Response"}),(0,k.jsxs)(c.A,{variant:"outlined",sx:{mt:1,borderRadius:2,overflow:"hidden",width:"100%"},children:[(0,k.jsx)(d.A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:2,py:1,bgcolor:"#f5f5f5",borderBottom:"1px solid #ddd"},children:(0,k.jsx)(l.A,{variant:"body2",color:"text.secondary",children:"JSON"})}),(0,k.jsx)(d.A,{sx:{fontFamily:"monospace",fontSize:"0.875rem",px:2,py:1.5,bgcolor:"#fafafa",whiteSpace:"pre-wrap"},children:(0,k.jsx)("pre",{children:JSON.stringify(r,null,2)})})]})]})]}),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)("div",{id:"advertiserTrackingIdSection",className:"col-lg-6 col-sm-12 col-md-6 col",children:[(0,k.jsx)(l.A,{variant:"body2",fontWeight:"bold",sx:{pb:1.5},color:"text.primary",children:"API"===I?"Select program to get Advertiser Tracking ID and Click ID":"Select program to get Advertiser Tracking ID"}),(0,k.jsx)(g.A,{required:!0,sortable:!0,options:(0,x.D)(N)||[],label:"Program",name:"programName",dataKey:"programName",onChange:function(e){var r;X({advertiserTrackingId:""});var t=e.target.value,n=(null===N||void 0===N||null===(r=N.find(function(e){return e.programName===t}))||void 0===r?void 0:r.programId)||0;O(n),M(t),n>0&&(R(!0),(0,v.lJ)(n,!0).then(function(e){R(!1),ae(e.trackingUrl,n),$(e.trackingUrl)}))},value:D})]}),"API Reconciliation"===I&&null!==Q.advertiserTrackingId&&""!==Q.advertiserTrackingId?(0,k.jsx)("div",{className:"col-lg-12 col-sm-12",children:(0,k.jsx)("div",{className:"reconTable",children:(0,k.jsxs)("table",{className:"table table-bordered",style:{marginBottom:"0px"},children:[(0,k.jsx)("thead",{style:{width:"100%",float:"left"},children:(0,k.jsx)("tr",{style:{width:"100%",float:"left"},children:(0,k.jsx)("th",{style:{width:"100%",float:"left"},children:"Advertiser Tracking ID"})})}),(0,k.jsx)("tbody",{style:{width:"100%",float:"left"},children:oe.map(function(e,r){return(0,k.jsx)("tr",{style:{width:"100%",float:"left"},children:(0,k.jsxs)("td",{style:{width:"100%",float:"left"},children:[e.trackingId,(0,k.jsx)(u.A,{title:S===e.trackingId?"Copied!":"Copy",children:(0,k.jsx)(m.A,{style:{float:"right"},size:"small",onClick:function(){return te(e.trackingId)},children:(0,k.jsx)(s.A,{fontSize:"small"})})})]})},r)})})]})})}):"","API"===I&&null!==H?(0,k.jsx)("div",{className:"col-lg-12 col-sm-12",children:(0,k.jsxs)("div",{className:"reconTable",children:[(0,k.jsxs)("table",{className:"table table-bordered",style:{marginBottom:"0px"},children:[(0,k.jsx)("thead",{children:(0,k.jsxs)("tr",{children:[(0,k.jsx)("th",{children:"Advertiser Tracking ID"}),(0,k.jsx)("th",{children:"Link"})]})}),(0,k.jsx)("tbody",{children:oe.map(function(e,r){return(0,k.jsxs)("tr",{children:[(0,k.jsxs)("td",{children:[e.trackingId,(0,k.jsx)(u.A,{title:S===e.trackingId?"Copied!":"Copy",children:(0,k.jsx)(m.A,{style:{float:"right"},size:"small",onClick:function(){return te(e.trackingId)},children:(0,k.jsx)(s.A,{fontSize:"small"})})})]}),(0,k.jsx)("td",{children:(0,k.jsxs)(j.A,{href:H,style:{color:"#0059FF",wordWrap:"break-word"},target:"_blank",rel:"noopener noreferrer",underline:"hover",children:[(0,k.jsx)(y.A,{}),H]})})]},r)})})]}),(0,k.jsxs)("small",{style:{display:"block",paddingTop:"10px",fontSize:"15px"},children:[(0,k.jsx)("strong",{children:"Note:"})," Click the link above to generate a click ID. Sample Click ID: 24.123456.1234567FOF89012345678901234"]})]})}):""]})]})})},98786:function(e,r,t){t.d(r,{D:function(){return n}});var n=function(e){return e.filter(function(e){return 1===e.status})}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.