Jump to content
Axle Change

[Script] Complete automated bot with autoprice

Recommended Posts

Axle Change    87
Axle Change

 

I don't think this needs much introduction as most of you already know me.

 

Source code is available on GitHub:

https://github.com/AxleChange/tf2-autoprice-bot

 

I included my personal list of near 1000 items, which took me a around a year to collect. Features include:

  • automatically undercuts other sellers on backpack.tf and overcuts on buy orders
  • automatically accepts offers and handles confirmations
  • creates and removes listings on backpack.tf automatically
  • maxstock
  • auto-flips items (i.e. it sells an item immediately after it is bought)
  • checks SR bans
  • calculates profit and logs items sold

Anyway if you're wondering why I'm doing this is mostly because I'm perma'd, also because I've lost interest over time. Seeing as I have no use for this anymore and I won't have time to develop it, I'm releasing the source code. Also I want to watch the world burn lul. 

 

Edit: fixed lmaxstock being undefined in exports.createSell, this got deleted when I pasted something wrong

Share this post


Link to post
Share on other sites
ḎℰѦÐ! Boom    541
ḎℰѦÐ! Boom
13 minutes ago, Axle Change said:

I don't think this needs much introduction as most of you already know me.

 

My question is, with undercutting bots, couldn't they easily be abused?
 

E.g. Bot is selling item for one key, User "undercuts" bot to 10 ref, Bot then does 9.88, then user makes 28 ref profit or whatever.

 

Can that happen?

Share this post


Link to post
Share on other sites
Axle Change    87
Axle Change
13 minutes ago, ḎℰѦÐ! Boom said:

My question is, with undercutting bots, couldn't they easily be abused?
 

E.g. Bot is selling item for one key, User "undercuts" bot to 10 ref, Bot then does 9.88, then user makes 28 ref profit or whatever.

 

Can that happen?

There are multiple criteria that need to be met for that to happen. The bot only undercuts other bots, which have the proper heartbeat enabled. The bot also only “follows” within certain ranges, which I set based on hard key values (I.e. value cannot fluctuate more than 3 Keys) And percentage based following. Also, a lot of the reason that this works is because the bot market is saturated enough that there are buyers and sellers of most items that makes outliers irrelevant. If you really wanted to, it’s not that hard to adjust it so that the bot will never list an item for lower than it bought it, as it already stores the price it bought the item for, and just check that versus the undercut. 

Share this post


Link to post
Share on other sites
ḎℰѦÐ! Boom    541
ḎℰѦÐ! Boom
44 minutes ago, Axle Change said:

There are multiple criteria that need to be met for that to happen. The bot only undercuts other bots, which have the proper heartbeat enabled. The bot also only “follows” within certain ranges, which I set based on hard key values (I.e. value cannot fluctuate more than 3 Keys) And percentage based following. Also, a lot of the reason that this works is because the bot market is saturated enough that there are buyers and sellers of most items that makes outliers irrelevant. If you really wanted to, it’s not that hard to adjust it so that the bot will never list an item for lower than it bought it, as it already stores the price it bought the item for, and just check that versus the undercut. 

 

 

Okay thanks... but I hope you don't make the world burn now.

Share this post


Link to post
Share on other sites
djsober    28
djsober
1 hour ago, Axle Change said:

There are multiple criteria that need to be met for that to happen. The bot only undercuts other bots, which have the proper heartbeat enabled. The bot also only “follows” within certain ranges, which I set based on hard key values (I.e. value cannot fluctuate more than 3 Keys) And percentage based following. Also, a lot of the reason that this works is because the bot market is saturated enough that there are buyers and sellers of most items that makes outliers irrelevant. If you really wanted to, it’s not that hard to adjust it so that the bot will never list an item for lower than it bought it, as it already stores the price it bought the item for, and just check that versus the undercut. 

Aren't all ur bots banned and got defrauded for 7000?

Share this post


Link to post
Share on other sites
Teeny Tiny Cat    2215
Teeny Tiny Cat
22 minutes ago, djsober said:

Aren't all ur bots banned and got defrauded for 7000?

 

How is this relevant to the thread?

Share this post


Link to post
Share on other sites
djsober    28
djsober
Just now, Teeny Tiny Cat said:

 

How is this relevant to the thread?

Just might not be the best person to talk about this topic but w/e.

Share this post


Link to post
Share on other sites
Teeny Tiny Cat    2215
Teeny Tiny Cat
1 minute ago, djsober said:

Just might not be the best person to talk about this topic but w/e.

 

He might not be the best person to talk to about the code he wrote?

Share this post


Link to post
Share on other sites
djsober    28
djsober
Just now, Teeny Tiny Cat said:

 

He might not be the best person to talk to about the code he wrote?

Well considering he used outdated software with bugs, might not be the best candidate. I'll stop talking before I get banned though.

Share this post


Link to post
Share on other sites
Teeny Tiny Cat    2215
Teeny Tiny Cat
1 minute ago, djsober said:

Well considering he used outdated software with bugs, might not be the best candidate. I'll stop talking before I get banned though.

 

If you want to ask a question about how his bot got exploited and if it's still vulnerable, ask that question. Don't bring up bans just to make him look bad.

Share this post


Link to post
Share on other sites
djsober    28
djsober
Just now, Teeny Tiny Cat said:

 

If you want to ask a question about how his bot got exploited and if it's still vulnerable, ask that question. Don't bring up bans just to make him look bad.

I already know the basics of how it happened, bptf automatic had a bug where it couldn't differentiate stranges and australiums so you can sell a cheap strange for the australium price, then use those keys to buy an actual australium and rinse and repeat.

Share this post


Link to post
Share on other sites
Teeny Tiny Cat    2215
Teeny Tiny Cat
3 minutes ago, djsober said:

I already know the basics of how it happened, bptf automatic had a bug where it couldn't differentiate stranges and australiums so you can sell a cheap strange for the australium price, then use those keys to buy an actual australium and rinse and repeat.

 

I think asking if that is accounted for and now safe is a reasonable question. His bans, again, have nothing to do with anything.

Share this post


Link to post
Share on other sites
« SɱokEy »    1
« SɱokEy »

So can you now explain how that guy stole your items?
I mean I don't think it was the bp.tf automatic Aussie bug ( because that bug only lets you steal the keys giving a strange item in return )
But that guy took out everything EVERY LAST SCRAP. 

Chances of that to happen again?


hmm you should have just appealed for your ban instead of making new accounts to make it even worse. After all, it was a simple ban for ban evasion 

oh well hope you are happy now that the economy is gona crash ~ can't imagine a 100 of these undercutting and uppercutting each other xD All items will reach a state where the profit margin will be 1 scrap lel

Share this post


Link to post
Share on other sites
« SɱokEy »    1
« SɱokEy »
3 hours ago, djsober said:

I already know the basics of how it happened, bptf automatic had a bug where it couldn't differentiate stranges and australiums so you can sell a cheap strange for the australium price, then use those keys to buy an actual australium and rinse and repeat.

Nope this is what everyone thinks ~ I don't think this is what happened in this case 

Share this post


Link to post
Share on other sites
« SɱokEy »    1
« SɱokEy »
5 hours ago, Axle Change said:

I included my personal list of near 1000 items, which took me a around a year to collect. Features include:

1

Y would it take a year to collect data of 1000 items :o or did u mean u took a year to make this bot running

Share this post


Link to post
Share on other sites
Axle Change    87
Axle Change
6 hours ago, djsober said:

Well considering he used outdated software with bugs, might not be the best candidate. I'll stop talking before I get banned though.

This is not related to automatic at all. I used several libraries but outside of that everything was coded by myself.

 

3 hours ago, « SɱokEy » said:

Y would it take a year to collect data of 1000 items :o or did u mean u took a year to make this bot running

 

I have run bots for around 1.5 years now. That list is the personal list of items I used in banking.

 

Regarding your first point about my bot being exploited:

1) I did not lose everything. This is a misconception from you tubers, what actually happened is I lost a large amount of the bots stock from an exploit, and I then transferred all of the items to a different account. This is how I was initially banned for ban evasion because the bot was also banned for declining listings, which I have since fixed (not going into further detail here)

 

2. Regarding the exploit itself, the exploit worked by setting a very high fake buy price/sell price while sending heartbeats on specific items where there were no current sellers. At the time of the exploit I had no “threshold” for following automatic   Buy/sell orders. Following that event, I set thresholds for buy/sell orders and other protections in the code. I believe they are +- 10 keys, and a percentage threshold of maybe 1.4. These can easily be adjusted. I also set the bot to not price anything over 50 keys or accept trades over some number, but I believe I removed this in the public release as people bank higher value items. 

 

Also, the code can be used without auto pricing if you are uncomfortable with it- although I did not add a way to create the initial listings for the first time without autopricing. If more people want this it is not too difficult to add.

Share this post


Link to post
Share on other sites
« SɱokEy »    1
« SɱokEy »
2 hours ago, Axle Change said:

1) I did not lose everything. This is a misconception from you tubers, what actually happened is I lost a large amount of the bots stock from an exploit, and I then transferred all of the items to a different account. This is how I was initially banned for ban evasion because the bot was also banned for declining listings, which I have since fixed (not going into further detail here)

2

I am not talking about any youtubers, I did some digging that day and It did appear as u lost everything. I mean I did see the compare links on both backpacks and most of the items are still here with him https://backpack.tf/profiles/76561198382606040 and I believe you 1st got suspended for not accepting the trades(that is what the suspension message 1st said) and then got banned for moving items on another account when u were already banned on one.

 

2 hours ago, Axle Change said:

2. Regarding the exploit itself, the exploit worked by setting a very high fake buy price/sell price while sending heartbeats on specific items where there were no current sellers. At the time of the exploit I had no “threshold” for following automatic   Buy/sell orders. Following that event, I set thresholds for buy/sell orders and other protections in the code. I believe they are +- 10 keys, and a percentage threshold of maybe 1.4. These can easily be adjusted. I also set the bot to not price anything over 50 keys or accept trades over some number, but I believe I removed this in the public release as people bank higher value items. 

1

Idk dude dosnt feel much convincing. I am not much of a coder but I did read through your code and your code does not have min/max protections (maybe I missed it) but I doubt if this was the issue. You said "specific items where there were no current sellers" if this is the case how did he take out all the items as I said above? Not every item had no sellers? and If I remember right your listings used to get removed when someone makes a buy order for much higher than (the rage or limit that is set)

 

2 hours ago, Axle Change said:

Also, the code can be used without auto pricing if you are uncomfortable with it- although I did not add a way to create the initial listings for the first time without autopricing. If more people want this it is not too difficult to add.

1

I still feel unsafe to use it and wont be using it at all ~ but I was very curious to know what actually happened I thought your server was hacked I mean You 1st stopped accepting trades and the next day the exploit happened, also in the config json there is an admin thing "The steamID64 for the admin of the bot. Any trade the admin sends will be accepted, and the are certain chat commands to control the bot." - More like what i feel that happened ~ That guy just took out everything in 32 trades giving back nothing in return 
https://backpack.tf/profiles/76561198382606040#!/compare/1511395200/1511481600 
https://backpack.tf/profiles/76561198319487961#!/compare/1511395200/1511481600
Removed 1429 items
Not saying it was a hack but looks more or less like it ~ what you said doesn't add up to me 

anyways that said Sorry this had to happen to you and you had to go through all this ~ as I said I was just curious to know what really happened
and yes I do feel its unsafe to use this code I would advise everyone against using it (unless they wanna make changes to it and make something new out of it) 

Share this post


Link to post
Share on other sites
djsober    28
djsober
1 hour ago, « SɱokEy » said:

I am not talking about any youtubers, I did some digging that day and It did appear as u lost everything. I mean I did see the compare links on both backpacks and most of the items are still here with him https://backpack.tf/profiles/76561198382606040 and I believe you 1st got suspended for not accepting the trades(that is what the suspension message 1st said) and then got banned for moving items on another account when u were already banned on one.

 

Idk dude dosnt feel much convincing. I am not much of a coder but I did read through your code and your code does not have min/max protections. I doubt if this was the issue. You said "specific items where there were no current sellers" if this is the case how did he take out all the items as I said above? Not every item had no sellers? and If I remember right your listings used to get removed when someone makes a buy order for much higher than (the rage or limit that is set)

 

I still feel unsafe to use it and wont be using it at all ~ but I was very curious to know what actually happened I thought your server was hacked I mean You 1st stopped accepting trades and the next day the exploit happened, also in the config json there is an admin thing "The steamID64 for the admin of the bot. Any trade the admin sends will be accepted, and the are certain chat commands to control the bot." - More like what i feel that happened ~ That guy just took out everything in 32 trades giving back nothing in return 
https://backpack.tf/profiles/76561198382606040#!/compare/1511395200/1511481600 
https://backpack.tf/profiles/76561198319487961#!/compare/1511395200/1511481600
Removed 1429 items
Not saying it was a hack but looks more or less like it ~ what you said doesn't add up to me 

anyways that said Sorry this had to happen to you and you had to go through all this ~ as I said I was just curious to know what really happened
and yes I do feel its unsafe to use this code I would advise everyone against using it (unless they wanna make changes to it and make something new out of it) 

Well afaik he got the items by selling a strange for Aussie price, doing that enough and using the keys to buy expensive items and then buying the strange back for cheap

Share this post


Link to post
Share on other sites
« SɱokEy »    1
« SɱokEy »
2 hours ago, djsober said:

Well afaik he got the items by selling a strange for Aussie price, doing that enough and using the keys to buy expensive items and then buying the strange back for cheap

This is the backpack.tf automatic bug selling strange version of the item for keys (works only when steam is down) this is not what happened to axle 

Share this post


Link to post
Share on other sites
OddHallucination    2
OddHallucination

Error while trying to run "node setup.js" any help?

 

module.js:557
    throw err;
    ^

Error: Cannot find module 'steam-user'
    at Function.Module._resolveFilename (module.js:555:15)
    at Function.Module._load (module.js:482:25)
    at Module.require (module.js:604:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (C:\Users\eavil\Downloads\Bot\setup.js:1:79)
    at Module._compile (module.js:660:30)
    at Object.Module._extensions..js (module.js:671:10)
    at Module.load (module.js:573:32)
    at tryModuleLoad (module.js:513:12)
    at Function.Module._load (module.js:505:3)

Share this post


Link to post
Share on other sites
j0hn cena    2
j0hn cena

nice bot, but instead of using the classifieds api endpoint, it crawls the stats pages of the items to get the prices, which is not allowed to do afaik, also its bypassing cloudflare.

Share this post


Link to post
Share on other sites
Axle Change    87
Axle Change
50 minutes ago, OddHallucination said:

Error while trying to run "node setup.js" any help?

 

module.js:557
    throw err;
    ^

Error: Cannot find module 'steam-user'
    at Function.Module._resolveFilename (module.js:555:15)
    at Function.Module._load (module.js:482:25)
    at Module.require (module.js:604:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (C:\Users\eavil\Downloads\Bot\setup.js:1:79)
    at Module._compile (module.js:660:30)
    at Object.Module._extensions..js (module.js:671:10)
    at Module.load (module.js:573:32)
    at tryModuleLoad (module.js:513:12)
    at Function.Module._load (module.js:505:3)

Use npm install before running setup.js

Share this post


Link to post
Share on other sites
Enzotoy2    0
Enzotoy2

Dear axle,

I have multiple questions :

1 - the bot can have multiple Admin ?

2 - i can disable some listing and renable them after ?

Thx for reply

Share this post


Link to post
Share on other sites
Neko    0
Neko

Your code is lacking comments and full of hardcoded magic numbers.

For example, what does means 34.11 in next part of code (file setup.js):

//callback of community.getUserInventoryContents
for (kl=0;kl<listings.length;kl++){
            for (p=0;p<listings[kl].inventory.length;p++){
                var item_ID=listings[kl].inventory[p];
                listings[kl].bought["_"+item_ID]=Number((listings[kl].buyprice.keys + (listings[kl].buyprice.ref/34.11)).toFixed(5));
            }
        }

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.

×