Skip to content
TORNLIFE More

Item Market Value

Started by Gnisis [1947349] on in API Development.

7 replies · 983 views · thread synced · 6 days ago · View on torn.com
About this thread

Posts archived: 8 / 8 posts (100%) · the total is Torn's reply count + the opening post at the last fetch

Counted by TornLife from the archived posts.

Archived posts
8
Discussion span
→
People posting
4
Likes on archived posts
5
Posts by staff, officers and moderators
2
Authority score
73 / 100
Historical score
24 / 100
Story score
34 / 100
Engagement score
62 / 100

Most-liked replies

Gnisis [1947349]

Hi there,

i'm actually making a google sheet to log all my city finds, and calculate the worth of it.

I have a Tab where i have listed all items with their Id, and i want to put, for each items, it's market value.

At this time, i use this API call : https://api.torn.com/torn/Id?selections=items&key=xxxxxx where Id is replace by the item Id of course.

But it means i need to repeat this API call for each items, and there are 900+ Ids, so 900+ API call to do, each time i want to update the market values of my item list.

In google sheet, that is limited, you can't ask it to run each line with a delimited timer, like 1 line per second, it reloads all the formulas at the same time, that will get my API key banned for sure...

So my question is, is there a call that can, instead of returning information of 1 items, return the infos for all the items ? Or is there a google script app that can do the job of calling the API for each ID at the pace of 1 call each 1250ms ?

Thank you for your help
Bug [1455582] Committee Committee

You can do multiple item ids by separating them with a comma, so:

https://api.torn.com/torn/1,2,3,4?selections=Items&key=KEY
Gnisis [1947349]

Thank you, i didn't know that i can do multiple items at the same time, it will really help me and make it easier now :)
Bug [1455582] Committee Committee

You can also get every single items info by leaving the ID empty, I don't know if that will be useful for your needs, but it's handy to know :)
Gnisis [1947349]

Thank you, Finally, i've stopped the google sheet integration, cause this utilisty is too limited...

I've coded myseld a Pascal/Delphi application that make 1 call based on your idea, and then i have parsed the JSON myself to retrieve the datas i need ;)
Gnisis [1947349]

You can list all the items in a bazaar, then use market value, then know that bazaar are more or less higher price of 1 to 5 % for cheap ones