> For the complete documentation index, see [llms.txt](https://docs.walecloud.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.walecloud.com/api-documentation/getting-started.md).

# Getting Started

### How do I import the API?

To integrate the Wale API into your project, we recommend using Gradle or Maven. **Do not shade it**.

1. **First, you need to register the repository server by using the following URL:**

{% tabs %}
{% tab title="Gradle (Groovy)" %}

```gradle
maven {
    name "waleRepositoryReleases"
    url "https://repo.walecloud.com/releases"
}
```

{% endtab %}

{% tab title="Maven" %}

```xml
<repositories>
    <repository>
        <id>waleRepositoryReleases</id>
        <name>waleRepositoryReleases</name>
        <url>https://repo.walecloud.com/releases</url>
    </repository>
</repositories>
```

{% endtab %}
{% endtabs %}

2. **After that, add the dependency to your project.**

You can always check the latest version on the [repository server](https://repo.walecloud.com/#/releases/at/stefan/wale-api). For this documentation, version `1.5.8` is used.

{% tabs %}
{% tab title="Gradle (Groovy)" %}

```gradle
dependencies {
    compileOnly "at.stefan:wale-api:VERSION"
}
```

{% endtab %}

{% tab title="Maven" %}

```xml
<dependencies>
    <dependency>
        <groupId>at.stefan</groupId>
        <artifactId>wale-api</artifactId>
        <version>VERSION</version>
        <scope>provided</scope>
    </dependency>
</dependencies>
```

{% endtab %}
{% endtabs %}

{% hint style="danger" %}
Important: **Do not** shade the API yourself; **depend** on the **Wale plugin**, which always includes the **latest** API version.
{% endhint %}

### How do I now use the API in my project?

{% hint style="warning" %}
Create **only one instance** per plugin. If you have multiple plugins using the API, try to create only one instance and centralize it, as it can **save** on **traffic**.
{% endhint %}

```java
// An example of how to initialize the API
public class Test extends JavaPlugin {
    
    @Getter
    private WaleAPI waleAPI;
    
    @Override
    public void onEnable() {
        waleAPI = new WaleAPI();
    }
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.walecloud.com/api-documentation/getting-started.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
