Get information about an AddOn.
name, title, notes, loadable, reason, security, newVersion = GetAddOnInfo(index or "name")
- Integer - The index of the AddOn in the user's AddOn list. Note that you cannot access Blizzard-provided AddOns through this mechanism.
- String - The name of the AddOn to be queried. You can access Blizzard-provided AddOns through this mechanism.
- String - The name of the AddOn (the folder name).
- String - The title of the AddOn as listed in the .toc file (presumably this is the appropriate localized one).
- String - The notes about the AddOn from its .toc file (presumably this is the appropriate localized one).
- Boolean - Indicates if the AddOn is loaded or eligible to be loaded, true if it is, false if it is not.
- String - The reason why the AddOn cannot be loaded. This is nil if the addon is loadable, otherwise it contains a string token indicating the reason that can be localized by prepending "ADDON_". ("BANNED", "CORRUPT", "DEMAND_LOADED", "DISABLED", "INCOMPATIBLE", "INTERFACE_VERSION", "MISSING")
- String - Indicates the security status of the AddOn. This is currently "INSECURE" for all user provided addons and "SECURE" for Blizzard_* AddOns.
- Boolean - Not currently used.
- If the function is passed a string, name will always be the value passed, so check if reason equals "MISSING" to find out if an addon exists.
- index or "name" is not case sensitive, at least not on Windows.
- If the function is passed a number that is out of range, you will get an error message, specifically
[<file name>]:<line number> AddOn index must be in the range of 1 to <GetNumAddOns()>
Patch 6.0.2 / API changes (2014-10-14): Removed 'enabled' return. 'loadable' return was changed from a flag to a boolean. Added 'newVersion' return. The enabled state of an addon can now be queried with GetAddOnEnableState.