WoW API Updates for Pre-Patch

API Discussion
Greetings!

The following are some of the changes being released for the WoW API with Pre-Patch:

  • Professions on a character profile will display each expansion level:
    {
    "id": 2507,
    "name": "Kul Tiran Inscription",
    "icon": "inv_inscription_tradeskill01",
    "rank": 1,
    "max": 150,
    "recipes": []
    },
    {
    "id": 2508,
    "name": "Legion Inscription",
    "icon": "inv_inscription_tradeskill01",
    "rank": 1,
    "max": 100,
    "recipes": []
    }
  • Heart of Azeroth and Azerite Empowered Items will be available at the /items endpoint

    Within Azerite Empowered Items, there is a new field: azeriteClassPowers. This is a map of IDs for each class that can wear the item, and each ID contains a list of Azerite Class Powers that could be unlocked on the item.

    "azeriteClassPowers": {
    "1": [
    {
    "id": 483,
    "tier": 3,
    "spellId": 280555,
    "bonusListId": 0
    },
    {
    "id": 434,
    "tier": 3,
    "spellId": 278751,
    "bonusListId": 0
    },


Please let us know if you encounter any issues. Thanks!
Hey. I've noticed that the "secondary" key under "professions" doesn't show the expansion-specific professions for Fishing or Cooking, just the classic one (caps at 300, skill IDs 356 and 185 respectively). Are there any plans to have the secondary professions data include the expansion-specific info like the primary professions do?
Is there a way to order the profs by expansion?
07/23/2018 05:16 AMPosted by Greymonkey
Is there a way to order the profs by expansion?


In Javascript you would need to get the array and run a sort on it by defining the first, second, third, etc names. I'm pretty sure it has to be exact though so it would be a pain...

const sortOrder = ['First', 'Second', 'Third', 'Fourth', 'Fifth', 'Sixth']

array.sort((a, b) => {
return sortOrder.indexOf(a.name) - sortOrder.indexOf(b.name)
})


...otherwise you could run a normal alphabetical sort, but the order may not be what you want.
I've also noticed that the API data doesn't include which profession slot each primary profession is in. E.g. if, in-game, I have Herbalism in the upper slot and Mining in the lower slot, nothing in the API data indicates this. It would be helpful if that data were included somehow, so that when we make tools to reflect in-game data, it can look the same.

Join the Conversation

Return to Forum