I put together a script that uses the WoW Community Platform APIs to find and post images of characters with transmogrified items. You can see the resulting tumblr blog here:
http://transmogfashion.tumblr.com/
There's no source code available, since the world doesn't need multiple copies of this running, and my script wasn't written for style. :) But I present this to the forum just as an example idea, to get you thinking of other things you can develop using the WoW Community Platform APIs.
Here's a step-by-step of what my script does.
1) Use the realm status API to get the list of realms, and pick one realm at random.
2) Use the auction house API to pull down the chosen realm's auctions, and pick a seller at random.
3) Use the character API to find the guild that seller belongs to. (If the seller has no guild, pick another seller.)
4) Use the guild API to get the roster of that guild, and pick a level 85 member at random.
5) Use the character API to get the list of equipped items and appearance options for the chosen guild member. If the member doesn't have at least 3 transmogged and visible slots, choose another member and repeat, looking at up to 15 characters in a guild.
6) If we still haven't found a member with 3 transmogged slots, pick another seller from the AH pull and go back to step 3.
7) Now that we have a character with a bunch of transmogged slots, use the item API to get the item names of the transmog appearance sources. Build a list of visible items, with item names, IDs, quality levels, and slot names.
8) Use the character API to find the character's selected title, gender, race, class, and thumbnail URL. Replace the "thumbnail" text with "profilemain" to build the URL for the full image from the Armory.
9) Use the tumblr API to post this data with appropriate tags to the tumblr blog.
I put this script on a cron job, and it'll run once every 4 hours. The purpose is to see how people are transmogging their items, and through the use of tags, we can select examples by race or class or transmog slot.
Very nice. Looks like it was also picked up by WoW Insider: http://wow.joystiq.com/2011/12/05/wow-api-used-to-display-player-transmogrification-sets/
|