@sourceloop/ctrl-plane-subscription-service
Version:
Subscription management microservice for SaaS control plane.
29 lines (28 loc) • 836 B
TypeScript
import { IServiceConfig } from '@sourceloop/core';
import { TInvoice } from 'loopback4-billing';
export { FeatureToggleDbName } from '@sourceloop/feature-toggle-service';
export type BaseUser = {
id: string;
};
export type LeadUser = {
userTenantId: string;
email: string;
} & BaseUser;
export type LeadUserWithToken = {
token: string;
} & LeadUser;
export declare const SubscriptionDbSourceName = "SubscriptionDB";
export type InvoiceStatus = 'paid' | 'posted' | 'payment_due' | 'not_paid' | 'voided' | 'pending';
export interface IPayload {
id: string;
event_type: string;
webhook_status: string;
content: IContent;
}
export interface IContent {
invoice: TInvoice;
}
export interface ISubscriptionServiceConfig extends IServiceConfig {
useCustomSequence: boolean;
useSequelize?: boolean;
}