# Products

{% hint style="info" %}
All categories and items list can be found in `server/editable/_items.lua`
{% endhint %}

#### Categories

> The `Config.Categories` table is the core of the marketplace. It allows you to organize products into distinct groups, control who can see them, and define the specific attributes for every item available for purchase.&#x20;

Each category is defined by a unique key index and contains three main components:

* `label`: The display name of the category as seen by players in the UI.
* `canAccess`: A server-side function that receives the `playerId`. It must return `true` to display the category or `false` to hide it (and all its items) from that specific player. Useful for job-locked or reputation-locked items.
* `items`: An array of tables containing the products available in that category.

#### Items Structure

All items must have the following structure:

> * **name**:`string` Item name&#x20;
> * **label**:`string` Item label
> * **stock**:`number` Starting stock
> * **price**:`number` Product price
> * **account**:`string` Account name for purchase
> * **account**:`label` Account label for UI
> * **probability**:`number` From 0 to 100, prob from getting the item added to the shop in every refresh
> * **image?**:`string` Image custom URL
> * **extension?**:`string` The image file extension to use when not providing a custom URL. Use this if your inventory uses an extension other than .png (e.g., .webp)

Example

```lua
{
    name = "laptop", 
    label = "Laptop", 
    stock = 99, 
    price = 50, 
    account = "cosmo", 
    accountLabel = "Cosmo", 
    probability = 100
},
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.av-scripts.com/laptop-pack-v3/dark-market/products.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
