## GET /v1/account/billing/credit-grants

List the credit added to your account and any reversals. The total is before usage. `GET /v1/account/budget` reports the available balance.

Required permissions: read:account.
API key: Supported.
CLI user token: Supported.
Session token: Requires the ellipsis:api scope, and the session's permissions.ellipsis rules must allow the operation.
Higher permission levels include lower levels: read < write < delete.

### Response

```text
{
  "grants": [
    {
      "amount": int,
      "category": str,
      "created_at": str,
      "id": str,
      "name": str,
      "source": str
    }
  ],
  "total_granted": int
}
```

### Python

```python
import os

from ellipsis import Ellipsis

client = Ellipsis(api_key=os.environ["ELLIPSIS_API_TOKEN"])

result = client.account.billing.grants()
print(result)
```

### TypeScript

```typescript
import { Ellipsis } from '@ellipsis-dev/sdk';

const client = new Ellipsis({
  apiKey: process.env.ELLIPSIS_API_TOKEN!,
});

const result = await client.account.billing.grants();
console.log(result);
```

### cURL

```bash
curl "https://api.ellipsis.dev/v1/account/billing/credit-grants" \
  -H "Authorization: Bearer $ELLIPSIS_API_TOKEN"
```

### Response schema

```json
{
  "properties": {
    "grants": {
      "items": {
        "properties": {
          "amount": {
            "type": "integer"
          },
          "category": {
            "enum": [
              "promotional",
              "paid"
            ],
            "type": "string"
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "source": {
            "enum": [
              "signup",
              "adhoc",
              "purchase",
              "auto_recharge",
              "migration",
              "refund_reversal",
              "yc_deal"
            ],
            "type": "string"
          }
        },
        "required": [
          "id",
          "created_at",
          "amount",
          "category",
          "source",
          "name"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "total_granted": {
      "type": "integer"
    }
  },
  "required": [
    "grants",
    "total_granted"
  ],
  "type": "object"
}
```
