Skip to content
Luna
Esc
↑↓navigate↵open⌘Jpreview

Get the payment details

Returns the card on file and who is billed, as Stripe has them. Luna keeps neither. They are read from Stripe each time and changed in the billing portal.

GET/_luna/orgs/{org}/billing/details
Authorization
AuthorizationBearer token · headerrequired

An account key (la_…), an API key (lt_…) or a session token (ls_…). The scopes listed are the permissions the operation needs.

Scopes:billing:read
Path parameters
orgstringrequired

The organisation, by its slug.

Responses
200

The payment details.

billingstringrequired

stripe when the cluster bills through Stripe, off when it does not bill.

cardCardItem | null
Show properties
One of:
CardItem
brandstring | null

The card's brand, such as visa.

last4string | null

The last four digits of the card's number.

expMonthinteger<int32> | null
min 0
expYearinteger<int32> | null
min 0
null
null
detailsBilledTo | null
Show properties
One of:
BilledTo
namestring | null
emailstring | null
phonestring | null
addressBillingAddress | null
Show properties
One of:
BillingAddress
line1string | null
line2string | null
citystring | null
statestring | null
postalCodestring | null
countrystring | null

The country, as a two-letter code.

null
null
null
null
default

The request failed. The status says how and error.message says why.

errorErrorDetailrequired
Show properties
codestring | null

A code for programs to branch on, when the error has one.

messagestringrequired

What went wrong, in a sentence a person can read.

Try it
Server
Authorization
Parameters
Request
curl -X GET 'https://luna.example.com/_luna/orgs/string/billing/details' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json'
Response
{
  "billing": "string",
  "card": {
    "brand": "string",
    "last4": "string",
    "expMonth": 0,
    "expYear": 0
  },
  "details": {
    "name": "string",
    "email": "string",
    "phone": "string",
    "address": {
      "line1": "string",
      "line2": "string",
      "city": "string",
      "state": "string",
      "postalCode": "string",
      "country": "string"
    }
  }
}

Was this page helpful?