<?php

namespace Alsendo\AlsendoWrapper\Api\Zaslat\Model;

class AddressBookListResponse
{
    /** @var array<string, ZaslatAddressBook> */
    public array $addresses = [];

    public function __construct(array $addresses = [])
    {
        $this->addresses = $addresses;
    }

    public function get(string $addressId): ?ZaslatAddressBook
    {
        return $this->addresses[$addressId] ?? null;
    }
}
