"""Pydantic models for GA4GH refget v2."""

from __future__ import annotations

from ai4gh.core.types import GA4GHBase


class RefgetMetadata(GA4GHBase):
    """Refget sequence metadata."""

    id: str
    md5: str | None = None
    trunc512: str | None = None
    ga4gh: str | None = None
    length: int
    aliases: list[RefgetAlias] | None = None


class RefgetAlias(GA4GHBase):
    """Refget sequence alias."""

    alias: str
    naming_authority: str


# Forward ref update
RefgetMetadata.model_rebuild()
