Cloud API
有关本项目的详细信息,请参阅我们详细的 文档。
本项目旨在提供非常简单的 API 访问方式。本项目修复了此前存在的所有依赖问题。 将平台 JAR 安装到服务器中,并按照下文描述使用依赖项。
[!CAUTION] Paper 专用 API 处于非常实验性的阶段且不稳定。如果您运行的是 Paper,请使用 Spigot API!
功能
- 易于使用的 API:只需将插件添加到服务器并将 api 作为 provided artifact 包含即可。
- 支持的服务器软件:支持 Spigot 及其分支、Paper、Folia、BungeeCord、Velocity、Fabric、Quilt 和 NeoForge。
- 易于访问 API:仅通过一个接口使用我们提供的每个 API 方法。
服务器安装
- 将 Spigot、Paper、Folia、BungeeCord 和 Velocity 的 JAR 放入服务器的
plugins目录。 - 将 Fabric/Quilt 或 NeoForge 的 JAR 放入服务器的
mods目录。 - 共享的 Fabric/Quilt 构建需要 Fabric API。
- Fabric、Quilt 和 NeoForge 支持仅限服务端,目标为 Minecraft 26.2,并且不需要客户端安装模组。
用法
Go
独立的 Go SDK 位于 go/ 中。它包含完整的 Controller REST API 以及类型化的 NATS 事件,不需要 Minecraft 插件运行时。
client, err := simplecloud.NewClientFromEnv()
if err != nil {
log.Fatal(err)
}
defer client.Close()
groups, _, err := client.Groups.List(context.Background(), nil)
有关安装、配置、事件和原始端点访问,请参阅 Go API README。
1. 依赖 simplecloud-api
2. 使用 APIs
如需始终最新的构件,请访问 dev artifacts 或 artifacts。
注意:如果您想使用开发版本,则必须使用 snapshot repository。
Gradle Kotlin
compileOnly("app.simplecloud.api:api:VERSION")
Gradle Groovy
compileOnly 'app.simplecloud.api:api:VERSION'
Maven
<dependencies>
<dependency>
<groupId>app.simplecloud.api</groupId>
<artifactId>api</artifactId>
<version>VERSION</version>
<scope>provided</scope>
</dependency>
</dependencies>
贡献
欢迎并非常感谢对 SimpleCloud 的贡献。然而,在您直接投入之前,我们希望您先阅读我们的 贡献指南。
NATS 集成测试
在运行隔离的 NATS 代理的情况下,使用 NATS_TEST_URL=nats://127.0.0.1:4222 ./gradlew :api:test --rerun-tasks 来测试重连前后的请求收件箱。当未设置该变量时,将跳过代理测试。Go SDK README 描述了等效的 Go 测试。
许可证
此存储库根据 Apache 2.0 许可协议授权。
[social-youtube]:
Cloud API
[][social-youtube]
Report a Bug
·
Request a Feature
? Give us a star — your support means the world to us!
All information about this project can be found in our detailed documentation.
This Project aims to provide very easy API access. This project fixes all dependency issues that were present before. Install the platform JAR on the server and use the dependency as described below.
[!CAUTION] Paper specific API is very experimental and unstable. Use Spigot API if you are running paper!
Features
- Easy API Use: Just add the plugin to your server and include the api as a provided artifact.
- Supported Server Software: Supports Spigot and forks, Paper, Folia, BungeeCord, Velocity, Fabric, Quilt, and NeoForge.
- Easy API access: Use every api method we provide, just from one interface.
Server Installation
- Put the Spigot, Paper, Folia, BungeeCord, and Velocity JAR in the server's
pluginsdirectory. - Put the Fabric/Quilt or NeoForge JAR in the server's
modsdirectory. - The shared Fabric/Quilt build requires Fabric API.
- Fabric, Quilt, and NeoForge support is server-side only, targets Minecraft 26.2, and does not require clients to install the mod.
Usage
Go
The standalone Go SDK lives in go/. It includes the complete Controller REST API plus typed NATS events and does not require a Minecraft plugin runtime.
client, err := simplecloud.NewClientFromEnv()
if err != nil {
log.Fatal(err)
}
defer client.Close()
groups, _, err := client.Groups.List(context.Background(), nil)
See the Go API README for installation, configuration, events, and raw endpoint access.
1. Depend on simplecloud-api
2. Use APIs
For always up-to-date artifacts visit dev artifacts or artifacts.
Note: If you want to use the dev version, you have to use the snapshot repository.
Gradle Kotlin
compileOnly("app.simplecloud.api:api:VERSION")
Gradle Groovy
compileOnly 'app.simplecloud.api:api:VERSION'
Maven
<dependencies>
<dependency>
<groupId>app.simplecloud.api</groupId>
<artifactId>api</artifactId>
<version>VERSION</version>
<scope>provided</scope>
</dependency>
</dependencies>
Contributing
Contributions to SimpleCloud are welcome and highly appreciated. However, before you jump right into it, we would like you to read our Contribution Guide.
NATS integration tests
With an isolated NATS broker running, use NATS_TEST_URL=nats://127.0.0.1:4222 ./gradlew :api:test --rerun-tasks to test request inboxes before and after reconnecting. The broker test is skipped when the variable is unset. The Go SDK README describes the equivalent Go tests.
License
This repository is licensed under Apache 2.0.
[social-youtube]:
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 SimpleCloud API Plugin
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
一个用于收集生物掉落物的多区块模组。
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
适用于 MC 1.18+ 的 Effekseer 加载器
模组
那是什么?一个 Waila/Hwyla 的分支。
评论 0
登录后参与评分
还没有评论,来抢沙发吧