CaseMap Server currently expsoses the CMServerAD service. This service exposes CaseMap Server version, case, fact, and issue information using a series of REST-based resources. You can query the service using either your browser, or programmatically. The following tutorials show how to retrieve the CaseMap Server version numbers using both paths.
Paste the following URL into your browser address window, replacing "localhost" with the location of your CaseMap server, and press Enter. |
using System.IO; using System.Net; using System.Web; using System.Xml; using System.Xml.XPath;
string serverResource = "http://localhost"; string resourceName = "/CaseMapAD/CMServerAD.svc/version"; string endPoint = serverResource + resourceName; If necessary, replace "localhost" with the URL of your CaseMap Server installation. Note that this code samples uses the Active Directory authentication (CaseMapAD). You could optionally use local authentication, by calling /CaseMapLA/CMServerLA.svc instead. Both services provide the same data: the difference is simply which authentication protocol is used. For more information, see About authentication.
HttpWebRequest request = WebRequest.Create(endPoint) as HttpWebRequest; request.Method = "GET";
HttpWebResponse response = request.GetResponse() as HttpWebResponse; DisplayMessage(response); Console.ReadLine(); DisplayMessage is a helper function you can use to display REST mesponses to the console. For more information, see CaseMap Server Helper Methods.
response.Close(); |