> For the complete documentation index, see [llms.txt](https://pellix-1.gitbook.io/pellix-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pellix-1.gitbook.io/pellix-docs/tables/config.md). Agents can also search and read this documentation through its [MCP server](https://pellix-1.gitbook.io/pellix-docs/~gitbook/mcp).

# config

Interface to perform operations with a configuration file.

**Performance note:**

Iterating through every configuration file entry is slow.

Do not retrieve config reference multiple times, save it in you script and reuse later if needed.

**Functions:**

```lua
config.get_ref(id: string): number
```

Retrieves a reference to the configuration entry

```lua
config.get(ref: number): boolean | number
```

Retrieves current configuration value by reference.

```lua
config.set(ref: number, value: boolean | number)
```

Sets the configuration value by reference.
