Archive

Archive for the ‘Receipts’ Category

SWS GetTransactionDetails Method

February 1, 2017 Leave a comment

Returns receipt detail information for the specified transaction ID(s).

Parameters

Name DataType Is Required
SiteID Long Required
Description The site’s ID number. This can be found using the GetSiteList method.
TransactionIDs ArrayOfLong Required
Description The transaction’s ID number. Transaction IDs are system generated for each payment transaction that occurs in the system. The transaction ID is returned when any MakePayment method is used.

Returned Parameters

Name DataType
TransactionID Long
Description The transaction’s ID number. Transaction IDs are system generated for each payment transaction that occurs in the system. A null or “0” response indicates the transaction failed.
ErrorMsg String
Description If there is an error processing this method this will provide text about the problem that occurred.
TransactionDate DateTime
Description The date the transaction occured.
TransactionTime String
Description The time the transaction occured.
PaymentAmount Decimal
Description The total amount to be paid after all assessments and credits are applied.
EscrowCreditAmount Decimal
Description The amount of the funds taken that were applied to cash credit/escrow.
Type String
Description The type of transaction that occurred.
Status String
Description The status of the transaction.
Agent String
Description The name of the user that completed the transaction.
AccountName String
Description The name on the account where the transaction occurred. This may differ from the primary contact’s name in some instances, such as a business account or a guardianship account.
TransactionPaymentMethod: PaymentMethod String
Description The type of payment that was received for the transaction.
TransactionPaymentMethod: Amount  Decimal
Description The total amount to be paid after all assessments and credits are applied.
TransactionPaymentMethod: AmountTendered Decimal
Description The amount received from the customer.
TransactionPaymentMethod: CashBack Decimal
Description If the payment was cash, this indicates the cash returned to the customer.
TransactionReceiptDetail: ChargeDate DateTime
Description The date the transaction occurred.
TransactionReceiptDetail: ItemDescription String
Description The name of the assessment that was paid.
TransactionReceiptDetail: Amount Decimal
Description The amount of the particular assessment.

Example

As with every method we need to pass in credentials. We do this with the LookupUser request object.

We’ll assume you’ve got a web reference, let’s name it SWS, in your Visual Studio project. At this point we need to our objects. We’ll need the standard service object, a GetTransactionDetails request object and a GetTransactionDetails response object. We can define and create those like this:

// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.GetTransactionDetails_Request request = new SWS.GetTransactionDetails_Request();
SWS.GetTransactionDetails_Response response;

Here’s my sample code of the Request object.

// GetTotalDuePastDue Request
request.SiteID = 123456;
request.TransactionIDs = new long[] { 123456 };

Finally we can call the method and pass across the login object and the request object to retrieve the transaction details. It’s a good idea to do this in a Try Catch block.

// Call the method that will load the response object
try
{
  response = service.GetTransactionDetails(user_request, request);
}
catch (Exception ex)
{
  MessageBox.Show(ex.Message);
}

Note that if something goes wrong the service will respond with an exception. You’ll want to take a look at that message returned in that exception so it can be debugged.

For a full list of methods see SWS Methods.

SWS GetRetailReceiptItems Method

May 23, 2011 Leave a comment

Retrieves the list of assessments for a specific transaction ID for retail sales only.

Parameters

Name Data Type Is Required
SiteID  Long  Required
Description  The site’s ID. This can be found using the GetSiteList method.
TransactionID  Long Required
Description The transaction’s ID number. Transaction IDs are system generated for each payment transaction that occurs in the system. If there is no transaction ID the transaction failed. The transaction ID is returned when any MakePayment method is used.

Returned Parameters

 Name Data Type
TNX_ID Long
Description The transaction’s ID number. Transaction IDs are system generated for each payment transaction that occurs in the system. A null or “0” response indicates the transaction failed.
SITE_ID Long
Description The site’s ID number.
ACCT_ID Long
Description The account’s ID associated with the transaction.
ACCT_NAME String
Description The name on the account. This may differ from the primary contact’s name in some instances, such as a business account or a guardianship account.
ACCT_TYPE Integer
Description A numerical value identifying the type of account.
Available values:

  • 1 – Personal
  • 2 – Business
RETAIL_ID Long
Description The ID of the retail item.
TNX_DETAIL_ID Long
Description The ID of the transaction detail
RETAIL_OBJECT_ID Long
Description The ID of the individual retail object.
TNX_DATE DateTime
Description The date of the transaction.
AMT Decimal
Description The amount of the transaction.
ITEM_PRICE Decimal
Description The price of the item.
TAX_CHARGED String
Description Indicates if tax was charged (“Y”) or not (“N”). Default is “Y”.
TAX Decimal
Description The amount of tax that was charged.
EXTENDED Decimal
Description The extended amount.
FULFILLED Decimal
Description The fulfilled amount.
ASS_ID Long
Description The assessment ID.
ASS_REF Long
Description The assessment reference number.
ICON String
Description The processed function for the transaction.
CLASS_DESC String
Description The description of the retail class.
ITEM_NAME String
Description The name of the item.
DESCRIPTION String
Description The description of the item sold.
QTY Decimal
Description The quantity of the item sold.
RETURNED Decimal
Description A numerical value displaying whether the item is returned.
PART_NUMBER String
Description The part number of the item.
SKU String
Description The individual SKU of the item sold.
BARCODE String
Description A numerical value assigned for an item type.
ITEM_TYPE Integer
Description The ID assigned to the tax group.
TAX_GROUP_ID Decimal
Description The ID for the tax group applicable to the retail revenue class.
STATUS Integer
Description A numerical value for the status of the transaction.

Example

As with every method we need to pass in credentials. We do this with the LookupUser request object.

We’ll assume you’ve got a web reference, let’s name it SWS, in your Visual Studio project.  At this point we need to our objects.  We’ll need the standard service object, a GetRetailReceiptItems request object and a GetRetailReceiptItems response object.  We can define and create those like this:

// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.GetRetailReceiptItems_Request request = new SWS.GetRetailReceiptItems_Request();
SWS.GetRetailReceiptItems_Response response;

Here’s my sample code of the Request object.

// GetRetailReceiptItems Request
request.SiteID = 123456;
request.TransactionID = 123456;

Finally we can call the method and pass across the login object and the request object to get items for our retail receipt. It’s a good idea to do this in a Try Catch block.

   ' Call the method that will load the response object
try
{
  response = service.GetRetailReceiptItems(user_request, request);
}
catch (Exception ex)
{
  MessageBox.Show(ex.Message);
}

Note that if something goes wrong the service will respond with an exception. You’ll want to take a look at that message returned in that exception so it can be debugged.

For a full list of methods see SWS Methods.

SWS viewReceiptPdf Method

April 28, 2011 Leave a comment

Provides a URL to view the requested document.

Parameters

Name DataType Is Required
AcctID Long Required
Description The account’s ID number. This is returned when you use the CreateNewAccount method or can be retrieved with the SearchBy method.
PdfTemplateID Long Required
Description The receipt’s ID number. You are able to retrieve this ID using the LTR_TYPE_ID from the getReceiptTemplateInfo method.
SiteID Long Required
Description The site’s ID number. This can be found using the GetSiteList method.
TransactionID Long Required
Description The transaction’s ID number. Transaction IDs are system generated for each payment transaction that occurs in the system. If there is no transaction ID the transaction failed. The transaction ID is returned when any MakePayment method is used.

Returned Parameters

Name DataType
TntPdfFilePath String
Description The file path to where the receipt is stored. Here is an example of what the receipt path might look like:

https://csiapp1.centershift.com/qa40/letters/
1000053626__1000305633_receipt.pdf

Example

As with every method we need to pass in credentials. We do this with the LookupUser request object.

We will assume you have a web reference, let us name it SWS, in your Visual Studio project. At this point we need to define our objects.  We will need the standard service object, a createOrViewReceipt request object, and a PdfFilePath response object. We can define and create those like this:

// Create a request and response objects
SWS.WSSoapClient service = new SWS.WSSoapClient();
SWS.createOrViewReceipt_Request request = new SWS.createOrViewReceipt_Request();
SWS.PdfFilePath_Response response;

Here is a sample code of the request object:

// ViewReceiptPDF Request
request.SiteID = 123546;
request.AcctID = 123456;
request.TransactionID = 123456;
request.PdfTemplateID = 123456;

Finally we can call the method and pass across the login object and the request object to retrieve our requested information. It’s a good idea to do this in a Try Catch block.

// Call the method that will load the response object
try
{
  response = service.viewReceiptPdf(user_request, request);
}
catch (Exception ex)
{
  MessageBox.Show(ex.Message);
}

Note that if something goes wrong the service will respond with an exception. You will want to capture the message in the exception so it can be debugged.

For a full list of methods see SWS Methods.

Categories: Payments, Printing, Receipts Tags: ,