Discord
v1.0.0Paper & Folia 1.21.11–26.3 (latest)

Developer API

Developer API for RogueTrade.

Last reviewed September 2026

Public API

#

RogueTradeAPI is available through ServicesManager with immutable views and async results.

Get RogueTradeAPI

#

Resolve the service after plugins have enabled. Always handle a missing provider so your plugin fails clearly instead of crashing.

text
// Add RogueTradeAPI from the installed plugin API to your imports.
RogueTradeAPI api = Bukkit.getServicesManager().load(RogueTradeAPI.class);

if (api == null) {
    getLogger().warning("RogueTradeAPI is unavailable; disabling this integration.");
    getServer().getPluginManager().disablePlugin(this);
    return;
}

// Keep the reference and call only methods exposed by your installed version.

Events

#

Register Bukkit listeners normally and use only event methods exposed by the installed API. Pre-events marked cancellable can stop an operation; completed events report an outcome after it has happened.

  • TradeOpenEvent
  • TradeOfferChangeEvent
  • TradeAcceptEvent
  • TradePreCompleteEvent (cancellable)
  • TradeCompleteEvent
  • TradeCancelEvent

Still stuck? Ask in Discord.