Wiki Navigation

API Reference
CRUD Operations

Trader Items API

Manage trader items and pricing for your server. Control what items traders buy and sell, set prices, and configure stock quantities for trader mods.

Authentication required: All endpoints require a valid Bearer token. See Authentication for details.

GET

List Trader Items

Retrieve a paginated list of trader items for a specific instance.

Endpoint

GET /api/instance/{instance_sid}/trader-item

Parameters

instance_sid
string required

The SID of the instance (URL parameter)

page integer

Page number for pagination. Defaults to 1.

like string

Filter trader items by classname using partial match.

Response

{
  "current_page": 1,
  "data": [
    {
      "sid": "abc123",
      "classname_id": 456,
      "classname": "AKM",
      "buy_price": 5000,
      "sell_price": 2500,
      "stock": -1,
      "trader_id": 1,
      "enabled": true
    }
  ],
  "per_page": 30,
  "total": 150
}
GET

Get Trader Item

Retrieve details of a specific trader item.

Endpoint

GET /api/instance/{instance_sid}/trader-item/{item_sid}

URL Parameters

instance_sid required

The SID of the instance

item_sid required

The SID of the trader item

POST

Create Trader Item

Create a new trader item for an instance.

Endpoint

POST /api/instance/{instance_sid}/trader-item

Request Body

classname_id
integer required

Associated classname ID

buy_price integer

Price players pay to buy

sell_price integer

Price players receive when selling

stock integer

Available stock quantity (-1 = unlimited)

trader_id integer

ID of the trader selling this item

enabled boolean

Whether item is available for trade

PATCH

Update Trader Item

PATCH /api/instance/{instance_sid}/trader-item/{item_sid}

Update an existing trader item. Include only fields to change.

DELETE

Delete Trader Item

DELETE /api/instance/{instance_sid}/trader-item/{item_sid}

Permanently delete a trader item from the instance.

Pro Tips

Set sell_price lower than buy_price to prevent infinite money exploits. Use stock limits for rare items to create scarcity. Set stock to -1 for common items that should always be available.