How do I check what munchkins are associated with a lead? | Community
Skip to main content
Dev_Team
New Participant
April 7, 2020
Question

How do I check what munchkins are associated with a lead?

  • April 7, 2020
  • 2 replies
  • 4785 views

I'm happy to provide more specific information if needed but basically:

 

1) User submits form

2) We push lead to Marketo using REST API (/rest/v1/leads/push.json)
3) We associate munchkin with the lead with REST API (/rest/v1/leads/{leadId}/associate.json)

How do I check if this munchkin has been successfully associated?

 

2 replies

SanfordWhiteman
New Participant
April 7, 2020

Also, you're already using 2 REST API calls for something the Forms 2.0 JS API can do with zero API calls.

 

Have you been thinking about the DoS vulnerability here?

Dev_Team
Dev_TeamAuthor
New Participant
April 7, 2020

Yes, I have seen you bring this up in other forum posts.

I will bring this up and discuss it further with some of my more experienced colleagues. I think the reason we are trying to use the REST API is so we can move the Marketo interactions to our backend. This way we don't have to worry so much about ad-blockers preventing us from interesting with Marketo. 

SanfordWhiteman
New Participant
April 7, 2020
This way we don't have to worry so much about ad-blockers preventing us from interesting with Marketo. 

Doesn't make sense. You're not going to have a Munchkin cookie if an ad blocker blocks marketo.com and mktoresp.com.

 

A Marketo form can work with an ad blocker running b/c it's not necessary for it to have any reference to Marketo-operated domains.

SanfordWhiteman
New Participant
April 7, 2020

If the cookie exists at all, then a successful call to the Associate Lead endpoint means it was associated.

 

You do not want to be checking the cookies field after every association, that would be a worst practice.

Dev_Team
Dev_TeamAuthor
New Participant
April 7, 2020

Thanks so much for the quick response Sandford.

Yes, I will not be deploying a check of the cookies field into prod however, when I tried to check it to see if it was working correctly it's value was null. Does that mean it hasn't been associated?

The way I tried to check was again with the REST API (/rest/v1/lead/{leadId}.json?fields=cookies`).

SanfordWhiteman
New Participant
April 7, 2020

That is indeed the way to spot-check. Are you sure you URL-encoded the cookie value correctly?