Force app uninstall for closed shops

Hi,

I found this guide Uninstall a Shopify app with an API request in the official docs. However, it doesn’t seem for inactive (closed) Shops, it returns a 404 error.

From an app developer perspective, it would be very helpful if this method also works for closed shops. Is this on purpose, or simply a technical reason that HTTP request can’t be routed to inactive shops?

Hi Zirkelc

One thing you could try would be to use the appInstallation query to get the uninstallUrl which can be used to uninstall your app.

Hi @Liam-Shopify

thanks for your reply!

I tested this GraphQL query, but without success:

  • active shops return null as uninstallUrl
  • inactive shops return a http 404 not found error

Hi again Zirkelc,

It looks like it isn’t currently possible to uninstall an app from a store that’s inactive - I’m thinking once the store is inactive there’s simply to way to make an API call to it. Although it’s strange you’re getting null for the uninstallUrl on active stores.

What would be your usecase for being able to uninstall apps from closed stores?

Hi @Liam-Shopify

thanks for confirming this. It looks like it is common practice to install an app from a test store and close the store afterwards. At least we have lots of installation from stores which were closed afterwards.

In my case, installing our app creates lots of data on our side and occupies resources (e.g. databases). If the shop is not active, it would be good to have a clean way of simply uninstalling the app so that we can free-up these resources. Another issue is that the closed shops have old version of an app (access scopes, webhooks, etc.) that might cause problem anyway if the store is being re-activated. I think this is the reason for Uninstall a Shopify app with an API request to exist in the first place.