> For the complete documentation index, see [llms.txt](https://visionstore.gitbook.io/visionstore-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://visionstore.gitbook.io/visionstore-docs/scripts/crafting/developers.md).

# Developers

Connect Vision Crafting to your own scripts without touching the protected core.

The core is protected by escrow, but it was built to be extended. You get **three tools**:

<table data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>📦 Exports</strong></td><td>Give benches, read and add bench XP, grant blueprints, read and grant Crafting Mastery, from any server resource.</td><td><a href="/visionstore-docs/scripts/crafting/developers/exports.md">Exports</a></td></tr><tr><td><strong>📡 Events</strong></td><td>Listen to every log line, NPC unlocks, and decide what a failed craft gives back.</td><td><a href="/visionstore-docs/scripts/crafting/developers/events.md">Events</a></td></tr><tr><td><strong>🔌 Bridges and config hooks</strong></td><td>Open-source framework, inventory, housing and HUD code, plus placement and instance hooks in the config.</td><td><a href="/visionstore-docs/scripts/crafting/developers/bridges.md">Bridges and config hooks</a></td></tr></tbody></table>

## Which one should I use?

| You want to...                                      | Use                                                                                                         |
| --------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| Sell or reward benches from a shop, job or quest    | `GivePortableBench` [export](/visionstore-docs/scripts/crafting/developers/exports.md)                      |
| Teach a blueprint from a quest or NPC               | `GrantBlueprint` [export](/visionstore-docs/scripts/crafting/developers/exports.md)                         |
| Show a crafter's rank on a leaderboard or phone app | `GetMasteryLifetimeXP` [export](/visionstore-docs/scripts/crafting/developers/exports.md)                   |
| Send logs to your own log system                    | `Chapo_Crafting:server:log` [event](/visionstore-docs/scripts/crafting/developers/events.md)                |
| Decide what a failed craft gives back               | `Chapo_Crafting:server:customFailure` [event](/visionstore-docs/scripts/crafting/developers/events.md)      |
| Only allow benches inside owned properties          | `Config.CanPlaceBench` [config hook](/visionstore-docs/scripts/crafting/developers/bridges.md#config-hooks) |
| Run on another framework or housing script          | [Bridges](/visionstore-docs/scripts/crafting/developers/bridges.md)                                         |

## Rules of the road

* **Server decides.** Every export is **server-side**. The client only ever sends a recipe id and a quantity, and everything is checked on the server.
* **Listen with `AddEventHandler`, never `RegisterNetEvent`.** The events are local server events.
* **Keep the folder name** `Chapo_Crafting`. Exports are called as `exports.Chapo_Crafting:...`.

## Bench ids

Each physical bench has a permanent **bench id** (a UUID). It's stored in the bench item's metadata (`metadata.benchId`) while the bench is in an inventory, and stays the same when it's placed, picked up or traded. Staff can see ids with `/crafting benches`.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://visionstore.gitbook.io/visionstore-docs/scripts/crafting/developers.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
