FROM RIVE AI AGENT --> `createStateMachineLayers` command not working & missing query tools

This report was prepared by the Rive AI agent based on its inability to use the tools he has listed as available.
Editor version 0.8.4187

Summary

The `animation_editor` tool's `createStateMachineLayers` command returns a success response but does not actually create any layers in the state machine. Additionally, there is no tool available to query or list existing state machine layers.

Steps to Reproduce

1. Create a new state machine using `createStateMachine`:

```json
{
  "command": "createStateMachine",
  "data": {"createStateMachine": {"name": "TestSM"}}
}
```

Result: Success - state machine is created and visible in the editor ✅

2. Create a layer on that state machine using `createStateMachineLayers`:

```json 
{
  "command": "createStateMachineLayers", 
  "data": {
    "stateMachineId": "<state-machine-id>",
    "layers": [{"name": "test-layer"}]
  }
}
```

Result: Returns `{"success":true,"message":"Layers added"}` but no layer appears in the state machine ❌

Expected Behavior

A new layer called "test-layer" should appear in the state machine.

Actual Behavior

The command reports success but no layer is created. This was tested on:

  • A newly created state machine

  • An existing state machine with layers

Both returned success messages but no layers were visible in the Rive editor.

Missing Tooling

There is no command available to:

  • List existing state machine layers within a state machine

  • Query layer IDs, state IDs, or transition IDs from existing state machines

  • Read the structure of an existing state machine

The `listStateMachines` command only returns the state machine name and ID, not its internal structure (layers, states, transitions).

The `queryObjects` tool does not return children of state machine objects, making it impossible to discover layer/state IDs programmatically.

Impact

This prevents programmatic creation and management of state machine layers, which blocks:

- `createStateMachineLayerStates` (requires layer ID)

- `createTransitions` (requires state IDs)

- `createConditions` (requires transition IDs)

Without the ability to query existing state machine structure or create new layers, the entire state machine building/editing workflow via the API is non-functional.

Suggested Additions

1. Fix `createStateMachineLayers` to actually create layers

2. Add `listStateMachineLayers` command to return layers within a state machine

3. Add `listLayerStates` command to return states within a layer

4. Add `listTransitions` command to return transitions between states

5. Ensure `queryObjects` returns children for state machine objects