1
0
mirror of https://github.com/bitwarden/server synced 2025-12-16 00:03:54 +00:00
Files
server/src/Billing/Services/IStripeFacade.cs
Alex Morask cd43535e66 [PM-12420] Stripe events recovery (#4793)
* Billing: Add event recovery endpoints

* Core: Add InternalBilling to BaseServiceUriSettings

* Admin: Scaffold billing section

* Admin: Scaffold ProcessStripeEvents section

* Admin: Implement event processing

* Run dotnet format
2024-09-26 12:36:43 -04:00

99 lines
3.4 KiB
C#

using Stripe;
namespace Bit.Billing.Services;
public interface IStripeFacade
{
Task<Charge> GetCharge(
string chargeId,
ChargeGetOptions chargeGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Customer> GetCustomer(
string customerId,
CustomerGetOptions customerGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Event> GetEvent(
string eventId,
EventGetOptions eventGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Invoice> GetInvoice(
string invoiceId,
InvoiceGetOptions invoiceGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<StripeList<Invoice>> ListInvoices(
InvoiceListOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Invoice> UpdateInvoice(
string invoiceId,
InvoiceUpdateOptions invoiceGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Invoice> PayInvoice(
string invoiceId,
InvoicePayOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Invoice> VoidInvoice(
string invoiceId,
InvoiceVoidOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<PaymentMethod> GetPaymentMethod(
string paymentMethodId,
PaymentMethodGetOptions paymentMethodGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<StripeList<Subscription>> ListSubscriptions(
SubscriptionListOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Subscription> GetSubscription(
string subscriptionId,
SubscriptionGetOptions subscriptionGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Subscription> UpdateSubscription(
string subscriptionId,
SubscriptionUpdateOptions subscriptionGetOptions = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Subscription> CancelSubscription(
string subscriptionId,
SubscriptionCancelOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<TaxRate> GetTaxRate(
string taxRateId,
TaxRateGetOptions options = null,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Discount> DeleteCustomerDiscount(
string customerId,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
Task<Discount> DeleteSubscriptionDiscount(
string subscriptionId,
RequestOptions requestOptions = null,
CancellationToken cancellationToken = default);
}