Skip to content

FeatherMC API

The FeatherMC API is a small library, io.github.1chenyip:feather-api, that adds the parts of the server that are unique to FeatherMC: reading feather.yml and reacting to FeatherMC’s built-in features. It is not a copy of the Paper API. It sits on top of it.

FeatherMC keeps the io.papermc.paper and org.bukkit packages, so every Paper, Spigot and Bukkit plugin runs on it unchanged. A plugin that only uses those classes needs nothing from this page.

TypeWhat it does
dev.feathermc.feather.FeatherStatic entry point: isAvailable(), brandName(), version(), config().
dev.feathermc.feather.FeatherPluginBase class for plugins that only run on FeatherMC, or on both FeatherMC and Paper. See Feather-only plugins.
dev.feathermc.feather.FeatherSupportStatic checks: isFeather(), serverType(), serverVersion() and requireFeather(plugin). Works on Paper too.
dev.feathermc.feather.FeatherServerThe FeatherMC-specific server accessor behind Feather. Implemented by FeatherMC, not by plugins.
dev.feathermc.feather.config.FeatherConfigViewA read-only view of feather.yml: the anti-lag-machine guard, the anti-cheat check and whether Sentry is on.
dev.feathermc.feather.event.TntMassDetonationEventCancellable. Fires before the TNT guard removes a cluster.
dev.feathermc.feather.event.AntiCheatFlagEventCancellable, and its action can be changed. Fires when the built-in anti-cheat flags a player.
dev.feathermc.feather.text.AlwaysFormatTurns legacy and/or MiniMessage text (colors, gradients, \n) into a component that renders anywhere. See Always format.

Everything else a plugin needs, such as blocks, entities, commands, the scheduler and Adventure, comes from the Paper API.

These docs are about plugins built for FeatherMC. Extend FeatherPlugin and the plugin runs on FeatherMC and disables itself with a clear message anywhere else. See Feather-only plugins.

public final class MyPlugin extends FeatherPlugin {
@Override
protected void onFeatherEnable() {
if (Feather.config().antiLagMachine().enabled()) {
// FeatherMC-specific behaviour
}
}
}

A plugin can also support Paper as a secondary target. See Supporting Paper too.

Full Javadoc

Adapted from the PaperMC docs (CC BY-SA 4.0). About these docs.