Wiki Navigation

API Reference
CRUD Operations

Trader Currencies API

Manage trader currencies to define how players pay for items. Configure custom currency classnames and values for your server's economy.

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

GET

List Trader Currencies

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

Endpoint

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

Parameters

instance_sid
string required

The SID of the instance (URL parameter)

like string

Filter currencies by classname using partial match.

amount integer

Number of results per page. Defaults to 30.

Response

{
  "current_page": 1,
  "data": [
    {
      "id": 1,
      "sid": "cur123abc456",
      "classname_id": 5432,
      "value": 1,
      "instance_id": 1,
      "created_at": "2025-01-15T10:30:00Z",
      "updated_at": "2025-01-15T10:30:00Z",
      "classname": {
        "id": 5432,
        "classname": "TraderPlus_Money_Dollar1"
      }
    }
  ],
  "per_page": 30,
  "total": 5
}
GET

Get Trader Currency

Retrieve details of a specific trader currency, including its classname information.

Endpoint

GET /api/instance/{instance_sid}/trader-currency/{currency_sid}

URL Parameters

instance_sid required

The SID of the instance

currency_sid required

The SID of the trader currency

POST

Create Trader Currency

Create a new trader currency for an instance.

Endpoint

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

Request Body

classname_id
integer required

ID of the classname entry representing this currency item

value
integer required

Value of the currency item (e.g., 1, 5, 10, 100)

Example Request

{
  "classname_id": 5432,
  "value": 100
}
PATCH

Update Trader Currency

PATCH /api/instance/{instance_sid}/trader-currency/{currency_sid}

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

DELETE

Delete Trader Currency

DELETE /api/instance/{instance_sid}/trader-currency/{currency_sid}

Permanently delete a trader currency from the instance.

Currency Denominations

Configure multiple currency items with different values to create a realistic economy. For example:

  • TraderPlus_Money_Dollar1 → value: 1
  • TraderPlus_Money_Dollar5 → value: 5
  • TraderPlus_Money_Dollar10 → value: 10
  • TraderPlus_Money_Dollar100 → value: 100