You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. Ensure you have the needed packages in your environment to run the example here after.
35
35
@@ -125,7 +125,7 @@ with KernelClient(server_url="http://localhost:8888", token="MY_TOKEN") as kerne
125
125
126
126
> [!NOTE]
127
127
>
128
-
> Instead of using the clients as context manager, you can call the `start()` and `stop()` methods.
128
+
> Instead of using the nbmodel clients as context manager, you can call the `start()` and `stop()` methods.
129
129
130
130
```py
131
131
from jupyter_nbmodel_client import NbModelClient, get_jupyter_notebook_websocket_url
@@ -150,21 +150,27 @@ finally:
150
150
kernel.stop()
151
151
```
152
152
153
-
> [!NOTE]
154
-
>
155
-
> To connect to Datalayer collaborative room, you can use the helper function `get_datalayer_websocket_url`:
153
+
## Usage with Datalayer
154
+
155
+
To connect to a [Datalayer collaborative room](https://docs.datalayer.app/platform#notebook-editor), you can use the helper function `get_datalayer_notebook_websocket_url`:
156
+
157
+
- The `server` is `https://prod1.datalayer.run` for the Datalayer production SaaS.
158
+
- The `room_id` is the id of your notebook shown in the URL browser bar.
159
+
- The `token` is the assigned token for the notebook.
160
+
161
+
All those details can be retrieved from a Notebook sidebar on the Datalayer SaaS.
156
162
157
163
```py
158
-
from jupyter_nbmodel_client import NbModelClient, get_datalayer_websocket_url
164
+
from jupyter_nbmodel_client import NbModelClient, get_datalayer_notebook_websocket_url
0 commit comments