CorefinityCorefinityDocs
Open the Control PanelControl Panel
Billing · 1 of 16

Get the billing account

Answers your company's billing account: its details and VAT basis, its balance, its card or Direct Debit mandate, its contract lines, the next invoice and what you may do; with=details adds the billing contacts and the countries the billing address may be in. Editing the details, paying an invoice and adding or removing a card or mandate are done in the Control Panel.

GET/api/corestack/billing/account

Query parameters

accountinteger

The billing account to read, by its id (see GET /corestack/billing/account). Left out, the request acts on your company's default billing account. An account that does not exist and one that is not your company's answer the same 404. At least 1.

account_idinteger

The same as account, under the name the MCP tools use. Send one of the two: when they name different accounts the request is refused 422 invalid on account_id. At least 1.

withstring

details adds billing_contacts and countries, which are null without it.

details

Returns

200 The billing account.

Fields of the 200 answer
addressobject or any or nullRequired
auto_chargebooleanRequired

Whether invoices are collected automatically.

backup_methodobject or any or nullRequired
balanceobjectRequired
Fields
accrued_this_periodobjectRequired

What has accrued this month so far.

Fields
amountstringRequired
currencystringRequired
balanceobjectRequired

What has accrued and is not invoiced yet, plus what is outstanding on open invoices.

Fields
amountstringRequired
currencystringRequired
credits_availableobjectRequired
Fields
amountstringRequired
currencystringRequired
currencystringRequired
last_accrual_atstring or nullRequired

The last hour that was accrued. Format: date-time.

linesarray of objectsRequired
Fields of each item
accruedobjectRequired

What the line has accrued this month.

Fields
amountstringRequired
currencystringRequired
contract_lineobjectRequired

A line of a contract, by name.

Fields
idintegerRequired

At least 1.

kindstringRequired

package, an addon (extra cores, memory, disk, log storage, a dedicated IP address) or uat, a staging environment.

packageaddonuat
labelstringRequired
hourlyobjectRequired

The line's price for one hour, with six decimal places.

Fields
amountstringRequired
currencystringRequired
hoursintegerRequired
monthlyobjectRequired
Fields
amountstringRequired
currencystringRequired
next_invoice_atstringRequired

Format: date-time.

outstandingobjectRequired

What is due on open invoices.

Fields
amountstringRequired
currencystringRequired
periodobjectRequired

This month (UTC).

Fields
endstring or nullRequired

Format: date-time.

startstringRequired

Format: date-time.

recent_activityarray of objectsRequired
Fields of each item
amountobjectRequired
Fields
amountstringRequired
currencystringRequired
atstring

Format: date-time.

contract_idinteger

At least 1.

currencystring
descriptionstring
invoiceobject or any or null
kindstringRequired
usage_mtdinvoicepaymentrefundcredit_appliedcredit_grantadjustment
productstring
throughstring or null

The last hour the running figure counts. Format: date-time.

billing_contactsarray of objects or any or nullRequired

With with=details, the company's owners and then its billing contacts. Otherwise null.

billing_emailstring or nullRequired
billing_namestring or nullRequired
companyobjectRequired
Fields
idintegerRequired

At least 1.

namestringRequired
contractsarray of objectsRequired
Fields of each item
contractobjectRequired
Fields
billing_modelstringRequired

metered: billed by the hour.

billing_periodstringRequired
monthlyannual
billing_startsstringRequired

on_delivery while the site or CoreCluster is still being created: nothing is billed and the free trial has not started.

startedon_delivery
billing_starts_atstring or nullRequired

The first hour the contract bills from. null while on_delivery, and for an older contract, whose starts_on is its first day. Format: date-time.

billing_starts_notestring or nullRequired

While on_delivery, the sentence the Control Panel shows. Otherwise null.

first_billed_atstring or nullRequired

The first hour the contract was charged for. Format: date-time.

idintegerRequired

At least 1.

money_backobject or any or nullRequired

The money-back guarantee the contract was opened with, or null when it has none.

referencestringRequired
starts_onstring or nullRequired

Format: date.

statusstringRequired
draftactiveexpiredcancelled
trial_ends_atstring or nullRequired

Format: date-time.

hourlyobjectRequired

The price for one hour, with six decimal places.

Fields
amountstringRequired
currencystringRequired
idintegerRequired

At least 1.

kindstringRequired
packageaddonuat
labelstringRequired
modifiersarray of objectsRequired

What changes the line's price, such as the Performance server type or the region.

Fields of each item
keystringRequired
labelstringRequired
value_percentstringRequired
monthlyobjectRequired
Fields
amountstringRequired
currencystringRequired
productobjectRequired
Fields
linestringRequired

cs CoreStack, cc CoreCluster, cse CoreStack Enterprise.

cscccse
regionstring or nullRequired
server_typestringRequired
StandardPerformance
quantityintegerRequired
sincestring or nullRequired

Format: date-time.

subjectobjectRequired

What the line is for.

Fields
hrefstringRequired

Its page in the Control Panel, as a path.

refobjectRequired
Fields
idintegerRequired

At least 1.

namestringRequired
typestringRequired
sitecluster
unitstring or nullRequired

What one of quantity is, for an add-on (core or GB).

untilstring or nullRequired

When the line ends, for one that a change has replaced. null while it runs on. Format: date-time.

countriesarray of objects or any or nullRequired

With with=details, the countries the billing address may be in. Otherwise null.

currencystringRequired
currency_lockedbooleanRequired

Whether the currency is fixed. It is, from the account's first invoice.

default_methodobject or any or nullRequired

The card that is charged first, or null.

demosarray of objectsRequired

The demos billed to this account. A demo bills nothing until it is kept.

Fields of each item
ends_atstring or nullRequired

Format: date-time.

idintegerRequired

At least 1.

kept_atstring or nullRequired

Format: date-time.

statestringRequired
idintegerRequired

At least 1.

is_defaultbooleanRequired
mandateobject or any or nullRequired
monthly_totalobjectRequired

What every open contract line costs a month in all.

Fields
amountstringRequired
currencystringRequired
namestringRequired
next_invoiceobject or any or nullRequired

The next invoice, or null when none is due.

po_referencestring or nullRequired

The purchase order reference written on invoices.

rightsobjectRequired

What you may do with the account.

Fields
can_editbooleanRequired
can_paybooleanRequired

Whether you may pay an invoice. Paying is done in the Control Panel.

can_viewbooleanRequired
reasonstring or nullRequired

billing_forbidden when you may not read the account, else null.

trialobject or any or nullRequired

The account's free trial, or null.

vatobjectRequired

The VAT basis of the account.

Fields
buyerstring or nullRequired

Whether Corefinity has recorded the buyer as a business or a consumer, when it has.

checkobject or any or nullRequired

An open check of the account's VAT by Corefinity, or null.

countrystringRequired

The country VAT is judged for, as a two-letter code.

kindstringRequired

How VAT applies, such as standard, reverse_charge or outside_scope.

labelstringRequired

The basis in words, as invoices carry it.

rate_percentnumberRequired
validationobjectRequired
Fields
statestringRequired

The state of the VAT number. none: there is no number. pending: it is being checked. valid and invalid: the outcome. unverified: it could not be checked. not_applicable: numbers of that country are not checked.

validunverifiedinvalidnonenot_applicablepending
validated_atstring or nullRequired

Format: date-time.

vat_numberstring or nullRequired
versionintegerRequired

The version of the billing details. Send it back when you save the VAT number.

If it is refused

StatusReasonWhat to do
401noneSend a valid token as Authorization: Bearer <token>.
403billing_forbiddenBilling is for the organisation's owner and billing contacts. Ask one of them to do this.
403company_unavailableYour company is unavailable.
403scope_requiredUse a token with the scope named in scope.
403two_factor_requiredTurn on two-factor on your account, then send again.
404feature_offThis feature is not on for your organisation yet.
422invalidFix the field named in field; errors says why.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl https://manage.corefinity.com/api/corestack/billing/account \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json"
{
  "address": {
    "city": "Manchester",
    "country": "GB",
    "line1": "14 Quay Street",
    "line2": null,
    "postcode": "M1 1AA"
  },
  "auto_charge": true,
  "backup_method": null,
  "balance": {
    "accrued_this_period": {
      "amount": "337.10",
      "currency": "GBP"
    },
    "balance": {
      "amount": "1057.10",
      "currency": "GBP"
    },
    "credits_available": {
      "amount": "25.00",
      "currency": "GBP"
    },
    "currency": "GBP",
    "last_accrual_at": null,
    "lines": [
      {
        "accrued": {
          "amount": "337.10",
          "currency": "GBP"
        },
        "contract_line": {
          "id": 9001,
          "kind": "package",
          "label": "CC8"
        },
        "hourly": {
          "amount": "0.806452",
          "currency": "GBP"
        },
        "hours": 418,
        "monthly": {
          "amount": "600.00",
          "currency": "GBP"
        }
      }
    ],
    "next_invoice_at": "2027-02-01T00:30:00Z",
    "outstanding": {
      "amount": "720.00",
      "currency": "GBP"
    },
    "period": {
      "end": "2027-02-01T00:00:00Z",
      "start": "2027-01-01T00:00:00Z"
    },
    "recent_activity": [
      {
        "amount": {
          "amount": "337.10",
          "currency": "GBP"
        },
        "contract_id": 5120,
        "currency": "GBP",
        "kind": "usage_mtd",
        "product": "CC8 · Northwind UK 1",
        "through": null
      },
      {
        "amount": {
          "amount": "25.00",
          "currency": "GBP"
        },
        "at": "2027-01-12T14:20:00Z",
        "description": "Credit granted · Goodwill credit",
        "invoice": null,
        "kind": "credit_grant"
      },
      {
        "amount": {
          "amount": "720.00",
          "currency": "GBP"
        },
        "at": "2027-01-01T00:30:00Z",
        "description": "Invoice CF-100057",
        "invoice": {
          "id": 8140,
          "number": "CF-100057"
        },
        "kind": "invoice"
      },
      {
        "amount": {
          "amount": "-660.00",
          "currency": "GBP"
        },
        "at": "2026-12-01T00:31:12Z",
        "description": "Payment for CF-100042",
        "invoice": {
          "id": 8123,
          "number": "CF-100042"
        },
        "kind": "payment"
      },
      {
        "amount": {
          "amount": "-60.00",
          "currency": "GBP"
        },
        "at": "2026-12-01T00:30:00Z",
        "description": "Credit applied to CF-100042",
        "invoice": {
          "id": 8123,
          "number": "CF-100042"
        },
        "kind": "credit_applied"
      },
      {
        "amount": {
          "amount": "720.00",
          "currency": "GBP"
        },
        "at": "2026-12-01T00:30:00Z",
        "description": "Invoice CF-100042",
        "invoice": {
          "id": 8123,
          "number": "CF-100042"
        },
        "kind": "invoice"
      },
      {
        "amount": {
          "amount": "50.00",
          "currency": "GBP"
        },
        "at": "2026-11-01T09:00:00Z",
        "description": "Credit granted · Welcome credit",
        "invoice": null,
        "kind": "credit_grant"
      }
    ]
  },
  "billing_contacts": [
    {
      "email": "[email protected]",
      "id": 2051,
      "name": "Maya Okafor",
      "role": "owner"
    }
  ],
  "billing_email": "[email protected]",
  "billing_name": "Northwind Digital Ltd",
  "company": {
    "id": 1180,
    "name": "Northwind Digital"
  },
  "contracts": [
    {
      "contract": {
        "billing_model": "metered",
        "billing_period": "monthly",
        "billing_starts": "started",
        "billing_starts_at": "2026-11-01T01:00:00Z",
        "billing_starts_note": null,
        "first_billed_at": "2027-01-01T00:00:00Z",
        "id": 5120,
        "money_back": null,
        "reference": "MC-1180-1",
        "starts_on": "2026-11-01",
        "status": "active",
        "trial_ends_at": null
      },
      "hourly": {
        "amount": "0.806452",
        "currency": "GBP"
      },
      "id": 9001,
      "kind": "package",
      "label": "CC8 · Northwind UK 1",
      "modifiers": [],
      "monthly": {
        "amount": "600.00",
        "currency": "GBP"
      },
      "product": {
        "line": "cc",
        "region": "United Kingdom",
        "server_type": "Standard"
      },
      "quantity": 1,
      "since": "2026-11-01T01:00:00Z",
      "subject": {
        "href": "/managed-clusters/clusters/1017",
        "ref": {
          "id": 1017,
          "name": "Northwind UK 1"
        },
        "type": "cluster"
      },
      "unit": null,
      "until": null
    }
  ],
  "countries": [
    {
      "code": "GB",
      "name": "United Kingdom"
    },
    {
      "code": "IE",
      "name": "Ireland"
    },
    {
      "code": "US",
      "name": "United States"
    }
  ],
  "currency": "GBP",
  "currency_locked": false,
  "default_method": {
    "added_at": "2026-11-01T09:05:00Z",
    "brand": "visa",
    "exp_month": 12,
    "exp_year": 2030,
    "id": 4410,
    "kind": "card",
    "label": null,
    "last4": "4242",
    "provider": "stripe",
    "role": "primary",
    "state": "active",
    "wallet": null
  },
  "demos": [],
  "id": 3107,
  "is_default": true,
  "mandate": null,
  "monthly_total": {
    "amount": "600.00",
    "currency": "GBP"
  },
  "name": "Northwind Digital's default billing account",
  "next_invoice": {
    "estimate": {
      "amount": "937.10",
      "currency": "GBP"
    },
    "issues_at": "2027-02-01T00:30:00Z",
    "period_end": "2027-02-01T00:00:00Z",
    "trial": false
  },
  "po_reference": "PO-2027-014",
  "rights": {
    "can_edit": true,
    "can_pay": false,
    "can_view": true,
    "reason": null
  },
  "trial": null,
  "vat": {
    "buyer": null,
    "check": null,
    "country": "GB",
    "kind": "standard",
    "label": "UK VAT 20 %",
    "rate_percent": 20,
    "validation": {
      "state": "none",
      "validated_at": null
    }
  },
  "vat_number": null,
  "version": 1184934486
}
Try it
Held in this tab's memory only. Never stored or sent to us.

Use a token with only the read scope. How to make one

Was this helpful?
Open in ClaudeOpen in ChatGPT