world.connect
Wait, up to about 30 s, until the world editor is open and connected in the user's browser, so engine tools (execute, capture, …) can drive it, and pin it for the rest of this conversation. It opens nothing: nothing on the server can open a browser. Call world.open first and act on its next, which says whether you show the user a link or run a command on their machine; an editor already open returns at once. With no editor connected it answers connected: false, how long it waited (waited_ms) and what the editor did (editor.state). A world with engines on more than one branch is refused rather than guessed at — name the branch, or use session.list / session.connect to pick one engine outright.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| guid | No | The same argument as `world`, under another name: give one of the two. A call giving them two different worlds is refused. | |
| world | No | Optional: the guid of the world to wait for (world.list names each of your worlds beside its guid). Omitted, any open editor. A value that is not a guid, a world's name included, is refused and connects nothing. | |
| branch | No | Which branch's engine you mean, when the world has engines on more than one. |