> For the complete documentation index, see [llms.txt](https://docs.ocelotbot.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ocelotbot.xyz/custom-commands/store-module.md).

# Store Module

The store module lets you store and retrieve values on a per-server basis. Values can be set/retrieved by any custom function in that server, regardless of who made it or who executes the function. Key and value length are limited to 191 characters.

## set(key: string, value: any)

Set a value, non-string values will be converted to a string

```lua
local store = require('store');
store.set("myVariable", "value");
return "Value set!";
```

## get(key: string)

Returns a string value stored at `key`

```lua
local store = require('store');
return store.get("myVariable");
```
