Soenneker.Stripe.PaymentMethods
11.0.1340
Prefix Reserved
dotnet add package Soenneker.Stripe.PaymentMethods --version 11.0.1340
NuGet\Install-Package Soenneker.Stripe.PaymentMethods -Version 11.0.1340
<PackageReference Include="Soenneker.Stripe.PaymentMethods" Version="11.0.1340" />
<PackageVersion Include="Soenneker.Stripe.PaymentMethods" Version="11.0.1340" />
<PackageReference Include="Soenneker.Stripe.PaymentMethods" />
paket add Soenneker.Stripe.PaymentMethods --version 11.0.1340
#r "nuget: Soenneker.Stripe.PaymentMethods, 11.0.1340"
#:package Soenneker.Stripe.PaymentMethods@11.0.1340
#addin nuget:?package=Soenneker.Stripe.PaymentMethods&version=11.0.1340
#tool nuget:?package=Soenneker.Stripe.PaymentMethods&version=11.0.1340
Soenneker.Stripe.PaymentMethods
Create, retrieve, update, attach, detach, and auto-page through Stripe payment methods with customer and type filtering.
Installation
dotnet add package Soenneker.Stripe.PaymentMethods
Configuration
{
"Stripe": {
"SecretKey": "sk_test_..."
}
}
Usage
using Soenneker.Stripe.Enums.PaymentMethodTypes;
using Soenneker.Stripe.PaymentMethods.Abstract;
using Soenneker.Stripe.PaymentMethods.Registrars;
using Stripe;
services.AddStripePaymentMethodsUtilAsScoped();
List<PaymentMethod>? cards = await paymentMethodsUtil.GetAllByUserIdAndType(
"cus_...",
StripePaymentMethodType.Card,
cancellationToken);
PaymentMethod? defaultCard = await paymentMethodsUtil.GetFirstByUserIdAndType(
"cus_...",
StripePaymentMethodType.Card,
cancellationToken);
await paymentMethodsUtil.Attach(
"pm_...",
new PaymentMethodAttachOptions { Customer = "cus_..." },
cancellationToken: cancellationToken);
GetAll, GetAllByUserIdAndType, and GetAllByUserIdAndTypes follow Stripe pagination and materialize every result, so use them carefully for large accounts. Despite its historical name, Delete detaches the payment method from its customer; it does not erase the payment method object from Stripe.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
-
net11.0
- Soenneker.Stripe.Client (>= 11.0.1606)
- Soenneker.Stripe.Enums.PaymentMethodTypes (>= 11.0.100)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Soenneker.Stripe.PaymentMethods:
| Package | Downloads |
|---|---|
|
Soenneker.Stripe.Suite
Bundle and register Soenneker's Stripe customer, payment, invoice-item, and subscription libraries. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 11.0.1340 | 0 | 12/1/2026 |
| 11.0.1339 | 0 | 12/1/2026 |
| 11.0.1338 | 0 | 12/1/2026 |
| 11.0.1337 | 0 | 11/30/2026 |
| 11.0.1336 | 47 | 11/30/2026 |
| 11.0.1335 | 60 | 11/30/2026 |
| 11.0.1334 | 63 | 11/30/2026 |
| 11.0.1333 | 47 | 11/30/2026 |
| 11.0.1332 | 63 | 11/29/2026 |
| 11.0.1331 | 75 | 11/29/2026 |
| 11.0.1330 | 262 | 11/21/2026 |
| 11.0.1329 | 171 | 11/19/2026 |
| 11.0.1327 | 145 | 11/19/2026 |
| 11.0.1326 | 110 | 11/18/2026 |
| 11.0.1325 | 115 | 11/18/2026 |
| 11.0.1324 | 137 | 11/18/2026 |
| 11.0.1322 | 121 | 11/18/2026 |
| 11.0.1321 | 126 | 11/18/2026 |
| 11.0.1320 | 126 | 11/17/2026 |
Updated Soenneker.Stripe.Client to 11.0.1606