Business
Writing documentation for FiveM resources
Write documentation that cuts support tickets: a README structure (requirements, installation, configuration), a config reference, exports and events API docs, framework notes, troubleshooting and FAQ, changelogs, and choosing a docs site.
Overview
Every question a buyer asks in your Discord is a missing sentence in your documentation. Good docs are the cheapest support you will ever have: they turn “it does not work” into a successful install, and they make a script look professional before anyone runs it.
A README template
# my_garage
Persistent garages with impound and job vehicles.
## Requirements
- ox_lib (latest release)
- oxmysql
- ESX Legacy, QBCore or Qbox
## Installation
1. Import `install.sql`.
2. Put `my_garage` in your resources folder.
3. Add to server.cfg after your framework:
ensure ox_lib
ensure my_garage
## Configuration
See `config.lua` — every option is described below.
## Commands
| Command | Who | What |
|---|---|---|
| /impound | police | Impound the nearest vehicle |
## Exports
`exports.my_garage:GetVehicles(source)` → list of the player’s vehicles.
## Troubleshooting
| Error | Fix |
|---|---|
| `attempt to index a nil value (global 'lib')` | ox_lib not started before my_garage |
## Changelog
- 1.2.0 — Qbox support, impound feesDocumenting configuration
For every option: name, type, default, what it does and an example. Group related options. If your config is well structured with annotations, most of this can be copied from it — see config.lua best practices and Lua annotations.
Documenting exports and events
| Include | Example |
|---|---|
| Name and side | GetVehicles (server export) |
| Parameters | source: number |
| Return value | { plate: string, model: string }[] |
| Example call | local cars = exports.my_garage:GetVehicles(src) |
| Events emitted | my_garage:vehicleStored (server, args: source, plate) |
Troubleshooting that saves tickets
Collect the errors people report and write the fix next to the exact message they see in F8 or the server console. Common ones for any script are covered in common Lua errors and F8 and server errors — link to them.
Where to host docs
- README in the resource — always, even with a docs site.
- A docs site (GitBook, Docusaurus, VitePress) for large or multiple products.
- Pin the docs link in your Discord support channel and Tebex listing.
Frequently asked questions
What should FiveM script documentation include?
Requirements, installation steps, a full config reference, commands and items, exports and events, troubleshooting, FAQ and a changelog.
Do escrowed scripts need documentation?
Even more — buyers cannot read the code, so the docs are all they have.
Where should I publish documentation?
In the resource’s README, and on a docs site for bigger products, linked from your store and Discord.
How do I reduce support requests?
Turn every repeated question into a troubleshooting or FAQ entry.
Need this built, not just explained?
Ten years of FiveM work, from Lua to NUI
Custom resources, React NUI, ESX / QBCore / Qbox integration, OneSync performance audits and security reviews — plus the websites and SEO around your server brand.
Related guides
- BusinessSelling your FiveM scripts through TebexCreate a Tebex account, complete identity verification, make a project and link your Cfx.re account. Upload your zipped resource to the Cfx.re Portal to escrow it, then create a Tebex package that delivers that “FiveM Asset”. Buyers get it in their Portal account and it runs on servers they own. Escrowed assets can only be distributed through Tebex. Add a clear description, a video preview, documentation and a support channel before launch.
- EngineeringDesigning a config.lua people can actually usePut values owners change (locations, prices, jobs, feature toggles) in config.lua, keep logic out of it, and split server-only values (webhooks, tokens, reward amounts) into a server-side config that is never sent to clients. Group settings, name them clearly, ship working defaults, validate the config at startup with readable errors, and leave config files editable under escrow with escrow_ignore.
- EngineeringThe FiveM Lua errors you will see most, and their fixes“Attempt to index a nil value” means you used . or [] on something that is nil — the object you expected was never set. “Attempt to call a nil value” means the function does not exist. Arithmetic, concatenate and compare errors mean a value you used is nil. Syntax errors (“'end' expected”, “unexpected symbol”) point at a missing keyword or character near the named line.
- BusinessA portfolio that wins FiveM workShow five or six of your best finished pieces with short in-game videos, link clean open-source samples on GitHub, and write brief case studies (problem, solution, result, resmon numbers). State your stack (Lua, ox_lib, frameworks, NUI), services and availability clearly, add testimonials from real clients, and keep contact one click away.