Sending An HTTP Request using Intersystems Cache
I have the following Business Process defined within a Production on an Intersystems Cache Installation

    /// Makes a call to Merlin based on the message sent to it from the pre-processor
Class sgh.Process.MerlinProcessor Extends Ens.BusinessProcess [ ClassType = persistent, ProcedureBlock ]
{

Property WorkingDirectory As %String;

Property WebServer As %String;

Property CacheServer As %String;

Property Port As %String;

Property Location As %String;

Parameter SETTINGS = "WorkingDirectory,WebServer,Location,Port,CacheServer";

Method OnRequest(pRequest As sgh.Message.MerlinTransmissionRequest, Output pResponse As Ens.Response) As %Status
{

	Set tSC=$$$OK
	
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Packaging an HTTP request for Saved form "_pRequest.DateTimeSaved)
	
	Set dateTimeSaved 		= pRequest.DateTimeSaved
	Set patientId			= pRequest.PatientId
	Set latestDateTimeSaved = pRequest.LatestDateTimeSaved
	Set formName			= pRequest.FormName
	Set formId				= pRequest.FormId
	Set episodeNumber		= pRequest.EpisodeNumber
	Set sentElectronically	= pRequest.SentElectronically
	Set styleSheet			= pRequest.PrintName
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Creating HTTP Request Class")
	
	set HTTPReq = ##class(%Net.HttpRequest).%New()
	
	Set HTTPReq.Server 		= ..WebServer
	Set HTTPReq.Port		= ..Port
	
	do HTTPReq.InsertParam("DateTimeSaved",dateTimeSaved)
	do HTTPReq.InsertParam("HospitalNumber",patientId)
	do HTTPReq.InsertParam("Episode",episodeNumber)
	do HTTPReq.InsertParam("Stylesheet",styleSheet)
	do HTTPReq.InsertParam("Server",..CacheServer)
	
	Set Status = HTTPReq.Post(..Location,0) Quit:$$$ISERR(tSC)
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Sent the following request: "_Status)
	
	Quit tSC
}

}

The thing is when I check the debug value (which is defined as a global) all I get is the number '1' - I have no idea therefore if the request has succeeded or even what is wrong (if it has not)

What do I need to do to find out 

A) What is the actual web call being made?

B) What the response is?

Sending An HTTP Request using Intersystems Cache
===

I have the following Business Process defined within a Production on an Intersystems Cache Installation

    /// Makes a call to Merlin based on the message sent to it from the pre-processor
Class sgh.Process.MerlinProcessor Extends Ens.BusinessProcess [ ClassType = persistent, ProcedureBlock ]
{

Property WorkingDirectory As %String;

Property WebServer As %String;

Property CacheServer As %String;

Property Port As %String;

Property Location As %String;

Parameter SETTINGS = "WorkingDirectory,WebServer,Location,Port,CacheServer";

Method OnRequest(pRequest As sgh.Message.MerlinTransmissionRequest, Output pResponse As Ens.Response) As %Status
{

	Set tSC=$$$OK
	
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Packaging an HTTP request for Saved form "_pRequest.DateTimeSaved)
	
	Set dateTimeSaved 		= pRequest.DateTimeSaved
	Set patientId			= pRequest.PatientId
	Set latestDateTimeSaved = pRequest.LatestDateTimeSaved
	Set formName			= pRequest.FormName
	Set formId				= pRequest.FormId
	Set episodeNumber		= pRequest.EpisodeNumber
	Set sentElectronically	= pRequest.SentElectronically
	Set styleSheet			= pRequest.PrintName
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Creating HTTP Request Class")
	
	set HTTPReq = ##class(%Net.HttpRequest).%New()
	
	Set HTTPReq.Server 		= ..WebServer
	Set HTTPReq.Port		= ..Port
	
	do HTTPReq.InsertParam("DateTimeSaved",dateTimeSaved)
	do HTTPReq.InsertParam("HospitalNumber",patientId)
	do HTTPReq.InsertParam("Episode",episodeNumber)
	do HTTPReq.InsertParam("Stylesheet",styleSheet)
	do HTTPReq.InsertParam("Server",..CacheServer)
	
	Set Status = HTTPReq.Post(..Location,0) Quit:$$$ISERR(tSC)
	
	Do ##class(sgh.Utils.Debug).LogDebugMsg("Sent the following request: "_Status)
	
	Quit tSC
}

}

The thing is when I check the debug value (which is defined as a global) all I get is the number '1' - I have no idea therefore if the request has succeeded or even what is wrong (if it has not)

What do I need to do to find out 

A) What is the actual web call being made?

B) What the response is?
