> 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/interface/cuxial-anuncios/commands.md).

# Commands & permissions

The two commands of Cuxial Announcements and who can use each one.

Cuxial Announcements has two commands: one for players and one for staff. Both names can be changed in `shared/config.lua`.

## Commands

| Command              | Who                           | What it does                                                                         |
| -------------------- | ----------------------------- | ------------------------------------------------------------------------------------ |
| `/anuncio <message>` | Players whose job has a style | Sends the message to every player on the server, with the style of the sender's job. |
| `/crearanuncio`      | Staff with `adminPermission`  | Opens the panel to create, edit and delete styles.                                   |

`<message>` is required.

### How `/anuncio` behaves

* The style is chosen by the name of the player's current job. Duty status and grade are not checked: any member of the job can announce.
* If the job has no style, the player gets an error notification and nothing is sent.
* After sending, the player must wait `cooldown` seconds (30 by default) before the next announcement. The wait is per player.
* Announcements are queued on each player's screen. One is shown at a time, for `duration` milliseconds, with a short pause before the next.

## Keys

The script registers no keys.

## Permissions

Opening the panel and saving or deleting styles require the permission set in `adminPermission`, `'admin'` by default. The check runs on the server through Cuxial Bridge, so it follows your framework:

{% tabs %}
{% tab title="QBox / QBCore" %}
The value is passed to the framework's own permission check. Use a permission that already exists on your server, such as the one your framework uses for its admin commands.
{% endtab %}

{% tab title="ESX" %}
`'admin'` matches players in the groups `admin` and `superadmin`. Any other value must be the exact name of the player's group.
{% endtab %}
{% endtabs %}

{% hint style="info" %}
The script adds no ACE permissions of its own, and `/anuncio` needs none. Access to it depends only on the player's job having a style.
{% endhint %}


---

# 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/interface/cuxial-anuncios/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.
