Skip to main content

Description

Sets or updates an attribute on an instance. Supports all Roblox attribute types including primitives and complex types. Complex types should be provided in the serialized format.

Endpoint

set_attribute

Parameters

path
string
required
The path to the instance (e.g., “Workspace.Part” or “ReplicatedStorage.Config”)
name
string
required
The name of the attribute to set
value
any
required
The value to set. For complex types, use the serialized format with type and value fields.

Response

ok
boolean
Returns true if the attribute was set successfully
error
string
Error message if the instance path could not be resolved

Complex Type Format

When setting complex types, use the serialized format:
  • Vector3: { type: "Vector3", value: [x, y, z] }
  • Vector2: { type: "Vector2", value: [x, y] }
  • Color3: { type: "Color3", value: [r, g, b] }
  • UDim2: { type: "UDim2", value: [xScale, xOffset, yScale, yOffset] }
  • UDim: { type: "UDim", value: [scale, offset] }
  • NumberRange: { type: "NumberRange", value: [min, max] }
  • CFrame: { type: "CFrame", value: [x, y, z, rx, ry, rz, ux, uy, uz, lx, ly, lz] }

Examples

Set a string attribute

{
  "path": "Workspace.Part",
  "name": "Description",
  "value": "Updated description"
}
Response:
{
  "ok": true
}

Set a number attribute

{
  "path": "Workspace.Door",
  "name": "MaxHealth",
  "value": 100
}
Response:
{
  "ok": true
}

Set a Vector3 attribute

{
  "path": "Workspace.SpawnPoint",
  "name": "SpawnOffset",
  "value": {
    "type": "Vector3",
    "value": [0, 10, 0]
  }
}
Response:
{
  "ok": true
}

Set a Color3 attribute

{
  "path": "Workspace.Part",
  "name": "TeamColor",
  "value": {
    "type": "Color3",
    "value": [1, 0, 0]
  }
}
Response:
{
  "ok": true
}

Build docs developers (and LLMs) love