# Code generated by Lark OpenAPI.

from typing import Any, Optional, Union, Dict, List, Set, IO, Callable, Type
from lark_oapi.core.construct import init
from .user_info import UserInfo


class GetByCardUserMailboxMessageResponseBody(object):
    _types = {
        "owner_info": UserInfo,
        "message_ids": List[str],
        "card_id": str,
    }

    def __init__(self, d=None):
        self.owner_info: Optional[UserInfo] = None
        self.message_ids: Optional[List[str]] = None
        self.card_id: Optional[str] = None
        init(self, d, self._types)

    @staticmethod
    def builder() -> "GetByCardUserMailboxMessageResponseBodyBuilder":
        return GetByCardUserMailboxMessageResponseBodyBuilder()


class GetByCardUserMailboxMessageResponseBodyBuilder(object):
    def __init__(self) -> None:
        self._get_by_card_user_mailbox_message_response_body = GetByCardUserMailboxMessageResponseBody()

    def owner_info(self, owner_info: UserInfo) -> "GetByCardUserMailboxMessageResponseBodyBuilder":
        self._get_by_card_user_mailbox_message_response_body.owner_info = owner_info
        return self

    def message_ids(self, message_ids: List[str]) -> "GetByCardUserMailboxMessageResponseBodyBuilder":
        self._get_by_card_user_mailbox_message_response_body.message_ids = message_ids
        return self

    def card_id(self, card_id: str) -> "GetByCardUserMailboxMessageResponseBodyBuilder":
        self._get_by_card_user_mailbox_message_response_body.card_id = card_id
        return self

    def build(self) -> "GetByCardUserMailboxMessageResponseBody":
        return self._get_by_card_user_mailbox_message_response_body
