private static void GetReceiptCallXMLRequest(XmlNode xmlGetReceiptCallNode, XmlDocument xmlDoc, GetReceiptsRequest request)
        {
            var receiptFilterNode = xmlDoc.CreateElement("ReceiptFilter");
            xmlGetReceiptCallNode.AppendChild(receiptFilterNode);

            var resultsNode = xmlDoc.CreateElement("Results");
            resultsNode.InnerText = request.Results.ToString();
            receiptFilterNode.AppendChild(resultsNode);

            var pageNumberNode = xmlDoc.CreateElement("PageNo");
            pageNumberNode.InnerText = request.PageNumber.ToString();
            receiptFilterNode.AppendChild(pageNumberNode);

            if (!string.IsNullOrEmpty(request.ModifiedSince.ToString()))
            {
                var modifiedSinceNode = xmlDoc.CreateElement("ModifiedSince");
                modifiedSinceNode.InnerText = request.ModifiedSince.ToString();
                receiptFilterNode.AppendChild(modifiedSinceNode);
            }

            if (!string.IsNullOrEmpty(request.CategoryId))
            {
                var categoryIdNode = xmlDoc.CreateElement("Category");
                categoryIdNode.InnerText = request.CategoryId;
                receiptFilterNode.AppendChild(categoryIdNode);
            }
        }
 public virtual GetReceiptsResponse GetReceipts(GetReceiptsRequest request)
 {
     return null;
 }
        /// <summary>
        /// Returns all the saved Receipts
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        public override GetReceiptsResponse GetReceipts(GetReceiptsRequest request)
        {
            var response = new GetReceiptsResponse();

            try
            {
                var xml = ConstructXMLRequest(request, RequestTypeEnum.GetReceiptCall);
                var responseStream = SendRequest(xml);
                var reader = new StreamReader(responseStream);
                //string a = reader.ReadToEnd();
                response.Receipts = (GetReceiptCallResponse)Deserialize(typeof (GetReceiptCallResponse), reader);
            }
            catch
            {
                throw new Exception("Error in Service.");
            }

            return response;
        }