Using the reporting API to query an ecommerce order by orderId

Is there a way to query an ecommerceOrder by orderId?

When I want to query ecommerce order data, I currently query the visitor who did the ecommerceOrder, and then extract the ecommerceOrder data from the visitors actionDetails:

It works fine, but that only works when you have both the orderId and the visitorId.

When checking my Magento installation, the ecommerce order ID matches the orderId in Piwik (nice feature!) but how can I use this order ID to request data for that order with the Piwik reporting API?

Hi Jeffrey

you need this: New segment 'ecommerceOrderId' to select a particular Ecommerce Order ID · Issue #9981 · matomo-org/piwik · GitHub

1 Like