Is there a JSL command to find the current Site ID? Since you can see this info from the top row of menus, it's hiding somewhere in there!
There is an existing defect to request that these functions be documented: S1479422