Documentation for 4.0 (pre-release). Using 3.x? See the README on main.
Skip to content

Currencies (Währungen) ​

Read-only API wrapper for the Billomat currency list at /currencies.

Access ​

php
$billomat->currencies

Justpilot\Billomat\Api\CurrenciesApi, created lazily on first access to $billomat->currencies.

Endpoints ​

MethodHTTPPath
list()GET/currencies
listPage()GET/currencies (page with metadata)
iterateAll()GET/currencies (lazy over all pages)

Fetching a single currency by ID (GET /currencies/{id}) is not implemented in the SDK; the list endpoint supports the filter code for ISO currency codes.

Methods ​

list(): list<Currency> ​

Lists all currencies.

php
$currencies = $billomat->currencies->list();

foreach ($currencies as $currency) {
    echo $currency->code . ': ' . $currency->name . PHP_EOL;
}

list() takes no filters. To look up a single currency (e.g. EUR), pass code to listPage() or filter the list on the client side:

php
$page = $billomat->currencies->listPage(['code' => 'EUR']);
$eur  = $page->items[0] ?? null;

Exceptions: AuthenticationException, HttpException.

listPage(array $filters = []): Page<Currency> ​

Like list(), with pagination metadata (page, perPage, total) in $page->info.

iterateAll(array $filters = [], int $pageSize = 100): Generator<int, Currency> ​

Lazy iteration over all pages.

Read model: Currency ​

final readonly class Justpilot\Billomat\Model\Currency

PropertyTypeMapping
codestringcode (fallback: currency_code)
name?stringname
symbol?stringsymbol
id?intid
extraarray<string,mixed>Fields the SDK doesn't map yet, raw (see Read models)

Currency::fromArray($data) hydrates from the wire format; Currency::toArray() writes snake_case back.

Unofficial SDK, not affiliated with Billomat GmbH. Released under the Apache License 2.0.