---
title: "List available credit packages"
method: GET
path: "/credits/packages"
tags: ["Credits"]
---

# List available credit packages

`GET /credits/packages`

## Request

- Base URL: `https://api.faireplace.com/api`
- URL: `https://api.faireplace.com/api/credits/packages`
- Auth: HTTP bearer

Retrieves the list of credit packages available for purchase for the tenant.

## Filtering

By default, only **active** packages are returned.
To include inactive packages, use `active_only=false`.

## Sorting

Packages are sorted by:
1. `display_order` ascending (configured display order)
2. Creation date ascending (in case of `display_order` tie)

## Multi-Tenant Isolation

The returned packages are automatically filtered by:
- `tenant_id` extracted from the JWT

Each tenant can have its own configured credit packages.

## Prerequisites for Purchase

For a package to be purchasable, it must:
- Be **active** (`active: true`)
- Have a **stripe_price_id** configured
- Belong to the user's tenant

## Usage Example

```bash
# List only active packages (default)
curl -X GET "https://api.faireplace.com/v1/credits/packages" \
  -H "Authorization: Bearer YOUR_API_KEY"

# List all packages (active and inactive)
curl -X GET "https://api.faireplace.com/v1/credits/packages?active_only=false" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

**Response**:
```json
{
  "packages": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "name": "Pack Starter",
      "description": "Starter pack ideal for small landlords",
      "credits_amount": 1000,
      "price_cents": 2990,
      "active": true,
      "display_order": 1
    },
    {
      "id": "550e8400-e29b-41d4-a716-446655440001",
      "name": "Pack Pro",
      "description": "Professional pack for active landlords",
      "credits_amount": 5000,
      "price_cents": 12990,
      "active": true,
      "display_order": 2
    },
    {
      "id": "550e8400-e29b-41d4-a716-446655440002",
      "name": "Pack Business",
      "description": "Business pack for large portfolio owners",
      "credits_amount": 20000,
      "price_cents": 49990,
      "active": true,
      "display_order": 3
    }
  ]
}
```

## Query parameters

- `active_only` boolean

## Response `200`

Package list retrieved successfully.

Always returns an array (empty if no packages are configured for the tenant).

- CreditPackagesResponse: Response containing the list of available credit packages.
  - `packages` CreditPackage[], required: List of packages, sorted by `display_order` ascending, then by creation date.
    - `id` string, uuid, required: Unique package identifier.
    - `name` string, required: Package name (e.g., "Pack Starter", "Pack Pro", "Pack Business").
    - `description` string, nullable: Detailed package description.
    - `credits_amount` integer, required: Number of credits included in the package (in cents). **Examples**: - `1000` = 10.00 EUR in credits - `5000` = 50.00 EUR in credits - `20000` = 200.00 EUR in credits
    - `price_cents` integer, required: Package price in euro cents. **Examples**: - `2990` = 29.90 EUR - `12990` = 129.90 EUR - `49990` = 499.90 EUR
    - `active` boolean, required: Indicates whether the package is currently available for purchase. Inactive packages are not returned by default in the list (unless `active_only=false` is specified).
    - `display_order` integer, required: Display order of the package in the list. Packages are sorted by `display_order` ascending, then by creation date. Default value: `0`

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `500`: Internal Server Error

---

[API](https://skmtc.dev/faireplace/apis/faireplace-property-management-api.md) · [All operations](https://skmtc.dev/faireplace/apis/faireplace-property-management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/faireplace/apis/faireplace-property-management-api/revisions/69de39762919?raw)
