Skip to content

Configuration

adminerest edited this page Jul 20, 2021 · 9 revisions

Configuration

First, copy the config.example.json to config.json The config file for the script is config.json

{
    "debug": false,
    "proxy": "",
    "language": "english",
    "steam_login_secure": "",
    "steam_id": "",
    "allow_to_sell_item": {
        "enable": true,
        "item_type": []
    },
    "disallow_to_sell_item" : {
        "enable": false,
        "item_type": []
    },
    "allow_to_sell_item_detail": {
        "enable": false,
        "item_detail_type": []
    },
    "disallow_to_sell_item_detail": {
        "enable": false,
        "item_detail_type": []
    },
    "price_setting": {
        "lowest_price": null,
        "highest_price": null,
        "calculation_formula": "",
        "least_sells_hours": 36,
        "hours_least_sells": 25,
        "least_sell_orders": 20,
        "least_buy_orders": 0,
        "normal_card": {
            "lowest_price": null,
            "highest_price": null
        },
        "foil_card": {
            "lowest_price": null,
            "highest_price": null
        },
        "other_item": {
            "lowest_price": null,
            "highest_price": null
        }
    }
}

debug

Type

boolean

Default

false

Explation

Enable the debug log or disable.
true: Enable, false: disable


proxy

Type

string

Default

""

Explation

http/https/socket5 proxy setting

Example:
"http://127.0.0.1:1087"
"https://user:pass@10.10.1.10:1080"
"socks5://127.0.0.1:1080"

Note: Seems socket5 proxy doesn't working.


language

Type

string

Default

english

Explation

The Steam language you are using now.
This property is very import because allow_to_sell_item_detail.item_detail_type and disallow_to_sell_item_detail.item_detail_type use this language to get item detail type name. If the language setting is wrong, the script will not match the setting in allow_to_sell_item_detail.item_detail_type and disallow_to_sell_item_detail.item_detail_type


steam_login_secure

Type

string

Default

""

Explation

The Steam Cookie which you now logged in
This property must to be set.
You can find this property from the web browser which you have logged your account. Use google to find out how to get Cookies from your web browser.


steam_id

Type

string

Default

""

Explation

The Steam ID which you now logged in
This property must to be set.


allow_to_sell_item.enable

Type

boolean

Default

true

Explation

Enable the allow_to_sell_item setting or disable true: Enable, false: disable


allow_to_sell_item.item_type

Type

list[int]

Default

[]

Explation

The types of items allowed to sell

Value Name Description
20 TradingCard Steam trading card, being used for crafting badges
21 FoilTradingCard Foil variant of TradingCard
3 ProfileBackground Profile background to use on your Steam profile (non-foil)
4 Emoticon Emoticon to use in Steam Chat
5 BoosterPack Booster pack containing 3 random cards from a game
6 Consumable Special consumable items that disappear after being used
7 SteamGems Steam gems being used for crafting boosters, sacks included
8 ProfileModifier Special items that can modify Steam profile appearance
10 SaleItem Special items awarded during Steam sales
11 Sticker Special items that can be used on Steam chat
12 ChatEffect Special items that can be used on Steam chat
13 MiniProfileBackground Special background for Steam profile
14 AvatarProfileFrame Special avatar frame for Steam profile
15 AnimatedAvatar Special animated avatar for Steam profile

For example, you want to sell TradingCard, FoilTradingCard, Emoticon and BoosterPack, just set "item_type": [20, 21, 4, 5]


disallow_to_sell_item.enable

Type

boolean

Default

false

Explation

Enable the disallow_to_sell_item setting or disable true: Enable, false: disable


disallow_to_sell_item.item_type

Type

list[int]

Default

[]

Explation

The types of items disallowed to sell
Same as the allow_to_sell_item.item_type


allow_to_sell_item_detail.enable

Type

boolean

Default

false

Explation

Enable the allow_to_sell_item_detail setting or disable true: Enable, false: disable


allow_to_sell_item_detail.item_detail_type

Type

list[string]

Default

[]

Explation

The types of items allowed to sell
The detail type name from Steam, like Counter-Strike: Global Offensive Trading Card
You can find it here


disallow_to_sell_item_detail.enable

Type

boolean

Default

false

Explation

Enable the disallow_to_sell_item_detail setting or disable true: Enable, false: disable


disallow_to_sell_item_detail.item_detail_type

Type

list[string]

Default

[]

Explation

The types of items disallowed to sell
Same as the allow_to_sell_item_detail.item_detail_type


price_setting.lowest_price

Type

float

Default

null

Explation

If the calculated selling price is lower than the lowest price, the item will not be sold. If the price_setting.lowest_price is null, this setting will disabled.


price_setting.highest_price

Type

float

Default

null

Explation

If the calculated selling price is higher than the highest price, the item will not be sold. If the price_setting.highest_price is null, this setting will disabled.


price_setting.calculation_formula

Type

str

Default

null

Explation

The calculation formula that how you want to calculate the selling price.
This property must to be set.
Because the code use eval() to run this property, so any Python code can be used.
The script provides some functions and variables to use.


Variables

highest_buy_price: current highest buying price
lowest_sell_price: current lowest selling price
total_buy_orders: total numbers of buying orders
total_sell_orders: total numbers of selling orders


Functions

get_history_sales_num(hours: int) -> int: The history sales number in hours. Return type: int
get_history_average_price(hours: int, weighted: bool = True) -> float: The average price in hours. weighted: Use weighted average calculation or not. Return type: float
get_history_highest_price(hours: int) -> float: The history highest price in hours. Return type: float sales_push_back(back_num: int) -> float: The price of back_num sales orders shifted backward. Return type: float


For example: "calculation_formula": "max(sales_push_back(total_sell_orders * 0.2), get_history_average_price(720))"


price_setting.least_sells_hours

Type

int

Default

36

Explation

If the sales volume is lower than price_setting.hours_least_sells within price_setting.least_sells_hours, this item will not be sold.


price_setting.hours_least_sells

Type

int

Default

25

Explation

If the sales volume is lower than price_setting.hours_least_sells within price_setting.least_sells_hours, this item will not be sold.


price_setting.least_sell_orders

Type

int

Default

20

Explation

If current selling orders is lower than price_setting.least_sell_orders, the item will not be sold.


price_setting.least_buy_orders

Type

int

Default

0

Explation

If current buying orders is lower than price_setting.least_buy_orders, the item will not be sold.


price_setting.normal_card.lowest_price

Type

float

Default

null

Explation

If the item is normal card and the selling price is lower than the lowest_price, the item will not be sold.


price_setting.normal_card.highest_price

Type

float

Default

null

Explation

If the item is normal card and the selling price is higher than the highest_price, the item will not be sold.


price_setting.foil_card.lowest_price

Type

float

Default

null

Explation

If the item is foil card and the selling price is lower than the lowest_price, the item will not be sold.


price_setting.foil_card.highest_price

Type

float

Default

null

Explation

If the item is foil card and the selling price is higher than the highest_price, the item will not be sold.


price_setting.other_item.lowest_price

Type

float

Default

null

Explation

If the item is not trading card and the selling price is lower than the lowest_price, the item will not be sold.


price_setting.other_item.highest_price

Type

float

Default

null

Explation

If the item is trading card and the selling price is higher than the highest_price, the item will not be sold.

Clone this wiki locally