"""Balance model — derived balance for an address."""

from typing import List

from pydantic import BaseModel, Field

from boxtime.models.node.asset import Asset


class Balance(BaseModel):
    """
    Derived balance for an address.

    Not a direct node schema — constructed by the client from unspent
    boxes.
    """

    nano_ergs: int = Field(alias="nanoErgs")
    tokens: List[Asset] = Field(default_factory=list)
