@lomray/microservice-payment-stripe
Version:
Stripe payment microservice based on NodeJS & inverted json.
44 lines (43 loc) • 1.21 kB
TypeScript
import StripeSdk from 'stripe';
import { EntityManager } from 'typeorm';
/**
* Payment method webhook handlers
*/
declare class PaymentMethod {
/**
* @private
*/
private readonly manager;
/**
* @private
*/
private readonly cardRepository;
/**
* @constructor
*/
/**
* @constructor
*/
constructor(manager: EntityManager);
/**
* Handles payment method update
* @description Expected card that can be setup via setupIntent
*/
/**
* Handles payment method update
* @description Expected card that can be setup via setupIntent
*/
handlePaymentMethodUpdated(event: StripeSdk.Event): Promise<void>;
/**
* Handles payment method detach
* @description Card and other payment methods should be removed in according subscribers
* @TODO: Handle other payment methods if needed
*/
/**
* Handles payment method detach
* @description Card and other payment methods should be removed in according subscribers
* @TODO: Handle other payment methods if needed
*/
handlePaymentMethodDetached(event: StripeSdk.Event): Promise<void>;
}
export { PaymentMethod as default };