I would like to suggest steamgifts to provide some API to developers.

Why?
Because there are some nice tools, like this one for example, that need some data about users/groups. For now, the only way - is to download all pages of user's profile in html and parse it. It's slow and it makes extra load to sg servers. If instead sg would provide some kind of API, that returns information in json - it would be beneficial to both sg and developers. If I'm wrong - please, tell me where is my mistake.
What?
For now, I believe we need these kinds of requests:

  1. Created giveaways of certain user. With listed winners(!), type (public/private/group/wl), name(s) of the group(s) (!), number of entries, game title(optional), steam id of the game, number of copies, end time, region lock(optional), level requirement(optional).
  2. Won giveaways of certain user. Same information as above, plus name of giveaway creator(optional)
  3. Group information. Basically - the same information as for group pages - separate requests to get group giveaways (same information as above), users (name, made giveaways, won giveaways, level), wishlist (game title, game id, quantity).
  4. Group identification. For now, to access group page we need some 5-letters code. There should be a way to get this code from steam group identifier.
  5. Maybe something else? Extra suggestions are welcome, I would gladly add them to this list.

What should NOT be available through API:

  1. List of current public giveaways. We all don't like bots, so why help them?

How?
It could be public, it could be open to every registered user by some ID in his profile, it even could be by-request, so that developer first will tell cg the reason why he needs access to API. I would be satisfied

Did I forgot something?
Tell me, I'll add it to this post if it's extra suggestion, and would try to answer if it's a question.

Sorry, no poll. A poll with only "Potato" option would look stupid.

9 years ago*

Comment has been collapsed.

i think this is a good idea. question is, will cg have the time (and be willing) to write the API. ^^

9 years ago
Permalink

Comment has been collapsed.

If he would have will to do this - I could wait as long as needed.

9 years ago
Permalink

Comment has been collapsed.

One thing to consider - if he were to build APIs with all of this information, people could essentially write a GUI for SG that completely replaces the SG website, as long as they're only interested in group/whitelist GAs, which many people are, and it would still facilitate the use of bots for those people. This would mean no ad revenue for cg, which is how the site exists in the first place.

9 years ago
Permalink

Comment has been collapsed.

people can already run adblock anyway, even worse - the way many SG addons now works is that they load pages in background to gather neccessary data from them - so they alreadty generate loads of page-loads without any ads being vewed anyway.

9 years ago
Permalink

Comment has been collapsed.

I realize - just pointing out that I don't think it's likely that cg is going to build an API to make this even easier/more common until/unless he finds another way to monetize.

9 years ago
Permalink

Comment has been collapsed.

PREMIUM MEMBERSHIP! :D:

9 years ago
Permalink

Comment has been collapsed.

This information is not useful for bots or alternate GUI builders, unless they want to make a bot/GUI for one particular group.

9 years ago
Permalink

Comment has been collapsed.

Why not? You just program it to make a call for each group you're in, and each person whose whitelist GAs you want to check. As JustArchi says below, people are doing it anyways with HTML parsing, and making it easier with an API isn't going to deter those people, but I still don't think cg is going to officially support something that bypasses his only real means of monetizing the site. Ideally, he needs to find another way to monetize - maybe by charging money to bulk gifters, aka advertisers, to have, as zelghadis puts it, a premium account, maybe by adding Captcha to GA pages to deter bots and force full page loads in order to enter GAs, maybe something else entirely. If he figures that out, he can support APIs, which would allow for more community development efforts for things like mobile apps, group interfaces, and alternative GUIs to suit people's preferences.

9 years ago
Permalink

Comment has been collapsed.

It's more easy to load first html page of giveaways once in a while end enter ending giveaways. No need to parse all groups and friends, which might not have giveaways at all.

9 years ago
Permalink

Comment has been collapsed.

You're right for the purpose of GA-entering bots, but not for alternative GUIs. The point of an alternative GUI is to take the same information you can get on the site, present it in a different way, and probably combine it with data from other sources, like some of the things ArchiBot does today. As JustArchi even said, it would be a lot easier with an API, but more to my point, either method bypasses the ad revenue that cg relies on. Yes, people are doing it today with HTML parsing, and even ad-blockers, but cg can't control that without doing a lot of work to obfuscate the data on the site and adapt to bots. That doesn't mean he's going to officially support an API to make that even easier though.
I, for example, do not bother with ad blockers, and am not willing to go to the trouble of building an HTML parser like JustArchi did in order to customize a GUI for my preferences and overcome some of the limitations of the site. However, if there was an API, I would be very likely to do so as a hobby project - pull in just the types of GAs I'm interested in (group/whitelist, and filtered public GAs by level and/or number of entries), present them with real CV calculations that take bundling into account, flag wishlisted games in the same view, show Steam data like review scores, show isthereanydeal data like lowest price and # of times and last date bundled, etc., etc., etc. If there was a complete API, my GUI would look much different, and cg wouldn't be getting a single ad display.

9 years ago
Permalink

Comment has been collapsed.

You forgot one thing - downloading html to parse causes more load to sg, so actually providing an API would save money. And it would change nothing to the bot/GUI creation - those who want it - would do it anyway. So I see that API would bring profit from any angle of view.

9 years ago
Permalink

Comment has been collapsed.

OK, you apparently have your point of view and will stick to it. No point in me continuing to argue with you. Let's just agree to disagree.

9 years ago
Permalink

Comment has been collapsed.

deal)

9 years ago
Permalink

Comment has been collapsed.

It would greatly help my bot, which is currently hacking around to automate Touhou Giveaways. So I'm +1'ing this, although I know that cg won't make it happen anytime soon. Lose your hope.

On the other hand, after I implemented nearly everything I could ever need to make it work, I don't care that much, at least until SGv3 comes.

9 years ago
Permalink

Comment has been collapsed.

Can you explain, in what way it would help your bot? What does your bot do, I suppose it's not another regular bot to enter giveaways by some pattern?

9 years ago
Permalink

Comment has been collapsed.

My bot automates my Touhou Giveaways group, with some of the content available on my website. It's used for automatically adding new group giveaways, marking winners, calculating ratio, checking bundled status, checking rating of the games, tags of the games, detecting leechers, inviting/kicking people out of the group, and many other things integrated with SG I have no time to list, as it's too much.

9 years ago
Permalink

Comment has been collapsed.

Well, as I thought - it's very specific) I doubt cg care a lot about such bots. Also, it's already written, so API would not do much harm.
May I add you in steam to discuss methods you used? Or it's "know-how" ?

9 years ago
Permalink

Comment has been collapsed.

Sure thing, go ahead. I don't want to raise my ego too much but I spent so much time on SG integration part, that I just have required knowledge to help you writing anything you want.

9 years ago
Permalink

Comment has been collapsed.

Also, speaking of not listing public giveaways, it doesn't make any sense to me, as everybody who would potentially be interested in using the API already has enough knowledge to list them using normal HTML parsing, the same way I do list my group giveaways for detecting and adding them to the database.

So, please don't do security through obscurity. I agree that it would make it easier, but I don't agree that we should not add certain feature only because somebody could have easier way to code something unfair. If I wanted, I could code it already.

9 years ago
Permalink

Comment has been collapsed.

Well, you got a point here... But to be honest - I don't know, who need this anyway (apart from bot-writers).

9 years ago
Permalink

Comment has been collapsed.

+10000

We really need an API to make all of our tools more efficient and decrease the impact on Steamgifts.

9 years ago
Permalink

Comment has been collapsed.

I like the idea of an API, and also, I believe it could be used to monetize the website. Maybe you need a premium membership to access some functions or over a number of API calls.

9 years ago
Permalink

Comment has been collapsed.

A quick bump :)

9 years ago
Permalink

Comment has been collapsed.

I'm almost sure there was a page describing SG API on the previous verion of site, no?

8 years ago
Permalink

Comment has been collapsed.

I don't remember anything like this, but even if it was there - it was for the old site, so it would not help us now.

8 years ago
Permalink

Comment has been collapsed.

Anyway your question answers mine - was checking out for API too.

8 years ago
Permalink

Comment has been collapsed.

Totally agree with this suggestion.
Right now my script requests bundle list per game. So if a user uses it for the first time, it'll request around 50 request to bundle list page. @_@
I'm afraid of DDOSing the server.

What should NOT be available through API:
List of current public giveaways. We all don't like bots, so why help them?

who need this anyway (apart from bot-writers).

I don't write bot, but I need this.
For example, I want to make a custom filter to SG giveaways to only show bundled / non bundled games, only games with trading cards, etc.

8 years ago
Permalink

Comment has been collapsed.

IMO, list of public giveaways are okay, thought I can't think of anything useful for this. Just don't make an API for people to JOIN any giveaway outside of SG.

8 years ago
Permalink

Comment has been collapsed.

+1

8 years ago
Permalink

Comment has been collapsed.

BUMP
8 years ago
Permalink

Comment has been collapsed.

Eventually, we can start making our own client-sided API to expose an interface we would use for future developments.
Then if cg have time and want to, he would always be able to offer open optimized calls/request to replace our parsing of multiple html results.
We then just adapt/update our API.

But does anyone competent want to do manage/design that API and have time ?

8 years ago
Permalink

Comment has been collapsed.

Everything I needed I already implemented in ArchiBoT, same for KnSYS with SGT. Mabako also done pretty much everything by hand. I don't know if there is anybody else on SG that heavily makes use of the site as a whole.

Creating an API would definitely be nice, but thing is, nobody from us needs it anymore. When we need a feature, we simply write it, not ask somebody else for something that will not happen. That's also why I'm pretty sure noone of us 3 will bother with rewriting everything from scratch just for the sake of writing it. I definitely won't - I'm not into any web development. ArchiBoT is in C#, not PHP.

Personally I think that KnSYS is the best call, but I honestly doubt that he decides to rewrite how SGT works just for the sake of implementing public API, I'd definitely not go this way.

So unless another guy joins the coding game, I'm pretty sure no API will happen, unless cg wakes up and do it himself.

8 years ago
Permalink

Comment has been collapsed.

Deleted

This comment was deleted 4 years ago.

8 years ago
Permalink

Comment has been collapsed.

Problem is, we both know that major part of the site requires PHPSESSID to operate. ArchiBoT wouldn't exist without that, and while I agree that sharing it with third-parties is considered bad security-wise, it's needed for some actions, and there is no way around it until cg does something with it.

I'm not shocked to see that it died - there are maybe a dozen of people at best that could make use of the API in some reasonable way. Personally I consider it waste of time, writing my own code that is basing on dynamic HTML tags is faster than learning how to do that in PHP, only to achieve the same result. Plus, it's always faster for me to do it from inside C#, and I like to have ArchiBoT parsing 10 giveaways per second (with full data like entries, bundled status, groups etc).

The idea is good, but the only guy that should do something with it is cg. Everybody else will do the same awful hacky stuff that has to be done anyway, which is a pure waste of time.

8 years ago*
Permalink

Comment has been collapsed.

Deleted

This comment was deleted 4 years ago.

8 years ago
Permalink

Comment has been collapsed.

And that's why ArchiBoT is doing the dirty work, and userscripts are only supposed to do simple queries. That's what I did with Arise, and it's heavily being used in official Arise userscript.

The same thing is being done in our 2hu userscript, it just asks website/API for the needed data, but that data is being gathered 24/7 by ArchiBoT. This way I solve major problems for many people and users, but due to being very group-specific, it can't help most of the userscript creators around. Sadly.

8 years ago
Permalink

Comment has been collapsed.

BUMP.
Especially actual nowadays, when rate limits implemented. API would allow to both reduce server load and scripts/services functionality.

3 years ago
Permalink

Comment has been collapsed.

I was reading this very interesting topic and didn't realize it was from 4 years ago until I read something about "SGv3" and "the old site" and went "wha...?"🤔 🤨

There are concepts so far beyond my understanding that I'm not going to bother trying to figure it out, but the premise seems good.

Also, I never have adblock on for this site but I also never ever see ads other than "support SG on patreon." Does anyone else see actual ads?

Anyway, have a bump.

3 years ago
Permalink

Comment has been collapsed.

maybe you have other addons, like noscript or umatrix? those can prevent adds from appearing too.

3 years ago
Permalink

Comment has been collapsed.

these are my addons (see the pic) In Tampermonkey, I have RAChart Enhancer and Touhou Giveaway Helper running. I have FF set to block all 3rd party cookies, tracking content, fingerprinters, and cryptominers, and to send a DNT request.
Ublock is turned off on SG.
乁( ◔ ౪◔)ㄏ

View attached image.
3 years ago
Permalink

Comment has been collapsed.

Since sgtools stopped working because of the rate limiting system an API at least for won games would be nice.

3 years ago
Permalink

Comment has been collapsed.

Sign in through Steam to add a comment.