GetGuildInfo(unit)
Usage
guildName, guildRankName, guildRankIndex = GetGuildInfo(unit);
Description
Returns the name of the unit's guild, that unit's rank title in the guild and its rank index.
Example
local guildName, guildRankName, guildRankIndex = GetGuildInfo("player");
Template:WoW API