MisarMisar Docs
MisarMailMisarBlogMisarReachMisarPostMisarDevMisarCoderMisarSEOMisar PlatformMisar SSO
API Reference

Billing

Subscription management, plan details, Stripe checkout, and customer portal

Billing endpoints manage subscriptions, Stripe checkout sessions, and customer portal access. All payments are processed through Misar AI Technology Pvt Ltd via Stripe.

Billing endpoints use session authentication (dashboard cookie), not API key auth. They are intended for use in the MisarMail dashboard UI.


Plans

PlanPriceDescription
free$0 / moGetting started — 3,000 emails/mo
pro$24.99 / moGrowing teams — 300,000 emails/mo
max$99.99 / moHigh-volume senders — 1,500,000 emails/mo
enterpriseCustomUnlimited — contact sales

See Plan Limits for the full feature matrix.


Get subscription

GET/mail/billing/subscription

Returns the current subscription plan, send limits, email usage, and trial status. dailyLimit/monthlyLimit are null when unlimited. trialEndAt is a UTC timestamp while a trial is active; null otherwise.

Response fields

successboolean

true when the request succeeded.

subscriptionobject

Plan state: planSlug, planName, priceMonthly, priceYearly, status, dailyLimit, monthlyLimit, renewalDate, cancelAtPeriodEnd, hasStripeSubscription, hasStripeCustomer, isTrialing, trialDaysRemaining, trialEndAt, trialPlanSlug.

usageobject

Email send counters: today and thisMonth.

Request
curl https://api.misar.io/mail/billing/subscription \
  -H "Cookie: sb-access-token=YOUR_SESSION"
200 — OK
{
  "success": true,
  "subscription": {
    "planSlug":              "pro",
    "planName":              "Pro",
    "priceMonthly":          24.99,
    "priceYearly":           239.9,
    "status":                "active",
    "dailyLimit":            10000,
    "monthlyLimit":          300000,
    "renewalDate":           "2026-04-30T23:59:59Z",
    "cancelAtPeriodEnd":     false,
    "hasStripeSubscription": true,
    "hasStripeCustomer":     true,
    "isTrialing":            false,
    "trialDaysRemaining":    null,
    "trialEndAt":            null,
    "trialPlanSlug":         null
  },
  "usage": {
    "today":     1240,
    "thisMonth": 4218
  }
}

Subscription status values

StatusMeaning
trialingFree trial active
activePaid subscription current
past_duePayment failed — grace period active
canceledSubscription ended
pausedManually paused via portal

Create checkout session

POST/mail/billing/checkout

Create a Stripe Checkout session to subscribe to or upgrade a paid plan. Returns a redirect URL — send the user to url. Stripe handles payment collection; the success and cancel redirect URLs are set server-side, so you don't pass them.

Request body

planSlugstringbodyrequired

pro or max. Enterprise is sales-assisted and is not available through checkout.

billingPeriodstringbodydefault: monthly

monthly or yearly.

Response fields

successboolean

true when the session was created.

urlstring

Stripe Checkout URL to redirect the user to.

Request
curl -X POST https://api.misar.io/mail/billing/checkout \
  -H "Cookie: sb-access-token=YOUR_SESSION" \
  -H "Content-Type: application/json" \
  -d '{
    "planSlug":      "pro",
    "billingPeriod": "monthly"
  }'
200 — OK
{
  "success": true,
  "url":     "https://checkout.stripe.com/c/pay/cs_live_..."
}

Create portal session

POST/mail/billing/portal

Create a Stripe Customer Portal session for managing the subscription (cancel, update card, view invoices). Takes no request body — the return URL is set server-side.

Response fields

successboolean

true when the session was created.

urlstring

Stripe Customer Portal URL.

Request
curl -X POST https://api.misar.io/mail/billing/portal \
  -H "Cookie: sb-access-token=YOUR_SESSION"
200 — OK
{
  "success": true,
  "url":     "https://billing.stripe.com/session/..."
}

Portal URLs expire after 5 minutes. Generate a fresh URL each time a user navigates to billing settings — do not cache them.