# Keychain

When using ox\_inventory, the doorlock offers a “keychain” option. This allows you to insert keys and door cards into the item.

{% hint style="danger" %}
**Compatibility** The "keychain" function only works with `ox_inventory`, since it offers a container system per item. Keychain can not be opened when using an inventory other than `ox_inventory`.
{% endhint %}

## Setup

After uploading the items according to the tutorial in *Configurations* section, go to `ox_inventory/modules/items/containers.lua` and insert the following code at the end of the file:

```lua
setContainerProperties('rd_keychain', {
    slots = 10,
    maxWeight = 1000.0,
    whitelist = { 'door_key', 'door_card' }
})
```

You can edit the code for maximum weight or number of slots.

{% hint style="danger" %}
It is important that we still have `return containers` at the end of the file!
{% endhint %}

In the final version, the end of the file should look like this:\
![](/files/KvOJLs1AOj0M6Rp5M97C)


---

# 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://documentation.rcore.cz/paid-resources/rcore_doorlock/keychain.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.
