mondantic: Converts Monday.com boards into Pydantic class definitions and populates them

mondantic is a free and open source Python library for working with Monday boards. From each board it creates a Pydantic class definition whose fields are the board’s columns. You can then hydrate the class from a board, so that each row of the board becomes an instance of that dataclass.

For example:


Becomes

class TestBoard(BaseModel):
    board_name: ClassVar[str] = 'Test Board'
    board_id: ClassVar[str] = '1964053908'
    name: Optional[ColumnValue] = Field(alias='name', default=None)
    owner: Optional[PeopleValue] = Field(alias='project_owner', default=None)
    status: Optional[StatusValue] = Field(alias='project_status', default=None)
    due_date: Optional[DateValue] = Field(alias='date', default=None)
    priority: Optional[StatusValue] = Field(alias='priority_1', default=None)
    notes: Optional[TextValue] = Field(alias='text9', default=None)
    budget: Optional[NumbersValue] = Field(alias='numbers', default=None)
    files: Optional[FileValue] = Field(alias='files_1', default=None)
    timeline: Optional[TimelineValue] = Field(alias='project_timeline', default=None)
    last_updated: Optional[LastUpdatedValue] = Field(alias='last_updated', default=None)

Advantages:

  • Allows developers to seamlessly use Monday data in downstream applications where Python is better suited
  • Static typing allows you to use autocompletion and type checking
  • Generating class definitions allows you to define a common set of interfaces for your team to work with

At present, you can install mondantic using pip install git+https://github.com/WEHI-ResearchComputing/mondantic.git, which will automatically resolve all dependencies.

Feel free to report issues and feature requests here on GitHub.