Hello @All,
I have a scenario where I need to validated current local machine connected Machine key with a list of the Group.
I’m not sure how to fetch connected Machine key through automation.
Anyone help|assistance would be highly appreciated.
Hello @All,
I have a scenario where I need to validated current local machine connected Machine key with a list of the Group.
I’m not sure how to fetch connected Machine key through automation.
Anyone help|assistance would be highly appreciated.
You may try to run a GET request for https://cloud.uipath.com/ORG_NAME/TENANT_NAME/orchestrator_/odata/LicensesRuntime/UiPath.Server.Configuration.OData.GetLicensesRuntime(robotType='Unattended')?$top=10&$orderby=IsLicensed%20desc
The results will be something like:
{
"@odata.context": "https://cloud.uipath.com/ORG_NAME/TENANT_NAME/orchestrator_/odata/$metadata#RuntimeLicenses",
"@odata.count": 1,
"value": [
{
"Key": "Machine_Unattended@LAPTOP-***",
"MachineId": ***,
"MachineName": "Machine_Unattended",
"HostMachineName": "LAPTOP-***",
"ServiceUserName": "",
"MachineType": "Template",
"Runtimes": 1,
"RobotsCount": 1,
"ExecutingCount": 0,
"IsOnline": true,
"IsLicensed": true,
"Enabled": true,
"MachineScope": "Default"
}
]
}
If you need to find the MachineKey and other details, perform a GET request for
https://cloud.uipath.com/ORG_NAME/TENANT_NAME/orchestrator_/odata/Machines?$top=1000&$expand=UpdateInfo&$orderby=Name%20asc
If you need to find the Unattended sessions, will help a GET request for
https://cloud.uipath.com/ORG_NAME/TENANT_NAME/orchestrator_/odata/Sessions/UiPath.Server.Configuration.OData.GetMachineSessionRuntimes?$filter=((MachineId%20eq%MACHINE_ID)%20and%20(Runtimes%20ne%200)%20and%20(((RuntimeType%20eq%20%273%27)%20or%20(RuntimeType%20eq%20%270%27)%20or%20(RuntimeType%20eq%20%277%27)%20or%20(RuntimeType%20eq%20%272%27)%20or%20(RuntimeType%20eq%20%278%27))))&$top=1000&$orderby=HostMachineName%20asc
Also, locally you may check these locations:
C:\Users\username\AppData\Roaming\UiPath\orchestratorConnectionCache.json
The UiPath.Settings
file is stored in the %localappdata%\UiPath\
folder when the Robot is deployed in user mode, and %programdata%\UiPath\
when the Robot is deployed in service mode. It is created the first time the UiPath Robot service starts.
SecureLicenseKey → The Machine Key that is used to connect to Orchestrator. The key is encrypted in the UiPath.settings file using DPAPI. This value can also be filled in and modified from the Orchestrator Settings window . If not connected to Orchestrator, this parameter should be empty.
Reference: UiPath.Settings File Description
Hey @marian.platonov , I’ll try and update u back with results… and thanks for ur quick assistance…
How i get current VM’s robot machine templet key using CLi?
I don’t know about a such feature.
Check the above response from my side and try to find the needed key.