Automated Billing and Provisioning
How IPTVbp automates the entire subscription lifecycle from purchase to provisioning, renewal, suspension, and cancellation.
Automated Billing and Provisioning
The core value of IPTVbp is automation. When a customer buys a subscription, everything from payment processing to panel account creation happens without manual intervention. This guide explains how the automation engine works and how to configure it.
The Subscription Lifecycle
Every subscription moves through these stages automatically:
Purchase -> Payment -> Provisioning -> Active -> Renewal -> Extension
|
Payment Fails
|
Grace Period -> Suspension -> Termination
Stage 1: Purchase and Payment
- Customer adds a product to their cart and proceeds to checkout.
- They select a payment method (Stripe, PayPal, or crypto).
- The payment gateway processes the transaction.
- IPTVbp receives a webhook confirmation (or redirect for crypto).
- An invoice is created with status Paid.
All of this happens in seconds with no manual steps.
Stage 2: Provisioning
Once payment is confirmed:
- IPTVbp looks up the product's panel configuration (which panel, which package, how many connections).
- The provisioning engine calls the panel API to create a new line/account.
- The panel returns the created line details (username, password, expiry).
- IPTVbp stores the credentials and external line ID.
- The subscription status is set to Active.
- A credentials email is sent to the customer.
If provisioning fails (panel down, API error), the job is queued for automatic retry. Retries happen at 1, 5, 15, and 60 minute intervals. After all retries fail, the subscription is flagged for manual review and you receive an alert.
Stage 3: Active Period
During the active period:
- The customer can stream using their credentials.
- They can view their subscription details in the customer portal.
- IPTVbp tracks the subscription expiry date.
- 3 days before expiry, a renewal reminder email is sent automatically.
Stage 4: Renewal
For recurring subscriptions (Stripe, PayPal):
- On the billing date, the payment gateway automatically charges the saved payment method.
- If successful, IPTVbp receives a webhook and extends the subscription on the panel.
- A renewal confirmation email is sent.
- The next billing date is set.
For one-time or crypto payments:
- IPTVbp sends a renewal reminder email with a payment link.
- The customer clicks the link and completes payment.
- After payment, the subscription is extended.
Stage 5: Failed Payment Handling
If a recurring payment fails:
- First attempt fails: IPTVbp logs the failure. Stripe automatically retries after 1 day.
- Second attempt fails: Another retry after 3 days. A "payment failed" email is sent to the customer asking them to update their card.
- Third attempt fails: The subscription enters the grace period.
Stage 6: Grace Period
The grace period gives customers time to fix payment issues without losing access:
- Default duration: 3 days (configurable per product from 0-14 days).
- During grace period: The subscription remains active (customer can still stream).
- Grace period emails: Sent at the start and 1 day before grace ends.
- Customer action: Update payment method or pay manually via the customer portal.
Configure the grace period at Settings > Billing > Grace Period.
Stage 7: Suspension
If the grace period expires without payment:
- IPTVbp calls the panel API to disable the customer's account.
- The subscription status changes to Suspended.
- A suspension notification is sent to the customer.
- The customer can no longer stream.
Suspended accounts are not deleted. If the customer pays, the account is instantly reactivated.
Stage 8: Reactivation
When a suspended customer pays:
- Payment is processed.
- IPTVbp calls the panel API to re-enable the account and set a new expiry date.
- The subscription status changes back to Active.
- A reactivation confirmation is sent.
Stage 9: Termination
After a configurable period of suspension (default: 30 days), terminated subscriptions are cleaned up:
- The panel account may be deleted (configurable -- some vendors prefer to keep data).
- The subscription status changes to Terminated.
- The customer must create a new subscription if they want to return.
Configuring Automation Settings
Go to Settings > Billing > Automation to configure:
| Setting | Default | Description |
|---|---|---|
| Grace Period | 3 days | Time after payment failure before suspension |
| Suspension Period | 30 days | Time before terminated |
| Renewal Reminder | 3 days before | When to send the first reminder |
| Failed Payment Email | Immediately | Email customer when payment fails |
| Auto-Suspend | Enabled | Automatically suspend after grace period |
| Auto-Terminate | Disabled | Automatically terminate after suspension period |
| Retry Schedule | 1, 3, 5 days | When to retry failed payments |
Webhook Events
If you need to integrate external systems, IPTVbp fires webhooks for all lifecycle events:
subscription.createdsubscription.activatedsubscription.renewedsubscription.payment_failedsubscription.grace_periodsubscription.suspendedsubscription.reactivatedsubscription.cancelledsubscription.terminated
Configure webhook endpoints at Settings > Webhooks.
Monitoring Automation
The Automation Dashboard (under Analytics) shows:
- Provisioning success rate (target: >99%).
- Average provisioning time (target: <5 seconds).
- Failed payment rate and recovery rate.
- Number of subscriptions in each lifecycle stage.
- Queue depth and processing status.
Review this dashboard weekly to catch issues early.
Related Articles
Xtream UI Integration Guide
Connect your Xtream UI or XUI panel to IPTVbp for automated subscription provisioning, renewals, and credential management.
Managing Customers and Subscriptions
Complete guide to managing customer accounts, subscriptions, renewals, and providing support.
Subscription Renewal Automation
Configure renewal reminders, failed payment handling, dunning sequences, and win-back campaigns for maximum retention.