> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jaksam-scripts.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Sold by hired dealer

> Se activa del lado del servidor cuando un hired dealer vende una droga.

Se activa en el servidor cuando un hired dealer vende una droga.

```lua Event theme={null}
AddEventHandler("drugs_creator:hiredDealers:itemSold", function(ownerIdentifier, ownerJob, drugName, quantity, totalPrice, territoryName, accountName)

end)
```

### Parámetros

| Nombre | Tipo de dato | Descripción |
| - | - | - |
| `ownerIdentifier` | string | Identificador del personaje del propietario del dealer |
| `ownerJob` | string | Nombre del job/gang del propietario en el momento de la contratación |
| `drugName` | string | ID del item de la droga vendida |
| `quantity` | integer | Cantidad vendida |
| `totalPrice` | integer | Dinero total obtenido con la venta |
| `territoryName` | string | Nombre del territorio donde se encuentra el dealer |
| `accountName` | string | Tipo de cuenta usada para la recompensa (money, black\_money, etc.) |

## Ejemplo

```lua theme={null}
AddEventHandler("drugs_creator:hiredDealers:itemSold", function(ownerIdentifier, ownerJob, drugName, quantity, totalPrice, territoryName, accountName)
    print(("[Hired Dealer] %s sold %dx %s for $%d in %s (owner: %s, account: %s)"):format(
        ownerJob, quantity, drugName, totalPrice, territoryName, ownerIdentifier, accountName
    ))
end)
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.