Creates a subscription for a customer on a billing plan. PayBridge immediately generates the first invoice and sends a payment link to the customer.
If the plan has trialDays > 0, the subscription starts in trial — no invoice is generated until the trial ends.
Documentation Index
Fetch the complete documentation index at: https://docs.paybridgenp.com/llms.txt
Use this file to discover all available pages before exploring further.
Your PayBridge API key. Obtain one from the dashboard under Settings → API Keys. Prefix: pk_sandbox_ for testing, pk_live_ for production.
ID of the billing customer.
"bc_01j9x2k3m4n5p6q7r8s9t0u1v2"
ID of the billing plan.
"bp_01j9x2k3m4n5p6q7r8s9t0u1v2"
When to start the subscription. Defaults to now.
Override the plan's defaultProvider for this subscription.
esewa, khalti, connectips, hamropay Your internal reference ID.
"subscription_abc123"
Subscription created.
"sub_01j9x2k3m4n5p6q7r8s9t0u1v2"
true when created with a live key, false for sandbox.
active, paused, past_due, cancelled, completed Human-friendly status including draft (future start) and trialing states.
draft, trialing, active, paused, past_due, cancelled, completed esewa, khalti, connectips, hamropay Your internal reference for this subscription.