talents ======= .. py:module:: sidequest_common.schemas.talents .. autoapi-nested-parse:: Talent calculator schemas: a class's three talent trees from Battle.net, and members' saved builds. ``class`` is a Python keyword, so the Python-side attribute is ``wow_class``; ``Field(alias=...)`` maps it to the wire name ``class`` in both directions, same as ``sidequest_common.schemas.events``. A build's ``code`` holds one digit per talent node (its spent rank, 0-9), node order sorted by ``(row, col)`` within each tree, the three trees joined by ``-``; trailing zeros may be trimmed. This is also the share-link format: ``/talents/?class=druid&build=``. .. py:data:: MAX_TALENT_POINTS :value: 51 .. py:data:: FIRST_TALENT_LEVEL :value: 10 .. py:data:: TALENT_ROW_POINTS :value: 5 A tree row opens once this many points, times the row minus one, are spent in that tree. .. py:data:: MAX_TALENT_BUILDS :value: 20 .. py:data:: TALENT_BUILD_NAME_MAX :value: 60 .. py:data:: TALENT_BUILD_NOTE_MAX :value: 200 .. py:class:: TalentRank Bases: :py:obj:`pydantic.BaseModel` One learnable rank of a talent node: the spell it grants and that rank's tooltip text. .. py:attribute:: spell_id :type: int .. py:attribute:: description :type: str .. py:class:: TalentNode Bases: :py:obj:`pydantic.BaseModel` One node in a specialization's talent tree, positioned on its grid. .. py:attribute:: id :type: int .. py:attribute:: row :type: int .. py:attribute:: col :type: int .. py:attribute:: max_rank :type: int .. py:attribute:: talent_id :type: int .. py:attribute:: name :type: str .. py:attribute:: icon_url :type: str | None .. py:attribute:: ranks :type: list[TalentRank] .. py:attribute:: requires :type: int | None .. py:class:: TalentTreeSchema Bases: :py:obj:`pydantic.BaseModel` One specialization's talent tree, as shown on the calculator. .. py:attribute:: spec_id :type: int .. py:attribute:: name :type: str .. py:attribute:: icon_url :type: str | None .. py:attribute:: nodes :type: list[TalentNode] .. py:class:: ClassTalents Bases: :py:obj:`pydantic.BaseModel` A class's three talent trees, as returned by ``GET /api/talents/{wow_class}``. .. py:attribute:: model_config .. py:attribute:: wow_class :type: sidequest_common.schemas.events.WowClass .. py:attribute:: trees :type: list[TalentTreeSchema] .. py:attribute:: max_points :type: int .. py:attribute:: first_level :type: int .. py:class:: TalentBuildCreate Bases: :py:obj:`pydantic.BaseModel` Body for ``POST /api/me/talent-builds``: a build the member wants to save. .. py:attribute:: model_config .. py:attribute:: wow_class :type: sidequest_common.schemas.events.WowClass .. py:attribute:: name :type: str .. py:attribute:: code :type: str .. py:attribute:: note :type: str | None .. py:class:: TalentBuildPinUpdate Bases: :py:obj:`pydantic.BaseModel` Body for ``PUT /api/talent-builds/{id}/pin`` (officer): pin or unpin a build for raids. .. py:attribute:: pinned :type: bool .. py:class:: TalentBuildSchema Bases: :py:obj:`pydantic.BaseModel` A saved talent build, as listed by ``GET /api/me/talent-builds`` or ``GET /api/talent-builds``. .. py:attribute:: model_config .. py:attribute:: id :type: uuid.UUID .. py:attribute:: wow_class :type: sidequest_common.schemas.events.WowClass .. py:attribute:: name :type: str .. py:attribute:: code :type: str .. py:attribute:: note :type: str | None .. py:attribute:: pinned :type: bool .. py:attribute:: member_id :type: int .. py:attribute:: member_name :type: str .. py:attribute:: created_at :type: datetime.datetime