> For the complete documentation index, see [llms.txt](https://docs.billingjs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.billingjs.com/getting-started/configure-webhooks-and-triggers.md).

# Configure Webhooks and Triggers

The best way to check if your users are having an active subscription and activate the premium features accordingly is to **keep a copy of their current subscription state on your database**.

To do that you will need to configure webhooks that will be called when a subscription is created or updated on Stripe.

{% hint style="warning" %}
Those are **required** to support **shared subscriptions** and **subscription transfers**
{% endhint %}

### The subscription webhook

To store the updated state of your customer's subscriptions

{% content-ref url="/pages/ICWniaXJxacLz1SJK5kQ" %}
[Subscription webhook](/getting-started/configure-webhooks-and-triggers/subscription-webhook.md)
{% endcontent-ref %}

### The customer webhook

To store the updated state of your customer's shared subscriptions and to support transferring subscription from one user to another

{% content-ref url="/pages/JODWisDyXPslwPLRgToZ" %}
[Customer Webhook](/getting-started/configure-webhooks-and-triggers/customer-webhook.md)
{% endcontent-ref %}

### The new user trigger

To handle new user already having a subscription, either because they were added to a shared subscription or because you added their subscription manually from the Stripe Dashboard

{% content-ref url="/pages/ymFeN4Leei5ShzA1u26k" %}
[New user trigger](/getting-started/configure-webhooks-and-triggers/new-user-trigger.md)
{% endcontent-ref %}
