Sales2.svc

Sending a Request to Sales2.svc
All calls to Sales2.svc require the AccessToken and the LocationToken in the HTTP Web Request Headers of the request. The parameters for the request body of each call are outlined in the sections below.

Sales2.svc Endpoint
Endpoint
https://{{server}}.brinkpos.net/Sales2.svc


HTTP Web Request Headers
Header Name
Header Value
AccessToken
{{AccessToken}}
LocationToken
{{LocationToken}}
This call is to submit orders to Brink. It is an important call to API integrators who submit orders via the Ordering.svc.

The response tells you what the Business Date is on the Register. The server may say something different because the Register could be ahead or behind. In the event that the server and Register business dates are different, these sync issues reported to Main Support.

Note: This call should only be made once a day, or at most once every three hours per location. The Register is unlikely to change the Business Date unless End of Day is run.

GetCurrentBusinessDate Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
BusinessDate
DateTime
Current Business Date shown on the register in a YYYY-MM-DD format (the time component will always return as 00:00:00)

Note: this reflects what is stored in the Register.sdf.
This call is to retrieve cash deposits received by the Register on the business date requested.

Note: This call does not allow for a DateTime Range. Therefore, if you would like Deposits for a week, month, or range any of dates, you need to do a loop that makes the call on a per day basis.
Please use the Best Practice Guide on the frequency of your calls.

GetDeposits Request
Data Name
Data Type
Data Description
BusinessDate
DateTime
Specify the Business Date would you like to see Deposits for


GetDeposits Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
Deposits
Array of Deposit
Deposits for this location on the business date requested


Deposit Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of this Deposit
Bag
string
Id for this Deposit, used for tracking purposes in Brink
BusinessDate
DateTime
Business date on which this Deposit was made (the time component will always return as 00:00:00)
DepositTypeId
int
Type of this Deposit

Note: Deposit Ids are not exposed via the API.
Id
int
Unique Id for this Deposit
Notes
string
Notes for this Deposit
Number
int
Number of the Register that accepted this Deposit. Since locations can have multiple Tills, the number is an indication of which Till received this Deposit.
Time
DateTimeOffset
Date and time of when this Deposit was made in UTC
This call returns any Deposits made for Future Date Orders received by the Register on the business date requested.
Future Date Orders are defined as orders that are made one or more days in advance.

Note: This call does not allow for a DateTime Range. Therefore, if you would like Deposits for a week, month, or range any of dates, you need to do a loop that makes the call on a per day basis.
Please use the Best Practice Guide on how many times per minute you should make this call!

GetFutureDateOrderDeposits Request
Data Name
Data Type
Data Description
BusinessDate
DateTime
Specify at what Date would you like to see the Deposits for


GetFutureDateOrderDeposits Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
Deposits
Future date order deposits for this location on the business date requested


FutureDateOrderDeposit Type
Data Name
Data Type
Data Description
BusinessDate
DateTime
Business date on which this FutureDateOrderDeposit was made (the time component will always return as 00:00:00)

Note: This corresponds with the date of the request and when the payment was processed, not when the Order was made.
OrderId
long
Maps to the Id of the future date Order of this FutureDateOrderDeposit. Note: Storing it in your own database would be beneficial.
OrderTotal
decimal
Total value of the future date Order that the FutureDateOrderDeposit was made for, including any discounts, promotions, surcharges, and/or taxes
PaymentId
int
Unique Id of the payment for this FutureDateOrderDeposit
TenderId
int
Maps to the Id of the Tender used to pay this FutureDateOrderDeposit.

Note: Future date orders or online orders cannot have Cash as a payment tender.
Time
DateTimeOffset
Date and time of when this FutureDateOrderDeposit was made in UTC
This call is to retrieve Future Date Orders. Future Date Orders are classified if the Order has a PickUpTime one day or more in advance.

Note: Once the current Business Date is equal to the PickUpTime of the Future Date Order, the Future Date Order becomes an Order, which can be viewed via the call GetOrders.

GetFutureDateOrders Request
Data Name
Data Type
Data Description
FutureDateRange
DateRange
Specify a date range you would like to retrieve the FutureDateOrders for
PriceRollUp
string
PriceRollUp is a way to tell Brink how you want your information to be displayed, specifically for combo Items. Default is RollUp if not specified.

We will use Child Items and Parent Items in the definitions below. Child Items are items that belong to a combo. So if I have an API Combo, which comes with Fries and a Drink, then the Fries and Drink are the Child Items and the API Combo is the Parent Item.

There are three different ways to specify PriceRollUp:
  • RollUp = The Child Items' prices roll up into the Combo. In other words, the Child Items will display a price of 0, but the Parent Item or Combo will have a value.

  • DetailsOnly = The Combo Items or Parent Items will have a value of 0, and the Child Items will have their individual pricing. No rolling up of pricing here.

  • RollUpAndDetails = The Combo Items or Parent Items will display their Combo Pricing and any Child Items will also have their pricing displayed. There are no displayed values of 0 unless the Item already has a value of 0 originally.



GetFutureDateOrders Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
FutureDateOrders
Array of Order
Future date orders for this location for the date range requested
This call is to retrieve all Orders opened on the business date requested.

Note: This call is quite heavy. We recommend a longer wait time on the Response, and to implement at least a 2-minute sleep in between calls to this method. Please refer to the Best Practice Guide.

GetOrders Request
Data Name
Data Type
Data Description
BusinessDate
DateTime
Specify the business date that you would like to retrieve Orders for
ExcludeOpenOrders
bool
Specify True to display only closed Orders, or False to display both open and closed Orders. Default is False if not specified.
ModifiedTime
DateTimeOffset?
(Optional) When specified, only Orders that have been modified on or after the specified time will be retrieved. This compares against any edited Orders on the Register time.
PriceRollUp
string
PriceRollUp is a way to tell Brink how you want your information to be displayed, specifically for combo Items. Default is RollUp if not specified.

We will use Child Items and Parent Items in the definitions below. Child Items are items that belong to a combo. So if I have an API Combo, which comes with Fries and a Drink, then the Fries and Drink are the Child Items and the API Combo is the Parent Item.

There are three different ways to specify PriceRollUp:
  • RollUp = The Child Items' prices roll up into the Combo. In other words, the Child Items will display a price of 0, but the Parent Item or Combo will have a value.

  • DetailsOnly = The Combo Items or Parent Items will have a value of 0, and the Child Items will have their individual pricing. No rolling up of pricing here.

  • RollUpAndDetails = The Combo Items or Parent Items will display their Combo Pricing and any Child Items will also have their pricing displayed. There are no displayed values of 0 unless the Item already has a value of 0 originally.



GetOrders Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
Orders
Array of Order
Orders for this location on the business date requested


Order Type
Data Name
Data Type
Data Description
BusinessDate
DateTime
Business date of this Order (the time component will always return as 00:00:00)
ClosedTime
DateTimeOffset?
Date and time this Order was closed in UTC, null if not yet closed
Entries
Array of OrderEntry
Entries in this Order. An OrderEntry can either be of type OrderItem or an OrderGiftCard.
Id
long
Unique Id of this Order
IdEncoded
string
Unique encoded Id of this Order
IsClosed
bool
True if this Order is closed, False if not
Name
string
Name of this Order
Payments
Array of OrderPayment
Payments applied to this Order
Total
decimal
Total for this Order


OrderDeposit Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of this OrderDeposit
BusinessDate
DateTime
Business date this OrderDeposit was taken
EmployeeId
int?
Maps to the Id of the Employee who applied this OrderDeposit
Id
int
Unique Id of this OrderDeposit
IsApplied
bool
True if this OrderDeposit has been applied to the Order, False if not
IsDeleted
bool
True if this OrderDeposit has been deleted, False if not
IsReversal
bool
True if this OrderDeposit is a reversal that offsets a deleted deposit, False if not
OriginalOrderDepositId
int?
Id of the original OrderDeposit being reversed, if this OrderDeposit is a reversal
PaymentId
int
Id of the OrderPayment that correlates to this OrderDeposit
TenderId
int
Maps to the Id of the Tender used for this OrderDeposit


OrderDiscount Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of this OrderDiscount
ApproverEmployeeId
int?
Maps to the Id of the Employee who approved this OrderDiscount
DiscountId
int
Maps to the Id of the Discount for this OrderDiscount
EmployeeId
int?
Maps to the Id of the Employee who applied this OrderDiscount
ExternalLoyaltyAccount
string
Number of the external loyalty account through which this OrderDiscount is applied
Id
int
Unique Id of this OrderDiscount within the Order
LoyaltyRewardId
int?
Maps to the Id of the LoyaltyReward if this OrderDiscount is applied via a loyalty reward
Name
string
Name of this OrderDiscount
Source
int
Returns one of the following:
  • 0 = Other
  • 1 = LoyaltyCard
  • 2 = LoyaltyReward


OrderEntry - OrderItem Type
Data Name
Data Type
Data Description
Description
string
Description of this OrderItem
Id
int
Unique Id of this OrderItem within the Order
ItemId
int
Maps to the Id of the Item of this OrderItem
Price
decimal
Price of this OrderItem


OrderEntry - OrderGiftCard Type
Data Name
Data Type
Data Description
DayPartId
int?
Maps to the Id of the DayPart of this OrderItem
Description
string
Description of this OrderGiftCard
Id
int
Unique Id of this OrderGiftCard within the Order
ItemId
int
Maps to the Id of the Item of this OrderItem
Price
decimal
Price of this OrderGiftCard
Promotions
Promotions applied to this OrderGiftCard


OrderItemDiscount Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of discount applied to the OrderItem
Id
int
Unique Id of this OrderItemDiscount within the OrderItem
OrderDiscountId
int
Maps to the Id of the Discount for this OrderItemDiscount


OrderItemModifier Type
Data Name
Data Type
Data Description
DisplayPrice
decimal
Price displayed for this OrderItemModifier
GrossSales
decimal
Gross sales for this OrderItemModifier and its children
Id
int
Unique Id of this OrderItemModifier within the OrderItem
ItemGrossSales
decimal
Gross sales for this OrderItemModifier only
ItemId
int
Maps to the Id of the Item for this OrderItemModifier
ItemNetSales
decimal
Net sales for this OrderItemModifier only
ModifierCodeId
int
Maps to the Id of the ModifierCode for this OrderItemModifier
ModifierGroupId
int
Maps to the Id of the ModifierGroup for this OrderItemModifier
Modifiers
Modifiers applied to this OrderItemModifier
NetSales
decimal
Net sales for this OrderItemModifier and its children
Price
decimal
Price of this OrderItemModifier
Taxes
Array of OrderEntryTax
Taxes applied to this OrderItemModifier


OrderEntryPromotion Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of promotion applied to the OrderEntry
Id
int
Unique Id of this OrderItemPromotion within the OrderEntry
OrderPromotionId
int
Maps to the Id of the Promotion of this OrderEntryPromotion


OrderEntryTax Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of tax applied to the OrderEntry
Id
int
Unique Id of this OrderEntryTax within the OrderEntry
IsInclusive
bool
True if this OrderEntryTax is an inclusive tax, False if not
TaxId
int
Maps to the Id of the Tax of this OrderEntryTax


OrderItemVoid Type
Data Name
Data Type
Data Description
ApproverEmployeeId
int
Maps to the Id of the Employee who approved this OrderItem
EmployeeId
int
Maps to the Id of the Employee who applied this OrderItem
Time
DateTimeOffset
Time at which this OrderItemVoid was processed in UTC
VoidReasonId
int
Specify the Id of the reason


OrderPayment Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of this OrderPayment
BusinessDate
DateTime
Business date this OrderPayment was applied (the time component will always return as 00:00:00)
Id
int
Unique Id of this OrderPayment within the Order
TenderId
int
Maps to the Id of the Tender of this OrderPayment


CreditCardTransactionInformation Type
Data Name
Data Type
Data Description
AuthorizationCode
string
Authorization code returned from Vantiv
CardToken
string
Card token returned from Vantiv
ClientTransactionIdentifier
string
Client transaction identifier returned from Vantiv
Result
string
Result returned from Vantiv


OrderPaymentDetail Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of this OrderPaymentDetail
EmployeeId
int?
Maps to the Id of the Employee who processed this OrderPaymentDetail
Id
int
Unique Id of this OrderPaymentDetail within the Order
TillNumber
int?
Maps to the Number of the Till that this OrderPaymentDetail was originally taken on
TipAmount
decimal
Tip amount for this OrderPaymentDetail
Type
int
Returns one of the following for the type of detail:
  • 1 = Initial Payment
  • 2 = Adjustment
  • 3 = Change given
  • 4 = Transfer from
  • 5 = Transfer to


OrderPromotion Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of promotion applied to the Order
ApproverEmployeeId
int?
Maps to the Id of the Employee who approved this OrderPromotion
EmployeeId
int?
Maps to the Id of the Employee who applied this OrderPromotion
Id
int
Unique Id of this OrderPromotion within the Order
Name
string
Name of this OrderPromotion
PromotionId
int
Maps to the Id of the Promotion of this OrderPromotion


OrderSurcharge Type
Data Name
Data Type
Data Description
Amount
decimal
Amount of surcharge applied to the Order
ApproverEmployeeId
int?
Maps to the Id of the Employee who approved this OrderSurcharge
EmployeeId
int?
Maps to the Id of the Employee who applied this OrderSurcharge
Id
int
Unique Id of this OrderSurcharge within the Order
IsSystemApplied
bool
True if this OrderSurcharge is automatically applied by the system, False if not
Name
string
Name of this OrderSurcharge
SurchargeId
int
Maps to the Id of the Surcharge of this OrderSurcharge
Taxes
Array of OrderEntryTax
Taxes on this OrderSurcharges
This call is to retrieve Tills on the business date requested.

GetTills Request
Data Name
Data Type
Data Description
BusinessDate
DateTime
Specify the Business Date that you would like to get Tills for


GetTills Response
Data Name
Data Type
Data Description
Message
string
Returns a Brink error message if the request did not go through successfully. Otherwise, this field will be null.
ResultCode
int
Returns one of the following:
  • 0 = Request went through successfully
  • 1 = Request returned an unknown error
  • 2 = Request was not valid
  • 3 = Server is currently unavailable and unable to receive the request
  • 4 = Access Denied
Tills
Array of Till
Tills for this location on the business date requested


Till Type
Data Name
Data Type
Data Description
BusinessDate
DateTime
Business date of this Till (This DateTime object's time component will be equal to 00:00:00)
DeclaredCash
decimal?
Amount of cash declared for this Till, for tills that have been closed
EmployeeId
int?
Maps to the Id of the Employee who owns this Till, for non-public tills, otherwise null
Number
int
Unique identifier for this Till


PaidInOut Type
Data Name
Data Type
Data Description
AccountType
int
Returns one of the following:
  • 0 = Cash In
  • 1 = Cash Out
Amount
decimal
Amount that was paid for this PaidInOut
Description
string
Description for this PaidInOut
EmployeeId
int
Maps to the Id of the Employee who processed this PaidInOut
Number
int
Unique identifier for this PaidInOut
PettyAccountId
int
Maps to the Id of the Account affected by this PaidInOut
Time
DateTimeOffset
Time at which this PaidInOut was processed in UTC


Skim Type
Data Name
Data Type
Data Description
CashDrawerName
string
Name of the CashDrawer from which Skim is performed
Duration
TimeSpan
Time from first prompt until Skim performed
SkimAmount
decimal
Amount that was processed in this Skim
SkimTime
DateTimeOffset
Time at which this Skim was processed in UTC
UserName
string
Name of the Employee who processed this Skim
                
                    
                    
GetCurrentBusinessDate Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetCurrentBusinessDate.Sales2ServiceReference; namespace Sales2_GetCurrentBusinessDate { class Program { static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; //Make GetCurrentBusinessDate call var response = client.GetCurrentBusinessDate(); //If call is successful if (response.ResultCode == 0) { Console.WriteLine("Current Business Date: " + response.BusinessDate); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetCurrentBusinessDate Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetCurrentBusinessDate { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = "AccessToken"; httpRequestProperty.Headers["LocationToken"] = "LocationToken"; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; var response = client.GetCurrentBusinessDateAsync(); Console.WriteLine("GetCurrentBusinessDate"); Console.WriteLine("----------------------"); //If call is successful if (response.Result.ResultCode == 0) { Console.WriteLine("Current Business Date: " + response.Result.BusinessDate); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetCurrentBusinessDate operation: " + ex.Message); } } } }
GetCurrentBusinessDate Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2"> <soapenv:Header/> <soapenv:Body> <v2:GetCurrentBusinessDate/> </soapenv:Body> </soapenv:Envelope>
GetCurrentBusinessDate Sample Code
from zeep import Client from zeep.transports import Transport import requests accessToken = 'AccessToken' locationToken = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken':accessToken,'LocationToken':locationToken}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/Sales2.svc' ) try: #Make GetCurrentBusinessDate call res = service.GetCurrentBusinessDate() #If call is successful if (res.ResultCode == 0): print("Current Business Date: {}".format(res.BusinessDate)) else: print("Error Code: " + res.ResultCode) print("Message: " + res.Message) except Exception as e: print(e)

                
                    
                    
GetDeposits Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetDeposits.Sales2ServiceReference; namespace Sales2_GetDeposits { class Program { static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; int count = 1; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; //Include BusinessDate parameter in request body var request = new GetDepositsRequest() { BusinessDate = new DateTime(2001, 01, 01), }; //Make GetDeposits call var response = client.GetDeposits(request); //If call is successful if (response.ResultCode == 0) { //Loop through collection of Deposit objects returned foreach (var deposit in response.Deposits) { Console.WriteLine("Deposit #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("Id: " + deposit.Id); Console.WriteLine("Amount: "+ deposit.Amount); Console.WriteLine("Bag: " + deposit.Bag); Console.WriteLine("BusinessDate: " + deposit.BusinessDate); Console.WriteLine("DepositTypeId: " + deposit.DepositTypeId); Console.WriteLine("Notes: " + deposit.Notes); Console.WriteLine("Number: " + deposit.Number); Console.WriteLine("Time: "); Console.WriteLine("\tDateTime: " + deposit.Time.DateTime); Console.WriteLine("\tOffsetMinutes: " + deposit.Time.Offset); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetDeposits Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetDeposits { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = 'AccessToken'; httpRequestProperty.Headers["LocationToken"] = 'LocationToken'; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; var request = new GetDepositsRequest() { BusinessDate = new DateTime(2022, 06, 09), }; //Make GetDeposits call var response = client.GetDepositsAsync(request); Console.WriteLine("GetDeposits"); Console.WriteLine("-----------"); //If call is successful if (response.Result.ResultCode == 0) { Console.WriteLine(response.Result.ResultCode); //Loop through collection of Deposit objects returned foreach (var deposit in response.Result.Deposits) { Console.WriteLine("Deposit #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("Id: " + deposit.Id); Console.WriteLine("Amount: " + deposit.Amount); Console.WriteLine("Bag: " + deposit.Bag); Console.WriteLine("BusinessDate: " + deposit.BusinessDate); Console.WriteLine("DepositTypeId: " + deposit.DepositTypeId); Console.WriteLine("Notes: " + deposit.Notes); Console.WriteLine("Number: " + deposit.Number); Console.WriteLine("Time: "); Console.WriteLine("\tDateTime: " + deposit.Time.DateTime); Console.WriteLine("\tOffsetMinutes: " + deposit.Time.Offset); Console.WriteLine("---------------------------"); count++; } Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetDeposits operation: " + ex.Message); } } } }
GetDeposits Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2"> <soapenv:Header/> <soapenv:Body> <v2:GetDeposits> <v2:request> <v2:BusinessDate>2001-01-01</v2:BusinessDate> </v2:request> </v2:GetDeposits> </soapenv:Body> </soapenv:Envelope>
GetDeposits Sample Code
from zeep import Client from zeep.transports import Transport import requests from datetime import datetime access_token = 'AccessToken' location_token = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken': access_token, 'LocationToken': location_token}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/Sales2.svc' ) #Prepare the dynamic type for GetDepositsRequest req_type = client.get_type('ns1:GetDepositsRequest') businessdate = datetime(2001, 1, 1) #Include BusinessDate parameter in request body req_data = req_type(BusinessDate=businessdate) count = 1 try: #Make GetDeposits call res = service.GetDeposits(req_data) #If call is successful if(res.ResultCode == 0): #Loop through collection of Deposits objects returned for deposit in res.Deposits.Deposit: print('Deposit #' + str(count)) print('---------------------------') print('Id: ' + str(deposit.Id)) print('Amount: ' + str(deposit.Amount)) print('Bag: ' + str(deposit.Bag)) print('BusinessDate: ' + str(deposit.BusinessDate)) print('DepositTypeId: ' + str(deposit.DepositTypeId)) print('Notes: ' + str(deposit.Notes)) print('Number: ' + str(deposit.Number)) print('Time: ') print('\tDateTime: ' + str(deposit.Time.DateTime)) print('\tOffsetMinutes: ' + str(deposit.Time.OffsetMinutes)) print('---------------------------') count += 1 print('End') else: print('Error Code: ' + str(res.ResultCode)) print('Message: ' + res.Message) except Exception as e: print(e)

                
                    
                    
GetFutureDateOrderDeposits Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetFutureDateOrderDeposits.Sales2ServiceReference; namespace Sales2_GetFutureDateOrderDeposits { class Program { static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; int count = 1; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; //Include BusinessDate parameter in request body var request = new GetFutureDateOrderDepositsRequest() { BusinessDate = new DateTime(2001, 01, 01), }; //Make GetFutureDateOrderDeposits call var response = client.GetFutureDateOrderDeposits(request); //If call is successful if (response.ResultCode == 0) { //Loop through collection of FutureDateOrderDeposit objects returned foreach (var deposit in response.Deposits) { Console.WriteLine("FutureDateOrderDeposit #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("Amount: " + deposit.Amount); Console.WriteLine("AuthCode: " + deposit.AuthCode); Console.WriteLine("Business Date: " + deposit.BusinessDate); Console.WriteLine("CardHolderName: " + deposit.CardHolderName); Console.WriteLine("CardNumber: " + deposit.CardNumber); Console.WriteLine("EmployeeId: " + deposit.EmployeeId); Console.WriteLine("MerchantAccountType: " + deposit.MerchantAccountType); Console.WriteLine("OrderId: " + deposit.OrderId); Console.WriteLine("OrderTotal: " + deposit.OrderTotal); Console.WriteLine("PaymentId: " + deposit.PaymentId); Console.WriteLine("SectionId: " + deposit.SectionId); Console.WriteLine("TenderId: " + deposit.TenderId); Console.WriteLine("TillNumber: " + deposit.TillNumber); Console.WriteLine("Time: "); Console.WriteLine("\tDateTime: " + deposit.Time.DateTime); Console.WriteLine("\tOffset:" + deposit.Time.Offset); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetFutureDateOrderDeposits Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetFutureDateOrderDeposits { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = 'AccessToken'; httpRequestProperty.Headers["LocationToken"] = 'LocationToken'; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; var request = new GetFutureDateOrderDepositsRequest() { BusinessDate = new DateTime(2022, 06, 09), }; //Make GetFutureDateOrderDeposits call var response = client.GetFutureDateOrderDepositsAsync(request); Console.WriteLine("GetFutureDateOrderDeposits"); Console.WriteLine("---------------------"); //If call is successful if (response.Result.ResultCode == 0) { Console.WriteLine(response.Result.ResultCode); //Loop through collection of FutureDateOrderDeposit objects returned foreach (var deposit in response.Result.Deposits) { Console.WriteLine("FutureDateOrderDeposit #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("Amount: " + deposit.Amount); Console.WriteLine("AuthCode: " + deposit.AuthCode); Console.WriteLine("Business Date: " + deposit.BusinessDate); Console.WriteLine("CardHolderName: " + deposit.CardHolderName); Console.WriteLine("CardNumber: " + deposit.CardNumber); Console.WriteLine("EmployeeId: " + deposit.EmployeeId); Console.WriteLine("MerchantAccountType: " + deposit.MerchantAccountType); Console.WriteLine("OrderId: " + deposit.OrderId); Console.WriteLine("OrderTotal: " + deposit.OrderTotal); Console.WriteLine("PaymentId: " + deposit.PaymentId); Console.WriteLine("SectionId: " + deposit.SectionId); Console.WriteLine("TenderId: " + deposit.TenderId); Console.WriteLine("TillNumber: " + deposit.TillNumber); Console.WriteLine("Time: "); Console.WriteLine("\tDateTime: " + deposit.Time.DateTime); Console.WriteLine("\tOffset:" + deposit.Time.Offset); Console.WriteLine("---------------------------"); count++; } Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetFutureDateOrderDeposits operation: " + ex.Message); } } } }
GetFutureDateOrderDeposits Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2"> <soapenv:Header/> <soapenv:Body> <v2:GetFutureDateOrderDeposits> <v2:request> <v2:BusinessDate>2001-01-01</v2:BusinessDate> </v2:request> </v2:GetFutureDateOrderDeposits> </soapenv:Body> </soapenv:Envelope>
GetFutureDateOrderDeposits Sample Code
from zeep import Client from zeep.transports import Transport import requests from datetime import datetime access_token = 'AccessToken' location_token = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken': access_token, 'LocationToken': location_token}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/Sales2.svc' ) #Prepare the dynamic type for GetFutureDateOrderDepositsRequest req_type = client.get_type('ns1:GetFutureDateOrderDepositsRequest') businessdate = datetime(2001, 1, 1) #Include BusinessDate parameter in request body req_data = req_type(BusinessDate=businessdate) count = 1 try: #Make GetFutureDateOrderDeposits call res = service.GetFutureDateOrderDeposits(req_data) #If call is successful if(res.ResultCode == 0): #Loop through collection of FutureDateOrderDeposit objects returned for deposit in res.Deposits.FutureDateOrderDeposit: print('FutureDateOrderDeposit #' + str(count)) print('---------------------------') print('Amount: ' + str(deposit.Amount)) print('AuthCode: ' + str(deposit.AuthCode)) print('Business Date: ' + str(deposit.BusinessDate)) print('CardHolderName: ' + str(deposit.CardHolderName)) print('CardNumber: ' + str(deposit.CardNumber)) print('EmployeeId: ' + str(deposit.EmployeeId)) print('MerchantAccountType: ' + str(deposit.MerchantAccountType)) print('OrderId: ' + str(deposit.OrderId)) print('OrderTotal: ' + str(deposit.OrderTotal)) print('PaymentId: ' + str(deposit.PaymentId)) print('SectionId: ' + str(deposit.SectionId)) print('TenderId: ' + str(deposit.TenderId)) print('TillNumber: ' + str(deposit.TillNumber)) print('Time: ') print('\tDateTime: ' + str(deposit.Time.DateTime)) print('\tOffsetMinutes: ' + str(deposit.Time.OffsetMinutes)) print('---------------------------') count += 1 print('End') else: print('Error Code: ' + str(res.ResultCode)) print('Message: ' + res.Message) except Exception as e: print(e)

                
                    
                    
GetFutureDateOrders Minified Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetFutureDateOrders.Sales2ServiceReference; namespace Sales2_GetFutureDateOrders { class Program { public static void DisplayModifiers(OrderItemModifier[] modifiers) { //Loop through collection of OrderItemModifier objects returned foreach (var mod in modifiers) { Console.WriteLine("\t\tId: " + mod.Id); Console.WriteLine("\t\tItemId: " + mod.ItemId); Console.WriteLine("\t\tModifierCodeId: " + mod.ModifierCodeId); Console.WriteLine("\t\tModifierGroupId: " + mod.ModifierGroupId); Console.WriteLine("\t\tPrice: " + mod.Price); //Loop through collection of OrderItemModifier objects returned if (mod.Modifiers.Length != 0) { DisplayModifiers(mod.Modifiers); } Console.WriteLine("\t\t------------"); } } static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; int count = 1; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; var dateRange = new DateRange(); dateRange.Start = new DateTime(2001, 01, 01); dateRange.End = new DateTime(2001, 01, 08); //Include FutureDateRange and PriceRollUp parameters in request body var request = new GetFutureDateOrdersRequest() { FutureDateRange = dateRange, PriceRollUp = "RollUpAndDetails", }; //Make GetFutureDateOrders call var response = client.GetFutureDateOrders(request); //If call is successful if (response.ResultCode == 0) { //Loop through collection of Order objects returned foreach (var futureDateOrder in response.FutureDateOrders) { Console.WriteLine("Order #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + futureDateOrder.BusinessDate); Console.WriteLine("ClosedTime: " + futureDateOrder.ClosedTime); Console.WriteLine("CustomerId: " + futureDateOrder.CustomerId); Console.WriteLine("EmployeeId: " + futureDateOrder.EmployeeId); Console.WriteLine("Entries:"); //Loop through collection of OrderItem objects returned foreach (var entry in futureDateOrder.Entries.OfType<OrderItem>()) { Console.WriteLine("\tModifiers: "); if (entry.Modifiers.Length != 0) { DisplayModifiers(entry.Modifiers); } } Console.WriteLine("FirstSendTime: " + futureDateOrder.FirstSendTime); Console.WriteLine("Id: " + futureDateOrder.Id); Console.WriteLine("IsClosed: " + futureDateOrder.IsClosed); Console.WriteLine("ModifiedTime: " + futureDateOrder.ModifiedTime); Console.WriteLine("Name: " + futureDateOrder.Name); Console.WriteLine("OpenedTime: " + futureDateOrder.OpenedTime); Console.WriteLine("Payments:"); //Loop through collection of OrderPayment objects returned if (futureDateOrder.Payments.Length != 0) { foreach (var payment in futureDateOrder.Payments) { Console.WriteLine("\tId: " + payment.Id); Console.WriteLine("\tAmount: " + payment.Amount); Console.WriteLine("\tBusinessDate: " + payment.BusinessDate); Console.WriteLine("\t-----------------------"); } } Console.WriteLine("PickUpTime: " + futureDateOrder.PickupTime); Console.WriteLine("Total: " + futureDateOrder.Total); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetFutureDateOrders Minified Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetFutureDateOrders { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } public static void DisplayModifiers(OrderItemModifier[] modifiers) { //Loop through collection of OrderItemModifier objects returned foreach (var mod in modifiers) { Console.WriteLine("\t\tId: " + mod.Id); Console.WriteLine("\t\tItemId: " + mod.ItemId); Console.WriteLine("\t\tModifierCodeId: " + mod.ModifierCodeId); Console.WriteLine("\t\tModifierGroupId: " + mod.ModifierGroupId); Console.WriteLine("\t\tPrice: " + mod.Price); //Loop through collection of OrderItemModifier objects returned if (mod.Modifiers.Length != 0) { DisplayModifiers(mod.Modifiers); } Console.WriteLine("\t\t------------"); } } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = 'AccessToken'; httpRequestProperty.Headers["LocationToken"] = 'LocationToken'; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; var dateRange = new DateRange(); dateRange._start = new DateTime(2001, 01, 01); dateRange._end = new DateTime(2001, 01, 08); //Include FutureDateRange and PriceRollUp parameters in request body var request = new GetFutureDateOrdersRequest() { FutureDateRange = dateRange, PriceRollUp = "RollUpAndDetails", }; //Make GetFutureDateOrders call var response = client.GetFutureDateOrdersAsync(request); Console.WriteLine("GetFutureDateOrders"); Console.WriteLine("--------------------"); //If call is successful if (response.Result.ResultCode == 0) { //Loop through collection of Order objects returned foreach (var futureDateOrder in response.Result.FutureDateOrders) { Console.WriteLine("Order #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + futureDateOrder.BusinessDate); Console.WriteLine("ClosedTime: " + futureDateOrder.ClosedTime); Console.WriteLine("CustomerId: " + futureDateOrder.CustomerId); Console.WriteLine("EmployeeId: " + futureDateOrder.EmployeeId); Console.WriteLine("Entries:"); //Loop through collection of OrderItem objects returned foreach (var entry in futureDateOrder.Entries.OfType<OrderItem>()) { Console.WriteLine("\tModifiers: "); if (entry.Modifiers.Length != 0) { DisplayModifiers(entry.Modifiers); } } Console.WriteLine("FirstSendTime: " + futureDateOrder.FirstSendTime); Console.WriteLine("Id: " + futureDateOrder.Id); Console.WriteLine("IsClosed: " + futureDateOrder.IsClosed); Console.WriteLine("ModifiedTime: " + futureDateOrder.ModifiedTime); Console.WriteLine("Name: " + futureDateOrder.Name); Console.WriteLine("OpenedTime: " + futureDateOrder.OpenedTime); Console.WriteLine("Payments:"); //Loop through collection of OrderPayment objects returned if (futureDateOrder.Payments.Length != 0) { foreach (var payment in futureDateOrder.Payments) { Console.WriteLine("\tId: " + payment.Id); Console.WriteLine("\tAmount: " + payment.Amount); Console.WriteLine("\tBusinessDate: " + payment.BusinessDate); Console.WriteLine("\t-----------------------"); } } Console.WriteLine("PickUpTime: " + futureDateOrder.PickupTime); Console.WriteLine("Total: " + futureDateOrder.Total); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetFutureDateOrders operation: " + ex.Message); } } } }
GetFutureDateOrders Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2" xmlns:brin="http://schemas.datacontract.org/2004/07/Brink.Foundation"> <soapenv:Header/> <soapenv:Body> <v2:GetFutureDateOrders> <v2:request> <v2:FutureDateRange> <brin:End>2001-01-08</brin:End> <brin:Start>2001-01-01</brin:Start> </v2:FutureDateRange> <v2:PriceRollUp>RollUpAndDetails</v2:PriceRollUp> </v2:request> </v2:GetFutureDateOrders> </soapenv:Body> </soapenv:Envelope>
GetFutureDateOrders Minified Sample Code
from zeep import Client from zeep.transports import Transport import requests from datetime import datetime def display_modifiers(modifiers, depth = 1): print('\t' * (depth) + 'Modifiers:') #Loop through collection of OrderItemModifier objects returned for mod in modifiers.OrderItemModifier: print('\t' * (depth + 1) + 'Id: ' + str(mod.Id)) print('\t' * (depth + 1) + 'ItemId: ' + str(mod.ItemId)) print('\t' * (depth + 1) + 'ModifierCodeId: ' + str(mod.ModifierCodeId)) print('\t' * (depth + 1) + 'ModifierGroupId: ' + str(mod.ModifierGroupId)) print('\t' * (depth + 1) + 'Price: ' + str(mod.Price)) if (mod.Modifiers != None): display_modifiers(mod.Modifiers, (depth + 2)) else: print('\t' * (depth + 1) + 'Modifiers: None') access_token = 'AccessToken' location_token = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken': access_token, 'LocationToken': location_token}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/Sales2.svc' ) #Prepare the dynamic types for GetFutureDateOrdersRequest req_type = client.get_type('ns1:GetFutureDateOrdersRequest') date_range_type = client.get_type('ns5:DateRange') #Include FutureDateRange and PriceRollUp parameters in request body start_date = datetime(2001, 1, 1) end_date = datetime(2001, 1, 8) date_range = date_range_type(Start=start_date, End=end_date) req_data = req_type(FutureDateRange=date_range, PriceRollUp='RollupandDetails') count = 1 try: #Make GetFutureDateOrders call res = service.GetFutureDateOrders(req_data) #If call is successful if(res.ResultCode == 0): #Loop through collection of Order objects returned for order in res.FutureDateOrders.Order: print('Order #' + str(count)) print('---------------------------') print('BusinessDate: ' + str(order.BusinessDate)) print('ClosedTime: ') print('\tDateTime: ' + str(order.ClosedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.ClosedTime.OffsetMinutes)) print('CustomerId: ' + str(order.CustomerId)) print('EmployeeId: ' + str(order.EmployeeId)) if(order.Entries != None): print('Entries:') for entry in order.Entries.OrderEntry: if(entry.Modifiers != None): display_modifiers(entry.Modifiers) else: print('\tModifiers: None') else: print('Entries: None') print('FirstSendTime:') print('\tDateTime: ' + str(order.FirstSendTime.DateTime)) print('\tOffsetMinutes: ' + str(order.FirstSendTime.OffsetMinutes)) print('Id: ' + str(order.Id)) print('IsClosed: ' + str(order.IsClosed)) print('ModifiedTime: ') print('\tDateTime: ' + str(order.ModifiedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.ModifiedTime.OffsetMinutes)) print('Name: ' + str(order.Name)) print('OpenedTime:') print('\tDateTime: ' + str(order.OpenedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.OpenedTime.OffsetMinutes)) if(order.Payments != None): print('Payments:') #Loop through collection of OrderPayment objects returned for payment in order.Payments.OrderPayment: print('\tId: ' + str(payment.Id)) print('\tAmount: ' + str(payment.Amount)) print('\tBusinessDate: ' + str(payment.BusinessDate)) print('\t-----------------------') else: print('Payments: None') print('PickupTime: ' + str(order.PickupTime)) print('Total: ' + str(order.Total)) print('---------------------------') count += 1 print('End') else: print('Error Code: ' + str(res.ResultCode)) print('Message: ' + res.Message) except Exception as e: print(e)

                
                    
                    
GetOrders Minified Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetOrders.Sales2ServiceReference; namespace Sales2_GetOrders { class Program { public static void DisplayModifiers(OrderItemModifier[] modifiers) { //Loop through collection of OrderItemModifier objects returned foreach (var mod in modifiers) { Console.WriteLine("\t\tId: " + mod.Id); Console.WriteLine("\t\tItemId: " + mod.ItemId); Console.WriteLine("\t\tModifierCodeId: " + mod.ModifierCodeId); Console.WriteLine("\t\tModifierGroupId: " + mod.ModifierGroupId); Console.WriteLine("\t\tPrice: " + mod.Price); //Loop through collection of OrderItemModifier objects returned if (mod.Modifiers.Length != 0) { DisplayModifiers(mod.Modifiers); } Console.WriteLine("\t\t------------"); } } static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; int count = 1; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; DateTime businessDate = new DateTime(2001, 01, 01); DateTimeOffset modifiedTime = new DateTimeOffset(2001, 01, 01, 12, 0, 0, new TimeSpan(0)); //Include parameters in request body var request = new GetOrdersRequest() { BusinessDate = businessDate, ExcludeOpenOrders = false, //ModifiedTime = modifiedTime, PriceRollUp = "RollUpAndDetails", }; //Make GetOrders call var response = client.GetOrders(request); //If call is successful if (response.ResultCode == 0) { //Loop through collection of Order objects returned foreach (var order in response.Orders) { Console.WriteLine("Order #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + order.BusinessDate); Console.WriteLine("ClosedTime: " + order.ClosedTime); Console.WriteLine("CustomerId: " + order.CustomerId); Console.WriteLine("EmployeeId: " + order.EmployeeId); Console.WriteLine("Entries:"); //Loop through collection of OrderItem objects returned foreach (var entry in order.Entries.OfType<OrderItem>()) { Console.WriteLine("\tModifiers: "); if (entry.Modifiers.Length != 0) { DisplayModifiers(entry.Modifiers); } } Console.WriteLine("FirstSendTime: " + order.FirstSendTime); Console.WriteLine("Id: " + order.Id); Console.WriteLine("IsClosed: " + order.IsClosed); Console.WriteLine("ModifiedTime: " + order.ModifiedTime); Console.WriteLine("Name: " + order.Name); Console.WriteLine("OpenedTime: " + order.OpenedTime); Console.WriteLine("Payments:"); //Loop through collection of OrderPayment objects returned if (order.Payments.Length != 0) { foreach (var payment in order.Payments) { Console.WriteLine("\tId: " + payment.Id); Console.WriteLine("\tAmount: " + payment.Amount); Console.WriteLine("\tBusinessDate: " + payment.BusinessDate); Console.WriteLine("\t-----------------------"); } } Console.WriteLine("PickUpTime: " + order.PickupTime); Console.WriteLine("Total: " + order.Total); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetOrders Minified Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetOrders { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } public static void DisplayModifiers(OrderItemModifier[] modifiers) { //Loop through collection of OrderItemModifier objects returned foreach (var mod in modifiers) { Console.WriteLine("\t\tId: " + mod.Id); Console.WriteLine("\t\tItemId: " + mod.ItemId); Console.WriteLine("\t\tModifierCodeId: " + mod.ModifierCodeId); Console.WriteLine("\t\tModifierGroupId: " + mod.ModifierGroupId); Console.WriteLine("\t\tPrice: " + mod.Price); //Loop through collection of OrderItemModifier objects returned if (mod.Modifiers.Length != 0) { DisplayModifiers(mod.Modifiers); } Console.WriteLine("\t\t------------"); } } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = 'AccessToken'; httpRequestProperty.Headers["LocationToken"] = 'LocationToken'; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; DateTime businessDate = new DateTime(2022, 06, 09); DateTimeOffset modifiedTime = new DateTimeOffset(2022, 06, 09, 12, 0, 0, new TimeSpan(0)); //Include parameters in request body var request = new GetOrdersRequest() { BusinessDate = businessDate, ExcludeOpenOrders = false, //ModifiedTime = modifiedTime, PriceRollUp = "RollUpAndDetails", }; //Make GetOrders call var response = client.GetOrdersAsync(request); Console.WriteLine("GetOrders"); Console.WriteLine("------------"); //If call is successful if (response.Result.ResultCode == 0) { Console.WriteLine(response.Result.ResultCode); //Loop through collection of Order objects returned foreach (var order in response.Result.Orders) { Console.WriteLine("Order #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + order.BusinessDate); Console.WriteLine("ClosedTime: " + order.ClosedTime); Console.WriteLine("CustomerId: " + order.CustomerId); Console.WriteLine("EmployeeId: " + order.EmployeeId); Console.WriteLine("Entries:"); //Loop through collection of OrderItem objects returned foreach (var entry in order.Entries.OfType<OrderItem>()) { Console.WriteLine("\tModifiers: "); if (entry.Modifiers.Length != 0) { DisplayModifiers(entry.Modifiers); } } Console.WriteLine("FirstSendTime: " + order.FirstSendTime); Console.WriteLine("Id: " + order.Id); Console.WriteLine("IsClosed: " + order.IsClosed); Console.WriteLine("ModifiedTime: " + order.ModifiedTime); Console.WriteLine("Name: " + order.Name); Console.WriteLine("OpenedTime: " + order.OpenedTime); Console.WriteLine("Payments:"); //Loop through collection of OrderPayment objects returned if (order.Payments.Length != 0) { foreach (var payment in order.Payments) { Console.WriteLine("\tId: " + payment.Id); Console.WriteLine("\tAmount: " + payment.Amount); Console.WriteLine("\tBusinessDate: " + payment.BusinessDate); Console.WriteLine("\t-----------------------"); } } Console.WriteLine("PickUpTime: " + order.PickupTime); Console.WriteLine("Total: " + order.Total); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetOrders operation: " + ex.Message); } } } }
GetOrders Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2" xmlns:sys="http://schemas.datacontract.org/2004/07/System"> <soapenv:Header/> <soapenv:Body> <v2:GetOrders> <v2:request> <v2:BusinessDate>2001-01-01</v2:BusinessDate> <v2:ExcludeOpenOrders>false</v2:ExcludeOpenOrders> <!--<v2:ModifiedTime> <sys:DateTime>?</sys:DateTime> <sys:OffsetMinutes>?</sys:OffsetMinutes> </v2:ModifiedTime>--> <v2:PriceRollUp>RollUpAndDetails</v2:PriceRollUp> </v2:request> </v2:GetOrders> </soapenv:Body> </soapenv:Envelope>
GetOrders Minified Sample Code
from zeep import Client from zeep.transports import Transport import requests from datetime import datetime def display_modifiers(modifiers, depth = 1): print('\t' * (depth) + 'Modifiers:') #Loop through collection of OrderItemModifier objects returned for mod in modifiers.OrderItemModifier: print('\t' * (depth + 1) + 'Id: ' + str(mod.Id)) print('\t' * (depth + 1) + 'ItemId: ' + str(mod.ItemId)) print('\t' * (depth + 1) + 'ModifierCodeId: ' + str(mod.ModifierCodeId)) print('\t' * (depth + 1) + 'ModifierGroupId: ' + str(mod.ModifierGroupId)) print('\t' * (depth + 1) + 'Price: ' + str(mod.Price)) if (mod.Modifiers != None): display_modifiers(mod.Modifiers, (depth + 2)) else: print('\t' * (depth + 1) + 'Modifiers: None') accessToken = 'AccessToken' locationToken = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken': accessToken, 'LocationToken': locationToken}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/sales2.svc' ) #Prepare the dynamic type for GetOrdersRequest req_type = client.get_type('ns1:GetOrdersRequest') datetime_offset_type = client.get_type('ns3:DateTimeOffset') #Include parameters in request body businessdate = datetime(2001, 01, 01) modified_date = datetime_offset_type(DateTime=businessdate, OffsetMinutes=0) req_data = req_type(BusinessDate=businessdate,ExcludeOpenOrders=False,PriceRollUp='RollupandDetails', ModifiedTime=modified_date) count = 1 try: #Make GetOrders call res = service.GetOrders(req_data) # If call is successful if(res.ResultCode == 0): #Loop through collection of Order objects returned for order in res.Orders.Order: print('Order #' + str(count)) print('---------------------------') print('BusinessDate: ' + str(order.BusinessDate)) print('ClosedTime: ') print('\tDateTime: ' + str(order.ClosedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.ClosedTime.OffsetMinutes)) print('CustomerId: ' + str(order.CustomerId)) print('EmployeeId: ' + str(order.EmployeeId)) if(order.Entries != None): print('Entries:') #Loop through collection of OrderItem objects returned for entry in order.Entries.OrderEntry: if(entry.Modifiers != None): display_modifiers(entry.Modifiers) else: print('\tModifiers: None') else: print('Entries: None') print('FirstSendTime:') print('\tDateTime: ' + str(order.FirstSendTime.DateTime)) print('\tOffsetMinutes: ' + str(order.FirstSendTime.OffsetMinutes)) print('Id: ' + str(order.Id)) print('IsClosed: ' + str(order.IsClosed)) print('ModifiedTime: ') print('\tDateTime: ' + str(order.ModifiedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.ModifiedTime.OffsetMinutes)) print('Name: ' + str(order.Name)) print('OpenedTime:') print('\tDateTime: ' + str(order.OpenedTime.DateTime)) print('\tOffsetMinutes: ' + str(order.OpenedTime.OffsetMinutes)) if(order.Payments != None): print('Payments:') #Loop through collection of OrderPayment objects returned for payment in order.Payments.OrderPayment: print('\tId: ' + str(payment.Id)) print('\tAmount: ' + str(payment.Amount)) print('\tBusinessDate: ' + str(payment.BusinessDate)) print('\t-----------------------') else: print('Payments: None') print('PickupTime: ' + str(order.PickupTime)) print('Total: ' + str(order.Total)) print('---------------------------') count += 1 print('End') else: print('Error Code: ' + str(res.ResultCode)) print('Message: ' + res.Message) except Exception as e: print(e)

                
                    
                    
GetTills Sample Code
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.ServiceModel; using System.ServiceModel.Web; using Sales2_GetTills.Sales2ServiceReference; namespace Sales2_GetTills { class Program { static void Main(string[] args) { //Connect to Sales2 service client var client = new SalesWebService2Client(); //Set security protocol to TLS 1.2 System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12; int count = 1; using (var scope = new OperationContextScope(client.InnerChannel)) { //Include tokens in HTTP Web Request Headers var headers = WebOperationContext.Current.OutgoingRequest.Headers; headers["AccessToken"] = @"AccessToken"; headers["LocationToken"] = @"LocationToken"; //Include BusinessDate parameter in request body var request = new GetTillsRequest() { BusinessDate = new DateTime(2001, 01, 01), }; //Make GetTills call var response = client.GetTills(request); //If call is successful if (response.ResultCode == 0) { //Loop through collection of Till objects returned foreach (var till in response.Tills) { Console.WriteLine("Till #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + till.BusinessDate); Console.WriteLine("CashDrawerId: " + till.CashDrawerId); Console.WriteLine("ClosedByEmployeeId: " + till.ClosedByEmployeeId); Console.WriteLine("ClosedTime: " + till.ClosedTime); Console.WriteLine("DeclaredCash " + till.DeclaredCash); Console.WriteLine("EmployeeId: " + till.EmployeeId); Console.WriteLine("IsClosed: " + till.IsClosed); Console.WriteLine("IsPublic: " + till.IsPublic); Console.WriteLine("IsVirtual: " + till.IsVirtual); Console.WriteLine("Number: " + till.Number); Console.WriteLine("OpenedTime: " + till.OpenedTime); Console.WriteLine("OverShort: " + till.OverShort); Console.WriteLine("PaidInOuts: "); //Loop through collection of PaidInOut objects returned foreach (var paidInOut in till.PaidInOuts) { Console.WriteLine("\tEmployeeId: " + paidInOut.EmployeeId); Console.WriteLine("\tAccountType: " + paidInOut.AccountType); Console.WriteLine("\tAmount:" + paidInOut.Amount); Console.WriteLine("\tDescription: " + paidInOut.Description); Console.WriteLine("\tNumber: " + paidInOut.Number); Console.WriteLine("\tPettyAccountId: " + paidInOut.PettyAccountId); Console.WriteLine("\tTime: " + paidInOut.Time.DateTime); Console.WriteLine("\t-----------------------"); } //Loop through collection of Skim objects returned foreach (var skim in till.Skims) { Console.WriteLine("\tCashDrawerName: " + skim.CashDrawerName); Console.WriteLine("\tDuration: " + skim.Duration); Console.WriteLine("\tSkimAmount:" + skim.SkimAmount); Console.WriteLine("\tSkimTime: " + skim.SkimTime.DateTime); Console.WriteLine("\UserName: " + skim.UserName); Console.WriteLine("\t-----------------------"); } Console.WriteLine("StartingBank: " + till.StartingBank); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.ResultCode); Console.WriteLine("Message: " + response.Message); Console.ReadKey(); } } } } }
GetTills Sample Code
using Microsoft.Extensions.DependencyInjection; using ServiceReference9; using System.ServiceModel.Channels; namespace Sales2_GetTills { class Program { public static ServiceCollection services = new ServiceCollection(); public static void AddSalesServiceClient() { services.AddTransient<ISalesWebService2>((provider) => { BasicHttpBinding binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 2147483647; EndpointAddress endpointAddress = new EndpointAddress("{YOUR_WSDL_URL_GOES_HERE}"); ChannelFactory<ISalesWebService2> factory = new ChannelFactory<ISalesWebService2>(binding, endpointAddress); return factory.CreateChannel(); }); } static void Main(string[] args) { AddSalesServiceClient(); ISalesWebService2 client = services.BuildServiceProvider().GetRequiredService<ISalesWebService2>(); try { int count = 1; using (OperationContextScope scope = new OperationContextScope((IContextChannel)client)) { OperationContext context = OperationContext.Current; HttpRequestMessageProperty httpRequestProperty = new HttpRequestMessageProperty(); httpRequestProperty.Headers["AccessToken"] = 'AccessToken'; httpRequestProperty.Headers["LocationToken"] = 'LocationToken'; context.OutgoingMessageProperties[HttpRequestMessageProperty.Name] = httpRequestProperty; var request = new GetTillsRequest() { BusinessDate = new DateTime(2001, 01, 01), }; //Make GetTills call var response = client.GetTillsAsync(request); Console.WriteLine("GetTills"); Console.WriteLine("--------"); //If call is successful if (response.Result.ResultCode == 0) { Console.WriteLine(response.Result.ResultCode); //Loop through collection of Till objects returned foreach (var till in response.Result.Tills) { Console.WriteLine("Till #" + count); Console.WriteLine("---------------------------"); Console.WriteLine("BusinessDate: " + till.BusinessDate); Console.WriteLine("CashDrawerId: " + till.CashDrawerId); Console.WriteLine("ClosedByEmployeeId: " + till.ClosedByEmployeeId); Console.WriteLine("ClosedTime: " + till.ClosedTime); Console.WriteLine("DeclaredCash " + till.DeclaredCash); Console.WriteLine("EmployeeId: " + till.EmployeeId); Console.WriteLine("IsClosed: " + till.IsClosed); Console.WriteLine("IsPublic: " + till.IsPublic); Console.WriteLine("IsVirtual: " + till.IsVirtual); Console.WriteLine("Number: " + till.Number); Console.WriteLine("OpenedTime: " + till.OpenedTime); Console.WriteLine("OverShort: " + till.OverShort); Console.WriteLine("PaidInOuts: "); //Loop through collection of PaidInOut objects returned foreach (var paidInOut in till.PaidInOuts) { Console.WriteLine("\tEmployeeId: " + paidInOut.EmployeeId); Console.WriteLine("\tAccountType: " + paidInOut.AccountType); Console.WriteLine("\tAmount:" + paidInOut.Amount); Console.WriteLine("\tDescription: " + paidInOut.Description); Console.WriteLine("\tNumber: " + paidInOut.Number); Console.WriteLine("\tPettyAccountId: " + paidInOut.PettyAccountId); Console.WriteLine("\tTime: " + paidInOut.Time.DateTime); Console.WriteLine("\t-----------------------"); } //Loop through collection of Skim objects returned foreach (var skim in till.Skims) { Console.WriteLine("\tCashDrawerName: " + skim.CashDrawerName); Console.WriteLine("\tDuration: " + skim.Duration); Console.WriteLine("\tSkimAmount:" + skim.SkimAmount); Console.WriteLine("\tSkimTime: " + skim.SkimTime.DateTime); Console.WriteLine("\UserName: " + skim.UserName); Console.WriteLine("\t-----------------------"); } Console.WriteLine("StartingBank: " + till.StartingBank); Console.WriteLine("---------------------------"); count++; } Console.WriteLine("End"); Console.ReadKey(); } else { Console.WriteLine("Error Code: " + response.Result.ResultCode); Console.WriteLine("Message: " + response.Result.Message); } } } catch (Exception ex) { Console.WriteLine("Error calling GetTills operation: " + ex.Message); } } } }
GetTills Sample Code
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://www.brinksoftware.com/webservices/sales/v2"> <soapenv:Header/> <soapenv:Body> <v2:GetTills> <v2:request> <v2:BusinessDate>2001-01-01</v2:BusinessDate> </v2:request> </v2:GetTills> </soapenv:Body> </soapenv:Envelope>
GetTills Sample Code
from zeep import Client from zeep.transports import Transport import requests from datetime import datetime accessToken = 'AccessToken' locationToken = 'LocationToken' #Include tokens in HTTP Web Request Headers session = requests.Session() session.headers.update({'AccessToken': accessToken, 'LocationToken': locationToken}) transport = Transport(session=session) #Connect to Sales2 service client client = Client(wsdl='{YOUR_WSDL_URL_GOES_HERE}', transport=transport) service = client.create_service( '{http://www.brinksoftware.com/webservices/sales/v2}BasicHttpBinding_ISalesWebService2', 'https://{YourStack}.brinkpos.net/sales2.svc' ) #Prepare the dynamic type for GetTillsRequest get_tills_request_type = client.get_type('ns1:GetTillsRequest') #Include BusinessDate parameter in request body businessdate = datetime(2001, 01, 01) req_data = get_tills_request_type(BusinessDate=businessdate) count = 1 try: #Make GetTills call res = service.GetTills(req_data) #If call is successful if (res.ResultCode == 0): #Loop through collection of Till objects returned for till in res.Tills.Till: print('Till #' + str(count)) print('---------------------------') print('BusinessDate: ' + str(till.BusinessDate)) print('CashDrawerId: ' + str(till.CashDrawerId)) print('ClosedByEmployeeId: ' + str(till.ClosedByEmployeeId)) print('ClosedTime: ') print('\tDateTime: ' + str(till.ClosedTime.DateTime)) print('\tOffsetMinutes: ' + str(till.ClosedTime.OffsetMinutes)) print('DeclaredCash: ' + str(till.DeclaredCash)) print('EmployeeId: ' + str(till.EmployeeId)) print('IsClosed: ' + str(till.IsClosed)) print('IsPublic: ' + str(till.IsPublic)) print('IsVirtual: ' + str(till.IsVirtual)) print('Number: ' + str(till.Number)) print('OpenedTime ') print('\tDateTime: ' + str(till.OpenedTime.DateTime)) print('\tOffsetMinutes: ' + str(till.OpenedTime.OffsetMinutes)) print('OverShort: ' + str(till.OverShort)) if (till.PaidInOuts != None): print('PaidInOuts: ') #Loop through collection of PaidInOut objects returned for paid_in_out in till.PaidInOuts: print('\tAccountType: ' + str(paid_in_out.AccountType)) print('\tAmount: ' + str(paid_in_out.Amount)) print('\tDescription: ' + paid_in_out.Description) print('\tEmployeeId: ' + str(paid_in_out.EmployeeId)) print('\tNumber: ' + str(paid_in_out.Number)) print('\tPettyAccountId: ' + str(paid_in_out.PettyAccountId)) print('\tTime: ' + str(paid_in_out.Time.DateTime)) else: print('PaidInOuts: None') if (till.Skims != None): print('Skims: ') #Loop through collection of Skim objects returned for skim in till.Skims: print('\tCashDrawerName: ' + str(skim.CashDrawerName)) print('\tDuration: ' + str(skim.Duration)) print('\tSkimAmount: ' + str(skim.SkimAmount)) print('\tSkimTime: ' + str(skim.SkimTime.DateTime)) print('\tUserName: ' + str(skim.UserName)) else: print('Skims: None') print('StartingBank: ' + str(till.StartingBank)) print('---------------------------') count += 1 print('End') else: print('Error Code: ' + str(res.ResultCode)) print('Message: ' + res.Message) except Exception as e: print(e)