Reputation: 115
I am trying to integrate commercetools via event bridge, I receive events like this:
{
"version": "0",
"id": "...",
"detail-type": "StoreProductSelectionsChanged",
"source": "...",
"account": "...",
"time": "2024-05-23T15:57:19Z",
"region": "eu-central-1",
"resources": [],
"detail": {
"notificationType": "Message",
"projectKey": "...",
"id": "...",
"version": 1,
"sequenceNumber": 19,
"resource": {
"typeId": "store",
"id": "..."
},
"resourceVersion": 19,
"resourceUserProvidedIdentifiers": {
"key": "test"
},
"type": "StoreProductSelectionsChanged",
"updatedProductSelections": [
{
"productSelection": {
"typeId": "product-selection",
"id": "..."
},
"active": false
}
]
}
}
The key in the event can be updatedProductSelections
(like in the example), addedProductSelections
or removedProductSelections
.
I am trying to match all three separatly.
The pattern i tried were either content-matching or like this:
{
"detail-type": [
"StoreProductSelectionsChanged"
],
"source": [{
"prefix": "aws.partner/commercetools.com"
}],
"detail": {
"updatedProductSelections": [{
"wildcard": "*"
}]
}
}
But this does not work. I searched a lot and red the docs, but no fitting answer...
Does any one have a solution?
Upvotes: 0
Views: 23