getproperties Synchronous

Read the reflected properties currently available on an Instance into a table. Use it to inspect an unfamiliar class or make a diagnostic snapshot.

Syntax
Luau
getproperties(instance: Instance) -> {[string]: any}

Parameters

Function parameters
ParameterTypeDescription
instanceInstanceInstance to inspect.

Returns

{[string]: any}

A table keyed by property name with values that could be read successfully.

Usage notes

Getter failures and nil values are omitted rather than aborting the entire enumeration. The returned table is a snapshot, not a live view.

Example

Example
Luau
local part = Instance.new("Part")
local properties = getproperties(part)
print("Name:", properties.Name)
print("Size:", properties.Size)
part:Destroy()
Kawaii documentation