Refactor subcription layer
This commit is contained in:
@@ -402,6 +402,24 @@ export class SubscriptionService {
|
||||
return apiClient.get(`/subscriptions/${tenantId}/invoices`);
|
||||
}
|
||||
|
||||
/**
|
||||
* Update the default payment method for a subscription
|
||||
*/
|
||||
async updatePaymentMethod(
|
||||
tenantId: string,
|
||||
paymentMethodId: string
|
||||
): Promise<{
|
||||
success: boolean;
|
||||
message: string;
|
||||
payment_method_id: string;
|
||||
brand: string;
|
||||
last4: string;
|
||||
exp_month?: number;
|
||||
exp_year?: number;
|
||||
}> {
|
||||
return apiClient.post(`/subscriptions/${tenantId}/update-payment-method?payment_method_id=${paymentMethodId}`, {});
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// NEW METHODS - Usage Forecasting & Predictive Analytics
|
||||
// ============================================================================
|
||||
|
||||
Reference in New Issue
Block a user