Handling refunds with EcommerceTransaction


#1

Hi all,

I’m looking at using the Android SDK (for instance) to log a refund event. Can I just provide a negative revenue value? Is there even any value in tracking refunds with Snowplow?

https://github.com/snowplow/snowplow/wiki/Android-Tracker#44-track-ecommerce-transactions-with-trackecommercetransaction-event

Thanks


#2

Although it’s possible to set a negative revenue the best option is to probably develop and use a self-describing JSON schema.

Iglu Central has some ecommerce related schemas that you could likely use as a starting point for a refund schema. You can then use SelfDescribingJson (or the equivalent in another tracker) to send this data to the collector. This allows a great deal of flexibility in sending metadata such as refund amount, product(s) etc.