How do I send event_id with Facebook pixel? - Stack Overflow

文章推薦指數: 80 %
投票人數:10人

To add an event_id parameter to the events you're sending through your pixel, go into your website's source code and add an event_id parameter ... Home Public Questions Tags Users Collectives ExploreCollectives FindaJob Jobs Companies Teams StackOverflowforTeams –Collaborateandshareknowledgewithaprivategroup. CreateafreeTeam WhatisTeams? Teams CreatefreeTeam CollectivesonStackOverflow Findcentralized,trustedcontentandcollaboratearoundthetechnologiesyouusemost. Learnmore Teams Q&Aforwork Connectandshareknowledgewithinasinglelocationthatisstructuredandeasytosearch. Learnmore HowdoIsendevent_idwithFacebookpixel? AskQuestion Asked 11monthsago Active 5monthsago Viewed 12ktimes 10 3 IgetanerrorfromFacebook: PurchaseEventMissingSomeDeduplicationParametersYou'resending PurchaseeventsthroughbothyourpixelandtheConversionsAPI,but they'renotbeingdeduplicatedproperlybecausenotenoughofthese eventsarereceivinganevent_idparameter.Eventinstancessent withoutanevent_idparametercannotbededuplicated. Addanevent_idparametertoallPurchaseeventsthatyou'resending frombothyourpixelandtheConversionsAPI.Toaddanevent_id parametertotheeventsyou'resendingthroughtheConversionsAPI, youcanusethePayloadHelpertoolontheFacebookforDevelopers sitetovalidatethatyourpayloadissetupcorrectly.Toaddan event_idparametertotheeventsyou'resendingthroughyourpixel,go intoyourwebsite'ssourcecodeandaddanevent_idparametertoeach ofyourPurchaseeventinstances. ButIamsendingevent_idinmypixeleventforPurchase! facebookfacebook-javascript-sdk Share Improvethisquestion Follow askedDec21'20at19:15 Simon_WeaverSimon_Weaver 126k7575goldbadges596596silverbadges642642bronzebadges Addacomment  |  1Answer 1 Active Oldest Votes 12 Thecorrectwaytosendevent_idontheserverwiththeConversionsAPIisatthesamelevelasevent_nameandnotinsideuser_dataorcustom_data. Howeverwiththepixelontheclientyouneedtosenditlikethisasathirdparametertofbq. fbq('track','Purchase',{value:12,currency:'USD'},{eventID:'purchase.123456'}); NoteitiscalledeventIDwhensentfrompixelandnotevent_id.Despitetheerrormessagecallingitevent_id!AttimeofwritingthiswastheonlypageIcouldfindthisthirdparameterdescribed. Youcanverifyintheeventsmanagertoolbyclicking'ViewDetails'foraneventandthenlookingat'EventDeduplication'.Itwillconfirmtheparameterisreceivedfromthepixel.Itmaynotshowhereforseveralhours,orevenuntilthenextday-evenifyou'reseeingeventsbeingreceivedinrealtime. Share Improvethisanswer Follow answeredDec21'20at19:15 Simon_WeaverSimon_Weaver 126k7575goldbadges596596silverbadges642642bronzebadges 2 2 CanyoupleasetellmehowcanIfindtheevent_idforAddToCartandotherevents?CurrentlyI'msendingtherequeststoconversionAPIwithoutevent_idparameter. – Amin Mar17at13:05 3 Itcanbewhateveryouwant!YoujustneedtosendtheSAMEIDontheclientandservertorepresentthesameAddToCartevent.Youcoulddosomethingsimpletostartlikeconstevent_id='ATC_'+newDate().getTime();andsendthatvaluetobothAPIs.UnlessyouarerunningAmazon.comyouprobablydon'thavetwopeopleaddingtocartthesamemillisecond-butaddasessionidorotherrandomnumbertobesure.AnotherwaywouldbetocallyourservertologtheeventandreturnaservergeneratedIDwhichyouthenpasstoFacebook'sAPI-ifyoudothismakesureitreturnsquickly. – Simon_Weaver Mar24at1:42 Addacomment  |  Highlyactivequestion.Earn10reputation(notcountingtheassociationbonus)inordertoanswerthisquestion.Thereputationrequirementhelpsprotectthisquestionfromspamandnon-answeractivity. Nottheansweryou'relookingfor?Browseotherquestionstaggedfacebookfacebook-javascript-sdkoraskyourownquestion. TheOverflowBlog Podcast397:Iscryptothekeytoademocratizingthemetaverse? Podcast398:Feelinginsecureaboutcode’ssecurity FeaturedonMeta Reducingtheweightofourfooter UpcomingresponsiveActivitypage TwoBornottwoB-Farewell,BoltClockandBhargav! Communityinputneeded:Therulesforcollectivesarticles Linked 0 HowdoIsendaneventidtomyFacebookPixelifmyconversionsAPIissetupthroughapartner? Related 1751 HowdoesFacebookdisablethebrowser'sintegratedDeveloperTools? 1 ConnectFacebookPixelwithFacebookanalytics 3 FacebookpixelPurchaseeventdeduplication 1 Facebookpixelhelpershowspurchaseeventworksbutfacebookeventsmanagerdoesn'tshowit 0 CannotseeparametervaluesusedforFacebookPurchaseEvent-FacebookPixel 0 FacebookPixel/E-Commerce:DeduplicationforFacebookpixelandConversionsAPIevents 1 FacebookConversion"SameEventID"error HotNetworkQuestions Whatconstituteshumoronthis"ibeforee"coffeemugtext? WhatteeniestlonechangewouldhaveactualizedtranscontinentalHighSpeedRailintheUSA? Aretherecountrieswherebeingnon-vaccinateddisqualifiesyoufrom"standard"healthinsurancecoverage(forthatparticulardisease)? find-Globbingwithdisjunction Whatarethetaximplicationsofbeingpaidforworkincompanyshares? Whatdothestarsinapowermetersymbolmean? HowdoesthisWhatsAppscamwork? Sourceofthequote"Iwillblurbyourbook,orIwillreadit,butnotboth" IsthereareasonforcommonGermanarticlesinagivencase? IsGandalfreallyon'du'termswiththeBalrog?(Odd'duzen'example) Hyper-AgileSubmarines? Peerreviewingwithdyslexia SimpleCalculatorPython Reallifeexamplesof*zero*weightedgesingraphs Whydon'toscilloscopeprobesusetwistedpairs? Explaininga"GreatCircleRoute"toyoungCivilAirPatrolcadets EjectCircuitBoardFromJig Couldawallgetaweaponsrating? Howisthis.mp4file596523hourslong? NormalizingsingularitiesinNDSolve Isitappropriatetoaskaboutthenumberofapplicantstoaposition? Aresomeprotonsmoremassivethanothersduetospinningatadifferentrateorbeinginamoreexcitedstate? HowcouldWolframResearchincreaseWolframLanguageadoption? TypescriptInheritance:Expandingbaseclassobjectproperty morehotquestions Questionfeed SubscribetoRSS Questionfeed TosubscribetothisRSSfeed,copyandpastethisURLintoyourRSSreader. Yourprivacy Byclicking“Acceptallcookies”,youagreeStackExchangecanstorecookiesonyourdeviceanddiscloseinformationinaccordancewithourCookiePolicy. Acceptallcookies Customizesettings  



請為這篇文章評分?