originally posted in:BungieNetPlatform
The vault is a vendor and some vendors have a section called acceptedItems which is an array of source/target bucket locations. This is how the vault knows where to put items you store in the vault despite not having the same buckets as your character. So while there may not be any items with the bucketHash, it is still very much used.
English
-
Interesting. Thanks for the info.
-
Good sleuthing lowlines! Indeed, it's a bit unintuitive, but the acceptedItems structure on vendors is indeed the source of truth for where items can safely transfer. And also just to follow up, the bucketTypeHash in the item definitions is the item's "default" bucket: if nothing else is acting on it and you receive this item, it will end up in the bucket defined there. However, you can act on an instance of an item and move it to the vault (for example). If you were to make a query for an account's Vault, you'd see that the item instance objects therein have bucketTypeHashes = the various vault buckets. So nothing will go to the vault by default (and thus you'll never see it if you're only looking at definitions), but if you're looking at instances you'll see items that are in those buckets.
-
Maybe I'm missing something again. I just looked at the first item in [i]items[/i] from [i]GetDestinyAccountSummary[/i] and the only fields are: [quote]itemId locked damageType isGridComplete characterIndex primaryStat transferStatus itemHash quantity[/quote]
-
Oh, GetDestinyAccountSummary is a horse of a different color - the new Summary service (which is in prototype, be warned as mentioned in another thread that it's going to be changing in a few ways before it becomes "official" around the 8th or so) doesn't return bucketHash yet. The final version of it will have that property - but if you make one of the more substantive calls, such as GetAccount, the items you see will have bucketHashes in them.
-
This got me digging around some of the responses from [i]GetCharacterInventory[/i] (which is what I have been using) and I barely noticed how the json is set up. Seems like all the items are just grouped up by the buckets - which should have been more obvious sooner had I not used some wonderful list comprehension to make everything into one list. Thanks.
-
No problem! The truth is that I really regret that server-side grouping - I wrote that contract (pretty much all of the Destiny contracts outside of stats and the grimoire), and one of the parts I regret the most is that inventory grouping by "bucket category". Prescribing our site's particular categorization of buckets has proven problematic for us in retrospect, and I imagine for third party sites as well... if you can, I'd say go on transforming it into one list and grab those bucket hashes: someday in the future, I hope to deprecate the inventory field as it exists now and replace it with a flattened list so that clients can pivot on that data any way they want without having to worry about our artificial "bucket category" concept. Yuck.