> For the complete documentation index, see [llms.txt](https://docs-nightbeam.gitbook.io/infinity-rifts/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-nightbeam.gitbook.io/infinity-rifts/docs/commands.md).

# Commands

The plugin registers one command, `/rift`, with alias `/rifts`. `plugin.yml` applies `infinityrifts.use` to the root command before the executor runs. All subcommands are case-insensitive. Unknown subcommands show help to players.

## Summary

| Syntax                          | Purpose                                         | Implementation permission              | Sender         |
| ------------------------------- | ----------------------------------------------- | -------------------------------------- | -------------- |
| `/rift`                         | Show player help; console gets give usage       | root `infinityrifts.use`               | Player/console |
| `/rift invite <player>`         | Invite an online player to the pending party    | `infinityrifts.use`                    | Player         |
| `/rift kick <player>`           | Remove an online member from the leader's party | `infinityrifts.use`                    | Player         |
| `/rift join <player>`           | Accept that online leader's invitation          | `infinityrifts.use`                    | Player         |
| `/rift leave`                   | Leave the current gateway or pending party      | root only                              | Player         |
| `/rift party`                   | Display pending-party or active-session members | root only                              | Player         |
| `/rift admin`                   | Open the admin gateway GUI                      | `infinityrifts.admin`                  | Player         |
| `/rift give <player> <gateway>` | Give an online player a configured gateway key  | `infinityrifts.admin.give` for players | Player/console |
| `/rift reload`                  | Reload main and gateway configuration objects   | `infinityrifts.admin.reload`           | Player         |
| `/rift list`                    | List loaded gateway IDs                         | `infinityrifts.admin`                  | Player         |

The console may execute only `give`; every other console subcommand responds `Only players can use this subcommand.` Console still passes the root permission under normal Bukkit behavior.

## Party commands

`invite`, `kick`, and `join` require exactly one meaningful player argument; extra arguments are ignored. Targets must be online and resolved by `Server#getPlayer`. The manager rejects self-invites, duplicate/missing invitations, party membership conflicts, active gateway conflicts, and party/cooldown violations with hard-coded MiniMessage responses. Invitations expire after `party.invite-timeout-seconds` (default 60). `join` names the inviting leader, not a gateway ID.

`leave` first removes a player from an active gateway with reason `PLAYER_LEAVE`; if not active, it leaves a pending party. `party` is read-only and prints online/offline state.

Examples:

```
/rift invite Steve
/rift join Alex
/rift kick Steve
/rift party
/rift leave
```

## Administrative commands

### `/rift admin`

Opens `AdminGui`. Left-clicking a gateway starts it at the administrator; shift-clicking reloads all gateway files. The GUI also has global reload, pagination, and close controls. See [GUI documentation](/infinity-rifts/docs/gui.md).

### `/rift give <player> <gateway>`

Creates the gateway's configured item, appends a generated wave/reward preview, and adds the PDC gateway ID. Invalid gateway IDs use `messages.gateway-not-found`; offline/unknown players use `messages.player-not-found`. Invalid key materials fall back to `NETHER_STAR`. Inventory overflow returned by `addItem` is not handled in this command, so use it when the target has space.

Console example:

```
rift give Steve void_gate
```

### `/rift reload`

Reloads `config.yml` and every `*.yml` directly inside `gateways/`. It does not call `RandomSpawnManager.reload()`, `GatewayManager.reload()`, or alter active instances. Invalid files log an error/warning; successfully parsed files replace the in-memory map.

### `/rift list`

Shows IDs and display names from the gateway map. File iteration/map order is not an API guarantee.

## Completion and errors

First-argument completion always exposes every subcommand without filtering by permission. Player-name positions return Bukkit's default online-player completion. The third argument of `give` completes loaded gateway IDs.

The root descriptor usage is `/rift <command>`. The implementation always returns `true`, so Bukkit does not emit descriptor usage on handler errors.
