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

# Commands & permissions

Commands and keys of Cuxial Community Service, and the staff permission each one needs.

Staff sanction players with four commands and review everything from one panel. Players have no commands: they only use the interaction key.

## Commands

| Command                           | Who                 | What it does                                                                                      |
| --------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------- |
| `/sanciones`                      | Staff (`group.mod`) | Opens or closes the sanctions panel.                                                              |
| `/comserv <id> <amount> <reason>` | Staff (`group.mod`) | Gives community service tasks to the player with that server id. The reason can be several words. |
| `/endcomserv <id>`                | Staff (`group.mod`) | Removes the community service of that player and moves them to the exit point.                    |
| `/jaila <id> <minutes> <reason>`  | Staff (`group.mod`) | Sends the player to administrative jail for that many minutes. The reason is one word.            |
| `/endjail <id>`                   | Staff (`group.mod`) | Removes the jail time of that player and moves them to the jail exit point.                       |
| `/taskcoords`                     | Everyone            | Turns the task mapping tool on or off.                                                            |

{% hint style="info" %}
All arguments are required. `<id>` is the server id of a connected player. `<amount>` and `<minutes>` must be greater than zero; decimals are rounded down.
{% endhint %}

### Rules

* A character holds one sanction at a time. `/comserv` and `/jaila` are refused while the player has community service or jail active.
* `/endcomserv` and `/endjail` only act on a player who has that sanction.
* The staff member and the player are notified of every sanction given or removed.
* Sanctions given and sanctions served are announced to the whole server in the chat.

## Sanctions panel

`/sanciones` opens a panel with one tab per sanction type. Each tab lists every character with an active sanction of that type, connected or not, with the details of the sanction.

From the panel, staff can remove a sanction from any character on the list. A connected player is released at once; a disconnected one finds the sanction gone on their next login.

## Keys

| Key          | Where                                  | What it does                                                                                     |
| ------------ | -------------------------------------- | ------------------------------------------------------------------------------------------------ |
| <kbd>E</kbd> | At the interaction point of a task     | Starts the task.                                                                                 |
| <kbd>E</kbd> | Task mapping tool                      | Copies the aimed object (model and position), or the ground position when no object is aimed at. |
| <kbd>G</kbd> | Task mapping tool, aiming at an object | Copies a full task entry for `config/shared.lua`.                                                |
| <kbd>X</kbd> | Task mapping tool                      | Closes the tool.                                                                                 |

## Task mapping tool

`/taskcoords` helps you write new tasks without typing coordinates by hand. While it is on, a line goes from your character to the point you are aiming at, up to 50 metres away. Objects are outlined, and their model and position are shown on screen.

| You press                  | Copied to the clipboard                                                                                                  |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| <kbd>E</kbd> on an object  | `object = { model = ..., coords = vec3(...) },`                                                                          |
| <kbd>E</kbd> on the ground | `coords = vec3(...),`                                                                                                    |
| <kbd>G</kbd> on an object  | A full task entry with `coords`, `name`, `object` and `progress`, ready to paste into a category of `COMSERV.taskZones`. |

After pasting a full entry, change its `name` and adjust `progress` to the task. The fields are explained in [Configuration](/scripts/core/cuxial-cmservices/configuration.md).

## Permissions

The staff commands and the panel pass two checks:

| Check                | Requirement                                                                  |
| -------------------- | ---------------------------------------------------------------------------- |
| Command access       | The player belongs to the ACE group `group.mod`, directly or by inheritance. |
| Framework permission | The player holds the `mod` permission of the framework.                      |

{% code title="server.cfg" %}

```cfg
# Moderators hold the "mod" permission
add_ace group.mod mod allow

# Admins inherit everything moderators can do
add_principal group.admin group.mod

# One line per staff member
add_principal identifier.license:xxxxxxxxxxxxxxxx group.mod
```

{% endcode %}

The panel checks the `mod` permission again on the server for every request, so its data cannot be read or changed by a player without it.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.cuxial.com/scripts/core/cuxial-cmservices/commands.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
