LogoLogo
  • Welcome
  • zAPI
    • Usage
      • Getting Started
      • JavaDocs
  • zHomes
    • Commands & Permissions
    • Hooks
      • PlaceholderAPI
      • WorldGuard
      • Vault
    • Plugin Files
      • config.yml
      • menus/
        • menu-homes.yml
      • languages/
        • de.yml
        • en.yml
        • es.yml
        • fr.yml
        • it.yml
        • nl.yml
        • pl.yml
        • pt-br.yml
        • ru.yml
    • Developer API
      • Getting Started
      • Events
      • JavaDocs
Powered by GitBook

Copyright @ 2025 yLeoft

On this page
  • Declare zAPI dependency in your build files
  • Maven
  • Gradle

Was this helpful?

Export as PDF
  1. zAPI
  2. Usage

Getting Started

Get started using the zAPI API.

PreviousUsageNextJavaDocs

Last updated 7 days ago

Was this helpful?

Declare zAPI dependency in your build files

The dependency is published on , meaning you don't need to parse the repository.

Maven

<build>
    <defaultGoal>clean package</defaultGoal>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-shade-plugin</artifactId>
            <version>3.5.3</version>
            <executions>
                <execution>
                    <phase>package</phase>
                    <goals>
                        <goal>shade</goal>
                    </goals>
                    <configuration>
                        <relocations>
                            <relocation>
                                <pattern>me.yleoft.zAPI</pattern>
                                <shadedPattern>your.package.shaded.zAPI</shadedPattern>
                            </relocation>
                        </relocations>
                    </configuration>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>

<dependencies>
    <dependency>
        <groupId>me.yleoft</groupId>
        <artifactId>zAPI</artifactId>
        <version>1.3.3</version>
        <scope>compile</scope>
    </dependency>
</dependencies>

maven-shade-plugin from org.apache.maven.plugins is used to relocate the package of the API, you can use it without relocating, but it may cause some incompatibilities.

Gradle

plugins {
    id("com.github.johnrengelman.shadow") version "8.1.1"
}

dependencies {
    implementation("me.yleoft:zAPI:1.3.3")
}

shadowJar {
    relocate 'me.yleoft.zAPI', 'your.package.shaded.zAPI'
}

shadowJar from com.github.johnrengelman.shadow is used to relocate the package of the API, you can use it without relocating, but it may cause some incompatibilities.

Maven Central