/// <summary>
        /// Allocation service from UPay
        /// </summary>
        /// <param name="requestTransactions">
        /// This element forms the body of the request.  It can contain one or more transaction elements.  
        /// Each of those can contain one or more allocation elements.
        /// </param>
        /// <returns>
        /// This is the response element.  It will contain a string representing the results of the allocation request.
        /// This will be the string "OK" if the process succeeded.  Otherwise, it will contain a list of error messages.
        /// Allocation records are *only* applied if all lines validate properly.
        /// </returns>
        public string Allocate(allocRequestTransaction[] requestTransactions)
        {
            string result;

            using (var client = new AllocClient())
            {
                try
                {
                    result = client.alloc(requestTransactions);
                }
                catch (Exception exception)
                {
                    return exception.Message;
                }
            }

            return result;
        }
        /// <summary>
        /// Provide the transactionId and merchantId which correspond to the transaction you wish to 'split'/allocate
        /// </summary>
        /// <param name="transactionId">
        /// This is the unique transaction ID assigned to a transaction within your merchant ID.  
        /// This value is returned to your server via the post-back in the TPG_TRANS_ID variable.
        /// </param>
        /// <param name="merchantId">
        /// This is the merchant ID as known to the TouchNet payment gateway.  You must obtain this 
        /// number from Internal Control.  It is an integer between 0 and 255.  It is NOT your 
        /// UPAY_SITE_ID or any other number that is used during the process.  (Sorry, this is due to 
        /// the data available to the nightly process.)
        /// </param>
        public TransactionAllocationManager(string transactionId, int merchantId)
        {
            Transaction = new allocRequestTransaction() {transactionId = transactionId, merchantId = merchantId};

            Allocations = new List<allocRequestTransactionAllocation>();
        }