AbuseZeroAbuseZero

Billing

Read the plan, credits and usage, and manage payments, payment methods and Enterprise plans.

Billing is the API form of Workspace settings → Usage, Subscription and Billing in the dashboard. Any connection with operations:general reads the plan, credits and usage. The workspace owner's own sign-in reads invoices and payment methods, buys credits, moves to a higher plan and manages payment settings, as in the dashboard.

Examples on this page use a server client signed in as the workspace owner:

import { AbuseZero } from "abusezero/server";

const abusezero = new AbuseZero({ accessToken: process.env.ABUSEZERO_ACCESS_TOKEN!, workspace: "74999074913993548694", outage: "throw" });

Who can use billing

ActionsScopeWho
Read the plan, usage, credit history, daily usage and Enterprise plans; preview an Enterprise plan codeoperations:generalAny connection, API keys included.
Read the upcoming charge, invoices, payment methods, billing details and a payment; get a quoteoperations:generalThe workspace owner.
Save billing details; set the low-credit alert; choose what stays active over your limitsoperations:configurationThe workspace owner.
Auto-reload, buying credits, a higher plan, yearly billing, undoing a downgrade, resuming, paying an overdue invoice, payment methods and Enterprise plan codesoperations:managementThe workspace owner.

"The workspace owner" means an OAuth sign-in by the owner, such as the AbuseZero CLI or the AbuseZero MCP server signed in as the owner. A machine client the owner created counts as the owner too. No API key holds operations:management, so API keys get KEY_PERMISSION_DENIED for those actions. They act for no person, so they get OWNER_REQUIRED for the rest. Machine clients someone else created and signed-in members who aren't the owner get OWNER_REQUIRED.

Every change takes an Idempotency-Key. Send the same key to retry a change safely: a payment is never charged twice for one key.

What stays in the dashboard

Canceling the subscription, downgrading (to Builder too), switching from yearly to monthly billing and moving to a higher plan on a shorter billing period are done by the workspace owner in Workspace settings → Subscription. A quote shows what any of them costs or saves, with confirmable: false.

When the bank asks to confirm a payment

Every payment returns a payment object. When its status is requires_action, the bank wants the person who owns the card to confirm it. Send them payment_page_url, the secure payment page for the charge, and read the payment again with Retrieve a payment once they're done.

When there's no saved payment method

Buying credits, a higher plan, paying an invoice and turning on auto-reload charge a saved payment method. Without one, they return PAYMENT_METHOD_REQUIRED. Make a billing approval link and give it to the workspace owner: they sign in, add a card or bank account and, for an upgrade, pay. The owner can also add one in Workspace settings → Billing.

Retrieve the plan

MethodPathScopeIdempotency-Key
GET/v1/billing/planoperations:generalNot used

Also available as abusezero billing plan in the AbuseZero CLI, abusezero_get_plan on the AbuseZero MCP server and plan() in the AbuseZero Node.js SDK.

Response

{
  "object": "billing_plan",
  "plan": "pro",
  "name": "Pro",
  "interval": "month",
  "subscribed": true,
  "renews_at": "2026-12-01T00:00:00.000Z",
  "ends_at": null,
  "scheduled_change": null,
  "enterprise": false,
  "payment": { "state": "ok", "due_at": null },
  "limits": { "protected_benefits": 10, "custom_policies": 100, "team_seats": 5, "retention_days": 90, "rate": 50 },
  "over_limit": null
}
FieldTypeDescription
planpayg, pro or scaleThe plan. payg is Builder.
namestringThe plan's name, such as Builder.
intervalmonth, year or nullThe billing period. null on Builder.
subscribedbooleanWhether the workspace has a Pro or Scale subscription.
renews_atstring or nullWhen the subscription renews next.
ends_atstring or nullWhen a canceled subscription ends. It can be resumed until then.
scheduled_changeobject or nullA downgrade or period change set for the end of the period: plan, name, interval and at. It can be undone.
enterprisebooleanWhether an Enterprise plan sets the workspace's plan.
payment.stateok, grace or overduegrace and overdue mean a renewal hasn't been paid. See Pay an overdue invoice.
payment.due_atstring or nullWhen the unpaid renewal was due.
limitsobjectThe workspace's limits from its plan and Enterprise plans: protected_benefits, custom_policies, team_seats, retention_days and rate, the requests per second.
over_limitobject or nullSet while the workspace is over its limits. state is grace before anything is paused and enforced after. grace_until is when the grace period ends. items lists the benefits and members that count, each with kind, id, name, paused and will_pause. See Choose what stays active over your limits.

Retrieve usage

MethodPathScopeIdempotency-Key
GET/v1/billing/usageoperations:generalNot used

Also available as abusezero billing usage in the AbuseZero CLI, abusezero_get_usage on the AbuseZero MCP server and usage() in the AbuseZero Node.js SDK.

Response

{
  "object": "billing_usage",
  "credits": { "available": 3800, "allowance": 1800, "pay_as_you_go": 2000, "per_evaluation": 5 },
  "usage": {
    "absolute": {
      "allowance_credits": { "used": 3200, "total": 5000 },
      "pay_as_you_go_credits": { "used": 400, "total": 2400 },
      "protected_benefits": { "used": 3, "total": 10 },
      "team_seats": { "used": 2, "total": 5 }
    },
    "allowance": null
  },
  "auto_reload": { "enabled": true, "capped": false, "threshold": null, "amount_dollars": null, "monthly_cap_dollars": null }
}
FieldTypeDescription
credits.availableintegerCredits available now.
credits.allowanceintegerOf those, the plan's allowance credits.
credits.pay_as_you_gointegerOf those, pay-as-you-go credits: credits bought, bonuses and other credits outside the plan's allowance.
credits.per_evaluationintegerCredits one evaluation uses.
usage.absoluteobjectThe four gauges Workspace settings → Usage shows: allowance_credits, pay_as_you_go_credits, protected_benefits and team_seats, each with used and total. Credits count this billing period, or this UTC month on Builder.
usage.allowanceobject or nullThe same gauges against the Pro or Scale plan alone. null without a subscription.
auto_reload.enabledbooleanWhether auto-reload is on.
auto_reload.cappedbooleanWhether this month's cap stops the next reload.
auto_reload.threshold, amount_dollars, monthly_cap_dollarsinteger or nullThe workspace owner's auto-reload settings. null for every other connection.

List credit history

Credits added, used and removed, newest first, 50 entries to a page. Evaluations are one entry per UTC day, and so are past webhook charges.

MethodPathScopeIdempotency-Key
GET/v1/billing/credit-historyoperations:generalNot used

Also available as abusezero billing credit-history in the AbuseZero CLI, abusezero_list_credit_history on the AbuseZero MCP server and creditHistory(query) in the AbuseZero Node.js SDK.

Query parameters

FieldTypeRequiredDescription
activitystringNoOne kind of activity: evaluations, webhooks, plan_credits, temporary_plan_credits, enterprise_plan_credits, purchase, first_purchase_bonus, survey_credits, yearly_conversion, expired, ended, replaced, enterprise_plan_removed, refund, dispute or adjustment.
directionadded or usedNoOnly credits added, or only credits used or removed.
days7, 30, 90 or 365NoThe last number of days.
from, tostringNoA range of UTC days, as YYYY-MM-DD, of up to 366 days. Send both.
cursorstringNoThe next_cursor from the previous page.

Response

Returns a list of entries:

{
  "object": "credit_entry",
  "date": "2026-11-09",
  "daily_total": true,
  "activity": "evaluations",
  "sources": ["plan"],
  "credits": -340,
  "plans": ["Pro"],
  "enterprise_plans": []
}
FieldTypeDescription
datestringThe entry's time, or the UTC day for a daily total.
daily_totalbooleanWhether the entry adds up a day of evaluations, or a day of past webhook charges.
activitystringWhat happened, from the list under activity above.
sourcesarray of stringsWhich credits it added to or used: plan, temporary_plan, enterprise_plan, purchased, bonus, survey, converted, adjustment or negative_balance.
creditsintegerCredits added (positive) or used or removed (negative).
plans, enterprise_plansarray of stringsThe plans and Enterprise plans behind the credits, by name.

Retrieve daily usage

Credits used each day of the last 30 days, in the workspace's time zone, with each day's busiest benefit.

MethodPathScopeIdempotency-Key
GET/v1/billing/daily-usageoperations:generalNot used

Also available as abusezero billing daily-usage in the AbuseZero CLI, abusezero_get_daily_usage on the AbuseZero MCP server and dailyUsage() in the AbuseZero Node.js SDK.

Response

{
  "object": "daily_usage",
  "time_zone": "Europe/London",
  "days": [
    { "day": "2026-11-09", "credits": 340, "top_benefit": { "name": "Signup credits", "evaluations": 30 } },
    { "day": "2026-11-10", "credits": 0, "top_benefit": null }
  ]
}

List Enterprise plans

The workspace's Enterprise plans, ended ones included, and what each one adds.

MethodPathScopeIdempotency-Key
GET/v1/billing/enterprise-plansoperations:generalNot used

Also available as abusezero billing enterprise-plans in the AbuseZero CLI, abusezero_list_enterprise_plans on the AbuseZero MCP server and enterprisePlans() in the AbuseZero Node.js SDK.

Response

Returns a list of Enterprise plans:

{
  "object": "enterprise_plan",
  "name": "Acme Enterprise",
  "active": true,
  "added_at": "2026-10-01T09:00:00.000Z",
  "ends_at": null,
  "grants": {
    "credits": 50000, "credit_cadence": "month", "credit_expiry": "period_end", "credit_expiry_days": null,
    "team_seats": 20, "protected_benefits": 50, "custom_policies": null, "rate": 200, "burst": 400, "concurrency": 20, "retention_days": 365
  }
}

credit_cadence is once, month or year. credit_expiry is never, period_end or days, with credit_expiry_days. A null limit adds nothing to the plan's own.

Preview an Enterprise plan code

Shows what a code adds, without redeeming it. Each try counts toward an hourly limit on codes.

MethodPathScopeIdempotency-Key
POST/v1/billing/enterprise-plan-codes/previewoperations:generalNot used

Also available as abusezero billing preview-code in the AbuseZero CLI, abusezero_preview_enterprise_plan_code on the AbuseZero MCP server and previewEnterprisePlanCode(code) in the AbuseZero Node.js SDK.

FieldTypeRequiredLimitsDescription
codestringYesUp to 80 charactersThe Enterprise plan code.

Returns 201 with object: "enterprise_plan_code_preview" and the plan it adds: name, description, the same fields as grants above, and duration_months.

Retrieve the upcoming charge

MethodPathScopeIdempotency-Key
GET/v1/billing/upcoming-chargeoperations:generalNot used

Also available as abusezero billing upcoming-charge in the AbuseZero CLI, abusezero_get_upcoming_charge on the AbuseZero MCP server and upcomingCharge() in the AbuseZero Node.js SDK. The workspace owner only.

Returns a list with the next renewal, if one is coming: amount_cents after discounts, at, the payment_method it charges and whether it's discounted. A subscription set to end has none.

List invoices

MethodPathScopeIdempotency-Key
GET/v1/billing/invoicesoperations:generalNot used

Also available as abusezero billing invoices in the AbuseZero CLI, abusezero_list_invoices on the AbuseZero MCP server and invoices(query) in the AbuseZero Node.js SDK. The workspace owner only.

Response

Returns a list of invoices, newest first, 20 to a page, plus outstanding_cents: everything still due across unpaid invoices.

{
  "object": "invoice",
  "number": "A1B2C3D4-0007",
  "created_at": "2026-11-01T00:00:00.000Z",
  "status": "paid",
  "description": "Pro plan (Monthly)",
  "period": { "start": "2026-11-01T00:00:00.000Z", "end": "2026-12-01T00:00:00.000Z" },
  "total_cents": 2500,
  "paid_cents": 2500,
  "due_cents": 0,
  "refunded_cents": 0,
  "payable": false,
  "url": "https://invoice.stripe.com/i/…"
}

status is open, paid, void or uncollectible. payable is true for an unpaid invoice. url is the invoice's secure payment page, where it can be viewed, downloaded and paid.

List payment methods

MethodPathScopeIdempotency-Key
GET/v1/billing/payment-methodsoperations:generalNot used

Also available as abusezero billing payment-methods in the AbuseZero CLI, abusezero_list_payment_methods on the AbuseZero MCP server and paymentMethods() in the AbuseZero Node.js SDK. The workspace owner only.

Response

Returns a list: the default first, then the backup payment methods in the order they're charged.

{
  "object": "payment_method",
  "id": "48210937465512093847",
  "type": "card",
  "brand": "visa",
  "last4": "4242",
  "exp_month": 12,
  "exp_year": 2028,
  "label": "Visa ending 4242",
  "default": true,
  "backup": null,
  "declined": false,
  "expired": false
}
FieldTypeDescription
typecard, bank_account or linkThe kind of payment method.
brand, last4, exp_month, exp_yearstring, integer or nullA card's brand, last four digits and expiry. null for a bank account.
defaultbooleanWhether it's the default payment method.
backupinteger or nullIts place among the backup payment methods, from 1. null for the default.
declinedbooleanWhether it was declined for good and is skipped until its details change.
expiredbooleanWhether its expiry date has passed.

Retrieve billing details

MethodPathScopeIdempotency-Key
GET/v1/billing/detailsoperations:generalNot used

Also available as abusezero billing details in the AbuseZero CLI, abusezero_get_billing_details on the AbuseZero MCP server and billingDetails() in the AbuseZero Node.js SDK. The workspace owner only.

Returns object: "billing_details" with name, email (the billing email), uses_account_email (whether that's the owner's account email), address (line1, line2, city, state, postal_code and country, or null) and tax_id (type and value, or null).

Retrieve a payment

MethodPathScopeIdempotency-Key
GET/v1/billing/payments/{id}operations:generalNot used

Also available as abusezero billing payment in the AbuseZero CLI, abusezero_get_payment on the AbuseZero MCP server and getPayment(id) in the AbuseZero Node.js SDK. The workspace owner only. Returns the payment object, with its latest status.

The payment object

{
  "object": "billing_payment",
  "id": "73492810562018437529",
  "kind": "credit_purchase",
  "status": "requires_action",
  "payment_page_url": "https://invoice.stripe.com/i/…",
  "credits": null,
  "bonus_credits": null,
  "scheduled": false
}
FieldTypeDescription
kindcredit_purchase, plan_change, invoice_payment or auto_reloadWhat the payment is for.
statussucceeded, pending, requires_action, failed or canceledpending means a bank payment is still processing; read it again later. failed means the payment method was declined.
payment_page_urlstring or nullSet when status is requires_action: the secure payment page where the person confirms the charge.
credits, bonus_creditsinteger or nullThe credits a paid credit purchase added, and its first-purchase bonus.
scheduledbooleanWhether a plan change was set for the end of the period.

Get a quote for a plan change

Prices a plan or billing period change, in either direction. Nothing changes. A quote is valid for 10 minutes.

MethodPathScopeIdempotency-Key
POST/v1/billing/quotesoperations:generalNot used

Also available as abusezero billing quote in the AbuseZero CLI, abusezero_quote_plan_change on the AbuseZero MCP server and quotePlanChange(input) in the AbuseZero Node.js SDK. The workspace owner only.

Request body

FieldTypeRequiredDescription
planpayg, pro or scaleYesThe plan to quote. payg is Builder.
intervalmonth or yearFor Pro and ScaleThe billing period.
promo_codestringNoA promo code, when subscribing from Builder.

Example

const quote = await abusezero.quotePlanChange({ plan: "scale", interval: "year" });

Response

{
  "object": "plan_change_quote",
  "id": "73492810562018437529",
  "plan": "scale",
  "interval": "year",
  "direction": "upgrade",
  "timing": "immediate",
  "confirmable": true,
  "charge_now_cents": 96000,
  "renewal_cents": 99000,
  "credits_now": 50000,
  "effective_at": "2026-11-10T12:00:00.000Z",
  "expires_at": "2026-11-10T12:10:00.000Z",
  "next_charge": { "amount_cents": 99000, "at": "2027-11-10T12:00:00.000Z", "discounted": false },
  "promotion": null
}
FieldTypeDescription
directionupgrade, downgrade or switchswitch keeps the plan and changes the billing period.
timingimmediate or period_endWhen the change takes effect.
confirmablebooleanWhether Change to a higher plan can confirm it. false for a downgrade, a switch to monthly billing or a higher plan on a shorter billing period: the owner makes those in the dashboard.
charge_now_centsintegerWhat's charged when it's confirmed.
renewal_centsintegerThe plan's full price each period.
credits_nowintegerThe plan credits added when it's confirmed.
next_chargeobject or nullThe first renewal after the change, after discounts.
promotionobject or nullThe promo code applied: code, amount_cents, full_cents and duration.

Update billing details

MethodPathScopeIdempotency-Key
PUT/v1/billing/detailsoperations:configurationRequired

Also available as abusezero billing update-details in the AbuseZero CLI, abusezero_update_billing_details on the AbuseZero MCP server and updateBillingDetails(input, key) in the AbuseZero Node.js SDK. The workspace owner only. The owner is emailed about the change, as from the dashboard.

FieldTypeRequiredLimitsDescription
namestringYesUp to 200 charactersThe name on invoices.
emailstringYesUp to 320 charactersThe billing email. Send "" to use the owner's account email.
addressobjectYesline1, line2, city, state, postal_code and country, a two-letter country code. Send "" for parts you leave out.
tax_idobject or nullYestype, such as eu_vat, gb_vat or us_ein, and value.

Returns 200 with the billing details. INVALID_BILLING_ADDRESS and INVALID_TAX_ID mean the address or tax ID wasn't accepted for its country.

Set the low-credit alert

MethodPathScopeIdempotency-Key
PUT/v1/billing/low-credit-alertoperations:configurationRequired

Also available as abusezero billing set-low-credit-alert in the AbuseZero CLI, abusezero_set_low_credit_alert on the AbuseZero MCP server and setLowCreditAlert(credits, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
creditsinteger or nullYesAlert when available credits fall to this many. null alerts by your usage pace instead.

Returns 200 with object: "low_credit_alert" and credits.

Choose what stays active over your limits

While the workspace is over its plan's limits, the newest benefits and members over the limit are paused when the grace period ends. Choose another one to pause instead. After pausing starts, the same request swaps them right away.

MethodPathScopeIdempotency-Key
POST/v1/billing/over-limitoperations:configurationRequired

Also available as abusezero billing choose-active in the AbuseZero CLI, abusezero_choose_what_stays_active on the AbuseZero MCP server and chooseWhatStaysActive(input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
kindbenefit or memberYesWhat to swap.
keep_activestringYesThe id of an item in over_limit.items that will pause or is paused.
pausestringYesThe id of an active item to pause instead.

Returns 201 with object: "over_limit_choice" and status: chosen during the grace period, swapped after it, or unchanged when the workspace is no longer over its limits. PAUSE_SWAP_STALE means either item changed; read the plan again.

Set up or change auto-reload

When credits fall below threshold, auto-reload buys amount_dollars of credits with the default payment method, on its own.

MethodPathScopeIdempotency-Key
PUT/v1/billing/auto-reloadoperations:managementRequired

Also available as abusezero billing set-auto-reload in the AbuseZero CLI, abusezero_set_auto_reload on the AbuseZero MCP server and setAutoReload(input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
enabledbooleanYesfalse turns auto-reload off.
thresholdinteger or nullWhen enabledReload when available credits fall below this many.
amount_dollarsinteger or nullWhen enabledWhat each reload buys, in US dollars. It must add more credits than threshold.
monthly_cap_dollarsinteger or nullNoThe most auto-reload spends in a UTC month, or null for no cap. Leave it out to keep the current cap.

Returns 200 with object: "auto_reload", the settings and spent_this_month_dollars. Turning it on needs a default payment method.

Buy credits

Charges the default payment method and adds the credits once it's paid.

MethodPathScopeIdempotency-Key
POST/v1/billing/credit-purchasesoperations:managementRequired

Also available as abusezero billing buy-credits in the AbuseZero CLI, abusezero_buy_credits on the AbuseZero MCP server and buyCredits(amountDollars, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
amount_dollarsintegerYesHow much to spend, in US dollars. INVALID_CREDIT_AMOUNT names the amounts allowed.

Example

const payment = await abusezero.buyCredits(50, "buy-credits-2026-11-10");
if (payment.status === "requires_action") console.log(`Confirm the payment: ${payment.payment_page_url}`);

Returns 201 with the payment object.

Retry a credit purchase

Tries a declined credit purchase again, with the default or another saved payment method.

MethodPathScopeIdempotency-Key
POST/v1/billing/credit-purchases/{id}/retryoperations:managementRequired

Also available as abusezero billing retry-purchase in the AbuseZero CLI, abusezero_retry_credit_purchase on the AbuseZero MCP server and retryCreditPurchase(id, input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
idstringYesThe payment's ID, in the path.
payment_method_idstringNoA saved payment method to charge instead of the default.

Returns 201 with the payment object. PAYMENT_ATTEMPTS_EXCEEDED means the payment was tried as many times as allowed.

Change to a higher plan

Confirms a quote for a higher plan on the same or a longer billing period, Builder to Pro or Scale included, or for yearly billing on the same plan. Its charge is made right away.

MethodPathScopeIdempotency-Key
POST/v1/billing/quotes/{id}/confirmoperations:managementRequired

Also available as abusezero billing change-plan in the AbuseZero CLI, abusezero_change_plan on the AbuseZero MCP server and changePlan(quoteId, input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
idstringYesThe quote's ID, in the path.
payment_method_idstringNoA saved payment method to charge instead of the default.

Returns 201 with the payment object, whose id is the quote's. A quote with confirmable: false returns PLAN_CHANGE_IN_DASHBOARD. QUOTE_EXPIRED means the quote is older than 10 minutes or billing changed since; get a new one.

Undo a scheduled downgrade

Keeps the current plan and billing period, so the subscription renews as it is.

MethodPathScopeIdempotency-Key
POST/v1/billing/scheduled-change/undooperations:managementRequired

Also available as abusezero billing undo-downgrade in the AbuseZero CLI, abusezero_undo_scheduled_downgrade on the AbuseZero MCP server and undoScheduledDowngrade(key) in the AbuseZero Node.js SDK. The workspace owner only. Returns 201 with object: "subscription_change" and status.

Resume the subscription

Resumes a canceled subscription before it ends, so it renews again.

MethodPathScopeIdempotency-Key
POST/v1/billing/subscription/resumeoperations:managementRequired

Also available as abusezero billing resume-subscription in the AbuseZero CLI, abusezero_resume_subscription on the AbuseZero MCP server and resumeSubscription(key) in the AbuseZero Node.js SDK. The workspace owner only. Returns 201 with object: "subscription_change" and status.

Pay an overdue invoice

MethodPathScopeIdempotency-Key
POST/v1/billing/invoices/payoperations:managementRequired

Also available as abusezero billing pay-overdue in the AbuseZero CLI, abusezero_pay_overdue_invoice on the AbuseZero MCP server and payOverdueInvoice(input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
invoice_numberstringNoThe number of an unpaid invoice. Leave it out to pay the overdue renewal.
payment_method_idstringNoA saved payment method to charge instead of the default.

Returns 201 with the payment object. INVOICE_NOT_FOUND means there's nothing unpaid to pay.

Make a payment method the default

The previous default becomes the first backup payment method. The new default then pays anything overdue.

MethodPathScopeIdempotency-Key
POST/v1/billing/payment-methods/{id}/defaultoperations:managementRequired

Also available as abusezero billing set-default-payment-method in the AbuseZero CLI, abusezero_set_default_payment_method on the AbuseZero MCP server and setDefaultPaymentMethod(id, key) in the AbuseZero Node.js SDK. The workspace owner only.

Returns 201 with object: "payment_method_change", status and overdue_invoices: each overdue invoice it paid, with number, amount_cents and status.

Move a backup payment method

MethodPathScopeIdempotency-Key
POST/v1/billing/payment-methods/{id}/moveoperations:managementRequired

Also available as abusezero billing move-payment-method in the AbuseZero CLI, abusezero_move_backup_payment_method on the AbuseZero MCP server and moveBackupPaymentMethod(id, direction, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
directionup or downYesOne place earlier or later in the order the backups are charged.

Returns 201 with object: "payment_method_change" and status.

Remove a payment method

MethodPathScopeIdempotency-Key
DELETE/v1/billing/payment-methods/{id}operations:managementRequired

Also available as abusezero billing remove-payment-method in the AbuseZero CLI, abusezero_remove_payment_method on the AbuseZero MCP server and removePaymentMethod(id, key) in the AbuseZero Node.js SDK. The workspace owner only.

The default can't be removed: make another payment method the default first. Returns 200 with object: "payment_method_change" and status, or PAYMENT_METHOD_PRIMARY for the default.

Redeem an Enterprise plan code

Adds the code's Enterprise plan to the workspace for good. Preview it first to see what it adds.

MethodPathScopeIdempotency-Key
POST/v1/billing/enterprise-plan-codes/redeemoperations:managementRequired

Also available as abusezero billing redeem-code in the AbuseZero CLI, abusezero_redeem_enterprise_plan_code on the AbuseZero MCP server and redeemEnterprisePlanCode(code, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredLimitsDescription
codestringYesUp to 80 charactersThe Enterprise plan code.

Returns 201 with object: "enterprise_plan_redemption", status: "redeemed" and the plan name.

For a workspace with no saved payment method: a link for the workspace owner to add a card or bank account, or to add one and pay for an upgrade. The owner signs in first, then sees what the link is for, with Decline. Nothing is charged until they pay on that screen.

MethodPathScopeIdempotency-Key
POST/v1/billing/approval-linksoperations:managementRequired

Also available as abusezero billing approval-link in the AbuseZero CLI, abusezero_create_billing_approval_link on the AbuseZero MCP server and createBillingApprovalLink(input, key) in the AbuseZero Node.js SDK. The workspace owner only.

FieldTypeRequiredDescription
kindadd_payment_method or upgradeYesupgrade adds a payment method and pays for the change.
planpro or scaleFor an upgradeThe plan to move to.
intervalmonth or yearFor an upgradeThe billing period.

An upgrade is a higher plan on the same or a longer billing period, Builder to Pro or Scale included, or yearly billing on the same plan, as Change to a higher plan allows. The plan and period the workspace already has returns PLAN_UNCHANGED, and anything else returns PLAN_CHANGE_IN_DASHBOARD.

Returns 201 with a billing_approval_link: its id, kind, plan, interval, status (waiting), the approval_url to give the owner, expires_at and completed_at. The approval_url is returned only here. The link works once and expires after an hour.

MethodPathScopeIdempotency-Key
GET/v1/billing/approval-links/{id}operations:generalNot used

Also available as abusezero billing approval-link-status in the AbuseZero CLI, abusezero_get_billing_approval_link on the AbuseZero MCP server and billingApprovalLink(id) in the AbuseZero Node.js SDK. The workspace owner only.

Returns the billing_approval_link with its status:

StatusWhat it means
waitingThe owner hasn't finished yet.
completedThe payment method was added, or the upgrade is in effect. Carry on.
declinedThe owner declined. Ask them before making another link.
expiredThe link expired. Make a new one if the owner still wants to go ahead.

An unknown id returns 404 with BILLING_APPROVAL_LINK_NOT_FOUND.

Errors

CodeStatusMeaning
OWNER_REQUIRED403The action needs the workspace owner: the owner's own sign-in, or a machine client the owner created. API keys can't use it.
PLAN_CHANGE_IN_DASHBOARD403The plan change is a downgrade, a switch to monthly billing or a higher plan on a shorter billing period. The owner makes that change in the dashboard.
BILLING_UNAVAILABLE403Billing changes aren't available for this workspace. Contact support.
PAYMENT_NOT_FOUND404No payment with this ID exists in the workspace.
INVOICE_NOT_FOUND404There's no unpaid invoice to pay.
CODE_INVALID404The Enterprise plan code isn't valid or was already used.
BILLING_APPROVAL_LINK_NOT_FOUND404No billing approval link with this ID exists in the workspace.
PAYMENT_METHOD_REQUIRED409The workspace has no saved payment method. Make a billing approval link for the owner.
PAYMENT_METHOD_PRIMARY409The default payment method can't be removed.
PAYMENT_METHOD_UNAVAILABLE409The payment method can't be charged. Choose another one.
PAYMENT_ATTEMPTS_EXCEEDED409The payment was tried as many times as allowed.
QUOTE_EXPIRED409The quote is no longer valid. Get a new one.
PLAN_UNCHANGED409Nothing would change: the plan is already this one, or there's nothing to undo or resume.
SUBSCRIPTION_INVOICE_UNPAID409Pay the overdue invoice before changing plans.
BILLING_OPERATION_PENDING409A payment for this request is still processing. Retry with the same idempotency key in a moment.
PAUSE_SWAP_STALE409A benefit or member you chose changed. Read the plan again.
INVALID_CREDIT_AMOUNT422The amount isn't one you can buy. The message names the amounts allowed.
CODE_ATTEMPTS_EXCEEDED429Too many Enterprise plan codes were tried. Try again in an hour.

For every other code, see REST API errors.

How is this guide?

Last updated on