Credits

Get credit balance

Retrieves the current credit balance of the authenticated user.

Behavior

  • If the user has never had credits, returns a balance of 0 (no 404 error)
  • The balance is always expressed in euro cents
  • The currency is always EUR for now

Multi-Tenant Isolation

The returned balance is automatically filtered by:

  • tenant_id extracted from the JWT
  • user_id extracted from the JWT (claim sub)

A user can only see their own balance, and only within their tenant.

Balance Format

The balance is returned in cents:

  • 5000 = 50.00 EUR of available credits
  • 2990 = 29.90 EUR of available credits
  • 0 = No credits available

Usage Example

curl -X GET https://api.faireplace.com/v1/credits/balance \
  -H "Authorization: Bearer YOUR_API_KEY"

Response:

{
  "balance": 5000,
  "currency": "EUR",
  "last_updated": "2026-01-28T10:30:00Z"
}
get/credits/balance

Request

  • Base URL: https://api.faireplace.com/api
  • URL: https://api.faireplace.com/api/credits/balance
  • Auth: HTTP bearer

Response

Balance retrieved successfully.

Always returns a balance (0 if the user has never had credits).

balanceinteger required

Credit balance in euro cents.

Examples:

  • 5000 = 50.00 EUR in credits
  • 2990 = 29.90 EUR in credits
  • 0 = No credits available
currency'EUR' required

Balance currency (always "EUR" for now).

last_updatedstring date-time nullable

Date and time of the last balance update (ISO 8601).

Format: YYYY-MM-DDTHH:mm:ssZ

Example response

{
  "balance": 5000,
  "currency": "EUR",
  "last_updated": "2026-01-28T10:30:00Z"
}

Changes

No recorded changes to this operation across all 1 revision of this API.