In live mode, Billing requires a Growth plan or higher. In sandbox mode, every plan can build and test the full Billing lifecycle. See the sandbox limits.
Core concepts
Plans define the recurring charge - amount, interval (monthly, yearly, etc.), trial period, and dunning behavior. Plans are templates; subscriptions are instances. Customers are the people being billed. They exist independently of subscriptions - you can have a customer with no active subscriptions. Subscriptions link a customer to a plan. When you create a subscription, PayBridgeNP immediately generates the first invoice (unless there’s a trial period). Invoices are generated automatically at each billing cycle. Each invoice has a payment link that PayBridgeNP sends to the customer. Invoices go fromopen → paid once the customer pays, or overdue if they don’t pay in time.
Sandbox limits
Sandbox Billing is open on every plan with these account-level guardrails:
Other sandbox emails are recorded but not sent. A sandbox subscription auto-expires after 12 generated invoices or 30 days without a payment. Coupons and dunning policies are mode-specific, so a sandbox coupon or policy never affects live Billing; the same code can exist once in each mode.
For usage, invoice items, subscription discounts, dunning actions, and proration, use a key belonging to the subscription or invoice’s project and mode. Another project’s key cannot access these records, even within the same account. A proration target plan must also belong to that project and mode. Dunning policy definitions remain shared within an account and mode.
Step 1: Create a plan
Interval options
Dunning settings
Dunning controls what happens when a customer doesn’t pay on time:Step 2: Create a customer
externalCustomerId field lets you link PayBridgeNP customers to your own user records.
Step 3: Create a subscription
- A future
startDatedisplays asdraft. At the start date it displays astrialingwhen a trial follows, otherwiseactive. - A trial displays as
trialing, and no invoice is generated until the trial ends. - An immediate subscription without a trial starts as
incomplete. PayBridgeNP generates the first invoice and sends its payment link; the subscription becomesactivewhen that invoice is paid.
Do not grant paid access from
status alone. active means billing is enabled, but it can coexist with an open first invoice after a trial or an overdue renewal when the plan uses keep_active. Base access for a billing period on that period’s invoice.paid event or paid invoice record. For immediate prepaid activation, the subscription stays incomplete until the first invoice is paid; if it remains unpaid for 24 hours, it becomes incomplete_expired and the invoice is voided.Subscription lifecycle
Activation and renewal states. An overdue invoice follows the action saved on the plan.