# exports/handlers

1. ban

```
exports['here_put_api_script_name']:ban(source, "here_put_reason") 
-- It putting someone to API banlist and it dropping him from server. 
Simple ban with api. EXPORT IS SERVER-SIDED example.
exports['minerixon']:ban(source, "Exploiting event without job.") 
minerixon is api folder, source is source from event and next to source is reason.
```

2. getAllPlayerIdentifiers&#x20;

```
exports['here_put_api_script_name']:getAllPlayerIdentifiers(source, boolean) 
- Use it if u want to get someones identifiers with API. 
boolean is true or false
If u set it to true API will return 1 table with every identifier even with tokens
if u set false then api will return you named table you can get from it: steam, license, ip, discord, liveid, xbl, name example.
true:

local identifiers = exports['minerixon']:getAllPlayerIdentifiers(source, true)

for k,v in pairs(identifiers) do
    print(v)    -- v return every identifier!
end
```

*false:*

```
local identifiers = exports['minerixon']:getAllPlayerIdentifiers(source, false) -- it contains steam, license, ip, discord, liveid, xbl, name

print(identifiers.name)
print(identifiers.license)
```

3. addPlayerPermission&#x20;

* Export is server sided.

  * You can call it like that example: exports\['name\_of\_ac\_folder']:addPlayerPermission(source, "bypass", true)
  * You can add it to your framework if you want to give someone permissions when he get role from server.

  ```lua
  exports['name_of_ac_folder']:addPlayerPermission(source, "bypass", true)
  ```

**HANDLERS:**

1. API:BanACHandler&#x20;

   ```lua
   AddEventHandler("API:BanACHandler", function(PlayerID, PlayerName, BanReason)
       -- you can write your code here.
   end)
   ```

So you can execute your code ex. Chat message for all/admins etc.
