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

# Events

## Notifications

<mark style="color:blue;">`Client`</mark> `nh:client:notify`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>title</code></td><td>string</td><td>A title for the notification</td><td><code>"Vehicle Spawned"</code></td></tr><tr><td><code>description</code></td><td>string</td><td>The main text of the notification, with support for new lines with: <code>\n</code></td><td><code>"You have successfully spawned an Adder"</code></td></tr><tr><td><code>time</code></td><td>integer</td><td>The time the notification should display in milliseconds</td><td><code>5000</code></td></tr><tr><td><code>style</code></td><td>string</td><td>The style of the notification</td><td><code>"info"</code>, <code>"error"</code>, <code>"warning"</code>, <code>"success"</code>, <code>"message"</code> and <code>"announcement"</code></td></tr><tr><td><code>location</code></td><td>string</td><td>The location of the notification</td><td><code>"left"</code>, <code>"center"</code>, <code>"right"</code></td></tr></tbody></table>

```lua
TriggerClientEvent("nh:client:notify", 1, "Vehicle Spawned", "You have successfully spawned an Adder", 5000, "success", "center")
```

## Update Peacetime

<mark style="color:orange;">`Server`</mark> `nh:server:update_peacetime_manual`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>area</code></td><td>string</td><td>The area code you wish to manage</td><td><code>"bc"</code></td></tr><tr><td><code>state</code></td><td>string</td><td>The state to update the area to</td><td><code>"cooldown"</code>, <code>"disabled"</code></td></tr><tr><td><code>time</code></td><td>integer</td><td>The time this should last for in minutes (required for cooldown/hold)</td><td><code>5</code> or <code>0</code></td></tr><tr><td><code>player</code></td><td>string</td><td>The person who set the priority</td><td><code>"Michael Scott"</code> or <code>"Console"</code></td></tr></tbody></table>

```lua
TriggerEvent("nh:server:update_peacetime_manual", "bc", "cooldown", 5, "console") -- on cooldown
TriggerEvent("nh:server:update_peacetime_manual", "bc", "disabled", 0, "console") -- disable
```

## Update Priority

<mark style="color:orange;">`Server`</mark> `nh:server:update_priority_manual`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>area</code></td><td>string</td><td>The area code you wish to manage</td><td><code>"bc"</code></td></tr><tr><td><code>state</code></td><td>string</td><td>The state to update the area to</td><td><code>"available"</code>, <code>"cooldown"</code>, <code>"hold"</code></td></tr><tr><td><code>time</code></td><td>integer</td><td>The time this should last for in minutes (required for cooldown/hold)</td><td><code>5</code> or <code>0</code></td></tr><tr><td><code>player</code></td><td>string</td><td>The person who set the priority</td><td><code>"Michael Scott"</code> or <code>"Console"</code></td></tr></tbody></table>

```lua
TriggerEvent("nh:server:update_priority_manual", "bc", "cooldown", 5, "console") -- set to cooldown (time required)
TriggerEvent("nh:server:update_priority_manual", "bc", "hold", 5, "console") -- set to hold (time required)
TriggerEvent("nh:server:update_peacetime_manual", "bc", "available", 0, "console") -- set to available (time set to 0)
```

## Update AOP

<mark style="color:orange;">`Server`</mark> `nh:server:update_aop_manual`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>areas</code></td><td>string</td><td>The area codes you wish to manage, you can specify multiple separated by a comma</td><td><code>"ss, gs"</code></td></tr><tr><td><code>player</code></td><td>string</td><td>The person who set the priority</td><td><code>"Michael Scott"</code> or <code>"Console"</code></td></tr></tbody></table>

```lua
TriggerEvent("nh:server:update_aop_manual", "ss, gs", "console")
```

## Refresh Custom Elements

<mark style="color:blue;">`Client`</mark> `nh:client:refresh_custom_elements`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>player</code></td><td>string</td><td>The area codes you wish to manage, you can specify multiple separated by a comma</td><td><code>"ss, gs"</code></td></tr></tbody></table>

```lua
TriggerEvent("nh:server:update_aop_manual", "ss, gs", "console")
```

## Update Custom Element

<mark style="color:orange;">`Server`</mark> `nh:server:update_custom_element`

<table><thead><tr><th width="216.27276611328125">Argument</th><th width="139.7274169921875">Type</th><th width="300">Description</th><th>Example</th></tr></thead><tbody><tr><td><code>id</code></td><td>string</td><td>The identifier for the custom element</td><td><code>"unit_counts"</code> </td></tr><tr><td><code>innerHTML</code></td><td>string</td><td>The InnerHTML to update in the custom element.</td><td><pre data-overflow="wrap"><code>&#x3C;b>LEO:&#x3C;/b> &#x3C;span style="color:var(--accent-color);">23&#x3C;/span> &#x3C;span style="color: #BBB;">/&#x3C;/span> &#x3C;b>SAMR:&#x3C;/b> &#x3C;span style="color:var(--accent-color);">8&#x3C;/span> &#x3C;span style="color: #BBB;">/&#x3C;/span> &#x3C;b>DHS:&#x3C;/b> &#x3C;span style="color:var(--accent-color);">1&#x3C;/span> &#x3C;span style="color: #BBB;">/&#x3C;/span> &#x3C;b>STAFF:&#x3C;/b> &#x3C;span style="color:var(--accent-color);">10&#x3C;/span>
</code></pre></td></tr></tbody></table>

```lua
local inner_html = '<b>LEO:</b> <span style="color:var(--accent-color);">23</span> <span style="color: #BBB;">/</span> <b>SAMR:</b> <span style="color:var(--accent-color);">8</span> <span style="color: #BBB;">/</span> <b>DHS:</b> <span style="color:var(--accent-color);">1</span> <span style="color: #BBB;">/</span> <b>STAFF:</b> <span style="color:var(--accent-color);">10</span>'

TriggerEvent("nh:server:update_custom_element", "unit_counts", inner_html)
```


---

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://nexeum.gitbook.io/docs/nex-hud/events.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
