from typing import Optional

from pydantic import BaseModel, Field


class GetFileUrlResponse(BaseModel):
    """Response model for getting a refreshed file URL.

    This class contains the unique identifier and a refreshed signed URL
    for an existing attachment, providing time-limited access to download
    the attachment.

    Attributes:
        id: The unique identifier of the attachment
        signed_url: A refreshed signed URL of the attachment in storage
    """

    id: Optional[str] = None
    signed_url: Optional[str] = Field(None, alias="signedUrl")
