Skip to main content

Prerequisites

Before integrating the Server API into your plugin, ensure you have:
  • Java 8 or higher installed
  • A Bukkit/Spigot server (1.8.8 or compatible)
  • Maven or Gradle for dependency management
  • The Ember Client Server API plugin installed on your server
You must install the Ember Client Server API plugin on your server before your plugin can interact with it. Download the latest version from the Releases page and place it in your plugins folder.

Add Maven Repository

1

Add the Ember Client Maven repository

Add the following repository to your pom.xml:
pom.xml
<repository>
   <id>emberclient-releases</id>
   <name>Ember Client</name>
   <url>https://repo.emberclient.net/releases</url>
</repository>
For Gradle users, add to your build.gradle:
build.gradle
repositories {
    maven {
        name = "emberclient-releases"
        url = "https://repo.emberclient.net/releases"
    }
}
2

Add the Server API dependency

Add the dependency to your pom.xml:
pom.xml
<dependency>
   <groupId>com.emberclient</groupId>
   <artifactId>ServerAPI</artifactId>
   <version>1.0</version>
</dependency>
For Gradle users:
build.gradle
dependencies {
    compileOnly 'com.emberclient:ServerAPI:1.0'
}
Use compileOnly (Gradle) or provided scope (Maven) since the Server API plugin will be available at runtime on your server.
3

Add softdepend to plugin.yml

Declare the Server API as a soft dependency so your plugin loads after it:
plugin.yml
name: YourPlugin
version: 1.0
main: com.yourpackage.YourPlugin
softdepend: [ECServerAPI]
Using softdepend instead of depend allows your plugin to load even if Ember Client Server API is not installed, so you can gracefully handle its absence.
4

Verify installation

Rebuild your project and verify that the dependency is available:
import com.emberclient.serverapi.ECServerAPI;

public class YourPlugin extends JavaPlugin {
    @Override
    public void onEnable() {
        ECServerAPI api = ECServerAPI.getInstance();
        if (api != null) {
            getLogger().info("Ember Client Server API connected!");
        } else {
            getLogger().warning("Ember Client Server API not found");
        }
    }
}
If the API is properly installed, you should see the success message when your plugin loads.

Next Steps

Now that you’ve installed the API, you’re ready to start building:

Quick Start

Build your first integration with code examples

Core Concepts

Learn about packets, events, and the API architecture

Build docs developers (and LLMs) love