coopdevs / lazona_connector

1 stars 0 forks source link

Provision Woocommerce webhooks through its API #5

Open sauloperez opened 3 years ago

sauloperez commented 3 years ago

This aims to guarantee that the Woocommerce site we are listening to has the necessary webhooks properly configured for this integration to work. This should also be idempotent so we don't end up with duplicate incoming requests.

sauloperez commented 3 years ago

This is the one I had to set up in production for the shipment integration to work

Screenshot from 2021-05-17 16-31-40

I'd like to provision it by simply executing a script ala Config as Code.

daniquilez commented 3 years ago

Only approach I've found is creating a script using woocommerce api: https://woocommerce.github.io/woocommerce-rest-api-docs/#webhooks

sauloperez commented 3 years ago

Exactly. That was the idea. I would implement it as a custom management command as explained on https://docs.djangoproject.com/en/3.2/howto/custom-management-commands/.