miro_api.models.board

Miro Developer Platform

### Miro Developer Platform concepts - New to the Miro Developer Platform? Interested in learning more about platform concepts?? Read our introduction page and familiarize yourself with the Miro Developer Platform capabilities in a few minutes. ### Getting started with the Miro REST API - Quickstart (video): try the REST API in less than 3 minutes. - Quickstart (article): get started and try the REST API in less than 3 minutes. ### Miro REST API tutorials Check out our how-to articles with step-by-step instructions and code examples so you can: - Get started with OAuth 2.0 and Miro ### Miro App Examples Clone our Miro App Examples repository to get inspiration, customize, and explore apps built on top of Miro's Developer Platform 2.0.

The version of the OpenAPI document: v2.0 Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.

  1# coding: utf-8
  2
  3"""
  4Miro Developer Platform
  5
  6<img src=\"https://content.pstmn.io/47449ea6-0ef7-4af2-bac1-e58a70e61c58/aW1hZ2UucG5n\" width=\"1685\" height=\"593\">  ### Miro Developer Platform concepts  - New to the Miro Developer Platform? Interested in learning more about platform concepts?? [Read our introduction page](https://beta.developers.miro.com/docs/introduction) and familiarize yourself with the Miro Developer Platform capabilities in a few minutes.   ### Getting started with the Miro REST API  - [Quickstart (video):](https://beta.developers.miro.com/docs/try-out-the-rest-api-in-less-than-3-minutes) try the REST API in less than 3 minutes. - [Quickstart (article):](https://beta.developers.miro.com/docs/build-your-first-hello-world-app-1) get started and try the REST API in less than 3 minutes.   ### Miro REST API tutorials  Check out our how-to articles with step-by-step instructions and code examples so you can:  - [Get started with OAuth 2.0 and Miro](https://beta.developers.miro.com/docs/getting-started-with-oauth)   ### Miro App Examples  Clone our [Miro App Examples repository](https://github.com/miroapp/app-examples) to get inspiration, customize, and explore apps built on top of Miro's Developer Platform 2.0.
  7
  8The version of the OpenAPI document: v2.0
  9Generated by OpenAPI Generator (https://openapi-generator.tech)
 10
 11Do not edit the class manually.
 12"""  # noqa: E501
 13
 14from __future__ import annotations
 15import pprint
 16import re  # noqa: F401
 17import json
 18
 19from datetime import datetime
 20from pydantic import BaseModel, Field, StrictStr
 21from typing import Any, ClassVar, Dict, List, Optional
 22from miro_api.models.board_member import BoardMember
 23from miro_api.models.board_policy import BoardPolicy
 24from miro_api.models.board_project import BoardProject
 25from miro_api.models.picture import Picture
 26from miro_api.models.team import Team
 27from miro_api.models.user_info_last_opened_by import UserInfoLastOpenedBy
 28from miro_api.models.user_info_short import UserInfoShort
 29from typing import Optional, Set
 30from typing_extensions import Self
 31
 32
 33class Board(BaseModel):
 34    """
 35    Contains the result data.
 36    """  # noqa: E501
 37
 38    created_at: Optional[datetime] = Field(
 39        default=None,
 40        description="Date and time when the board was created. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 41        alias="createdAt",
 42    )
 43    created_by: Optional[UserInfoShort] = Field(default=None, alias="createdBy")
 44    current_user_membership: Optional[BoardMember] = Field(default=None, alias="currentUserMembership")
 45    description: StrictStr = Field(description="Description of the board.")
 46    id: StrictStr = Field(description="Unique identifier (ID) of the board.")
 47    last_opened_at: Optional[datetime] = Field(
 48        default=None,
 49        description="Date and time when the board was last opened by any user. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 50        alias="lastOpenedAt",
 51    )
 52    last_opened_by: Optional[UserInfoLastOpenedBy] = Field(default=None, alias="lastOpenedBy")
 53    modified_at: Optional[datetime] = Field(
 54        default=None,
 55        description="Date and time when the board was last modified. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 56        alias="modifiedAt",
 57    )
 58    modified_by: Optional[UserInfoShort] = Field(default=None, alias="modifiedBy")
 59    name: StrictStr = Field(description="Name of the board.")
 60    owner: Optional[UserInfoShort] = None
 61    picture: Optional[Picture] = None
 62    policy: Optional[BoardPolicy] = None
 63    team: Optional[Team] = None
 64    project: Optional[BoardProject] = None
 65    type: StrictStr = Field(description="Type of the object that is returned. In this case, type returns `board`.")
 66    view_link: Optional[StrictStr] = Field(default=None, description="URL to view the board.", alias="viewLink")
 67    additional_properties: Dict[str, Any] = {}
 68    __properties: ClassVar[List[str]] = [
 69        "createdAt",
 70        "createdBy",
 71        "currentUserMembership",
 72        "description",
 73        "id",
 74        "lastOpenedAt",
 75        "lastOpenedBy",
 76        "modifiedAt",
 77        "modifiedBy",
 78        "name",
 79        "owner",
 80        "picture",
 81        "policy",
 82        "team",
 83        "project",
 84        "type",
 85        "viewLink",
 86    ]
 87
 88    model_config = {
 89        "populate_by_name": True,
 90        "validate_assignment": True,
 91        "protected_namespaces": (),
 92    }
 93
 94    def to_str(self) -> str:
 95        """Returns the string representation of the model using alias"""
 96        return pprint.pformat(self.model_dump(by_alias=True))
 97
 98    def to_json(self) -> str:
 99        """Returns the JSON representation of the model using alias"""
100        # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
101        return json.dumps(self.to_dict())
102
103    @classmethod
104    def from_json(cls, json_str: str) -> Optional[Self]:
105        """Create an instance of Board from a JSON string"""
106        return cls.from_dict(json.loads(json_str))
107
108    def to_dict(self) -> Dict[str, Any]:
109        """Return the dictionary representation of the model using alias.
110
111        This has the following differences from calling pydantic's
112        `self.model_dump(by_alias=True)`:
113
114        * `None` is only added to the output dict for nullable fields that
115          were set at model initialization. Other fields with value `None`
116          are ignored.
117        * Fields in `self.additional_properties` are added to the output dict.
118        """
119        excluded_fields: Set[str] = set(
120            [
121                "additional_properties",
122            ]
123        )
124
125        _dict = self.model_dump(
126            by_alias=True,
127            exclude=excluded_fields,
128            exclude_none=True,
129        )
130        # override the default output from pydantic by calling `to_dict()` of created_by
131        if self.created_by:
132            _dict["createdBy"] = self.created_by.to_dict()
133        # override the default output from pydantic by calling `to_dict()` of current_user_membership
134        if self.current_user_membership:
135            _dict["currentUserMembership"] = self.current_user_membership.to_dict()
136        # override the default output from pydantic by calling `to_dict()` of last_opened_by
137        if self.last_opened_by:
138            _dict["lastOpenedBy"] = self.last_opened_by.to_dict()
139        # override the default output from pydantic by calling `to_dict()` of modified_by
140        if self.modified_by:
141            _dict["modifiedBy"] = self.modified_by.to_dict()
142        # override the default output from pydantic by calling `to_dict()` of owner
143        if self.owner:
144            _dict["owner"] = self.owner.to_dict()
145        # override the default output from pydantic by calling `to_dict()` of picture
146        if self.picture:
147            _dict["picture"] = self.picture.to_dict()
148        # override the default output from pydantic by calling `to_dict()` of policy
149        if self.policy:
150            _dict["policy"] = self.policy.to_dict()
151        # override the default output from pydantic by calling `to_dict()` of team
152        if self.team:
153            _dict["team"] = self.team.to_dict()
154        # override the default output from pydantic by calling `to_dict()` of project
155        if self.project:
156            _dict["project"] = self.project.to_dict()
157        # puts key-value pairs in additional_properties in the top level
158        if self.additional_properties is not None:
159            for _key, _value in self.additional_properties.items():
160                _dict[_key] = _value
161
162        return _dict
163
164    @classmethod
165    def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
166        """Create an instance of Board from a dict"""
167        if obj is None:
168            return None
169
170        if not isinstance(obj, dict):
171            return cls.model_validate(obj)
172
173        _obj = cls.model_validate(
174            {
175                "createdAt": obj.get("createdAt"),
176                "createdBy": UserInfoShort.from_dict(obj["createdBy"]) if obj.get("createdBy") is not None else None,
177                "currentUserMembership": (
178                    BoardMember.from_dict(obj["currentUserMembership"])
179                    if obj.get("currentUserMembership") is not None
180                    else None
181                ),
182                "description": obj.get("description"),
183                "id": obj.get("id"),
184                "lastOpenedAt": obj.get("lastOpenedAt"),
185                "lastOpenedBy": (
186                    UserInfoLastOpenedBy.from_dict(obj["lastOpenedBy"]) if obj.get("lastOpenedBy") is not None else None
187                ),
188                "modifiedAt": obj.get("modifiedAt"),
189                "modifiedBy": UserInfoShort.from_dict(obj["modifiedBy"]) if obj.get("modifiedBy") is not None else None,
190                "name": obj.get("name"),
191                "owner": UserInfoShort.from_dict(obj["owner"]) if obj.get("owner") is not None else None,
192                "picture": Picture.from_dict(obj["picture"]) if obj.get("picture") is not None else None,
193                "policy": BoardPolicy.from_dict(obj["policy"]) if obj.get("policy") is not None else None,
194                "team": Team.from_dict(obj["team"]) if obj.get("team") is not None else None,
195                "project": BoardProject.from_dict(obj["project"]) if obj.get("project") is not None else None,
196                "type": obj.get("type"),
197                "viewLink": obj.get("viewLink"),
198            }
199        )
200        # store additional fields in additional_properties
201        for _key in obj.keys():
202            if _key not in cls.__properties:
203                _obj.additional_properties[_key] = obj.get(_key)
204
205        return _obj
class Board(pydantic.main.BaseModel):
 34class Board(BaseModel):
 35    """
 36    Contains the result data.
 37    """  # noqa: E501
 38
 39    created_at: Optional[datetime] = Field(
 40        default=None,
 41        description="Date and time when the board was created. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 42        alias="createdAt",
 43    )
 44    created_by: Optional[UserInfoShort] = Field(default=None, alias="createdBy")
 45    current_user_membership: Optional[BoardMember] = Field(default=None, alias="currentUserMembership")
 46    description: StrictStr = Field(description="Description of the board.")
 47    id: StrictStr = Field(description="Unique identifier (ID) of the board.")
 48    last_opened_at: Optional[datetime] = Field(
 49        default=None,
 50        description="Date and time when the board was last opened by any user. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 51        alias="lastOpenedAt",
 52    )
 53    last_opened_by: Optional[UserInfoLastOpenedBy] = Field(default=None, alias="lastOpenedBy")
 54    modified_at: Optional[datetime] = Field(
 55        default=None,
 56        description="Date and time when the board was last modified. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).",
 57        alias="modifiedAt",
 58    )
 59    modified_by: Optional[UserInfoShort] = Field(default=None, alias="modifiedBy")
 60    name: StrictStr = Field(description="Name of the board.")
 61    owner: Optional[UserInfoShort] = None
 62    picture: Optional[Picture] = None
 63    policy: Optional[BoardPolicy] = None
 64    team: Optional[Team] = None
 65    project: Optional[BoardProject] = None
 66    type: StrictStr = Field(description="Type of the object that is returned. In this case, type returns `board`.")
 67    view_link: Optional[StrictStr] = Field(default=None, description="URL to view the board.", alias="viewLink")
 68    additional_properties: Dict[str, Any] = {}
 69    __properties: ClassVar[List[str]] = [
 70        "createdAt",
 71        "createdBy",
 72        "currentUserMembership",
 73        "description",
 74        "id",
 75        "lastOpenedAt",
 76        "lastOpenedBy",
 77        "modifiedAt",
 78        "modifiedBy",
 79        "name",
 80        "owner",
 81        "picture",
 82        "policy",
 83        "team",
 84        "project",
 85        "type",
 86        "viewLink",
 87    ]
 88
 89    model_config = {
 90        "populate_by_name": True,
 91        "validate_assignment": True,
 92        "protected_namespaces": (),
 93    }
 94
 95    def to_str(self) -> str:
 96        """Returns the string representation of the model using alias"""
 97        return pprint.pformat(self.model_dump(by_alias=True))
 98
 99    def to_json(self) -> str:
100        """Returns the JSON representation of the model using alias"""
101        # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
102        return json.dumps(self.to_dict())
103
104    @classmethod
105    def from_json(cls, json_str: str) -> Optional[Self]:
106        """Create an instance of Board from a JSON string"""
107        return cls.from_dict(json.loads(json_str))
108
109    def to_dict(self) -> Dict[str, Any]:
110        """Return the dictionary representation of the model using alias.
111
112        This has the following differences from calling pydantic's
113        `self.model_dump(by_alias=True)`:
114
115        * `None` is only added to the output dict for nullable fields that
116          were set at model initialization. Other fields with value `None`
117          are ignored.
118        * Fields in `self.additional_properties` are added to the output dict.
119        """
120        excluded_fields: Set[str] = set(
121            [
122                "additional_properties",
123            ]
124        )
125
126        _dict = self.model_dump(
127            by_alias=True,
128            exclude=excluded_fields,
129            exclude_none=True,
130        )
131        # override the default output from pydantic by calling `to_dict()` of created_by
132        if self.created_by:
133            _dict["createdBy"] = self.created_by.to_dict()
134        # override the default output from pydantic by calling `to_dict()` of current_user_membership
135        if self.current_user_membership:
136            _dict["currentUserMembership"] = self.current_user_membership.to_dict()
137        # override the default output from pydantic by calling `to_dict()` of last_opened_by
138        if self.last_opened_by:
139            _dict["lastOpenedBy"] = self.last_opened_by.to_dict()
140        # override the default output from pydantic by calling `to_dict()` of modified_by
141        if self.modified_by:
142            _dict["modifiedBy"] = self.modified_by.to_dict()
143        # override the default output from pydantic by calling `to_dict()` of owner
144        if self.owner:
145            _dict["owner"] = self.owner.to_dict()
146        # override the default output from pydantic by calling `to_dict()` of picture
147        if self.picture:
148            _dict["picture"] = self.picture.to_dict()
149        # override the default output from pydantic by calling `to_dict()` of policy
150        if self.policy:
151            _dict["policy"] = self.policy.to_dict()
152        # override the default output from pydantic by calling `to_dict()` of team
153        if self.team:
154            _dict["team"] = self.team.to_dict()
155        # override the default output from pydantic by calling `to_dict()` of project
156        if self.project:
157            _dict["project"] = self.project.to_dict()
158        # puts key-value pairs in additional_properties in the top level
159        if self.additional_properties is not None:
160            for _key, _value in self.additional_properties.items():
161                _dict[_key] = _value
162
163        return _dict
164
165    @classmethod
166    def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
167        """Create an instance of Board from a dict"""
168        if obj is None:
169            return None
170
171        if not isinstance(obj, dict):
172            return cls.model_validate(obj)
173
174        _obj = cls.model_validate(
175            {
176                "createdAt": obj.get("createdAt"),
177                "createdBy": UserInfoShort.from_dict(obj["createdBy"]) if obj.get("createdBy") is not None else None,
178                "currentUserMembership": (
179                    BoardMember.from_dict(obj["currentUserMembership"])
180                    if obj.get("currentUserMembership") is not None
181                    else None
182                ),
183                "description": obj.get("description"),
184                "id": obj.get("id"),
185                "lastOpenedAt": obj.get("lastOpenedAt"),
186                "lastOpenedBy": (
187                    UserInfoLastOpenedBy.from_dict(obj["lastOpenedBy"]) if obj.get("lastOpenedBy") is not None else None
188                ),
189                "modifiedAt": obj.get("modifiedAt"),
190                "modifiedBy": UserInfoShort.from_dict(obj["modifiedBy"]) if obj.get("modifiedBy") is not None else None,
191                "name": obj.get("name"),
192                "owner": UserInfoShort.from_dict(obj["owner"]) if obj.get("owner") is not None else None,
193                "picture": Picture.from_dict(obj["picture"]) if obj.get("picture") is not None else None,
194                "policy": BoardPolicy.from_dict(obj["policy"]) if obj.get("policy") is not None else None,
195                "team": Team.from_dict(obj["team"]) if obj.get("team") is not None else None,
196                "project": BoardProject.from_dict(obj["project"]) if obj.get("project") is not None else None,
197                "type": obj.get("type"),
198                "viewLink": obj.get("viewLink"),
199            }
200        )
201        # store additional fields in additional_properties
202        for _key in obj.keys():
203            if _key not in cls.__properties:
204                _obj.additional_properties[_key] = obj.get(_key)
205
206        return _obj

Contains the result data.

created_at: Optional[datetime.datetime]
current_user_membership: Optional[miro_api.models.board_member.BoardMember]
description: typing.Annotated[str, Strict(strict=True)]
id: typing.Annotated[str, Strict(strict=True)]
last_opened_at: Optional[datetime.datetime]
modified_at: Optional[datetime.datetime]
name: typing.Annotated[str, Strict(strict=True)]
picture: Optional[miro_api.models.picture.Picture]
team: Optional[miro_api.models.team.Team]
type: typing.Annotated[str, Strict(strict=True)]
additional_properties: Dict[str, Any]
model_config = {'populate_by_name': True, 'validate_assignment': True, 'protected_namespaces': ()}
def to_str(self) -> str:
95    def to_str(self) -> str:
96        """Returns the string representation of the model using alias"""
97        return pprint.pformat(self.model_dump(by_alias=True))

Returns the string representation of the model using alias

def to_json(self) -> str:
 99    def to_json(self) -> str:
100        """Returns the JSON representation of the model using alias"""
101        # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
102        return json.dumps(self.to_dict())

Returns the JSON representation of the model using alias

@classmethod
def from_json(cls, json_str: str) -> Optional[typing_extensions.Self]:
104    @classmethod
105    def from_json(cls, json_str: str) -> Optional[Self]:
106        """Create an instance of Board from a JSON string"""
107        return cls.from_dict(json.loads(json_str))

Create an instance of Board from a JSON string

def to_dict(self) -> Dict[str, Any]:
109    def to_dict(self) -> Dict[str, Any]:
110        """Return the dictionary representation of the model using alias.
111
112        This has the following differences from calling pydantic's
113        `self.model_dump(by_alias=True)`:
114
115        * `None` is only added to the output dict for nullable fields that
116          were set at model initialization. Other fields with value `None`
117          are ignored.
118        * Fields in `self.additional_properties` are added to the output dict.
119        """
120        excluded_fields: Set[str] = set(
121            [
122                "additional_properties",
123            ]
124        )
125
126        _dict = self.model_dump(
127            by_alias=True,
128            exclude=excluded_fields,
129            exclude_none=True,
130        )
131        # override the default output from pydantic by calling `to_dict()` of created_by
132        if self.created_by:
133            _dict["createdBy"] = self.created_by.to_dict()
134        # override the default output from pydantic by calling `to_dict()` of current_user_membership
135        if self.current_user_membership:
136            _dict["currentUserMembership"] = self.current_user_membership.to_dict()
137        # override the default output from pydantic by calling `to_dict()` of last_opened_by
138        if self.last_opened_by:
139            _dict["lastOpenedBy"] = self.last_opened_by.to_dict()
140        # override the default output from pydantic by calling `to_dict()` of modified_by
141        if self.modified_by:
142            _dict["modifiedBy"] = self.modified_by.to_dict()
143        # override the default output from pydantic by calling `to_dict()` of owner
144        if self.owner:
145            _dict["owner"] = self.owner.to_dict()
146        # override the default output from pydantic by calling `to_dict()` of picture
147        if self.picture:
148            _dict["picture"] = self.picture.to_dict()
149        # override the default output from pydantic by calling `to_dict()` of policy
150        if self.policy:
151            _dict["policy"] = self.policy.to_dict()
152        # override the default output from pydantic by calling `to_dict()` of team
153        if self.team:
154            _dict["team"] = self.team.to_dict()
155        # override the default output from pydantic by calling `to_dict()` of project
156        if self.project:
157            _dict["project"] = self.project.to_dict()
158        # puts key-value pairs in additional_properties in the top level
159        if self.additional_properties is not None:
160            for _key, _value in self.additional_properties.items():
161                _dict[_key] = _value
162
163        return _dict

Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic's self.model_dump(by_alias=True):

  • None is only added to the output dict for nullable fields that were set at model initialization. Other fields with value None are ignored.
  • Fields in self.additional_properties are added to the output dict.
@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[typing_extensions.Self]:
165    @classmethod
166    def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
167        """Create an instance of Board from a dict"""
168        if obj is None:
169            return None
170
171        if not isinstance(obj, dict):
172            return cls.model_validate(obj)
173
174        _obj = cls.model_validate(
175            {
176                "createdAt": obj.get("createdAt"),
177                "createdBy": UserInfoShort.from_dict(obj["createdBy"]) if obj.get("createdBy") is not None else None,
178                "currentUserMembership": (
179                    BoardMember.from_dict(obj["currentUserMembership"])
180                    if obj.get("currentUserMembership") is not None
181                    else None
182                ),
183                "description": obj.get("description"),
184                "id": obj.get("id"),
185                "lastOpenedAt": obj.get("lastOpenedAt"),
186                "lastOpenedBy": (
187                    UserInfoLastOpenedBy.from_dict(obj["lastOpenedBy"]) if obj.get("lastOpenedBy") is not None else None
188                ),
189                "modifiedAt": obj.get("modifiedAt"),
190                "modifiedBy": UserInfoShort.from_dict(obj["modifiedBy"]) if obj.get("modifiedBy") is not None else None,
191                "name": obj.get("name"),
192                "owner": UserInfoShort.from_dict(obj["owner"]) if obj.get("owner") is not None else None,
193                "picture": Picture.from_dict(obj["picture"]) if obj.get("picture") is not None else None,
194                "policy": BoardPolicy.from_dict(obj["policy"]) if obj.get("policy") is not None else None,
195                "team": Team.from_dict(obj["team"]) if obj.get("team") is not None else None,
196                "project": BoardProject.from_dict(obj["project"]) if obj.get("project") is not None else None,
197                "type": obj.get("type"),
198                "viewLink": obj.get("viewLink"),
199            }
200        )
201        # store additional fields in additional_properties
202        for _key in obj.keys():
203            if _key not in cls.__properties:
204                _obj.additional_properties[_key] = obj.get(_key)
205
206        return _obj

Create an instance of Board from a dict

def model_post_init(self: pydantic.main.BaseModel, __context: Any) -> None:
265def init_private_attributes(self: BaseModel, __context: Any) -> None:
266    """This function is meant to behave like a BaseModel method to initialise private attributes.
267
268    It takes context as an argument since that's what pydantic-core passes when calling it.
269
270    Args:
271        self: The BaseModel instance.
272        __context: The context.
273    """
274    if getattr(self, '__pydantic_private__', None) is None:
275        pydantic_private = {}
276        for name, private_attr in self.__private_attributes__.items():
277            default = private_attr.get_default()
278            if default is not PydanticUndefined:
279                pydantic_private[name] = default
280        object_setattr(self, '__pydantic_private__', pydantic_private)

This function is meant to behave like a BaseModel method to initialise private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

Args: self: The BaseModel instance. __context: The context.

model_fields = {'created_at': FieldInfo(annotation=Union[datetime, NoneType], required=False, alias='createdAt', alias_priority=2, description='Date and time when the board was created. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).'), 'created_by': FieldInfo(annotation=Union[UserInfoShort, NoneType], required=False, alias='createdBy', alias_priority=2), 'current_user_membership': FieldInfo(annotation=Union[BoardMember, NoneType], required=False, alias='currentUserMembership', alias_priority=2), 'description': FieldInfo(annotation=str, required=True, description='Description of the board.', metadata=[Strict(strict=True)]), 'id': FieldInfo(annotation=str, required=True, description='Unique identifier (ID) of the board.', metadata=[Strict(strict=True)]), 'last_opened_at': FieldInfo(annotation=Union[datetime, NoneType], required=False, alias='lastOpenedAt', alias_priority=2, description='Date and time when the board was last opened by any user. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).'), 'last_opened_by': FieldInfo(annotation=Union[UserInfoLastOpenedBy, NoneType], required=False, alias='lastOpenedBy', alias_priority=2), 'modified_at': FieldInfo(annotation=Union[datetime, NoneType], required=False, alias='modifiedAt', alias_priority=2, description='Date and time when the board was last modified. Format: UTC, adheres to [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), includes a [trailing Z offset](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)).'), 'modified_by': FieldInfo(annotation=Union[UserInfoShort, NoneType], required=False, alias='modifiedBy', alias_priority=2), 'name': FieldInfo(annotation=str, required=True, description='Name of the board.', metadata=[Strict(strict=True)]), 'owner': FieldInfo(annotation=Union[UserInfoShort, NoneType], required=False), 'picture': FieldInfo(annotation=Union[Picture, NoneType], required=False), 'policy': FieldInfo(annotation=Union[BoardPolicy, NoneType], required=False), 'team': FieldInfo(annotation=Union[Team, NoneType], required=False), 'project': FieldInfo(annotation=Union[BoardProject, NoneType], required=False), 'type': FieldInfo(annotation=str, required=True, description='Type of the object that is returned. In this case, type returns `board`.', metadata=[Strict(strict=True)]), 'view_link': FieldInfo(annotation=Union[Annotated[str, Strict(strict=True)], NoneType], required=False, alias='viewLink', alias_priority=2, description='URL to view the board.'), 'additional_properties': FieldInfo(annotation=Dict[str, Any], required=False, default={})}
model_computed_fields = {}
Inherited Members
pydantic.main.BaseModel
BaseModel
model_extra
model_fields_set
model_construct
model_copy
model_dump
model_dump_json
model_json_schema
model_parametrized_name
model_rebuild
model_validate
model_validate_json
model_validate_strings
dict
json
parse_obj
parse_raw
parse_file
from_orm
construct
copy
schema
schema_json
validate
update_forward_refs