logo Developer API
Market Buy Orders


Intro

Buy orders are a feature to request items you want to buy, at the price you want to buy them. This feature gives our sellers a heads up for items that will be purchased instantly when listed for sale at or below given prices.

All of the following methods require the API Key, which you can retrieve through the settings page after you enable API access for your account. All API calls are accessible through GET and POST methods. Furthermore, all API calls require Secure Access to be enabled, and a two-factor security code generated for every single API call you make. For information on how to generate this two-factor security code, see the General API documentation.

The interactive widget you will see under the respective API calls here once your account is Secure Access-verified generates the codes automatically.

Default API throttle limits are 8 requests per second. Contact us if you need higher limits.


Using Different Steam Games' Inventories

As of 09/17/2017, you can now use different games' inventories at BitSkins for trading/buying/selling purposes. Game-specific API endpoints are listed below, with the optional parameter app_id. If this parameter is not specified, the API requests are interpreted as being for CS:GO (Counter-Strike: Global Offensive) by default to avoid breaking CS:GO-specific developer implementations.

The available games at BitSkins are as follows. Please note that this list may be expanded at any time in the future, so check back!

Game NameShort Nameapp_idcontext_id
Counter-Strike: Global OffensiveCSGO7302
Defense of the Ancients 2DotA25702
PlayerUnknown's BattlegroundsPUBG5780802
Team Fortress 2TF24402
PayDay 2PD22186202
RustRUST2524902
Killing Floor 2KF22320902

Please note that the context_id parameter can be provided alongside, but this is not currently required.


Create Buy Order

Allows you to create a buy order for a single item. Buy orders are executed within 30 seconds if someone lists an item for sale that is at or below your buy order price. Funds are not withheld because of pending buy orders, but will be automatically cancelled if your account has insufficient funds to execute a buy order when an eligible item is up for sale.

Multiple simultaneous calls to this method may result in 'Failed to acquire lock' errors.

Endpoint
/api/v1/create_buy_order

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
name
The name of the item you want to purchase.
price
The price at which you want to purchase the item. Use 'auto' to buy at current market value.
quantity
Number of buy orders to create at this price for this item. (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/create_buy_order/?api_key=API_KEY&code=CODE&name=NAME&price=PRICE&quantity=QUANTITY&app_id=APP_ID
           
        

Get Expected Place in Queue

Allows you to retrieve the expected place in queue for a new buy order without creating the buy order.

Endpoint
/api/v1/get_expected_place_in_queue_for_new_buy_order

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
name
The name of the item you want to purchase.
price
The price at which you want to purchase the item. Use 'auto' to buy at current market value.
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_expected_place_in_queue_for_new_buy_order/?api_key=API_KEY&code=CODE&name=NAME&price=PRICE&app_id=APP_ID
           
        

Cancel Buy Orders

Allows you to cancel upto 999 active buy orders.

Multiple simultaneous calls to this method may result in 'Failed to acquire lock' errors.

Endpoint
/api/v1/cancel_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
buy_order_ids
Comma-separated string of up to 999 buy order IDs.
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/cancel_buy_orders/?api_key=API_KEY&code=CODE&buy_order_ids=BUY_ORDER_IDS&app_id=APP_ID
           
        

Cancel All Buy Orders

Allows you to cancel all buy orders for a given item name.

Multiple simultaneous calls to this method may result in 'Failed to acquire lock' errors.

Endpoint
/api/v1/cancel_all_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
market_hash_name
The item name
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/cancel_all_buy_orders/?api_key=API_KEY&code=CODE&market_hash_name=MARKET_HASH_NAME&app_id=APP_ID
           
        

Get My Buy Orders

Allows you to retrieve all buy orders you have placed, whether active or not.

Endpoint
/api/v1/get_buy_order_history

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
page
The page number. (optional)
type
Either listed, settled, cancelled_by_user, or cancelled_by_system (optional)
market_hash_name
An item's name (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_buy_order_history/?api_key=API_KEY&code=CODE&page=PAGE&type=TYPE&market_hash_name=MARKET_HASH_NAME&app_id=APP_ID
           
        

Get Settled Orders

Allows you to retrieve all buy orders you made that have been settled. Provides information on the item you purchased to settle this buy order. Deprecated, use get_buy_order_history.

Endpoint
/api/v1/get_settled_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
page
The page number. (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_settled_buy_orders/?api_key=API_KEY&code=CODE&page=PAGE&app_id=APP_ID
           
        

Get Active Buy Orders

Allows you to retrieve all buy orders that have not been cancelled or settled. Deprecated, use get_buy_order_history.

Endpoint
/api/v1/get_active_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
page
The page number. (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_active_buy_orders/?api_key=API_KEY&code=CODE&page=PAGE&app_id=APP_ID
           
        

Get Cancelled Buy Orders

Allows you to retrieve all buy orders that have been cancelled by you or the system. The system cancels buy orders automatically if you have insufficient funds to settle the buy order. Deprecated, use get_buy_order_history.

Endpoint
/api/v1/get_cancelled_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
page
Page number. (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_cancelled_buy_orders/?api_key=API_KEY&code=CODE&page=PAGE&app_id=APP_ID
           
        

Get Market Buy Orders

Allows you to retrieve all market orders by all buyers (except your own) that need fulfillment.

Endpoint
/api/v1/get_market_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
market_hash_name
The item name for which you seek buy orders. If not provided, you will get active buy orders for all items. (optional)
page
Page number. (optional)
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/get_market_buy_orders/?api_key=API_KEY&code=CODE&market_hash_name=MARKET_HASH_NAME&page=PAGE&app_id=APP_ID
           
        

Summarize Buy Orders

Allows you to retrieve a summary of all market buy orders. Results include your own buy orders, where applicable.

Endpoint
/api/v1/summarize_buy_orders

Request Parameters

api_key
Your API Key as a string.
code
Two-factor authentication code.
app_id
The app_id for the inventory's game (defaults to CS:GO if not specified). (optional)

Example Request

          
https://bitskins.com/api/v1/summarize_buy_orders/?api_key=API_KEY&code=CODE&app_id=APP_ID