BlueTracker

Bluetracker
Volver al Bluetracker

Get item_(sub)classes out of the auction house api

API Discussion

Hello,

I have a mysql table (auction_data) where I store the auction house api data.

item_id | item_class | item_subclass | actual_price | actual_quantity |last_update
------------------------------------------------------------------------------------------------------------------
82033   |            |               | 5727700      |      12         |2020-09-25 16:30

To get the above datas I use this loop:

foreach ($array['auctions'] as $auctiondata) { 

$sql = "REPLACE INTO `auction_data`
                (`item_id`, `actual_price`, `actual_quantity`, `last_update`)
            VALUES
                ('{$auctiondata['item']['id']}', '{$auctiondata['buyout']}', '{$auctiondata['quantity']}', NOW())";

if ($conn->query($sql) === TRUE) {
   //
} else {
   //
  }
}

The variable $array is the “php json decoded” array of

https://eu.api.blizzard.com/data/wow/connected-realm/581/auctions?namespace=dynamic-eu&locale=de_DE&access_token=$token";`

As you see I still need the item_class and item_subclass of all the items in the table.

For these informations I would need to loop every single_item id through the

/data/wow/item/{itemId} API

and " json_decode" these arrays.

Could you help me how to code that?

Maguthul
28-10-2020 20:40:11

Hi all,

The 1000 result limit is indeed an intentional limitation applied to the result set. Furthermore, the pattern described by Schiller using the min functionality is indeed an acceptable usage of the Search APIs, so no worries there.

Hopefully, this clears up some of your questions.

Fuente

Completar Registro

Política de cookie (EU)

BlueTracker

Back to Top

Log In

Or with username:

Forgot password?

Don't have an account? Register

Forgot password?

Enter your account data and we will send you a link to reset your password.

Your password reset link appears to be invalid or expired.

Log in

Privacy Policy

To use social login you have to agree with the storage and handling of your data by this website.

Add to Collection

No Collections

Here you'll find all collections you've created before.