I’m trying to subscribe to metaobjects/create using the config file like below.
[[webhooks.subscriptions]]
topics = [ “metaobjects/create”, “metaobjects/delete”, “metaobjects/update” ]
uri = “arn:aws:events:us-east-1::event-source/aws.partner/shopify.com/-/”
filter = “id:*”
However, I get the error “Version can not be created. The webhook topic (metaobjects/create) requires a valid filter.”
Providing no filter, a blank filter, and other filters all fail.
Providing a filter for published metaobjects also fail.
filter = “capabilities.publishable.status:active”
Any clues how I can subscribe to metaobjects and their localizations?
@keiraarts the metaobject topics historically used subtopics which were migrated to filters. To subscribe to a metaobjects topic you will need to provide a filter in the format type:your_metaboject_type
. This is required as we validate that you have permission to subscribe to the metaobject type.
Hey Dave!
I spent more time digging into this issue.
I could not subscribe to a webhook topic to a metaobject BEFORE the metaobject was created. This caused a lot of errors on shopify.app.toml because I was trying to subscribe to a webhook topic for my merchants before all of them had the same metaobject definition created.
Changed my order of operations worked: I registered the metaobjects across all merchants, then subscribed to the webhook topic, and it worked!
1 Like