# 2 - 开发者API

包：`cn.jonjs.pvpr.api`

类：`PVPRewardsAPI`

引用方法：`PVPRewardsAPI.someFunction();`

API版本：**`3`**

{% tabs %}
{% tab title="所有方法体" %}
{% code title="PVPRewardsAPI.java" %}

```java
均为静态方法, 请直接使用 PVPRewards.someFunction();

```

{% endcode %}
{% endtab %}

{% tab title="使用示例" %}
{% code title="YourPlugin.java" %}

```java
// 其他省略
Player player = event.getPlayer();
int pvpPoint = PVPRewardsAPI.getPoint(player.getName());
player.sendMessage("我的PVP积分: " + pvpPoint);

```

{% endcode %}
{% endtab %}
{% endtabs %}


---

# Agent Instructions: 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:

```
GET https://pvprdoc.jonjs.cn/kai-fa-zhe/developer-2.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
