Mobile "armory"
The only way to “upgrade” a piece of equipment is to find one with a higher required level or a higher rarity. That’s it. All stats are directly related to those two properties. (Except for leveling items, which have a lower required level than stat level, but the best stat level available on them is 74.)
Try Dulfy Database
It has some very well thought-out filter options. You can use it to find equipment with certain stat combinations. As an example, here’s a list of all lv 80 heavy boots of exotic rarity with Berserker’s stats: http://db.dulfy.net/search/0/80-80/armor-boots/exotic/0/power,precision,critdamage,heavy/0/0/
I can see why you want the API involved. The information you want is available, in pieces, across many sites and none of them (not even the wiki) has all of it. It’s difficult to put all of it together and still make it presentable. Worse still is keeping it updated, as some sources for items get removed from the game periodically, and others are added with almost every update.