mcp

v0.4.13
@openbone/mcp Checked 5 hours ago Published 4 days ago

MCP server for OpenBone: let AI agents rig, animate and wire up interactive skeletal animations

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

set_document setDocument

[project] Change document settings: name, artboard size, skeleton origin within the artboard (pixels, y-down), background, fps, reference scale, texture filter ("nearest" for pixel art).

ParameterTypeDescription
background
fpsnumber
heightnumber
namestring
originXnumber
originYnumber
referenceScalenumberSize in percent the rig's physics (gravity, wind) and IK softness values were made for (default 100); they scale by the skeleton's size relative to it
textureFilterstringHow images are sampled when scaled: "nearest" keeps hard pixel edges (pixel art), "linear" (default) smooths
widthnumber

add_image addImage

[project] Register an image asset (PNG/JPG/WebP as a data: URI, URL, or path relative to the project file).

ParameterTypeDescription
height *number
name *string
src *string
width *number
idstringOptional explicit id (generated when omitted)

update_image updateImage

[project] Change an image asset: name, src (new pixels, e.g. the art file changed) and size. When the size changes, region attachments using it grow or shrink with it (same pixel density; their place, scale and rotation are kept).

ParameterTypeDescription
image *stringImage id or name
heightnumber
namestring
srcstring
widthnumber

delete_image deleteImage

[project] Remove an image asset. Fails if attachments still use it.

ParameterTypeDescription
image *stringImage id or name

set_atlas setAtlas

[project] Store a texture atlas: packed pages (images, usually PNG data: URIs) and, per image, the rectangle it occupies in a page. Packed images are drawn from their page, so the WebGL renderer batches them into one draw call. Optional `white` is a solid white block in a page that untextured shapes sample from. Set `premultipliedAlpha` when the page pixels are premultiplied (renderers then use the matching blend). Regions may be trimmed (offsets) and carry an outline `polygon` (polygon packing). Pass `atlas: null` to remove the atlas. With `stripImageSources`, packed images lose their own src…

ParameterTypeDescription
atlas *
stripImageSourcesboolean

add_bone addBone

[rig] Add a bone. Position/rotation are local to the parent (y-up, degrees CCW). Parent defaults to the root bone.

ParameterTypeDescription
colorstringHex color like #ff8800 or #ff880080
idstringOptional explicit id (generated when omitted)
inheritstring
lengthnumber
namestring
parent
rotationnumberDegrees, counter-clockwise, relative to parent
scaleXnumber
scaleYnumber
shearXnumber
shearYnumber
xnumber
ynumber

update_bone updateBone

[rig] Change a bone's setup pose, name or parent.

ParameterTypeDescription
bone *stringBone id or name
colorstringHex color like #ff8800 or #ff880080
inheritstring
lengthnumber
namestring
parent
rotationnumberDegrees, counter-clockwise, relative to parent
scaleXnumber
scaleYnumber
shearXnumber
shearYnumber
xnumber
ynumber

delete_bone deleteBone

[rig] Delete a bone with all its descendant bones, their slots and any constraints/timelines that reference them.

ParameterTypeDescription
bone *stringBone id or name

add_slot addSlot

[rig] Add a slot (a draw-order layer attached to a bone that displays one attachment). Appended on top of the draw order unless index given.

ParameterTypeDescription
bone *stringBone id or name
blendstring
colorstringHex color like #ff8800 or #ff880080
darkstringTwo-colour tint: what the image's dark parts become (#rrggbb)
idstringOptional explicit id (generated when omitted)
indexintegerDraw order position (0 = back)
namestring

update_slot updateSlot

[rig] Change a slot's name, bone, tint color, two-colour tint (dark: what the image's dark parts become, null for none), blend mode, visible attachment (null to hide) or draw-order index.

ParameterTypeDescription
slot *stringSlot id or name
attachmentstring | null
blendstring
bonestringBone id or name
colorstringHex color like #ff8800 or #ff880080
dark
indexinteger
namestring

delete_slot deleteSlot

[rig] Delete a slot and its attachments.

ParameterTypeDescription
slot *stringSlot id or name

add_skin addSkin

[rig] Add a skin (an alternative set of attachments, e.g. outfits).

ParameterTypeDescription
name *string
idstringOptional explicit id (generated when omitted)

rename_skin renameSkin

[rig] Rename a skin. The default skin (the first one) keeps its name.

ParameterTypeDescription
name *string
skin *stringSkin id or name

delete_skin deleteSkin

[rig] Delete a skin and all of its attachments. The default skin cannot be deleted.

ParameterTypeDescription
skin *stringSkin id or name

duplicate_skin duplicateSkin

[rig] Copy a skin (all its attachments) into a new skin, e.g. to start a new outfit from an existing one.

ParameterTypeDescription
name *string
skin *stringSkin id or name
idstringOptional explicit id (generated when omitted)

add_to_skin addToSkin

[rig] Make bones and/or constraints skin-only (Spine skin bones/constraints): anything listed in any skin is active only while a skin listing it is set. Inactive bones (and the bones below them) are not posed and their slots are not drawn; inactive constraints are skipped. Example: a cape's bones and physics only in the 'knight' skin.

ParameterTypeDescription
skin *stringSkin (not the default skin) id or name
bonesarray
constraintsarray

remove_from_skin removeFromSkin

[rig] Take bones and/or constraints out of a skin's list. Once no skin lists them they are always active again.

ParameterTypeDescription
skin *stringSkin (not the default skin) id or name
bonesarray
constraintsarray

copy_attachment copyAttachment

[attachment] Copy an attachment from one skin to another (and optionally to another slot or name). Copying a default-skin attachment into an outfit skin under the same name makes the outfit override it.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
toSkin *stringSkin id or name
fromSkinstringDefaults to the default skin
namestringNew attachment name (defaults to the same name)
toSlotstringDefaults to the same slot

add_region addRegion

[attachment] Attach an image (textured quad) to a slot. Offset/rotation are relative to the slot's bone.

ParameterTypeDescription
image *stringImage id or name
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
colorstringHex color like #ff8800 or #ff880080
heightnumber
namestringAttachment name (defaults to the image/shape name)
rotationnumber
scaleXnumber
scaleYnumber
skewXnumberSkew in degrees (slants the vertical edges)
skewYnumberSkew in degrees (slants the horizontal edges)
skinstringDefaults to the default skin
widthnumber
xnumber
ynumber

add_shape addShape

[attachment] Attach a vector shape (rect, ellipse or polygon) to a slot; no image needed. Great for quick prototypes and UI.

ParameterTypeDescription
shape *string
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
fillstringHex color like #ff8800 or #ff880080
heightnumber
namestringAttachment name (defaults to the image/shape name)
pointsarrayPolygon points flat [x0,y0,x1,y1,...] (polygon only)
radiusnumberRect corner radius
rotationnumber
skinstringDefaults to the default skin
strokestringHex color like #ff8800 or #ff880080
strokeWidthnumber
widthnumber
xnumber
ynumber

add_mesh addMesh

[attachment] Attach a deformable mesh. Either give a grid (cols x rows over the image, centred at x,y) or explicit vertices/uvs/triangles.

ParameterTypeDescription
image *stringImage id or name
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
colorstringHex color like #ff8800 or #ff880080
colsinteger
heightnumber
hullinteger
namestringAttachment name (defaults to the image/shape name)
rowsinteger
skinstringDefaults to the default skin
trianglesarray
uvsarray
verticesarray
widthnumber
xnumber
ynumber

add_linked_mesh addLinkedMesh

[attachment] Add a linked mesh (like Spine's): a mesh that uses another mesh's vertices, triangles and weights with a different image, e.g. the same rigged sleeve in another outfit or colour. Edit the parent and every linked mesh follows. `deform: true` (default) makes the parent's deform keys move it too. The parent defaults to the same slot; give `parentSlot` / `parentSkin` when it lives elsewhere.

ParameterTypeDescription
image *stringImage id or name
parent *stringName of the parent mesh attachment
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
colorstringHex color like #ff8800 or #ff880080
deformboolean
namestringAttachment name (defaults to the image/shape name)
parentSkinstringSkin of the parent mesh id or name
parentSlotstringSlot of the parent mesh id or name
skinstringDefaults to the default skin

add_bounding_box addBoundingBox

[attachment] Attach a bounding-box polygon (hit area for listeners/pointer events). Give vertices or a rect.

ParameterTypeDescription
slot *stringSlot id or name
activateboolean
heightnumber
namestringAttachment name (defaults to the image/shape name)
skinstringDefaults to the default skin
verticesarray
widthnumber
xnumber
ynumber

add_clipping addClipping

[attachment] Add a clipping mask to a slot. It is not drawn; the slots after it in draw order, up to and including `end`, are clipped to its outline (e.g. keep a shine sweep inside a rounded button). Give a rect/ellipse (width, height, radius) or polygon points, or raw vertices.

ParameterTypeDescription
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
endLast slot that is clipped; null = every slot drawn after this one
heightnumber
namestringAttachment name (defaults to the image/shape name)
pointsarrayPolygon points flat [x0,y0,...] (shape polygon)
radiusnumberRect corner radius
rotationnumber
shapestring
skinstringDefaults to the default skin
verticesarrayRaw outline flat [x0,y0,...] in slot-bone space; overrides shape
widthnumber
xnumber
ynumber

add_point addPoint

[attachment] Attach a point (a named locator, e.g. a gun muzzle) to a slot.

ParameterTypeDescription
slot *stringSlot id or name
activateboolean
namestringAttachment name (defaults to the image/shape name)
rotationnumber
skinstringDefaults to the default skin
xnumber
ynumber

add_path addPath

[attachment] Attach a bezier path (used by path constraints) to a slot, in slot-bone space. Give `anchors` (flat [x0,y0,x1,y1,...]; handles are placed automatically for a smooth curve) or `vertices` (flat, 3 points per knot: [inX,inY, x,y, outX,outY, ...]). Bind it to control bones with autoWeights to bend it.

ParameterTypeDescription
slot *stringSlot id or name
activateboolean
anchorsarrayPoints the curve passes through, flat [x0,y0,x1,y1,...]
closedboolean
colorstringHex color like #ff8800 or #ff880080
namestringAttachment name (defaults to the image/shape name)
skinstringDefaults to the default skin
verticesarrayExplicit knots, 6 numbers each: in handle, anchor, out handle

update_attachment updateAttachment

[attachment] Change properties of an existing attachment (any field of its type, e.g. x, y, width, fill, vertices). Mesh vertices are slot-bone local; on a weighted mesh they are re-bound to the same bones at the new position. When the vertex count changes pass uvs too (triangles are recomputed if omitted).

ParameterTypeDescription
attachment *string
props *object
slot *stringSlot id or name
skinstringSkin id or name

delete_attachment deleteAttachment

[attachment] Remove an attachment from a slot.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
skinstringSkin id or name

auto_weights autoWeights

[attachment] Bind a mesh (or path or bounding box) to bones automatically: each vertex is weighted to its nearest bones (by distance to the bone segment) in the setup pose.

ParameterTypeDescription
attachment *string
bones *arrayBones that may influence the mesh
slot *stringSlot id or name
falloffnumberHigher = sharper transitions
maxInfluencesinteger
skinstringSkin holding the mesh (defaults to the default skin)

set_weights setWeights

[attachment] Set explicit weights for one mesh, path or bounding-box vertex (positions computed from the setup pose). Weights are normalised.

ParameterTypeDescription
attachment *string
influences *array
slot *stringSlot id or name
vertex *integer
skinstringSkin holding the mesh (defaults to the default skin)

set_mesh_weights setMeshWeights

[attachment] Set bone weights for many mesh vertices at once (e.g. a weight-painting stroke). Each entry replaces that vertex's influences; vertices not listed keep theirs. Weights are normalised per vertex and the mesh keeps its setup-pose shape.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
vertices *array
skinstringSkin holding the mesh (defaults to the default skin)

set_weights_in_area setWeightsInArea

[attachment] Set bone weights for every vertex of a mesh, path or bounding box that lies inside an area of the setup pose (skeleton space, y up): a box {xMin?, xMax?, yMin?, yMax?} (leave a side out for no limit, e.g. {yMax:205} = everything below y 205) or a polygon [x0,y0,x1,y1,...]. Use it to pin parts to one bone (feet to the legs bone, a hem to the skirt) without listing vertex indices. blend: vertices up to this far outside the area get a share falling off to 0 (a soft edge). mode replace (default) swaps the vertex's influences for these; add mixes them into its current ones. Weights are…

ParameterTypeDescription
attachment *string
influences *array
slot *stringSlot id or name
areaobjectBox in skeleton space (y up); omitted sides are unbounded
blendnumberSoft edge: distance outside the area over which the new weights fade out
modestring
polygonarrayPolygon [x0,y0,x1,y1,...] in skeleton space (y up), instead of area
skinstringSkin holding the attachment (defaults to the default skin)

smooth_weights smoothWeights

[attachment] Smooth a weighted mesh: blend each vertex's bone weights toward the average of its mesh neighbours (strength 0..1). Optionally only some vertices.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
skinstringSkin id or name
strengthnumber
verticesarrayVertex indices (default all)

prune_weights pruneWeights

[attachment] Prune a weighted mesh: drop bone influences below `threshold` and keep at most `maxInfluences` per vertex, then renormalise. Optionally only some vertices.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
maxInfluencesinteger
skinstringSkin id or name
thresholdnumber
verticesarray

swap_weights swapWeights

[attachment] Swap two bones' weights on a mesh: every vertex (or only `vertices`) gives bone `from`'s weight to `to` and the other way round. Handy after mirroring a limb or binding the wrong bone. The mesh keeps its setup-pose shape.

ParameterTypeDescription
attachment *string
from *stringBone id or name
slot *stringSlot id or name
to *stringBone id or name
skinstringSkin id or name
verticesarrayVertex indices (default all)

add_ik_constraint addIkConstraint

[constraint] Add an IK constraint: 1 bone aims at the target, or 2 bones (parent then child, e.g. thigh+shin) bend to reach it. Optional softness, stretch and compress.

ParameterTypeDescription
bones *array
target *stringTarget bone id or name
bendPositiveboolean
compressboolean1-bone only: scale the bone down when the target is closer than its length
idstringOptional explicit id (generated when omitted)
mixnumber
namestring
softnessnumber2-bone only: distance before full extension where the chain eases into straight (0 = off)
stretchbooleanScale bones up along their length when the target is out of reach
uniformbooleanWith stretch/compress: scale both axes, keeping proportions
volumebooleanWith stretch/compress: keep volume (the bone gets thinner as it stretches, wider as it squashes). Ignored with uniform

update_ik_constraint updateIkConstraint

[constraint] Change an IK constraint's mix, bend direction, softness, stretch/compress/uniform/volume, target or name. Animate bend/stretch/compress with setKeys (properties bend: 1|-1, stretch: 1|0, compress: 1|0; stepped).

ParameterTypeDescription
constraint *stringIK constraint id or name
bendPositiveboolean
compressboolean1-bone only: scale the bone down when the target is closer than its length
mixnumber
namestring
softnessnumber2-bone only: distance before full extension where the chain eases into straight (0 = off)
stretchbooleanScale bones up along their length when the target is out of reach
targetstringBone id or name
uniformbooleanWith stretch/compress: scale both axes, keeping proportions
volumebooleanWith stretch/compress: keep volume (the bone gets thinner as it stretches, wider as it squashes). Ignored with uniform

add_transform_constraint addTransformConstraint

[constraint] Make bones copy (mix toward) the rotation/translation/scale/shear of a target bone, plus offsets. World or local space; absolute or relative (adds the target's change from its setup pose).

ParameterTypeDescription
bones *array
target *stringTarget bone id or name
idstringOptional explicit id (generated when omitted)
localbooleanCopy local (parent-space) values instead of world transforms
localSourcebooleanMapping only: read the target's local values (default: same space as `local`)
maparrayProperty mapping (replaces copying): each entry writes offset + target[from] x scale, clamped to min..max, into every bone's `to`; entries with the same `to` add up. Example: target x drives rotation:…
mixRotatenumber
mixScalenumber
mixShearnumberBlend of the shear between the bone's axes
mixTranslatenumber
namestring
offsetRotationnumber
offsetScaleXnumberAdded to the copied scale
offsetScaleYnumber
offsetShearnumber
offsetXnumber
offsetYnumber
relativebooleanAdd the target's change from its setup pose instead of copying its absolute value

update_transform_constraint updateTransformConstraint

[constraint] Change a transform constraint's mixes, offsets, space (local), relative mode, property mapping (map, localSource), bones, target or name.

ParameterTypeDescription
constraint *stringTransform constraint id or name
bonesarray
localbooleanCopy local (parent-space) values instead of world transforms
localSourcebooleanMapping only: read the target's local values (default: same space as `local`)
maparrayProperty mapping (replaces copying): each entry writes offset + target[from] x scale, clamped to min..max, into every bone's `to`; entries with the same `to` add up. Example: target x drives rotation:…
mixRotatenumber
mixScalenumber
mixShearnumberBlend of the shear between the bone's axes
mixTranslatenumber
namestring
offsetRotationnumber
offsetScaleXnumberAdded to the copied scale
offsetScaleYnumber
offsetShearnumber
offsetXnumber
offsetYnumber
relativebooleanAdd the target's change from its setup pose instead of copying its absolute value
targetstringBone id or name

add_path_constraint addPathConstraint

[constraint] Place and rotate a chain of bones along a slot's path attachment (add one with addPath). Bones are ordered parent first. Good for tails, tentacles, ropes and things moving along a track.

ParameterTypeDescription
bones *array
target *stringSlot showing a path attachment id or name
constantSpeedbooleanMeasure positions inside each curve segment by arc length, so bones stay evenly spaced (default true). false: raw bezier parameter, bones bunch where handles are short
idstringOptional explicit id (generated when omitted)
mixRotatenumber
mixXnumber
mixYnumber
namestring
offsetRotationnumber
positionnumberWhere the first bone sits along the path
positionModestringfixed: position is a distance; percent: 0..1 of the path length
rotateModestringtangent: follow the curve direction; chain: point at the next bone's spot; chainScale: chain and stretch to reach it
spacingnumber
spacingModestringlength: bone length + spacing; fixed: spacing; percent: spacing x path length; proportional: spacing x path length shared by bone length

update_path_constraint updatePathConstraint

[constraint] Change a path constraint's modes, position, spacing, mixes, bones, target slot or name.

ParameterTypeDescription
constraint *stringPath constraint id or name
bonesarray
constantSpeedbooleanMeasure positions inside each curve segment by arc length, so bones stay evenly spaced (default true). false: raw bezier parameter, bones bunch where handles are short
mixRotatenumber
mixXnumber
mixYnumber
namestring
offsetRotationnumber
positionnumberWhere the first bone sits along the path
positionModestringfixed: position is a distance; percent: 0..1 of the path length
rotateModestringtangent: follow the curve direction; chain: point at the next bone's spot; chainScale: chain and stretch to reach it
spacingnumber
spacingModestringlength: bone length + spacing; fixed: spacing; percent: spacing x path length; proportional: spacing x path length shared by bone length
targetstringSlot id or name

add_physics_constraint addPhysicsConstraint

[constraint] Add spring-based secondary motion (hair, cloth, antennae, tails) to a bone. Add one per bone of a chain, parent first. Deterministic for a fixed timestep.

ParameterTypeDescription
bone *stringBone id or name
dampingnumberVelocity decay per second
fpsnumberSimulation steps per second (fixed timestep)
gravitynumberDownward acceleration (units/s²)
idstringOptional explicit id (generated when omitted)
inertianumberHow much of the bone's own movement is resisted (1 = full lag)
massnumber
mixnumber
namestring
rotatenumberHow much the simulation rotates the bone
scaleXnumberHow much the simulation stretches the bone
strengthnumberSpring stiffness back to the animated pose
volumebooleanKeep volume when scaleX stretches the bone (it gets thinner as it stretches)
windnumberSideways +x acceleration (units/s²)
xnumberHow much the simulation moves the bone origin horizontally
ynumberHow much the simulation moves the bone origin vertically

update_physics_constraint updatePhysicsConstraint

[constraint] Change a physics constraint's channels, spring settings, gravity, wind, mix, bone or name.

ParameterTypeDescription
constraint *stringPhysics constraint id or name
bonestringBone id or name
dampingnumberVelocity decay per second
fpsnumberSimulation steps per second (fixed timestep)
gravitynumberDownward acceleration (units/s²)
inertianumberHow much of the bone's own movement is resisted (1 = full lag)
massnumber
mixnumber
namestring
rotatenumberHow much the simulation rotates the bone
scaleXnumberHow much the simulation stretches the bone
strengthnumberSpring stiffness back to the animated pose
volumebooleanKeep volume when scaleX stretches the bone (it gets thinner as it stretches)
windnumberSideways +x acceleration (units/s²)
xnumberHow much the simulation moves the bone origin horizontally
ynumberHow much the simulation moves the bone origin vertically

delete_constraint deleteConstraint

[constraint] Delete an IK, transform, path or physics constraint (and its animation timelines).

ParameterTypeDescription
constraint *stringConstraint id or name

set_constraint_order setConstraintOrder

[constraint] Set the order constraints are applied in each frame (all kinds in one list; default: ik, transform, path, physics, each in creation order). Pass every constraint (id or name) once, first applied first; an empty list restores the default order. Example: apply a transform constraint before an IK so the IK sees its result.

ParameterTypeDescription
constraints *arrayEvery constraint, in the new order; [] goes back to the default order

add_slider addSlider

[constraint] Add a slider: a driver scrubs an animation (Spine 4.2 sliders). Driver = a bone's local property (bone + property, e.g. shoulder rotation 0..100 plays a shadow or corrective animation) or a number input. from..to of the driver maps to timeFrom..timeTo seconds (default the whole animation); mix blends it in; additive adds its change on top. Sliders apply before IK and the other constraints.

ParameterTypeDescription
animation *stringAnimation id or name
additivebooleanAdd the animation's change from the setup pose instead of replacing
boneDriver bone (its local property scrubs the animation)
fromnumberDriver value that shows timeFrom
idstringOptional explicit id (generated when omitted)
inputstring | nullDriver number input (name or id, any state machine) instead of a bone
loopbooleanWrap past the range instead of clamping
mixnumber
namestring
propertystringDriver property of the bone
timeFrom
timeToDefault: the animation's length
tonumberDriver value that shows timeTo

update_slider updateSlider

[constraint] Change a slider's animation, driver (bone + property, or input), ranges, mix, loop, additive or name.

ParameterTypeDescription
slider *stringSlider name or id
additivebooleanAdd the animation's change from the setup pose instead of replacing
animationstringAnimation id or name
boneDriver bone (its local property scrubs the animation)
fromnumberDriver value that shows timeFrom
inputstring | nullDriver number input (name or id, any state machine) instead of a bone
loopbooleanWrap past the range instead of clamping
mixnumber
namestring
propertystringDriver property of the bone
timeFrom
timeToDefault: the animation's length
tonumberDriver value that shows timeTo

delete_slider deleteSlider

[constraint] Delete a slider.

ParameterTypeDescription
slider *stringSlider name or id

create_animation createAnimation

[animation] Create an empty animation. Duration 0 means 'until the last key'.

ParameterTypeDescription
name *string
durationnumber
idstringOptional explicit id (generated when omitted)

update_animation updateAnimation

[animation] Rename an animation, change its duration, mark whether it is exported (export: false keeps a helper animation out of exports unless picked), or give it a colour for the editor's lists (color: null removes it).

ParameterTypeDescription
animation *stringAnimation id or name
color
durationnumber
exportboolean
namestring

delete_animation deleteAnimation

[animation] Delete an animation (state machine states using it are cleared).

ParameterTypeDescription
animation *stringAnimation id or name

set_keys setKeys

[animation] Set one or more keyframes on a timeline (absolute values). Keys are merged into the timeline (same time = replaced); pass replace:true to make the timeline exactly these keys. Examples: bone rotation {target:'bone', id:'arm', property:'rotation', keys:[{time:0,value:0},{time:0.5,value:45,curve:'easeInOut'}]}; path constraint {target:'path', id:'tail-path', property:'position', keys:[...]}; slot color value '#ff0000'; particle emitter {target:'particles', id:'exhaust', property:'emitting', keys:[{time:0,value:true},{time:1,value:false}]} or property 'rate' (numbers); slot attachment…

ParameterTypeDescription
animation *stringAnimation id or name
keys *array
target *stringWhat is animated: bone property, slot color/attachment, constraint (ik/transform/path/physics) values, particle emitter (id = slot; emitting true/false, rate), mesh/path deform, sequence frame, draw o…
attachmentstringMesh/path attachment name (deform) or sequence attachment name (sequence)
idstringBone/slot/constraint id or name (not needed for drawOrder)
propertystringbone: rotation|x|y|scaleX|scaleY|shearX|shearY|inherit (stepped: normal|onlyTranslation|noRotation|noScale); slot: color|attachment; ik: mix|softness|bend|stretch|compress; transform: mix|mixRotate|mi…
replacebooleantrue: the timeline gets exactly these keys (its other keys are removed); false (default): keys are added, replacing any at the same times

delete_key deleteKey

[animation] Delete the keyframe at `time` from a timeline (removes the timeline when empty).

ParameterTypeDescription
animation *stringAnimation id or name
target *stringWhat is animated: bone property, slot color/attachment, constraint (ik/transform/path/physics) values, particle emitter (id = slot; emitting true/false, rate), mesh/path deform, sequence frame, draw o…
time *number
attachmentstring
idstring
propertystring

move_key moveKey

[animation] Move a keyframe to a new time (and optionally change its curve).

ParameterTypeDescription
animation *stringAnimation id or name
target *stringWhat is animated: bone property, slot color/attachment, constraint (ik/transform/path/physics) values, particle emitter (id = slot; emitting true/false, rate), mesh/path deform, sequence frame, draw o…
time *number
attachmentstring
curve
idstring
newTimenumber
propertystring

delete_timeline deleteTimeline

[animation] Remove a whole timeline (all keys for that property) from an animation.

ParameterTypeDescription
animation *stringAnimation id or name
target *stringWhat is animated: bone property, slot color/attachment, constraint (ik/transform/path/physics) values, particle emitter (id = slot; emitting true/false, rate), mesh/path deform, sequence frame, draw o…
attachmentstring
idstring
propertystring

remove_broken_keys removeBrokenKeys

[animation] Remove timelines, event keys and sound keys that point at bones, slots, constraints, events or sounds no longer in the document (left behind by hand edits or merges). Without `animation`, cleans every animation.

ParameterTypeDescription
animationstringAnimation id or name

add_event addEvent

[animation] Define a named event (fired from animation keys or listeners, delivered to scripts and the host app).

ParameterTypeDescription
name *string
audiostring
floatnumber
idstringOptional explicit id (generated when omitted)
intinteger
stringstring

add_event_key addEventKey

[animation] Fire an event at a time in an animation (optionally overriding its payload). Creates the event if needed.

ParameterTypeDescription
animation *stringAnimation id or name
event *string
time *number
floatnumber
intinteger
stringstring

delete_event_key deleteEventKey

[animation] Remove an event key from an animation.

ParameterTypeDescription
animation *stringAnimation id or name
event *stringEvent id or name
time *number

transform_keys transformKeys

[animation] Shift and/or scale picked keys in time (the dopesheet's move and scale): newTime = pivot + (time - pivot) * scale + offset, clamped at 0 and rounded to frames when `fps` is given. Moved keys replace keys already at their new time. Example: shift a walk's keys 0.25 s later {animation:'walk', keys:[{target:'bone', id:'leg', property:'rotation', times:[0,0.5]}], offset:0.25}; play twice as fast {…, scale:0.5, pivot:0}.

ParameterTypeDescription
animation *stringAnimation id or name
eventsarray
fpsnumber
keysarray
offsetnumber
pivotnumber
scalenumber

paste_keys pasteKeys

[animation] Paste keys (e.g. copied from this or another animation) at time `at`: each key's time is relative to the start of the copy. Creates timelines as needed and replaces keys already at those times. Event keys paste the same way. Example: {animation:'run', at:0.5, keys:[{target:'bone', id:'head', property:'rotation', time:0, value:10}, {target:'bone', id:'head', property:'rotation', time:0.2, value:-5, curve:'easeInOut'}]}.

ParameterTypeDescription
animation *stringAnimation id or name
atnumber
eventsarray
keysarray

delete_keys deleteKeys

[animation] Delete many picked keys at once (timelines left empty are removed). Same `keys` / `events` shape as transformKeys.

ParameterTypeDescription
animation *stringAnimation id or name
eventsarray
keysarray

create_state_machine createStateMachine

[interactivity] Create a state machine (Rive-style) with one empty layer.

ParameterTypeDescription
name *string
idstringOptional explicit id (generated when omitted)
layerNamestring

delete_state_machine deleteStateMachine

[interactivity] Delete a state machine.

ParameterTypeDescription
stateMachine *stringState machine id or name

add_layer addLayer

[interactivity] Add a layer. Layers run in parallel; later layers override properties they key (e.g. body walk + face blink).

ParameterTypeDescription
name *string
stateMachine *stringState machine id or name
idstringOptional explicit id (generated when omitted)

add_input addInput

[interactivity] Add an input the host app / listeners / scripts control: bool, number, string or trigger (one-shot). Text attachments show inputs with {name} templates; number inputs can drive properties through bindings (addBinding).

ParameterTypeDescription
name *string
stateMachine *stringState machine id or name
type *string
defaultboolean | number | string
idstringOptional explicit id (generated when omitted)
mutesstringBool inputs: the bus (id or name) this input mutes while true, "master" for every sound, "" for none. Then the host, page controls, listeners and scripts all mute it by setting the input (e.g. a music…

update_input updateInput

[interactivity] Rename an input, change its default value, or make a bool input mute a sound bus (`mutes`).

ParameterTypeDescription
input *stringInput id or name
stateMachine *stringState machine id or name
defaultboolean | number | string
mutesstringBool inputs: the bus (id or name) this input mutes while true, "master" for every sound, "" for none. Then the host, page controls, listeners and scripts all mute it by setting the input (e.g. a music…
namestring

delete_input deleteInput

[interactivity] Delete an input and every condition, action and binding using it.

ParameterTypeDescription
input *stringInput id or name
stateMachine *stringState machine id or name

add_state addState

[interactivity] Add a state to a layer. 'animation' plays one animation; 'blend1d' blends animations by a number input; 'exit' stops the layer. The first state added becomes the entry state. onComplete names a state to go to once the animation has played through (play once, then continue).

ParameterTypeDescription
stateMachine *stringState machine id or name
animationstringAnimation id or name
blendarray
blendInputstringNumber input id or name
entrybooleanMake this the layer's entry state
idstringOptional explicit id (generated when omitted)
layerstringDefaults to the first layer
loopboolean
namestring
onCompleteState to go to when the animation finishes (after the first cycle when looping)
speednumber
typestring
xnumber
ynumber

update_state updateState

[interactivity] Change a state's name, animation, loop, speed, blend setup, onComplete target (null clears it), editor position, or make it the entry.

ParameterTypeDescription
state *stringState id or name
stateMachine *stringState machine id or name
animation
blendarray
blendInputstringNumber input id or name
entryboolean
layerstringDefaults to the first layer
loopboolean
namestring
onComplete
speednumber
xnumber
ynumber

delete_state deleteState

[interactivity] Delete a state and its transitions.

ParameterTypeDescription
state *stringState id or name
stateMachine *stringState machine id or name
layerstringDefaults to the first layer

add_transition addTransition

[interactivity] Add a transition between states. from may be '@any'. All conditions must pass (trigger inputs pass when fired). Optional cross-fade duration (s) and exitTime (fraction of the source animation that must have played).

ParameterTypeDescription
from *stringState id/name or "@any"
stateMachine *stringState machine id or name
to *stringState id or name
conditionsarray
durationnumber
exitTime
idstringOptional explicit id (generated when omitted)
layerstringDefaults to the first layer

update_transition updateTransition

[interactivity] Replace a transition's conditions, duration or exitTime.

ParameterTypeDescription
stateMachine *stringState machine id or name
transition *string
conditionsarray
durationnumber
exitTime
layerstringDefaults to the first layer

delete_transition deleteTransition

[interactivity] Delete a transition.

ParameterTypeDescription
stateMachine *stringState machine id or name
transition *string
layerstringDefaults to the first layer

add_listener addListener

[interactivity] React to pointer input on a slot's bounding box (or the whole artboard when slot is null): down, up, click, enter, exit, move → actions (setInput, toggleInput, fireTrigger, reportEvent, runScript, playSound, stopSound, setEmitter {slot, emitting} to start/stop a particle emitter, emitParticles {slot, count} for a one-off burst).

ParameterTypeDescription
actions *array
event *string
stateMachine *stringState machine id or name
idstringOptional explicit id (generated when omitted)
namestring
slot

delete_listener deleteListener

[interactivity] Delete a listener.

ParameterTypeDescription
listener *string
stateMachine *stringState machine id or name

add_script addScript

[interactivity] Add a sandboxed JavaScript script. Define any of: onStart(), onUpdate(dt), onEvent(e), onPointer(p), or custom functions for runScript actions. API: ob.input(name) / ob.setInput(name, v) / ob.fire(name) / ob.emit(event, payload) / ob.bone(name) -> {x,y,rotation,scaleX,scaleY,worldX,worldY} / ob.setBone(name, {rotation,...}) / ob.slot(name, {color, attachment}) / ob.time / ob.log(...).

ParameterTypeDescription
code *string
name *string
idstringOptional explicit id (generated when omitted)

update_script updateScript

[interactivity] Replace a script's code or name.

ParameterTypeDescription
script *stringScript id or name
codestring
namestring

attach_script attachScript

[interactivity] Run a script for the whole state machine, or only while a given state is active.

ParameterTypeDescription
script *stringScript id or name
stateMachine *stringState machine id or name
layerstringDefaults to the first layer
statestringState id or name

delete_script deleteScript

[interactivity] Delete a script and detach it everywhere.

ParameterTypeDescription
script *stringScript id or name

set_state_input setStateInput

[interactivity] Make a state set a bool/number/string input when it is entered (value null removes it). Use it to reset a round: e.g. the idle state sets multiplier back to 1 and status to 'Press START' after a crash or cash-out.

ParameterTypeDescription
input *stringInput id or name
state *stringState id or name
stateMachine *stringState machine id or name
value *boolean | number | string | null
layerstringLayer id or name

add_audio addAudio

[audio] Add an audio file (WAV/MP3/OGG) as a data: URI or a path relative to the project. By default also creates a sound of the same name on the sfx bus, ready to play from event keys, audio keys, states or listeners.

ParameterTypeDescription
name *string
src *stringdata: URI, relative path or URL
busBus for the created sound (default sfx; null = master)
durationnumberSeconds (0 = unknown)
idstringOptional explicit id (generated when omitted)
loopbooleanCreated sound loops
soundbooleanAlso create a sound using this asset
soundIdstringOptional explicit id (generated when omitted)

update_audio updateAudio

[audio] Rename an audio asset or replace its source / duration.

ParameterTypeDescription
asset *stringAudio asset id or name
durationnumber
namestring
srcstring

delete_audio deleteAudio

[audio] Delete an audio asset, the sounds that use it and everything that plays them.

ParameterTypeDescription
asset *stringAudio asset id or name

add_sound addSound

[audio] Create a sound from an audio asset with its own bus, volume, rate (pitch), loop and fade in/out.

ParameterTypeDescription
asset *stringAudio asset id or name
name *string
busBus id/name (default sfx); null plays straight into the master
fadeInnumberFade-in seconds when started
fadeOutnumberFade-out seconds when stopped (also when its state/animation ends)
idstringOptional explicit id (generated when omitted)
loopboolean
ratenumberPlayback rate / pitch (1 = original, 2 = octave up)
volumenumberLinear volume (1 = unchanged)

update_sound updateSound

[audio] Change a sound's name, asset, bus, volume, rate, loop or fades.

ParameterTypeDescription
sound *stringSound id or name
assetstringAudio asset id or name
busBus id/name (default sfx); null plays straight into the master
fadeInnumberFade-in seconds when started
fadeOutnumberFade-out seconds when stopped (also when its state/animation ends)
loopboolean
namestring
ratenumberPlayback rate / pitch (1 = original, 2 = octave up)
volumenumberLinear volume (1 = unchanged)

delete_sound deleteSound

[audio] Delete a sound and every key, state hook, listener action and event reference that plays it (the asset stays).

ParameterTypeDescription
sound *stringSound id or name

add_bus addBus

[audio] Add a mixer bus (documents start with sfx, music and ui). Sounds route into one bus; bus volume and mute apply to all of them.

ParameterTypeDescription
name *string
idstringOptional explicit id (generated when omitted)
mutedboolean
volumenumberLinear volume (1 = unchanged)

update_bus updateBus

[audio] Rename a bus or change its volume / mute.

ParameterTypeDescription
bus *stringBus id or name
mutedboolean
namestring
volumenumberLinear volume (1 = unchanged)

delete_bus deleteBus

[audio] Delete a bus. Its sounds play straight into the master.

ParameterTypeDescription
bus *stringBus id or name

set_audio_mix setAudioMix

[audio] Set the master volume and/or mute every sound in the document.

ParameterTypeDescription
masternumberLinear volume (1 = unchanged)
mutedboolean

add_audio_key addAudioKey

[audio] Start a sound at a time on an animation's audio track (replaces a key of the same sound at that time).

ParameterTypeDescription
animation *stringAnimation id or name
sound *stringSound id or name
time *number
loopbooleanOverrides the sound's loop; looping keys stop when the animation ends or is replaced
ratenumberOverrides the sound's rate
volumenumberMultiplies the sound's volume

update_audio_key updateAudioKey

[audio] Move an audio key or change its volume / rate / loop overrides (null clears an override).

ParameterTypeDescription
animation *stringAnimation id or name
sound *stringSound id or name
time *number
loopboolean | null
newTimenumber
rate
volume

delete_audio_key deleteAudioKey

[audio] Remove an audio key from an animation.

ParameterTypeDescription
animation *stringAnimation id or name
sound *stringSound id or name
time *number

set_event_sound setEventSound

[audio] Play a sound whenever an event fires (from animation keys, listeners or scripts). sound null removes it.

ParameterTypeDescription
event *stringEvent id or name
sound *
volumenumberLinear volume (1 = unchanged)

set_state_sound setStateSound

[audio] Play or stop a sound when a state is entered or exited (replaces the same sound's hook for that moment). A looping sound played on enter stops (with its fade-out) when the state exits.

ParameterTypeDescription
sound *stringSound id or name
state *stringState id or name
stateMachine *stringState machine id or name
actionstring
layerstringDefaults to the first layer
onstring
volumenumberLinear volume (1 = unchanged)

delete_state_sound deleteStateSound

[audio] Remove a state's sound hook (for one moment, or both when `on` is omitted).

ParameterTypeDescription
sound *stringSound id or name
state *stringState id or name
stateMachine *stringState machine id or name
layerstringLayer id or name
onstring

add_font addFont

[project] Add a font file (TTF/OTF; WOFF/WOFF2 work on the web only) as a data: URI or a path relative to the project. Text attachments whose font list names `family` use it (the face whose weight is closest to theirs) before any installed font, in the editor and every runtime.

ParameterTypeDescription
family *stringFamily name texts use in their font list, e.g. "Noto Serif JP"
name *stringAsset name (usually the file name)
src *stringdata: URI, relative path or URL
idstringOptional explicit id (generated when omitted)
stylestring
weightintegerCSS weight of the file's face (400 regular, 700 bold)

update_font updateFont

[project] Rename a font asset, change its family, weight or style, or replace its file.

ParameterTypeDescription
font *stringFont id or name
familystring
namestring
srcstring
stylestring
weightintegerCSS weight of the file's face (400 regular, 700 bold)

delete_font deleteFont

[project] Delete a font asset. Texts that used its family fall back to installed fonts.

ParameterTypeDescription
font *stringFont id or name

add_sequence addSequence

[attachment] Attach a frame-by-frame sequence (image sequence or sprite sheet) to a slot. Frames are image refs in order, sheet cells {image, rect:{x,y,width,height}}, or a `grid` over one sheet image. The frame shown is floor(time x fps) + offset, mapped by mode; bind `input` (a number input) to drive the frame from a state machine, or key it with setKeys target 'sequence'.

ParameterTypeDescription
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
colorstringHex color like #ff8800 or #ff880080
fpsnumber
framesarrayFrames in order: image ids/names, or {image, rect, trim}
gridobjectCut a sprite sheet image into a grid of frames (give cols/rows or the frame size)
heightnumber
inputstring | nullNumber input (id or name) whose value is the frame counter
modestringloop wraps; once plays through then hides; pingPong goes forward then back; holdLast stops on the last frame
namestringAttachment name (defaults to the image/shape name)
offsetintegerFrames added to the frame counter
rotationnumber
scaleXnumber
scaleYnumber
skewXnumberSkew in degrees (slants the vertical edges)
skewYnumberSkew in degrees (slants the horizontal edges)
skinstringDefaults to the default skin
widthnumberFrame width (default: the first frame's size)
xnumber
ynumber

set_sequence_frames setSequenceFrames

[attachment] Replace or reorder the frames of a sequence attachment (frames in the new order, or a `grid` over a sheet image). `resize` sets the attachment size to the first frame's size.

ParameterTypeDescription
attachment *string
slot *stringSlot id or name
framesarray
gridobjectCut a sprite sheet image into a grid of frames (give cols/rows or the frame size)
resizeboolean
skinstringDefaults to the skin that holds the attachment (active skin, then default)

add_particles addParticles

[attachment] Attach a particle emitter to a slot (rocket exhaust, sparks, confetti, smoke, coins). It emits from the slot bone's world transform. Start from a `preset` (fire, smoke, sparks, confetti, exhaust, coins) and override any setting. Key `emitting`/`rate` with setKeys (target 'particles', id = slot); state machines switch it with setStateEmitter or setEmitter/emitParticles listener actions.

ParameterTypeDescription
slot *stringSlot id or name
activatebooleanShow this emitter in the slot's setup pose
anglenumberSpread in degrees around the direction
angularVelocityarrayExtra spin in degrees per second as [min, max]; each particle picks a random value in between
blendstring
burstsarrayOne-off spawns: count particles at time seconds into each emitter cycle
colorsarrayColour over life: stops with t 0..1 and #rrggbbaa colours (alpha fades)
dragnumberVelocity decay per second
durationnumberEmitter cycle length in seconds
emittingbooleanEmitting on/off in the setup pose (keyable: timeline target 'particles', property 'emitting')
endRotationarrayRotation at death in degrees (interpolated over the life) as [min, max]; each particle picks a random value in between
endSizearraySize at death as [min, max]; each particle picks a random value in between
gravitynumberDownward acceleration in units/s² (negative rises)
heightnumberBox height
imagestringImage for look 'image' (packed atlas images work too)
lifetimearraySeconds a particle lives as [min, max]; each particle picks a random value in between
lookstringcircle = soft dot, square, spark = streak along velocity, image = textured quad
loopbooleanRepeat the cycle (bursts replay each cycle); false stops emitting after duration
maxParticlesintegerLive particle cap; extra spawns are dropped
namestringAttachment name (defaults to the preset name or 'particles')
presetstring
prewarmbooleanStart as if one cycle had already run (smoke and exhaust look settled at time 0)
radiusnumberCircle radius / cone mouth half-width
ratenumberParticles per second (keyable: property 'rate')
rotationnumberEmission direction in degrees in slot-bone space (90 = bone +y)
seedintegerRandom seed: the same seed and time give the same particles
shapestringWhere particles spawn: point, circle (emits outwards), box, cone (mouth of radius)
skinstringDefaults to the default skin
spacestringworld: particles stay put when the bone moves (trails); local: they move with the bone
speedarrayStart speed in units/s as [min, max]; each particle picks a random value in between
startRotationarrayRotation at birth in degrees as [min, max]; each particle picks a random value in between
startSizearraySize at birth as [min, max]; each particle picks a random value in between
stretchnumberSpark streak length in seconds of velocity
widthnumberBox width
xnumber
ynumber

update_particles updateParticles

[attachment] Change settings of a particle emitter (validated). Pass only the fields to change; `preset` first resets every field to that preset.

ParameterTypeDescription
attachment *stringParticles attachment name
slot *stringSlot id or name
anglenumberSpread in degrees around the direction
angularVelocityarrayExtra spin in degrees per second as [min, max]; each particle picks a random value in between
blendstring
burstsarrayOne-off spawns: count particles at time seconds into each emitter cycle
colorsarrayColour over life: stops with t 0..1 and #rrggbbaa colours (alpha fades)
dragnumberVelocity decay per second
durationnumberEmitter cycle length in seconds
emittingbooleanEmitting on/off in the setup pose (keyable: timeline target 'particles', property 'emitting')
endRotationarrayRotation at death in degrees (interpolated over the life) as [min, max]; each particle picks a random value in between
endSizearraySize at death as [min, max]; each particle picks a random value in between
gravitynumberDownward acceleration in units/s² (negative rises)
heightnumberBox height
imagestringImage for look 'image' (packed atlas images work too)
lifetimearraySeconds a particle lives as [min, max]; each particle picks a random value in between
lookstringcircle = soft dot, square, spark = streak along velocity, image = textured quad
loopbooleanRepeat the cycle (bursts replay each cycle); false stops emitting after duration
maxParticlesintegerLive particle cap; extra spawns are dropped
presetstring
prewarmbooleanStart as if one cycle had already run (smoke and exhaust look settled at time 0)
radiusnumberCircle radius / cone mouth half-width
ratenumberParticles per second (keyable: property 'rate')
rotationnumberEmission direction in degrees in slot-bone space (90 = bone +y)
seedintegerRandom seed: the same seed and time give the same particles
shapestringWhere particles spawn: point, circle (emits outwards), box, cone (mouth of radius)
skinstringSkin id or name
spacestringworld: particles stay put when the bone moves (trails); local: they move with the bone
speedarrayStart speed in units/s as [min, max]; each particle picks a random value in between
startRotationarrayRotation at birth in degrees as [min, max]; each particle picks a random value in between
startSizearraySize at birth as [min, max]; each particle picks a random value in between
stretchnumberSpark streak length in seconds of velocity
widthnumberBox width
xnumber
ynumber

set_state_emitter setStateEmitter

[interactivity] Make a state switch a slot's particle emitter on or off when the state is entered (emitting null removes the switch). Turning it on restarts the emitter cycle, so bursts replay.

ParameterTypeDescription
emitting *boolean | null
slot *stringSlot with a particles attachment id or name
state *stringState id or name
stateMachine *stringState machine id or name
layerstringLayer id or name

add_text addText

[attachment] Attach text to a slot. `text` is a template: {input} or {input:0.00} shows a state machine input (number patterns: 0.00 decimals, #,##0 thousands, leading + sign, trailing %, any other characters kept, e.g. {multiplier:0.00x} → 2.35x). The width x height box (estimated when omitted) is the alignment frame and hit area.

ParameterTypeDescription
slot *stringSlot id or name
activatebooleanShow this attachment in the slot's setup pose
alignstring
colorstringHex color like #ff8800 or #ff880080
fontstringCSS font family
heightnumber
namestringAttachment name (defaults to the image/shape name)
outlinestringHex color like #ff8800 or #ff880080
outlineWidthnumber
rotationnumber
sizenumber
skinstringDefaults to the default skin
textstring
weightinteger
widthnumber
xnumber
ynumber

add_binding addBinding

[interactivity] Drive a bone, slot or constraint property from a number (or bool) input, every frame after animations: input [inMin, inMax] maps linearly (clamped) to [outMin, outMax]. Bone: rotation/x/y/scaleX/scaleY/shearX/shearY; slot: color (hex outputs) or alpha (0..1); constraints: their keyable values (ik mix, path position, ...). Example: altitude 0..100 → rocket bone y 0..300.

ParameterTypeDescription
input *stringNumber input id or name
object *stringBone, slot or constraint id or name
outMax *
outMin *
property *string
stateMachine *stringState machine id or name
target *string
idstringOptional explicit id (generated when omitted)
inMaxnumber
inMinnumber

update_binding updateBinding

[interactivity] Change an input binding's input, target object, property or ranges.

ParameterTypeDescription
binding *string
stateMachine *stringState machine id or name
inMaxnumber
inMinnumber
inputstringNumber input id or name
objectstringBone, slot or constraint id or name
outMax
outMin
propertystring
targetstring

delete_binding deleteBinding

[interactivity] Delete an input binding.

ParameterTypeDescription
binding *string
stateMachine *stringState machine id or name

set_folder setFolder

[project] Put slots, skins, animations, events, constraints or state machines in a folder ("body/arms"; null or "" = top level). Folders only organise the editor lists and tree: they never change drawing, posing or exports.

ParameterTypeDescription
folder *string | nullFolder path, "/" between levels; null or "" for the top level
items *array
kind *stringWhat the items are (constraint = IK, transform, path, physics constraints and sliders)

rename_folder renameFolder

[project] Rename or move a folder with everything in it, sub-folders included ("body/arms" → "limbs"). `to` null or "" deletes the folder level: its items and sub-folders move up into the parent. For slots, `bone` limits it to the slots of one bone.

ParameterTypeDescription
from *stringCurrent folder path
kind *stringWhat the items are (constraint = IK, transform, path, physics constraints and sliders)
to *string | nullNew path; null or "" removes this level (contents move to the parent folder)
bonestringSlots only: only the slots on this bone

import_data importData

[project] Import data from another OpenBone project (like Spine's "Import data"). Picked `animations` and `skins` (ids or names in the source) are copied, matching bones, slots, constraints and events by name; keys and attachments for bones or slots this project lacks are skipped and reported. The images and sounds they use come along (reused when a same-named one exists here). `skeleton: true` brings in the whole skeleton (bones, slots, constraints and every skin's attachments) under a new root bone named after the source project. `onConflict` decides what happens when a picked animation or s…

ParameterTypeDescription
document *Source project: an OpenBone document object or its JSON text
animationsarraySource animation ids or names to copy
onConflictstring
skeletonbooleanBring in the whole skeleton under a new root bone
skinsarraySource skin ids or names to copy

new_project

Start a new empty project (root bone only). With `path` (.obone), it is saved and autosaved after every edit. An existing file at `path` is never replaced unless `overwrite` is true: use open_project to edit it.

ParameterTypeDescription
name *string
backgroundstring | null
heightnumber
originXnumber
originYnumber
overwritebooleanReplace an existing file at `path` (its contents are lost)
pathstring
widthnumber

open_project

Open an .obone file.

ParameterTypeDescription
path *string

save_project

Save the project (optionally to a new path).

ParameterTypeDescription
pathstring

get_guide

How to use OpenBone tools: coordinate system, workflow, examples.

get_summary

Readable outline of the open project: bones, slots, animations, state machines.

get_document

Raw JSON of the open document or one section of it.

ParameterTypeDescription
sectionstring

validate

Check the document for broken references and problems. Issues with a `fix` can be repaired by calling the tool `fix.tool` with `fix.args` (the editor's one-click fix). With hints: true, also lists advisory hints (unused images, empty skins/animations, settings with no effect) that never block an export.

ParameterTypeDescription
hintsbooleanAlso list advisory hints

undo

Undo the last edit.

redo

Redo the last undone edit.

import_image

Import a PNG/JPG/WebP from disk as an image asset (size detected). Stored as a path relative to the project file, or embedded when `embed` is true or the project is unsaved.

ParameterTypeDescription
path *string
embedboolean
namestring

import_font

Import a font file (TTF/OTF; WOFF/WOFF2 work on the web only) from disk as a font asset. Its family, weight and style are read from the file unless given. Texts whose font list names that family draw with it in the editor, render_frame, exports and every runtime, before installed fonts, so text looks the same everywhere. Stored as a path relative to the project file, or embedded when `embed` is true or the project is unsaved.

ParameterTypeDescription
path *string
embedboolean
familystringFamily name texts use (default: the family in the file)
namestring
stylestring
weightinteger

import_audio

Import a WAV/MP3/OGG/FLAC file from disk (its duration is read from the file) as an audio asset plus a sound of the same name (on the sfx bus unless `bus` is given). Stored as a path relative to the project file, or embedded when `embed` is true or the project is unsaved. Then play it with add_audio_key, set_event_sound, set_state_sound or a playSound listener action.

ParameterTypeDescription
path *string
busstring
embedboolean
loopboolean
namestring

pack_atlas

Pack every image into texture atlas pages (embedded PNGs, or JPEGs) and store them with set_atlas, so renderers draw packed images (and shapes) from one texture: fewer WebGL draw calls. Re-run after adding images. With stripImageSources the file carries only the pages. Identical images are stored once (alias) and blank ones take no space (ignoreBlank) by default; filterMin/filterMag/wrapX/wrapY/pixelFormat are written for runtimes; debug outlines every region.

ParameterTypeDescription
aliasbooleanStore identical images (same pixels after trimming) once; their regions share a rect (default true)
alphaThresholdintegerAlpha at or below this counts as transparent for trimming, polygons and blank images (default 0)
bleedbooleanGive fully transparent pixels the colour of the nearest visible one (alpha stays 0): no dark fringes when filtered (default on unless premultipliedAlpha)
debugbooleanDraw a magenta outline around every region on the pages (for checking a pack)
duplicatePaddingbooleanWith edge padding, copy opaque edges opaque too: hard edges like a loose texture (default true; off = opaque edges fade out)
edgePaddingbooleanRepeat each image's edge pixels into half its padding so filtering never reads neighbours (default true)
filterMagstringTexture magnification filter (default linear)
filterMinstringTexture minification filter written for runtimes (default linear)
ignoreBlankbooleanFully transparent images take no space; their regions are marked empty (default true)
jpegQualityintegerJPEG quality (default 90)
maxHeightinteger
maxSizeintegerLargest page width and height (default 2048); maxWidth / maxHeight override one axis
maxWidthinteger
minHeightinteger
minWidthintegerSmallest page width (default 0)
multipleOf4booleanPage sizes are multiples of 4, for block-compressed formats (default false)
paddingintegerEmpty pixels around each image (default 2)
pageFormatstringPage image format (default png); JPEG pages are opaque
pixelFormatstringPixel format hint for runtimes (default RGBA8888)
polygonsbooleanPolygon packing: region attachments draw a tight outline around the visible pixels instead of the full quad
powerOfTwobooleanPage sizes are powers of two (default true)
premultipliedAlphabooleanStore page pixels premultiplied (rgb × alpha); renderers use the matching blend
resamplestringResampling for scaled packs (default bilinear)
rotatebooleanTurn images 90° when that packs tighter (images used by particles stay upright)
scaleStore images at this fraction of their size; "auto" shrinks only as much as needed to fit one page
scalesarrayexport_file atlas format: several scales in one pack, one data file + page set each, e.g. [{scale:1,suffix:""},{scale:0.5,suffix:"@0.5x"}]
squarebooleanPages are square (default false)
stripImageSourcesboolean
stripWhitespacebooleanPack each image by its visible bounds (meshes keep what their uvs cover; particle images stay whole)
wrapXstringTexture wrap along x (default clamp)
wrapYstring

render_frame

Render the artboard to a PNG you can look at. Setup pose by default; or an animation at `time`; or a state machine after `steps`. Bones are drawn as blue wedges, bounding boxes dashed orange, clipping masks dashed violet.

ParameterTypeDescription
animationstring
scalenumber
showBonesboolean
showBoundingBoxesboolean
skinstringSkin (outfit) name to show; default skin only when omitted
stateMachinestringState machine name (empty string = first)
stepsarray
timenumber
wireframeboolean

render_gif

Render an animated GIF of an animation or state machine run, saved to `out` (and returned as an image).

ParameterTypeDescription
animationstring
durationnumber
fpsinteger
outstringOutput path (default next to the project)
scalenumber
showBonesboolean
skinstringSkin (outfit) name to show; default skin only when omitted
stateMachinestring
stepsarrayState machine inputs over time (each step's advance is its duration)

simulate_state_machine

Run a state machine headlessly through steps (set inputs, fire triggers, pointer events, advance time) and get a log of state changes, events, input changes, audio commands and script output. Use to test interactivity.

ParameterTypeDescription
steps *array
stateMachinestring

inspect_pose

World positions/rotations of bones (skeleton space, y-up) for the setup pose or an animation at a time.

ParameterTypeDescription
animationstring
bonesarray
timenumber

export_file

Export the project like the editor's Export dialog (same code as `openbone export`). Formats: obone (whole project; embed: true makes it self-contained), json / obonb (runtime data: picked animations, state machines; obonb is binary; pack: true embeds a texture atlas), atlas (ZIP: runtime JSON + atlas pages as PNG/JPEG files; atlas.scales gives one data file + page set per scale), png / jpeg (one frame, or a ZIP of every frame with sequence: true), apng, gif, psd (one layer per frame), avi / mov (Motion-JPEG video with the run's sound), mp4 (H.264 + AAC) / webm (VP9 + Opus) through ffmpeg on t…

ParameterTypeDescription
format *string
animationstring
animationsarrayjson/obonb/atlas: animations to keep (names; default all marked for export). spritesheet: clips (default all exported animations)
atlasobjectTexture atlas settings for atlas / pack
audiobooleanavi/mov/mp4/webm: include the sound the run plays (WAV decodes always; MP3/OGG/FLAC and the mp4/webm encoders need ffmpeg on the PATH)
binarybooleanweb: animation as .obonb (default true); atlas: runtime data as .obonb instead of .json (default false)
clipbooleanweb: false draws past the artboard's edges (default: clipped to the artboard)
durationnumberSeconds (default the animation's length, or 2 for state machines)
embedbooleanobone/json/obonb: embed every image and audio file in the file, so it opens on its own anywhere (e.g. a copy to open in the web editor, which can't read files next to it)
enginestring
fitstringweb: how the artboard fits the player (default contain)
fpsinteger
fullscreenFitstringweb: fit while full screen (default auto)
minifybooleanweb: minified player
outstringOutput path (default <project>.<ext> next to the project)
packbooleanjson/obonb/web: pack images into an embedded texture atlas
qualitynumbermp4/webm: quality 0..1 (default 0.85)
scalenumber
sequencebooleanpng/jpeg: every frame in a ZIP instead of one frame
singleFilebooleanweb: one HTML file (works from file://)
skinstring
stateMachinestring
stateMachinesarrayjson/obonb/atlas: state machines to keep (default all)
stepsarray
timenumberpng/jpeg single frame: time in the animation
transparentbooleanTransparent background (png, apng, gif, psd, spritesheet)

trace_mesh

Trace a mesh from an image's visible pixels (like the editor's Trace mesh / Re-trace outline): less transparent area is drawn and the mesh can bend. On a region: replaces it with a mesh in the same place, size, rotation and tint. On a mesh: re-traces it where it sits (same image mapping) and binds it again to the same bones with automatic weights (or to `bones`), with as many influences per vertex as before; its deform keys no longer apply. maxHull: outline detail cap (16 simple, 48 balanced, 96+ detailed); tolerance: how closely the outline follows the edge in image pixels (default 1% of the…

ParameterTypeDescription
slot *string
attachmentstringRegion or mesh attachment name (default the slot's current one)
bonesarrayRe-tracing a mesh: bind to these bones instead of the ones it used
falloffnumberRe-tracing a weighted mesh: automatic weights falloff (default 2; higher = sharper)
interiorinteger
maxHullinteger
paddingnumber
skinstringSkin holding the attachment (default: where it is found)
thresholdintegerAlpha above this counts as visible
tolerancenumberOutline simplification in image pixels (smaller follows the edge more closely; default 1% of the image's longer side). maxHull only caps the count.

lip_sync

Lip sync: analyse a sound (WAV) and key a mouth slot's attachments to it, stepped, starting at `start` seconds in `animation` (created if missing); the sound is added to the animation's audio track. Six shapes: rest, closed (M/B/P), small, open, wide, round; the slot's attachment names are guessed per shape unless `mapping` is given.

ParameterTypeDescription
slot *stringMouth slot with one attachment per mouth shape
sound *stringSound name or id
animationstringAnimation name (default: a new 'lipsync <sound>' animation)
mappingobjectShape → attachment name
startnumber

pose_bones

Pose tool (inverse kinematics without a constraint): bend `bone` and up to `chain`-1 of its parents so the bone's tip reaches a target point, given in ARTBOARD pixels (y-down, top-left origin; the same space as render_frame). Without `animation` it changes the setup pose; with `animation` (+ `time`) it sets rotation keys there. The root bone never moves.

ParameterTypeDescription
bone *string
x *number
y *number
animationstring
chaininteger
timenumber

bake_constraints

Bake constraints into keys ("key constrained"): play `animation`, sample the bones' local values as they are after IK, transform, path and physics constraints (and sliders), and write them as ordinary bone keys. By default the bones are every bone a constraint moves, and the mixes of those constraints are keyed to 0 over the range so the motion is not applied twice. Use it to freeze physics into editable keys, or to hand off a rig to a runtime without constraints. One undo step.

ParameterTypeDescription
animation *stringAnimation id or name
bonesarrayBones (ids or names) to bake; default: every constrained bone
disableConstraintsbooleanKey the mixes of the constraints that moved the baked bones to 0 over the range
endnumberRange end in seconds (default: the animation's length)
fpsnumberSamples per second
skinstringSkin to bake with (skin bones/constraints follow it)
startnumberRange start in seconds (default 0)
tolerancenumberDrop keys a straight line between their neighbours reproduces within this (degrees/units; scales use 1/100 of it). 0 = a key per sample

get_stats

Skeleton statistics like the editor's Stats panel: bones, slots, constraints, visible/total attachments, vertices, weighted vertex transforms, triangles, clipping masks, estimated draw calls, images and image area.

ParameterTypeDescription
skinstring

process_image

Prepare art for rigging: run `ops` in order on an image (a file path or a project image name/id), save the result as a PNG at `out` and optionally import it (`importAs`: a new image of that name) or replace a project image in place (`replace`: regions using it keep their pixel density). Ops: keyColor (remove a flat background colour everywhere, soft edges, no colour fringe; colour defaults to the border median, sampleFrom:'top' for strips like grass that touch the bottom), differenceMatte (cut out what differs from `other`, the same picture with the object painted out — e.g. a tree, to anima…

ParameterTypeDescription
input *stringImage file path (relative to the project folder or absolute) or a project image name/id
ops *array
out *stringOutput PNG path (relative to the project folder or absolute)
importAsstringImport the result as a new image with this name
replacestringReplace this project image (name or id) with the result, keeping its id