guild_ranks#
Guild rank roles: which Discord rank role a member’s in-game guild rank calls for.
The API reports the in-game rank names a member’s characters hold on the Battle.net guild roster
(MemberLink.guild_ranks, best first). Each name maps to one Discord rank role:
the role with the same name (case-insensitive):
Adventurer-> Adventurer;else the one role whose name starts with it, since the game cuts rank names at 15 characters:
Expedition Lead-> Expedition Leader;else, for a rank ending in
Altwhose stem is a rank (Quest MasterAlt), Alternate Path: an alt’s rank says whose alt it is, not what the player is, and their main’s rank wins anyway.
A name that matches nothing is ignored. The member gets the highest rank role any of their ranks maps to, and loses
every other rank role. The three officer roles carry moderator permissions, so they’re only granted from
battlenet_guild_ranks: characters the member’s own Battle.net account owns, which no addon upload or site link
can fake. When a member’s highest rank is an officer rank that only a site-linked character holds, the sync leaves
their rank roles alone rather than grant it, or demote someone who really is an officer.
- sidequest_bot.lib.guild_ranks.RANK_ROLE_NAMES: tuple[str, ...] = ('Quest Master', 'Quest Guide', 'Expedition Leader', 'Seasoned Adventurer', 'Adventurer', 'New...#
Every Discord guild rank role, highest first.
- sidequest_bot.lib.guild_ranks.OFFICER_RANK_ROLE_NAMES#
granted only from Battle.net-owned characters.
- Type:
Rank roles with moderator permissions
- sidequest_bot.lib.guild_ranks.ALT_RANK_ROLE_NAME = 'Alternate Path'#
- sidequest_bot.lib.guild_ranks.rank_role_name(rank: str) str | None[source]#
The Discord rank role for the in-game rank
rank, or None if it maps to none (see the module docstring).
- sidequest_bot.lib.guild_ranks.wanted_rank_role(ranks: collections.abc.Sequence[str], battlenet_ranks: collections.abc.Sequence[str]) str | None[source]#
The one rank role a member should hold, or None to leave their rank roles as they are.
ranksare all their characters’ in-game ranks,battlenet_ranksthose of the characters their Battle.net account owns. None when no rank maps to a rank role, or when the highest is an officer role no Battle.net-owned character’s rank calls for.