Method GetPEPhoneDetail

Type: FusionOSServices.Controllers.PEPhoneDetailController

Summary

REST service that provides an interface to read the PEPhoneDetail table

Example

GET https://fusion.centralsquare.com/FusionOSServices/v2/ONESolution/PersonEntity/PEPhoneDetail/00000001/BL/01

Parameters

TypeDescription
System.String the employee ID
System.String the phone code
System.String the address code

Sample Code

using System.Net;

public void MethodName(parms){
    string uri = "https://fusion.centralsquare.com/FusionOSServices/v2/ONESolution/PersonEntity/PEPhoneDetail/00000001/BL/01";
    WebClient wc = new WebClient();
    Common.SetResponseType(wc, "json");
    Common.SetLicenseKey(wc);
    string stringResult = wc.DownloadString(new Uri(uri));
    
    JObject response = JObject.Parse(stringResult);
    foreach(var addressRec in response["RequestResponse"]["DATA"]["PEPHONEDETAIL"])
    {
       // TODO
    }
}

$.get('https://fusion.centralsquare.com/FusionOSServices/v2/ONESolution/PersonEntity/PEPhoneDetail/00000001/BL/01', function(response) {
    $('#resultDiv).html(response); 
 });

Sample Responses


                        
            {
              "RequestResponse": {
                "Count": "1",
                "DATA": {
                  "PEPHONEDETAIL": [
                    {
                      "peId": "00000001",
                      "phoneTypeCd": "CL",
                      "phoneNumber": "8541258945",
                      "phoneExtension": "",
                      "createWho": "NAYANAT~1",
                      "createWhen": "6/16/2010 9:48:24 PM",
                      "updateWho": "RESTAPI",
                      "updateWhen": "9/28/2020 9:38:51 PM",
                      "uniqueKey": "03BF3DE0-1BD7-4C52-9430-CA262EB9939E",
                      "addrCd": "PM",
                      "phoneCountryCd": ""
                    }
                  ]
                }
              }
            }
            
        

Remarks

The first logical directory after /PEAssocDetail is the PE ID. After that, the next directory is the phone code, followed by the address code. If all are specified, and a corresponding record exists, that record will be returned in the PEPhoneDetail array of size 1 (see below). If the address code is left off the URL, then all records for that PE ID and phone code will be returned in the array. If the phone code and address codes are left off, then all records for that PE ID will be returned. Errors are returned as JSON objects with messages in the #text attribute, e.g.: { "#text": "No ID found in path" }