Jump to content
McKay Development

Identifying Steam Items


Dr. McKay

Recommended Posts

  • 3 months later...

So there isn't any easy way to link an item the bot received to the original owner?

 

In my project we may need to give items back to the user. If the items can change their names and their 5 IDs after a trade or something, we'll have to figure out a guaranteed way to make sure that we will always know who were the owners of the items, and this sounds too much difficult...

 

Can anyone here help me with this?

 

 

The trade receipt page contains the new item data. If you're using node-steam-tradeoffer-manager, you only need to use offer.getReceivedItems.

 

 

Hello, i have the same question.

 

The use case is:

 

1. Webuser set prices for items and requests API to deposit them;

 

i.assetid          i.market_name  i.classid       i.instanceid

9400869287   Falchion Case   991959905  0

9400869231   Falchion Case   991959905  0

9400869172   Falchion Case   991959905  0

9400869102   Falchion Case   991959905  0

 

2. API saves items and sends trade offer beetween webuser and trade bot;

3. Trade bot accepts the offer;

4. At this point i have to set correct prices for received items, but i can't match saved and received items because they are totally identical except the assetid property.

 

i.assetid          i.market_name   i.classid        i.instanceid

9401413793   Falchion Case    991959905   0

9401413749   Falchion Case    991959905   0

9401413842   Falchion Case    991959905   0

9401413881   Falchion Case    991959905   0

 

Please let me know If you are have any approaches to solve this.

 

Thank you.

Edited by Selectah
Link to comment
Share on other sites

  • 4 months later...

Thank you for this helpful thread.

I do have a question though; you mentioned that an asset id will be unique in an app in a specific context, but will (new) asset id's caused by new or traded items -always- be different from any asset id that has ever existed within the app and context, regardless of which user's inventory it's in? This worries me because I'm not sure whether I should account for duplicate asset id's over time or across different inventories when old asset id's might get reused, or will that never happen and will they always be unique no matter how many transactions happen within the app across the whole of Steam?

 

Thank you in advance.

Link to comment
Share on other sites

So, just to be sure, Steam only guarantees an assetid to be unique at any specific given point in time rather than over the entire existence of the app's global inventory, but the implementation of the system that Valve used for their own games guarantees that assetid's are assigned through incrementing and thus it is reasonable to assume that those specifically will always be unique?

Link to comment
Share on other sites

  • 1 month later...

I need some help, I am trying to find a special knife pattern in CSGO called sapphires, ruby and black pearl. These special patterns are all in the Doppler series but, there is also Phase 1-4  pattern which isn't what I want. Is there a chance I could directly search up the special patterns on the steam market?

Link to comment
Share on other sites

  • 5 months later...

Hi, 

First many thanks for the explanation of the different entitities in the Steam Asset API. It was very confusing to me before reading your post. Now, at least, I'm able to ask a question :-). 

 

This one is about the Asset Classes. Do have any thoughts about how an Inventory provider should handle these classes when mapping a number of them to a single description returned in the GetAssetClassInfo response? To me it feels like constructing an apple from a pear. How can one interpret an AssetClass? Is an Asset aggregated by a number of AssetClasses? 

It also seems strange that these classes are cached in Steam. What information is cached then? Only their ids? Because the Steam Asset API don't let Steam know anything about an individual Asset Class information despite the GetAssetClassInfo request (since it only returns the overall Asset information). 

Maybe I completely missunderstood this?!

Best regards, 

Einar

Link to comment
Share on other sites

Hi, 

First many thanks for the explanation of the different entitities in the Steam Asset API. It was very confusing to me before reading your post. Now, at least, I'm able to ask a question :-). 

 

This one is about the Asset Classes. Do have any thoughts about how an Inventory provider should handle these classes when mapping a number of them to a single description returned in the GetAssetClassInfo response? To me it feels like constructing an apple from a pear. How can one interpret an AssetClass? Is an Asset aggregated by a number of AssetClasses? 

It also seems strange that these classes are cached in Steam. What information is cached then? Only their ids? Because the Steam Asset API don't let Steam know anything about an individual Asset Class information despite the GetAssetClassInfo request (since it only returns the overall Asset information). 

Maybe I completely missunderstood this?!

Best regards, 

Einar

 

Assuming you're talking about what the Steamworks documentation refers to as an "asset class" and that by "inventory provider" you mean an item server backend, which is kind of outside the scope of this thread but I'll answer anyway.

 

Asset classes basically describe the "nature" of an item, and you define them yourself. For example, in Valve games each item has a definition index (defindex), which is a class. def_index: 1234

But each item can also have special attributes, for example a StatTrak CS:GO item. So you might have stattrak: true

This means that each item/asset has multiple asset classes.

 

You expose a class to Steam for every kind of attribute that changes how the item is rendered, so you end up with basically a list of display-affecting attributes. You could read the above as "this item has def_index 1234 and it is a stattrak item". Then Steam calls GetAssetClassInfo with that listing of classes and expects you to return a proper description, which gets cached indefinitely for that set of classes. So that means that your set of classes for a specific item needs to include all the data necessary to build a comprehensive description.

 

The purpose of asset classes and descriptions is to decouple the display information from the actual asset. For example, every CS:GO Case Key is completely identical so there's no reason to store all the display information with each individual item. So instead the economy server requests the list of classes for the assetid from the item server, which replies with a list of classes that the economy server has already seen. Thus the econ server knows that it's seen this kind of item before and doesn't need to request display information.

Link to comment
Share on other sites

Assuming you're talking about what the Steamworks documentation refers to as an "asset class" and that by "inventory provider" you mean an item server backend, which is kind of outside the scope of this thread but I'll answer anyway.

 

Asset classes basically describe the "nature" of an item, and you define them yourself. For example, in Valve games each item has a definition index (defindex), which is a class. def_index: 1234

But each item can also have special attributes, for example a StatTrak CS:GO item. So you might have stattrak: true

This means that each item/asset has multiple asset classes.

 

You expose a class to Steam for every kind of attribute that changes how the item is rendered, so you end up with basically a list of display-affecting attributes. You could read the above as "this item has def_index 1234 and it is a stattrak item". Then Steam calls GetAssetClassInfo with that listing of classes and expects you to return a proper description, which gets cached indefinitely for that set of classes. So that means that your set of classes for a specific item needs to include all the data necessary to build a comprehensive description.

 

The purpose of asset classes and descriptions is to decouple the display information from the actual asset. For example, every CS:GO Case Key is completely identical so there's no reason to store all the display information with each individual item. So instead the economy server requests the list of classes for the assetid from the item server, which replies with a list of classes that the economy server has already seen. Thus the econ server knows that it's seen this kind of item before and doesn't need to request display information.

Thanks for your comprehensive answer and yes your assumptions were right about what i was refering to with Asset Class and Inventory provider.

 

So an Asset Class represents a specific piece of display information of an Asset and could have been called AssetDisplayParameter instead?

What confuses me most is the "conversion" of the list of classes to an asset description in the GetAssetClassInfo request. Steam can't know wich part in the response to this method belongs to which classes. So I guess Steam caches the complete signature of classes in the GetAssetClassInfo request in order to be able to re-use display information?

 

 

Link to comment
Share on other sites

So an Asset Class represents a specific piece of display information of an Asset and could have been called AssetDisplayParameter instead?

 

I suppose you could say that.

 

What confuses me most is the "conversion" of the list of classes to an asset description in the GetAssetClassInfo request. Steam can't know wich part in the response to this method belongs to which classes. So I guess Steam caches the complete signature of classes in the GetAssetClassInfo request in order to be able to re-use display information?

 

GetAssetClassInfo takes as input a list of classes and responds as output with a single description. That description corresponds to the entire list of input classes. So the response should correspond to all classes. Which means that I think you understand it correctly, Steam does cache the complete signature of classes.

Link to comment
Share on other sites

I suppose you could say that.

 

 

GetAssetClassInfo takes as input a list of classes and responds as output with a single description. That description corresponds to the entire list of input classes. So the response should correspond to all classes. Which means that I think you understand it correctly, Steam does cache the complete signature of classes.

So from Steams point of view instead of a list of classes-values it could use some kind of identifier to the description.

 

Anyway thanks a lot for you took the time to answer me despite it was a bit off-topic. I think I have the picture now :).

Edited by Einar_100
Link to comment
Share on other sites

  • 4 months later...

McKay, Is it possible that asset id is different in the url? I get a number from the item's assetid and id which are literally the same. But when i see it in the inventory appid context id are same but asset id is completely different even in length.

 

edit: my bad. asset id was changed after trade but i get assetid by using offer.getReceivedItems only if the items sent to a bot account. It shows an error saying the offer is not accepted if the items taken from a bot account. I used getReceivedItems in callback of accept(offer).

 

edit 2: i used getExchangeDetails too. It gives no trade id unable to get trade details error. As long as if any items are not taken from a bot account, which means bot gives nothing, then it works as expected. I wonder why it works when no item is taken from a bot account. Unfortunately, this happens to be the same for getReceivedItems. I tested every possible scenario. 

Edited by tvman99
Link to comment
Share on other sites

×
×
  • Create New...