Stripe — Handling Stripe WebHooks in .NET / ASP.NET Core

Ashish Patel
.NET Hub
Published in
2 min readNov 29, 2018

--

Receive event notifications with Stripe Webhooks in ASP.NET Core.

.NET Hub —Handling Stripe WebHooks in .NET / ASP.NET

In recent years Stripe has become a major payment provider. It is loved by business owners and customers for a reason. Stripe has easy-to-use APIs, SDKs in multiple languages, and outstanding documentation.

When building Stripe integrations, you might want your applications to receive events as they occur in your Stripe accounts, so that your backend systems can execute actions accordingly. To enable webhook events, you need to register webhook endpoints. After you register them, Stripe can push real-time event data to your application’s webhook endpoint when events happen in your Stripe account.

Receiving webhook events are particularly useful for listening to asynchronous events, such as when a customer’s bank confirms a payment, a customer disputes a charge, a recurring payment succeeds, or when collecting subscription payments.

Stripe generates event data that we can send you to inform you of activity in your account. When an event occurs, Stripe generates a new Event object. A single API request might result in the creation of multiple events.

NuGet: To integrate Stripe Webhooks, you need to install below NuGet packages.

PM> Install-Package Stripe.net

--

--

Ashish Patel
.NET Hub

Cloud Architect • 4x AWS Certified • 6x Azure Certified • 1x Kubernetes Certified • MCP • .NET • Terraform • DevOps • Blogger [https://bit.ly/iamashishpatel]