SOLVED

Re: Woo commerce coupon code into custom field

Go to solution
Anonymous
Not applicable

Woo commerce coupon code into custom field

Hey - I've got a list of coupon codes generated by Woo commerce in a JSON file and I want to pull these into a Marketo custom field to then send to customers in an automated email.

I've attempted to get this working using a web hook as shown in the example below;

Screenshot 2017-10-09 11.56.17.png

My campaign is then triggered on the form fill out which calls the web hook. There is an error however, as the coupon code is not pulling into the wooCoupon market field in the test contact record. Has anyone tried anything similar using coupons from Woo Commerce?

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Re: Woo commerce coupon code into custom field

The field type is URL, so there is the issue! Silly error. Thanks for your help Sanford much appreciated.

View solution in original post

8 REPLIES 8
SanfordWhiteman
Level 10 - Community Moderator

Re: Woo commerce coupon code into custom field

If you have a static JSON file (not a webserver that is serving responses based on the JSON file) then you obviously can't perform lookups into the file by passing query parameters.

If you have an an active process on the back end that returns a single JSON object for the {{Lead.Referral_Email}}:

{

  "my_coupon" : "12345"

}

then there's nothing WooCommerce-specific here. It'll map back just fine.

Note your token {{lead.Lead.Referral_Email}} also looks malformed. It's probably just {{Lead.Referral_Email}}.

Anonymous
Not applicable

Re: Woo commerce coupon code into custom field

Thanks for your response Sanford. We are using webserver response but still not getting the woo coupon code into the custom field. Is there a way I can debug?

SanfordWhiteman
Level 10 - Community Moderator

Re: Woo commerce coupon code into custom field

Can you show the Activity Log details for the Call Webhook entry?

Anonymous
Not applicable

Re: Woo commerce coupon code into custom field

Hi Sanford - activity log below. The web hook hit woo but didn't pull the code into the Marketo custom field. An error with the flow maybe?

Screenshot 2017-10-25 12.07.37.png

SanfordWhiteman
Level 10 - Community Moderator

Re: Woo commerce coupon code into custom field

Need the details (click the Activity ID).

Anonymous
Not applicable

Re: Woo commerce coupon code into custom field

Sorry about that mate, this tells us a bit more.....

Screenshot 2017-10-25 12.31.22.png

SanfordWhiteman
Level 10 - Community Moderator

Re: Woo commerce coupon code into custom field

That should've updated the field. It isn't blocked from webhook-based updates in Admin, right? And it's a String?

Anonymous
Not applicable

Re: Woo commerce coupon code into custom field

The field type is URL, so there is the issue! Silly error. Thanks for your help Sanford much appreciated.