GUID and fully qualified references - Metasys - LIT-12013522 - Software Application - Basic Services client library for .NET (and COM) - Metasys API - 4.2

Metasys REST Client for .NET and COM Developer Guide

Brand
Metasys
Product name
Basic Services client library for .NET (and COM)
Metasys API
Document type
API Reference Guide
Document number
LIT-12013522
Version
4.2
Revision date
2021-04-07
Language
English

Some methods require that you know the Globally Unique Identifier (GUID) of the object that you want to access. In order to find the GUID you can use the GUID method. The GUID method uses a reference string to identify a specific object on a device. The following section shows an example of the GUID method, the different portions of a reference string, how to obtain the reference for an item, and an example of a reference string exception.

Example of a GUID method

Guid id = client.GetObjectIdentifier("siteName:naeName/Folder1.AV1");

Example of a reference string

<siteDirectorComputerName>:<deviceComputerName>/<item1>.<child1>.<grandchild1>

The smallest valid reference contains the Site Director's computer name and the device's computer name that the API uses to refer to a specific device on a site. When you add names to the right of the forward slash, you refer to a specific object on a device.

The siteDirectorComputerName is the computer name of the Site Director that you log on to. The deviceComputerName is the computer name of the device that hosts the object you want to receive the method.

Note: Make sure that the client is logged on to the Site Director at all times. The siteDirectorComputerName portion of the object reference and the site that the object is a member of must match.

How to obtain a reference for an item

To obtain a reference of an item, use one of the following methods:
  • In the Site Management Portal (SMP) UI, hover the cursor over an item in navigation view. The tool tip displays with the reference of the object.
  • In the Metasys UI, see the command dialog box.
  • In the Metasys UI, in an object's detail window, see the network tree.
  • The advanced focus view for most objects.

Example of a reference string exception

siteDirectorComputerName:siteDirectorComputerName/$site

This string is an exception to the normal reference string. The $site object specifies the site object. The site object appears at the top of the all items navigation view in the SMP UI. The site object is always on the Site Director, so the siteDirectorComputerName replaces deviceComputerName in the string.