question

Danielle Cox avatar image
Danielle Cox asked Danielle Cox commented

How do I handle cleanup after an uninstall of my app

As part of my Android clover program I am creating inventory items. I need to be able to delete these upon an uninstall. I am hoping the following can work:

Install the application Upon first run of the application I create certain inventory items to support our platform

Upon an uninstall, I need to be able to remove those items.

Is there an uninstall broadcast (or other event) that I can use to do this uninstall? I've noticed there is a webhook, is this something I can use even though I don't have a webapp?

5 comments
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Jeffrey Blattman avatar image Jeffrey Blattman ♦♦ commented ·

There's no "you are going to be uninstalled" broadcast on the device.

0 Likes 0 ·
Danielle Cox avatar image Danielle Cox commented ·

Can I use the webhook and the REST API? I am being told I will not be approved if I can't clean this up.

0 Likes 0 ·
Jeffrey Blattman avatar image Jeffrey Blattman ♦♦ commented ·

Hey I'm looking into that. Did you consider creating a custom line item for the order, to avoid the need to create an inventory item? Not sure what your app does or if this is an option.

0 Likes 0 ·
Jeffrey Blattman avatar image Jeffrey Blattman ♦♦ commented ·

If you could describe in some detail how your app is working we can possibly provide some guidance.

0 Likes 0 ·
Danielle Cox avatar image Danielle Cox commented ·

We are creating an item that can then be repeatedly purchased Register. We are trying to make it so that the client doesn't have to leave the register. A custom line item would have to be created outside of the register. This all works great, but the Clover business person we were assigned wants us to handle cleaning up upon an uninstall.

0 Likes 0 ·

1 Answer

Jeffrey Blattman avatar image
Jeffrey Blattman answered

Okay, the short answer is that there's no way today to cleanup after an uninstall. I filed an internal issue to provide developers with a way to handle this, in this particular use case (reactive inventory item, or whatever you want to call it).

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community