Customer Creation Webhook Returns an Empty Body but Carts Update Doesn't

Solved
Highlighted
New Member
3 0 0

Hi everyone,

 

As the title states, I am developing an app that subscribes to webhooks of a development store using the webhooks API. I try two types of webhooks, carts update and customer creation. In the carts update, I get a body in the request containing the items in the cart but in the customer creation request, the body is always empty and I don't get any data about the customer who just signed up. Why is that and how to solve it?

 

Note: testing webhooks created through the admin page returns a correct body in both webhooks.

0 Likes
Shopify Staff
Shopify Staff
1365 54 201

Hey @AlyMohsen98.

 

Would you mind sharing a time frame and shop URL on which this last occurred? With that, I should be able to see what might have happened in logs, and the events leading up to it. At this time, with test webhooks in the admin's settings/notifications area, I cannot replicate by sending a test customers/create webhook, so more information is much appreciated.

 

For what it's worth, I'm not seeing other reports of this coming in form a support perspective, so I'm curious if this is ongoing for you.

 

Cheers.

0 Likes
New Member
3 0 0

Hi Alex,

First of all thanks for your reply and concern. The name of my development shop is "testgameball3.myshopify.com" and the id of the webhook is "

674095857750". The webhooks should send to my app the data of the created customer but it returns and empty json body.

0 Likes

Success.

Shopify Staff
Shopify Staff
1365 54 201

Hey @AlyMohsen98.

 

Upon further investigation it looks like you  may have specified fields on that webhook resource with an invalid value of gameball - customers/create. The expected value is a comma separated list of fields on the webhook object, such as "id,first_name,billing_address". Since the value in fields is not considered valid, it looks like we're resolving it to nil, or no fields. We could probably validate this better on creation or update requests.

 

Cheers.

1 Like