---
title: "The billing methods an organization can choose"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Billing API › Billing

`GET /v1/billing-methods`

## Authentication

Requires one of the following:

- `oauth`, http, header `Authorization`
- `sessionCookie`, apiKey, in cookie

## Code samples

### cURL

```curl
curl --request GET \
  --url https://billing.ezghcloud.com/v1/billing-methods \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://billing.ezghcloud.com/v1/billing-methods';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://billing.ezghcloud.com/v1/billing-methods"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

OK

#### Example

```json
{
  "methods": [
    {
      "id": "string",
      "name": "string"
    }
  ],
  "default": "string"
}
```

- `ListBillingMethods.response.200.methods` (array<object>, required)
  - `ListBillingMethods.response.200.methods.id` (string, required)
  - `ListBillingMethods.response.200.methods.name` (string, required)
- `ListBillingMethods.response.200.default` (string, required) — The method an organization gets when it doesn't choose one.

### 401

unauthenticated: no valid credential.

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "issues": [
      {
        "path": "string",
        "message": "string"
      }
    ]
  }
}
```

- `ListBillingMethods.response.401.error` (object, required)
  - `ListBillingMethods.response.401.error.code` (string, required) — What went wrong, for programs: branch on this, never on message.
  - `ListBillingMethods.response.401.error.message` (string, required) — What went wrong, for people.
  - `ListBillingMethods.response.401.error.issues` (array<object>, optional) — With invalid_request: each invalid field.
    - `ListBillingMethods.response.401.error.issues.path` (string, required)
    - `ListBillingMethods.response.401.error.issues.message` (string, required)

### 429

too_many_requests: slow down.

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "issues": [
      {
        "path": "string",
        "message": "string"
      }
    ]
  }
}
```

- `ListBillingMethods.response.429.error` (object, required)
  - `ListBillingMethods.response.429.error.code` (string, required) — What went wrong, for programs: branch on this, never on message.
  - `ListBillingMethods.response.429.error.message` (string, required) — What went wrong, for people.
  - `ListBillingMethods.response.429.error.issues` (array<object>, optional) — With invalid_request: each invalid field.
    - `ListBillingMethods.response.429.error.issues.path` (string, required)
    - `ListBillingMethods.response.429.error.issues.message` (string, required)

### 500

internal_error: a bug; the details are in the logs, under the request ID.

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "issues": [
      {
        "path": "string",
        "message": "string"
      }
    ]
  }
}
```

- `ListBillingMethods.response.500.error` (object, required)
  - `ListBillingMethods.response.500.error.code` (string, required) — What went wrong, for programs: branch on this, never on message.
  - `ListBillingMethods.response.500.error.message` (string, required) — What went wrong, for people.
  - `ListBillingMethods.response.500.error.issues` (array<object>, optional) — With invalid_request: each invalid field.
    - `ListBillingMethods.response.500.error.issues.path` (string, required)
    - `ListBillingMethods.response.500.error.issues.message` (string, required)

### 503

unavailable, ledger_unavailable or payments_unavailable: retry later.

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "issues": [
      {
        "path": "string",
        "message": "string"
      }
    ]
  }
}
```

- `ListBillingMethods.response.503.error` (object, required)
  - `ListBillingMethods.response.503.error.code` (string, required) — What went wrong, for programs: branch on this, never on message.
  - `ListBillingMethods.response.503.error.message` (string, required) — What went wrong, for people.
  - `ListBillingMethods.response.503.error.issues` (array<object>, optional) — With invalid_request: each invalid field.
    - `ListBillingMethods.response.503.error.issues.path` (string, required)
    - `ListBillingMethods.response.503.error.issues.message` (string, required)


Source: https://docs.ezghcloud.com/billing-api/Billing/ListBillingMethods/index.md
