Unable to add "Mandatory Compliance Webhooks" from a .Net Core web app

Hi,

We are building a .NET Core web application that connects to any Shopify store (with the merchant’s permission) so we can read orders and customer data and provide customer-service support.

I created a public app in Shopify Partners and implemented OAuth using the app’s Client ID and Client Secret, which is working.
However, I am stuck during the app submission process, specifically on the requirement to process mandatory compliance webhooks.

Here is what I’ve tried and where I’m confused:

  • While creating the app, I added a return URL pointing to my web application.

  • On that return URL page, I attempted to use the Shopify Admin API to create the three mandatory compliance webhooks.

  • When I click the “Run” button on the Shopify Partners submission page, that return URL is never called, and my page is not hit at all.

  • I already have controller endpoints in my .NET app to receive the three mandatory compliance webhooks.

  • According to Shopify documentation, these webhooks can be defined in the shopify.app.toml file, but I learned that this only applies to apps created using the Shopify CLI.

  • My app is not built with the Shopify CLI. It’s a custom .NET web app that should work with any Shopify store that installs it.

Because of this, I’m not sure what the correct approach is.

Could you please guide me on how to properly pass the submission requirements for:

  1. Providing the mandatory compliance webhooks

  2. Verifying incoming webhooks using HMAC signatures

Any clarification on how Shopify expects non-CLI, custom apps to handle this would be greatly appreciated.

Thank you.

1 Like

Hi @Kamran_Ajmal

Mandatory compliance webhooks are now managed exclusively in the app configuration TOML (see this doc) so you will need to create a .toml file in your app to add these webhooks.

What you’ll need to do:

  1. Your .NET app stays as-is — you don’t need to rewrite it or restructure it

  2. Install Shopify CLI (it’s a Node.js-based tool)

  3. Run shopify app config link to connect to your existing Partner Dashboard app

  4. Edit the shopify.app.toml to add your compliance webhook URLs

  5. Run shopify app deploy to push the configuration to Shopify

The CLI is only used for configuration management — your actual web application continues to run on your own hosting as a completely separate .NET project. There’s more info in this doc:

1 Like

Hi, @Liam-Shopify!

When I run shopify app config link, I receive the error:

“The directory <omitted_path> doesn’t have a package.json.”.

It comes from

I have an .NET application where I’m trying to register my webhooks.

Also, if I run shopify app deploy I receive the same error as mentioned above.

How can I manage to fix it? Do I need to create a mocked package.json? What’s the usage of it?

1 Like

It worked creating a valid empty package.json file:

1 Like