Skip to content

Commit d7113db

Browse files
committed
Add SinglaR token to header
1 parent 520dbdb commit d7113db

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/uipath_mcp/_cli/_runtime/_runtime.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -175,17 +175,14 @@ async def execute(self) -> Optional[UiPathRuntimeResult]:
175175
root_span.set_attribute("command", str(self._server.command))
176176
root_span.set_attribute("args", json.dumps(self._server.args))
177177
root_span.set_attribute("span_type", "MCP Server")
178-
179-
def token_factory() -> str:
180-
return os.environ.get("UIPATH_ACCESS_TOKEN", "")
181-
178+
182179
self._signalr_client = SignalRClient(
183180
signalr_url,
184-
access_token_factory=token_factory,
185181
headers={
186182
"X-UiPath-Internal-TenantId": self.context.trace_context.tenant_id, # type: ignore
187183
"X-UiPath-Internal-AccountId": self.context.trace_context.org_id, # type: ignore
188184
"X-UIPATH-FolderKey": self.context.folder_key,
185+
"Authorization": f"Bearer {self._uipath._config.secret}",
189186
},
190187
)
191188
self._signalr_client.on("MessageReceived", self._handle_signalr_message)

0 commit comments

Comments
 (0)