[Update] Joining and controlling Omniverse Live Session from a headless Kit-based microservice

Operating System:
Windows
Linux
Kit Version:
110 (Kit App Template)
109 (Kit App Template)
108 (Kit App Template)
107 (Kit App Template)
106 (Kit App Template)
105 (Launcher)
Kit Template:
USD Composer
USD Explorer
USD Viewer
Custom
GPU Hardware:
A series (Blackwell)
A series (ADA)
A series
50 series
40 series
30 series
GPU Driver:
Latest
Recommended (573.xx)
Other
Work Flow:
Main Issue: can’t find a way to open a live session
Reproduction Steps:
Error Code:

Previous topic

Hi Richard and everyone interested in the live session topic,

Thanks to Richard for the information first.
And finally, I found the correct Python package and API to access a stage’s live session on an NVIDIA Nucleus server. I list the steps, because can’t share the source code. I will reply if anyone got problem.

## Join Flow Steps and Kit Functions

1. Get USD context

- `omni.usd.get_context()`

2. Initialize Layers and LiveSyncing

- `layers.get_layers(self._usd_context)`

- `layers_state.get_live_syncing()`

3. Open stage

- `omni.usd.get_context.open_stage_async(cleaned_stage_url, omni.usd.UsdContextInitialLoadSet.LOAD_ALL)`

- `omni.usd.get_context.get_stage()`

4. Read layer identifiers

- `stage.GetRootLayer().identifier`

- `stage.GetSessionLayer()`

5. Find / create / join live session

- `live_syncing.find_live_session_by_name(root_layer_identifier, session_name)`

- `live_syncing.create_live_session(session_name, root_layer_identifier)`

- `live_syncing.join_live_session(target_session)`

- `live_syncing.join_live_session_by_url(root_layer_identifier, full_url, True)`

6. Verify joined state

- `live_syncing.get_current_live_session(root_layer_identifier)`

- Check `current_session.joined` and `current_session.valid`

7. Leave session (leave API)

- `live_syncing.stop_live_session(layer_identifier)`

## API Call Chain (Forum-ready)

- HTTP API`/live_session/join` → `get_live_session_manager()` → `LiveSessionManager.join_session(stage_url, session_name)`

Thank you SO much for this detailed reply to help the community. I will be sure to bookmark this and share it out as needed !