bLoyal API Documention and Samples

Methods: LoyaltyEngine Web Service Reference

Description

The bLoyal LoyaltyEngine web service enables you to add the bLoyal Promotions and Loyalty Engine into your application using SOAP web services.  The web service methods provided by LoyaltyEngine.svc are below.

Methods
Name  Description 
CalculateSalesTransaction  CalculateSalesTransaction() is the primary method used to integrate the bLoyal Promotions and Loyalty engine with an application.  You pass in a sales transaction (e.g. a POS sale, shopping cart, or order) and bLoyal processes it and returns any Discounts that applied, Loyalty Benefits that will accrue, and any suggested Offers
CommitTransactionExternalId  CalculateSalesTransaction returns suggested loyalty accruals and usage.  You must commit the transaction to lock in the point acruals or usage once the customer has paid.  You can do this either with your transaction number or the bLoyal geneated transaction Token.  This a lieightweight call takes your transaction number (as TransactionExternalId) as input and commits the loyalty transaction(s) associated with the transaction.  It must be called as soon as your system captures funds on the trasnction.  You can later call SubmitSalesTransation offline to record the full detail of the transaction with bLoyal.
CommitTransactionToken  CalculateSalesTransaction returns suggested loyalty accruals and usage.  You must commit the transaction to lock in the point acruals or usage once the customer has paid.  You can do this either with your transaction number or the bLoyal geneated transaction Token.  This a lieightweight call takes the bLoyal transaction Token as input and commits the loyalty transaction(s) associated with the transaction.  It must be called as soon as your system captures funds on the trasnction.  You can later call SubmitSalesTransation offline to record the full detail of the transaction with bLoyal.
CreateTransactionToken  If your system does not have a unique transaction number at the time you call a POS Snippet then you can use CreateTransactionToken to have bLoyal create a unique transction Token that can be used with the POS Snippets and the CalculateSalesTransaction call.
CreateVisit   
CustomerQuickSearch  Performs the bLoyal customer quick search algorithm and returns a list of one or more customers that match the criteria.  The quick search algorithm may be bLoyal client specific and searches across the fields the client wants to search on.
DeleteSubscriberGroupMembership   
GetAvailableSubscriberGroups   
GetAvailableVisitTypes   
GetCustomer  Gets customer details from bLoyal given a bLoyal Id.
GetCustomerByExternalId  Gets customer details from bLoyal given your customer Id (the ExternalId of the customer).
GetDevice  Gets details about the device that you are using.
GetDeviceUsageId  Creates a temporary usage id Token that can be used by the POS Snippets.  The token is generated from the login credentials you are using to log in to the web service
GetTransactionCustomer  Returns the customer that has been assigned to the current transaction given the bLoyal generated transaction token.  The method returns the TransactionCustomer entity which contains the key summary identification information of the customer.
GetTransactionCustomerByExternalId  Returns the customer that has been assigned to the current transaction given your local transaction number.  Returns the TransactionCustomer entity which contains the key summary identification information of the customer.
GetTransactionTokenByExternalId  Returns the bLoyal generated transaction token that is associated with your transaction number.  If a token has not been created yet then one will be automatically created.
SaveCustomer   
SaveSubscriberGroupMembership   
SetTokenCustomer  Set the customer to the transaction given the bLoyal transaction token.  This call is normally not needed since you can pass in the customer information on the CalculateSalesTransaction() method.
SubmitSalesTransaction  Submit the full detail of the sales transction to bLoyal.  This method can be called either in flow of the transaction or asynchronously later.  All sales transactions should be submitted to bLoyal regardless of whether a customer was assigned or a benefit was applied.