# Usage

{% hint style="info" %}
**Each notification call should consist of following:**

* Type - one of 5 notifications types *(see Features)*
* Title - notification title
* Text - notification text
* Time - how long should the notification stay on screen (in miliseconds)
* Sound - should the sound be played (true/false)
  {% endhint %}

## There are two ways of sending a notification:

### By event:

#### *Triggering on client side:*

<pre class="language-lua"><code class="lang-lua"><strong>TriggerEvent('pc_notifications:Notify', type, title, text, time, true) 
</strong></code></pre>

#### *Triggering on server side:*

```lua
TriggerClientEvent('pc_notifications:Notify', playerId, type, title, text, time, true) 
```

### By export:

```lua
exports['pc_notifications']:Notify(type, title, text, time, true)
```
