feat: map conversationalService.conversationalUserId to runtime context [JAR-9965]#119
Merged
Merged
Conversation
3eaf6bb to
9a743f8
Compare
Add synthetic_user_id to UiPathRuntimeContext plus the fps_mappings entry, so the conversational bridge can present the conversation owner id to CAS on the websocket handshake. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
9a743f8 to
1642ce3
Compare
There was a problem hiding this comment.
Pull request overview
This PR extends UiPathRuntimeContext to carry a conversation “owner” identifier (synthetic_user_id) by mapping it from fpsProperties["conversationalService.syntheticUserId"]. This enables downstream components (e.g., the conversational bridge) to include the synthetic user id during the CAS WebSocket handshake.
Changes:
- Added
synthetic_user_id: str | NonetoUiPathRuntimeContext. - Added an FPS mapping from
conversationalService.syntheticUserId→synthetic_user_idinUiPathRuntimeContext.from_config(...). - Extended
tests/test_context.pyto assert the new FPS key is correctly loaded into the context.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/uipath/runtime/context.py |
Adds the synthetic_user_id field and maps it from fpsProperties into runtime context. |
tests/test_context.py |
Adds an assertion covering the new FPS→context mapping. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
maxduu
approved these changes
Jun 12, 2026
Match the CAS-side rename: the forwarded conversation owner id may be a real cloud user id or a synthetic user id, so 'synthetic' was misleading. Renames the context field (conversational_user_id) and the FpsProperties key (conversationalService.conversationalUserId). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
cristipufu
approved these changes
Jun 16, 2026
10dcad7 to
3b7b1bb
Compare
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



TL;DR
Map
conversationalService.conversationalUserIdfrom FpsProperties onto a newconversational_user_idfield onUiPathRuntimeContext, so the conversational bridge can present the conversation owner id to CAS on the WebSocket handshake.Solution
runtime/context.py: addconversational_user_id: str | NonetoUiPathRuntimeContextand afps_mappingsentry"conversationalService.conversationalUserId" -> "conversational_user_id". The value may be a real cloud user id or a synthetic user id.tests/test_context.py(asserts the fps key maps onto the field).Consumed by
uipathbridge (sends it as theX-UiPath-Internal-ConversationalUserIdhandshake header) → AgentInterfaces CAS (validates againstconversation.user_idto authorize Unified Runtime Robot connections for RunAsMe=false conversations).