Skip to content

Developer API

Sauron_Dev edited this page Jun 9, 2026 · 3 revisions

Developer API

VortexEnchantments includes an API package for integrations.

Package:

com.vortexrpg.enchantments.api

Integration Goals

Use the API when another plugin needs to:

  • Check whether an item has VortexEnchantments.
  • Read enchantment data.
  • Add or remove enchantments through supported methods.
  • Build menus or rewards around Vortex enchant ids.
  • Integrate custom progression, crates, quests, or dungeons.

Best Practices

  • Do not parse lore manually if an API method exists.
  • Do not modify plugin data containers without using supported methods.
  • Do not run expensive item scans every tick.
  • Cache carefully and invalidate when items change.
  • Avoid cross-region unsafe entity access on Folia.

Dependency Setup

Add VortexEnchantments as a compile-only dependency in your plugin project when a public artifact is available.

Example Gradle shape:

dependencies {
    compileOnly("com.vortexrpg:VortexEnchantments:<version>")
}

If using a local jar:

dependencies {
    compileOnly(files("libs/VortexEnchantments.jar"))
}

Plugin Load Order

Use softdepend or depend depending on whether your plugin can run without VortexEnchantments.

softdepend:
  - VortexEnchantments

Use depend only if your plugin cannot start without it.

Support

For API questions, join:

https://discord.gg/Tya84XrgSF

Clone this wiki locally