# Best Practices

***

### ✅ Always Use Codex APIs

Avoid direct framework calls when CodexCore provides an abstraction.

***

### 🔒 Secure Sensitive Actions

Use server callbacks for:

* Money transactions
* Inventory changes
* Trust updates

***

### 🧼 Validate Everything

Never assume:

* DB results exist
* Player data is valid
* Events are trusted

Always check.

***

### ⚡ Optimize UX

Pair actions with:

* Notifications
* Progress bars
* Prompts

Clear feedback improves immersion.

***

### 🧪 Test Before Production

Enable DeveloperMode on test servers only.

{% hint style="info" %}
Disable DeveloperMode on live servers for performance and security.
{% endhint %}
