> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://documentation.celestory.io/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# 🟪 Set in Object

# 🟪 Set in Object

${frame}[Video: anatomy of the Set in object block](https://celestory-docs-videos.netlify.app/en/anatomie-bloc/setinobject.html)

![Set in Object](https://celestory-docs-illustrations.netlify.app/en/SetInObject_EN.svg)

The Set in Object block lets you add or update a property in an Object variable. An "Object" here is simply a variable that groups several related pieces of information under one name (a bit like a record card: one slot for `nickname`, one for `score`, etc.) instead of creating a separate variable for each one.

Essential for progressively building or enriching that record (e.g. a player record) throughout the scenario, before sending it to an API or saving it.

## 📥 Inputs

-   variable (Object variable): The Object variable to modify. If it is empty, a new object is created in it.
-   path (Text): The name of the property to set (e.g. `score`, `nickname`). This field also accepts a dotted path to reach a nested property (e.g. `player.stats.score`) or a list item by its index (e.g. `items.0`).
-   value (Dynamic variable): The value to assign to this property (Text, Number, Boolean, List or nested Object).

## 📤 Outputs

-   out (Stream): Continues the flow once the property has been set.

## 💡 Example

**Scenario: Building a player record throughout the game**

1. At the start of the game, an empty `player` Object variable is created.
2. After character creation, a Set in Object block adds the `nickname` property with the value entered by the player.
3. After each round, another Set in Object block updates the `score` property.
4. The `player` variable, now complete, can then be sent via an HTTP Request block or saved — just reconnect it wherever it's needed, it already holds everything.

## ⚙️ Technical Details

-   **Internal ID**: `setInObject`
-   **Behavior**: If the property already exists, its value is overwritten. If not, it is added to the object.
-   **No "object" output**: This block does not return the updated object on a dedicated output point — it directly updates the Object variable connected as input. To read the result, reconnect that same variable to another block further down the graph.

---

*Documented version: v1*