{"title":"Payment-linked loyalty program","category":"default","creationDate":1727794860,"content":"<p>You can use customer recognition to make your existing loyalty program more frictionless for your customers by removing the need for a traditional loyalty card or app. In this tutorial, we'll explain how you can link your loyalty system to their customer profile. When they make a payment in your online or physical store, you can automatically recognize them, and award them with points, discounts, or a reward.<\/p>\n<p>When you offer a payment-linked loyalty, you also give your customers an extra incentive to provide you their contact details, which you can also use to <a href=\"\/unified-commerce\/loyalty-program\/create-profiles\">create a customer profile<\/a>.<\/p>\n<h2>Requirements<\/h2>\n<p>To use payment-linked loyalty, make sure that:<\/p>\n<ol>\n<li>You can already <a href=\"\/unified-commerce\/loyalty-program\/create-profiles\">create customer profiles<\/a> and <a href=\"\/unified-commerce\/loyalty-program\/recognize-customers\">recognize returning customers<\/a> across your sales channels.<\/li>\n<li>You have a loyalty system that keeps track of customer registration, as well as other data such as points balance and rewards eligibility.<\/li>\n<\/ol>\n<h2>Online loyalty<\/h2>\n<p>When your customer makes a purchase in your web or in-app store, attempt to recognize them, and check whether they have already enrolled in your loyalty program.<\/p>\n<p>From here, you can either ask them to register for your loyalty program, or check whether they are eligible for a loyalty reward, before continuing with the transaction.<\/p>\n<h3>Step 1: Recognize customer<\/h3>\n<p>Before making a purchase, your customer will provide you with their contact details, such as an email address or phone number (for example, when creating or signing in to their account, or through your guest checkout).<\/p>\n<p>To recognize whether this is a returning customer:<\/p>\n<ul>\n<li>Check whether their contact details match a <code>shopperEmail<\/code> that you have <a href=\"\/unified-commerce\/loyalty-program\/create-profiles#store-customer-data\">stored in your customer database<\/a>.\n<ul>\n<li><em>If the email matches<\/em>, they are a returning customer. Proceed to the next step to get their loyalty rewards points.<\/li>\n<li><em>If the email is not your database<\/em>, proceed to step 3 to <a href=\"#step-3-continue-with-payment\">continue the payment<\/a>. In the payment request, you might want to include other parameters to <a href=\"\/unified-commerce\/loyalty-program\/create-profiles#create-profile-from-online-payment\">create a customer profile for them<\/a>.<\/li>\n<\/ul><\/li>\n<\/ul>\n<h3>Step 2: Request customer input<\/h3>\n<p>After you have determined if they are a returning customer, query your loyalty system database using the <code>shopperEmail<\/code> and check their loyalty program status. Next, present a relevant message in your UI:<\/p>\n<ul>\n<li>If they <em>are not<\/em> a member of your loyalty program, this message should ask them to register.<\/li>\n<li>If they <em>are<\/em> already a member, you could inform them how close they are to receiving a reward or, if they have enough points, ask them whether they want to redeem their reward.<\/li>\n<\/ul>\n<h3>Step 3: Continue with payment<\/h3>\n<p>Continue with the purchase by initiating a payment. Here is how you can make a payment for a customer <code>shopperEmail<\/code> <strong>john_smith@example.com<\/strong> with a corresponding<code>shopperReference<\/code> <strong>ShopperID-A16729<\/strong>.<\/p>\n<ol>\n<li>\n<p>Make a POST  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments<\/a>\u00a0request.<\/p>\n<div data-component-wrapper=\"code-sample\">\n<code-sample :title=\"'Payments request'\" :id=\"''\" :code-data='[{\"language\":\"json\",\"tabTitle\":\"\",\"content\":\"{\\n    \\\"amount\\\": {\\n    \\\"currency\\\": \\\"EUR\\\",\\n    \\\"value\\\": 500\\n    },\\n    \\\"reference\\\": \\\"YOUR_ORDER_NUMBER\\\",\\n    \\\"paymentMethod\\\": {\\n        \\\"type\\\": \\\"scheme\\\",\\n        \\\"encryptedCardNumber\\\": \\\"test_4111111111111111\\\",\\n        \\\"encryptedExpiryMonth\\\": \\\"test_03\\\",\\n        \\\"encryptedExpiryYear\\\": \\\"test_2030\\\",\\n        \\\"encryptedSecurityCode\\\": \\\"test_737\\\"\\n    },\\n    \\\"shopperReference\\\": \\\"ShopperID-A16729\\\",\\n    \\\"returnUrl\\\": \\\"https:\\\/\\\/your-company.example.com\\\/...\\\",\\n    \\\"merchantAccount\\\": \\\"YOUR_MERCHANT_ACCOUNT\\\"\\n}\"}]' :enable-copy-link-to-code-block=\"true\" :code-sample-card-size=\"'fullsize'\"><\/code-sample>\n<\/div>\n<p>The response includes:<\/p>\n<ul>\n<li><code>pspReference<\/code>: our unique identifier for this payment.<\/li>\n<li><code>resultCode<\/code>: <span translate=\"no\"><strong>Authorised<\/strong><\/span><\/li>\n<\/ul>\n<p>The following example shows a successful response with a PSP reference of <strong>881468919096134D<\/strong>.<\/p>\n<pre><code class=\"language-json\">{\n    \"pspReference\": \"881468919096134D\",\n    \"resultCode\": \"Authorised\"\n}<\/code><\/pre>\n<\/li>\n<li>\n<p>In your loyalty system database, update the loyalty points in your record for<code>shopperEmail<\/code> <strong>john_smith@example.com<\/strong>.<\/p>\n<\/li>\n<\/ol>\n<p>When you have set up a loyalty system for your online transactions you can do the same for in-person transactions.<\/p>\n<h2>In-person loyalty<\/h2>\n<p>There are two flows you can use to perform payment-linked loyalty using your point-of-sale integration.<\/p>\n<ul>\n<li>\n<p><strong>Synchronous<\/strong>:  using data you receive from Adyen before the payment is initiated.<\/p>\n<p>With this flow, you use the data that you receive from Adyen to query your loyalty system database. You then present loyalty information, such as a points balance or a personalized message, to your customer while they are making their purchase.<\/p>\n<\/li>\n<li>\n<p><strong>Asynchronous<\/strong>: using data you receive from a webhook after the payment has been processed.<\/p>\n<p>This flow requires less integration work, but you will not be able to present real-time loyalty information to your customer. You update your loyalty system at a later time with the information that you receive from webhooks.<\/p>\n<\/li>\n<\/ul>\n<p>To implement any of these flows, select a tab below:<\/p>\n\n<div id=\"tabFHy9x\">\n    <div data-component-wrapper=\"tabs\">\n        <tabs\n                        :items=\"[{&quot;title&quot;:&quot;Synchronous&quot;,&quot;content&quot;:&quot;\\n&lt;h3&gt;Synchronous in-person loyalty&lt;\\\/h3&gt;\\n&lt;p&gt;By using a synchronous loyalty flow, you&#039;ll be able to present your loyal customers with information such as points balance and redeemable rewards while they are making a purchase.&lt;\\\/p&gt;\\n&lt;p&gt;We&#039;ll explain how you can use your terminal&#039;s built-in touchscreen to interact with your customers. We&#039;ll cover how you can ask them to register in your loyalty program, present customized messaging, and inform them when they are due to receive a loyalty reward.&lt;\\\/p&gt;\\n&lt;p&gt;When your customer makes a purchase at the point of sale, check whether they are registered in your loyalty program. From here, you can either ask them to register, or check whether they are eligible for a loyalty reward, before continuing with the transaction.&lt;\\\/p&gt;\\n&lt;h4&gt;Step 1: Recognize customer&lt;\\\/h4&gt;\\n&lt;p&gt;To determine whether your customer is a member of your loyalty program, attempt to recognize them with a card acquisition request.&lt;\\\/p&gt;\\n&lt;p&gt;When the customer makes a purchase at the point of sale:&lt;\\\/p&gt;\\n&lt;ol&gt;\\n&lt;li&gt;\\n&lt;p&gt;Make a card acquisition request to &lt;a href=\\&quot;\\\/unified-commerce\\\/loyalty-program\\\/recognize-customers#recognize-returning-customers-in-store\\&quot;&gt;recognize the customer&lt;\\\/a&gt;.&lt;\\\/p&gt;\\n&lt;p&gt;The example below shows a card acquisition request for a customer who is making a &lt;strong&gt;EUR&amp;nbsp;10.99&lt;\\\/strong&gt; purchase.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Card acquisition request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n    \\\\\\&quot;SaleToPOIRequest\\\\\\&quot;: {\\\\n        \\\\\\&quot;MessageHeader\\\\\\&quot;:{\\\\n            \\\\\\&quot;ProtocolVersion\\\\\\&quot;:\\\\\\&quot;3.0\\\\\\&quot;,\\\\n            \\\\\\&quot;MessageClass\\\\\\&quot;:\\\\\\&quot;Service\\\\\\&quot;,\\\\n            \\\\\\&quot;MessageCategory\\\\\\&quot;:\\\\\\&quot;CardAcquisition\\\\\\&quot;,\\\\n            \\\\\\&quot;MessageType\\\\\\&quot;:\\\\\\&quot;Request\\\\\\&quot;,\\\\n            \\\\\\&quot;SaleID\\\\\\&quot;:\\\\\\&quot;POSSystemID12345\\\\\\&quot;,\\\\n            \\\\\\&quot;ServiceID\\\\\\&quot;:\\\\\\&quot;0207111104\\\\\\&quot;,\\\\n            \\\\\\&quot;POIID\\\\\\&quot;:\\\\\\&quot;V400m-324688179\\\\\\&quot;\\\\n        },\\\\n        \\\\\\&quot;CardAcquisitionRequest\\\\\\&quot;: {\\\\n            \\\\\\&quot;SaleData\\\\\\&quot;: {\\\\n                \\\\\\&quot;SaleTransactionID\\\\\\&quot;: {\\\\n                    \\\\\\&quot;TransactionID\\\\\\&quot;: \\\\\\&quot;15890\\\\\\&quot;,\\\\n                    \\\\\\&quot;TimeStamp\\\\\\&quot;: \\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;\\\\n                },\\\\n            },\\\\n            \\\\\\&quot;CardAcquisitionTransaction\\\\\\&quot;: {\\\\n                \\\\\\&quot;TotalAmount\\\\\\&quot;: 10.99\\\\n            }\\\\n        }\\\\n    }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;You receive a response that includes an &lt;code&gt;AdditionalResponse&lt;\\\/code&gt; object, with a base64-encoded string that you need to decode to get a JSON object, or a string of form-encoded key-value pairs. In our examples, we use form-encoded key-value pairs.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Card acquisition response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n    \\\\\\&quot;SaleToPOIResponse\\\\\\&quot;: {\\\\n        \\\\\\&quot;CardAcquisitionResponse\\\\\\&quot;: {\\\\n            \\\\\\&quot;POIData\\\\\\&quot;: {\\\\n                \\\\\\&quot;POITransactionID\\\\\\&quot;: {\\\\n                    \\\\\\&quot;TimeStamp\\\\\\&quot;: \\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;,\\\\n                    \\\\\\&quot;TransactionID\\\\\\&quot;: \\\\\\&quot;4rVu001575460969123\\\\\\&quot;\\\\n                },\\\\n                \\\\\\&quot;POIReconciliationID\\\\\\&quot;: \\\\\\&quot;1000\\\\\\&quot;\\\\n            },\\\\n            \\\\\\&quot;SaleData\\\\\\&quot;: {\\\\n                \\\\\\&quot;SaleTransactionID\\\\\\&quot;: {\\\\n                    \\\\\\&quot;TimeStamp\\\\\\&quot;: \\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;,\\\\n                    \\\\\\&quot;TransactionID\\\\\\&quot;: \\\\\\&quot;15890\\\\\\&quot;\\\\n                }\\\\n            },\\\\n            \\\\\\&quot;PaymentInstrumentData\\\\\\&quot;: {...},\\\\n            \\\\\\&quot;Response\\\\\\&quot;: {\\\\n                \\\\\\&quot;Result\\\\\\&quot;: \\\\\\&quot;Success\\\\\\&quot;,\\\\n                \\\\\\&quot;AdditionalResponse\\\\\\&quot;:\\\\\\&quot;...alias=M469509594859802...\\\\\\&quot;\\\\n            }\\\\n        },\\\\n        \\\\\\&quot;MessageHeader\\\\\\&quot;: {...}\\\\n    }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;Check if the &lt;code&gt;AdditionalResponse&lt;\\\/code&gt; object contains the &lt;code&gt;alias&lt;\\\/code&gt; of the shopper&#039;s card. You need the &lt;code&gt;alias&lt;\\\/code&gt; to identify the shopper in your database.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;Query your loyalty system database using the &lt;code&gt;alias&lt;\\\/code&gt; to identify the shopper in your database. Get information about whether the customer has already registered in your loyalty program, how many points they have, and if they are eligible for a reward.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;h4&gt;Step 2: Request customer input&lt;\\\/h4&gt;\\n&lt;p&gt;After you have determined if they are a new or returning customer, present a relevant message on the terminal screen:&lt;\\\/p&gt;\\n&lt;ul&gt;\\n&lt;li&gt;If the customer &lt;em&gt;is not&lt;\\\/em&gt; a member of your loyalty program, you can &lt;a href=\\&quot;#register-loyalty-member\\&quot;&gt;ask them to register&lt;\\\/a&gt;, and collect their email address if you do not have it yet.&lt;\\\/li&gt;\\n&lt;li&gt;If the customer &lt;em&gt;is&lt;\\\/em&gt; a member, and is eligible for a reward, you can &lt;a href=\\&quot;#redeem-loyalty-reward\\&quot;&gt;ask them whether they want to redeem this reward&lt;\\\/a&gt;.&lt;\\\/li&gt;\\n&lt;li&gt;If the customer &lt;em&gt;is&lt;\\\/em&gt; a loyalty member but &lt;em&gt;is not yet&lt;\\\/em&gt; eligible for a reward, &lt;a href=\\&quot;#continue-payment-sync\\&quot;&gt;continue with the payment&lt;\\\/a&gt;.&lt;\\\/li&gt;\\n&lt;\\\/ul&gt;\\n&lt;h5&gt;Register loyalty member&lt;\\\/h5&gt;\\n&lt;p&gt;If your customer is not a member of your loyalty program, you can register them directly from your Adyen-supplied payment terminal.&lt;\\\/p&gt;\\n&lt;p&gt;When you register a new loyalty member, we recommend collecting their email address. This makes it easier for you to link their online and in-person loyalty, as well as send them email updates. You can also use this email address to &lt;a href=\\&quot;\\\/unified-commerce\\\/digital-receipts\\&quot;&gt;send them an e-receipt&lt;\\\/a&gt; for their in-store transaction. If collecting an email address is not possible, you can collect their phone number, or another unique identifier for the customer instead.&lt;\\\/p&gt;\\n&lt;p&gt;To register a customer into your loyalty scheme:&lt;\\\/p&gt;\\n&lt;ol&gt;\\n&lt;li&gt;\\n&lt;p&gt;Make a &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;GetConfirmation&lt;\\\/strong&gt;&lt;\\\/span&gt; &lt;a href=\\&quot;\\\/point-of-sale\\\/shopper-engagement\\\/shopper-input\\&quot;&gt;input request&lt;\\\/a&gt; from your POS app, asking whether the customer wants to register for your loyalty program.&lt;\\\/p&gt;\\n&lt;p&gt;The following example shows how to present &lt;strong&gt;Would you like to join our loyalty program?&lt;\\\/strong&gt; on the terminal display, as well as the options &lt;strong&gt;Yes&lt;\\\/strong&gt; and &lt;strong&gt;No&lt;\\\/strong&gt;.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;GetConfirmation input request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n   \\\\\\&quot;SaleToPOIRequest\\\\\\&quot;:{\\\\n      \\\\\\&quot;MessageHeader\\\\\\&quot;:{\\\\n         \\\\\\&quot;ProtocolVersion\\\\\\&quot;:\\\\\\&quot;3.0\\\\\\&quot;,\\\\n         \\\\\\&quot;MessageClass\\\\\\&quot;:\\\\\\&quot;Service\\\\\\&quot;,\\\\n         \\\\\\&quot;MessageCategory\\\\\\&quot;:\\\\\\&quot;Payment\\\\\\&quot;,\\\\n         \\\\\\&quot;MessageType\\\\\\&quot;:\\\\\\&quot;Request\\\\\\&quot;,\\\\n         \\\\\\&quot;ServiceID\\\\\\&quot;:\\\\\\&quot;0207112304\\\\\\&quot;,\\\\n         \\\\\\&quot;SaleID\\\\\\&quot;:\\\\\\&quot;POSSystemID12345\\\\\\&quot;,\\\\n         \\\\\\&quot;POIID\\\\\\&quot;:\\\\\\&quot;V400m-324688179\\\\\\&quot;\\\\n      },\\\\n      \\\\\\&quot;InputRequest\\\\\\&quot;:{\\\\n         \\\\\\&quot;DisplayOutput\\\\\\&quot;:{\\\\n            \\\\\\&quot;Device\\\\\\&quot;:\\\\\\&quot;CustomerDisplay\\\\\\&quot;,\\\\n            \\\\\\&quot;InfoQualify\\\\\\&quot;:\\\\\\&quot;Display\\\\\\&quot;,\\\\n            \\\\\\&quot;OutputContent\\\\\\&quot;:{\\\\n               \\\\\\&quot;OutputFormat\\\\\\&quot;:\\\\\\&quot;Text\\\\\\&quot;,\\\\n               \\\\\\&quot;PredefinedContent\\\\\\&quot;:{\\\\n                  \\\\\\&quot;ReferenceID\\\\\\&quot;:\\\\\\&quot;GetConfirmation\\\\\\&quot;\\\\n               },\\\\n               \\\\\\&quot;OutputText\\\\\\&quot;:[\\\\n                  {\\\\\\&quot;Text\\\\\\&quot;:\\\\\\&quot;Welcome stranger!\\\\\\&quot;},\\\\n                  {\\\\\\&quot;Text\\\\\\&quot;:\\\\\\&quot;Would you like to join our loyalty program?\\\\\\&quot;},\\\\n                  {\\\\\\&quot;Text\\\\\\&quot;:\\\\\\&quot;No\\\\\\&quot;},\\\\n                  {\\\\\\&quot;Text\\\\\\&quot;:\\\\\\&quot;Yes\\\\\\&quot;}\\\\n               ]\\\\n            }\\\\n         },\\\\n         \\\\\\&quot;InputData\\\\\\&quot;:{\\\\n            \\\\\\&quot;Device\\\\\\&quot;:\\\\\\&quot;CustomerInput\\\\\\&quot;,\\\\n            \\\\\\&quot;InfoQualify\\\\\\&quot;:\\\\\\&quot;Input\\\\\\&quot;,\\\\n            \\\\\\&quot;InputCommand\\\\\\&quot;:\\\\\\&quot;GetConfirmation\\\\\\&quot;,\\\\n            \\\\\\&quot;MaxInputTime\\\\\\&quot;:30\\\\n         }\\\\n      }\\\\n   }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;Your message is shown on the terminal display. The customer indicates whether they would like to register.&lt;\\\/p&gt;\\n&lt;p&gt;When they are done selecting their option, you receive the input response that contains an &lt;code&gt;Input.ConfirmedFlag&lt;\\\/code&gt;. If this is &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;true&lt;\\\/strong&gt;&lt;\\\/span&gt;, proceed to the next step to register your customer to your loyalty program. Otherwise, you can continue &lt;a href=\\&quot;#step-3-continue-with-payment\\&quot;&gt;processing the transaction&lt;\\\/a&gt;.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n    &lt;code-sample :title=\\&quot;&#039;GetConfirmation input response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n   \\\\\\&quot;SaleToPOIRequest\\\\\\&quot;:{\\\\n\\\\t      \\\\\\&quot;InputResponse\\\\\\&quot;: {\\\\n\\\\t         \\\\\\&quot;InputResult\\\\\\&quot;: {\\\\n\\\\t            \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerInput\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Input\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;Response\\\\\\&quot;: {\\\\n\\\\t               \\\\\\&quot;Result\\\\\\&quot;: \\\\\\&quot;Success\\\\\\&quot;,\\\\n\\\\t               \\\\\\&quot;AdditionalResponse\\\\\\&quot;: \\\\\\&quot;...\\\\\\&quot;\\\\n\\\\t            },\\\\n\\\\t            \\\\\\&quot;Input\\\\\\&quot;: {\\\\n\\\\t               \\\\\\&quot;ConfirmedFlag\\\\\\&quot;: true,\\\\n\\\\t               \\\\\\&quot;InputCommand\\\\\\&quot;: \\\\\\&quot;GetConfirmation\\\\\\&quot;\\\\n\\\\t            }\\\\n\\\\t         },\\\\n\\\\t         \\\\\\&quot;OutputResult\\\\\\&quot;: {\\\\n\\\\t            \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerDisplay\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Display\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;Response\\\\\\&quot;: {\\\\n\\\\t               \\\\\\&quot;Result\\\\\\&quot;: \\\\\\&quot;Success\\\\\\&quot;\\\\n\\\\t            }\\\\n\\\\t         }\\\\n      },\\\\n\\\\t      \\\\\\&quot;MessageHeader\\\\\\&quot;: {...}\\\\n   }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;ol start=\\&quot;3\\&quot;&gt;\\n&lt;li&gt;\\n&lt;p&gt;If the customer indicated that they would like to register, and you do not already have their email address, make a &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;GetText&lt;\\\/strong&gt;&lt;\\\/span&gt; &lt;a href=\\&quot;\\\/point-of-sale\\\/shopper-engagement\\\/shopper-input\\&quot;&gt;input request&lt;\\\/a&gt; from your POS app. This should ask the customer to enter their email address.&lt;\\\/p&gt;\\n&lt;p&gt;The example &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;GetText&lt;\\\/strong&gt;&lt;\\\/span&gt; request below would present the message &lt;strong&gt;Enter your email address&lt;\\\/strong&gt; on the terminal display. An on-screen keyboard also appears on the terminal.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;GetText input request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t   \\\\\\&quot;SaleToPOIRequest\\\\\\&quot;: {\\\\n\\\\t      \\\\\\&quot;MessageHeader\\\\\\&quot;: {\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;ProtocolVersion\\\\\\&quot;:\\\\\\&quot;3.0\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;MessageClass\\\\\\&quot;:\\\\\\&quot;Service\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;MessageCategory\\\\\\&quot;:\\\\\\&quot;Payment\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;MessageType\\\\\\&quot;:\\\\\\&quot;Request\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;SaleID\\\\\\&quot;:\\\\\\&quot;POSSystemID12345\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;ServiceID\\\\\\&quot;:\\\\\\&quot;0207112311\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t \\\\\\&quot;POIID\\\\\\&quot;:\\\\\\&quot;V400m-324688179\\\\\\&quot;\\\\n\\\\t\\\\t  },\\\\n\\\\t      \\\\\\&quot;InputRequest\\\\\\&quot;: {\\\\n\\\\t         \\\\\\&quot;DisplayOutput\\\\\\&quot;: {\\\\n\\\\t            \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerDisplay\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Display\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;OutputContent\\\\\\&quot;: {\\\\n\\\\t               \\\\\\&quot;OutputFormat\\\\\\&quot;: \\\\\\&quot;Text\\\\\\&quot;,\\\\n\\\\t               \\\\\\&quot;PredefinedContent\\\\\\&quot;: {\\\\n\\\\t                  \\\\\\&quot;ReferenceID\\\\\\&quot;: \\\\\\&quot;GetText\\\\\\&quot;\\\\n\\\\t               },\\\\n\\\\t            \\\\\\&quot;OutputText\\\\\\&quot;: [\\\\n\\\\t               {\\\\\\&quot;Text\\\\\\&quot;: \\\\\\&quot;Enter your email address\\\\\\&quot;}\\\\n\\\\t            ]\\\\n\\\\t         }\\\\n\\\\t      },\\\\n\\\\t         \\\\\\&quot;InputData\\\\\\&quot;: {\\\\n\\\\t            \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerInput\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Input\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;InputCommand\\\\\\&quot;: \\\\\\&quot;TextString\\\\\\&quot;,\\\\n\\\\t            \\\\\\&quot;MaxInputTime\\\\\\&quot;: 120,\\\\n\\\\t            \\\\\\&quot;DefaultInputString\\\\\\&quot;: \\\\\\&quot;name@domain.com\\\\\\&quot;\\\\n\\\\t         }\\\\n\\\\t      }\\\\n\\\\t   }\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;The customer enters their email address on the terminal. When they are done typing in their email address, you receive an input response, with the customer&#039;s email address provided in the &lt;code&gt;Input.TextInput&lt;\\\/code&gt;.&lt;\\\/p&gt;\\n&lt;p&gt;The example below shows what this response would look like if the customer entered the email address &lt;strong&gt;john.smith@example.com&lt;\\\/strong&gt;.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;GetText input response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t  \\\\\\&quot;SaleToPOIResponse\\\\\\&quot;: {\\\\n\\\\t    \\\\\\&quot;InputResponse\\\\\\&quot;: {\\\\n\\\\t      \\\\\\&quot;InputResult\\\\\\&quot;: {\\\\n\\\\t        \\\\\\&quot;Device\\\\\\&quot;:\\\\\\&quot;CustomerInput\\\\\\&quot;,\\\\n\\\\t        \\\\\\&quot;InfoQualify\\\\\\&quot;:\\\\\\&quot;Input\\\\\\&quot;,\\\\n\\\\t        ...\\\\n\\\\t        },\\\\n\\\\t        \\\\\\&quot;Input\\\\\\&quot;: {\\\\n\\\\t          \\\\\\&quot;TextInput\\\\\\&quot;:\\\\\\&quot;john.smith@example.com\\\\\\&quot;,\\\\n\\\\t          \\\\\\&quot;InputCommand\\\\\\&quot;:\\\\\\&quot;TextString\\\\\\&quot;\\\\n\\\\t        }\\\\n\\\\t      },\\\\n\\\\t      \\\\\\&quot;OutputResult\\\\\\&quot;: {\\\\n\\\\t        \\\\\\&quot;Device\\\\\\&quot;:\\\\\\&quot;CustomerDisplay\\\\\\&quot;,\\\\n\\\\t        \\\\\\&quot;InfoQualify\\\\\\&quot;:\\\\\\&quot;Display\\\\\\&quot;,\\\\n\\\\t        \\\\\\&quot;Response\\\\\\&quot;: {\\\\n\\\\t          \\\\\\&quot;Result\\\\\\&quot;:\\\\\\&quot;Success\\\\\\&quot;\\\\n\\\\t        }\\\\n\\\\t      }\\\\n\\\\t    },\\\\n\\\\t  \\\\\\&quot;MessageHeader\\\\\\&quot;: {...}\\\\n\\\\t  }\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;Get the email address and include it when you &lt;a href=\\&quot;#step-3-continue-with-payment\\&quot;&gt;continue with the payment&lt;\\\/a&gt;.&lt;\\\/p&gt;\\n&lt;div class=\\&quot;notices blue\\&quot;&gt;\\n&lt;p&gt;As a courtesy, you may want to send an email to your customer, confirming their registration in your loyalty program and explaining how it works.&lt;\\\/p&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;h5&gt;Redeem loyalty reward&lt;\\\/h5&gt;\\n&lt;p&gt;If your customer has earned a loyalty reward, you can use your Adyen-supplied payment terminal to inform them and give them the option to redeem their reward. If the customer agrees to redeem their reward, you can then adjust the value of the transaction before you make a payment.&lt;\\\/p&gt;\\n&lt;p&gt;To ask if a customer wants to redeem their loyalty points:&lt;\\\/p&gt;\\n&lt;ol&gt;\\n&lt;li&gt;\\n&lt;p&gt;Make a &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;GetConfirmation&lt;\\\/strong&gt;&lt;\\\/span&gt; &lt;a href=\\&quot;\\\/point-of-sale\\\/shopper-engagement\\\/shopper-input\\&quot;&gt;input request&lt;\\\/a&gt;, to ask your customer whether they would like to redeem their loyalty points with this transaction.&lt;\\\/p&gt;\\n&lt;p&gt;The following example shows how to present a prompt for a free coffee on the terminal display, asking the customer whether they would like to redeem it now.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;GetConfirmation input request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=\\&quot;[{&amp;quot;language&amp;quot;:&amp;quot;json&amp;quot;,&amp;quot;tabTitle&amp;quot;:&amp;quot;&amp;quot;,&amp;quot;content&amp;quot;:&amp;quot;{\\\\n   \\\\&amp;quot;SaleToPOIRequest\\\\&amp;quot;:{\\\\n      \\\\&amp;quot;MessageHeader\\\\&amp;quot;:{\\\\n         \\\\&amp;quot;ProtocolVersion\\\\&amp;quot;:\\\\&amp;quot;3.0\\\\&amp;quot;,\\\\n         \\\\&amp;quot;MessageClass\\\\&amp;quot;:\\\\&amp;quot;Service\\\\&amp;quot;,\\\\n         \\\\&amp;quot;MessageCategory\\\\&amp;quot;:\\\\&amp;quot;Payment\\\\&amp;quot;,\\\\n         \\\\&amp;quot;MessageType\\\\&amp;quot;:\\\\&amp;quot;Request\\\\&amp;quot;,\\\\n         \\\\&amp;quot;ServiceID\\\\&amp;quot;:\\\\&amp;quot;0207112311\\\\&amp;quot;,\\\\n         \\\\&amp;quot;SaleID\\\\&amp;quot;:\\\\&amp;quot;POSSystemID12345\\\\&amp;quot;,\\\\n         \\\\&amp;quot;POIID\\\\&amp;quot;:\\\\&amp;quot;V400m-324688179\\\\&amp;quot;\\\\n      },\\\\n      \\\\&amp;quot;InputRequest\\\\&amp;quot;:{\\\\n         \\\\&amp;quot;DisplayOutput\\\\&amp;quot;:{\\\\n            \\\\&amp;quot;Device\\\\&amp;quot;:\\\\&amp;quot;CustomerDisplay\\\\&amp;quot;,\\\\n            \\\\&amp;quot;InfoQualify\\\\&amp;quot;:\\\\&amp;quot;Display\\\\&amp;quot;,\\\\n            \\\\&amp;quot;OutputContent\\\\&amp;quot;:{\\\\n               \\\\&amp;quot;OutputFormat\\\\&amp;quot;:\\\\&amp;quot;Text\\\\&amp;quot;,\\\\n               \\\\&amp;quot;PredefinedContent\\\\&amp;quot;:{\\\\n                  \\\\&amp;quot;ReferenceID\\\\&amp;quot;:\\\\&amp;quot;GetConfirmation\\\\&amp;quot;\\\\n               },\\\\n               \\\\&amp;quot;OutputText\\\\&amp;quot;:[\\\\n                  {\\\\&amp;quot;Text\\\\&amp;quot;:\\\\&amp;quot;You&#039;ve earned a free coffee!\\\\&amp;quot;},\\\\n                  {\\\\&amp;quot;Text\\\\&amp;quot;:\\\\&amp;quot;Would you like to have it now?\\\\&amp;quot;},\\\\n                  {\\\\&amp;quot;Text\\\\&amp;quot;:\\\\&amp;quot;No\\\\&amp;quot;},\\\\n                  {\\\\&amp;quot;Text\\\\&amp;quot;:\\\\&amp;quot;Yes\\\\&amp;quot;}\\\\n               ]\\\\n            }\\\\n         },\\\\n         \\\\&amp;quot;InputData\\\\&amp;quot;:{\\\\n            \\\\&amp;quot;Device\\\\&amp;quot;:\\\\&amp;quot;CustomerInput\\\\&amp;quot;,\\\\n            \\\\&amp;quot;InfoQualify\\\\&amp;quot;:\\\\&amp;quot;Input\\\\&amp;quot;,\\\\n            \\\\&amp;quot;InputCommand\\\\&amp;quot;:\\\\&amp;quot;GetConfirmation\\\\&amp;quot;,\\\\n            \\\\&amp;quot;MaxInputTime\\\\&amp;quot;:30\\\\n         }\\\\n      }\\\\n   }\\\\n}&amp;quot;}]\\&quot; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;Your message is shown on the terminal display. The customer indicates whether they would like to redeem their loyalty points for a reward.&lt;\\\/p&gt;\\n&lt;p&gt;When they are done selecting their option, you receive the input response that contains an &lt;code&gt;Input.ConfirmedFlag&lt;\\\/code&gt;. If this is &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;true&lt;\\\/strong&gt;&lt;\\\/span&gt;, proceed to the next step to give the reward to your customer. Otherwise, continue &lt;a href=\\&quot;#step-3-continue-with-payment\\&quot;&gt;processing the transaction&lt;\\\/a&gt;.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;GetConfirmation input response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n  \\\\\\&quot;SaleToPOIResponse\\\\\\&quot;: {\\\\n    \\\\\\&quot;InputResponse\\\\\\&quot;: {\\\\n      \\\\\\&quot;InputResult\\\\\\&quot;: {\\\\n        \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerInput\\\\\\&quot;,\\\\n        \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Input\\\\\\&quot;,\\\\n        \\\\\\&quot;Response\\\\\\&quot;: {\\\\n          \\\\\\&quot;Result\\\\\\&quot;: \\\\\\&quot;Success\\\\\\&quot;,\\\\n          \\\\\\&quot;AdditionalResponse\\\\\\&quot;: \\\\\\&quot;...\\\\\\&quot;\\\\n        },\\\\n        \\\\\\&quot;Input\\\\\\&quot;: {\\\\n          \\\\\\&quot;ConfirmedFlag\\\\\\&quot;: true,\\\\n          \\\\\\&quot;InputCommand\\\\\\&quot;: \\\\\\&quot;GetConfirmation\\\\\\&quot;\\\\n        }\\\\n      },\\\\n      \\\\\\&quot;OutputResult\\\\\\&quot;: {\\\\n        \\\\\\&quot;Device\\\\\\&quot;: \\\\\\&quot;CustomerDisplay\\\\\\&quot;,\\\\n        \\\\\\&quot;InfoQualify\\\\\\&quot;: \\\\\\&quot;Display\\\\\\&quot;,\\\\n        \\\\\\&quot;Response\\\\\\&quot;: {\\\\n          \\\\\\&quot;Result\\\\\\&quot;: \\\\\\&quot;Success\\\\\\&quot;\\\\n        }\\\\n      }\\\\n    },\\\\n    \\\\\\&quot;MessageHeader\\\\\\&quot;: {...}\\\\n  }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;When a customer indicates they want to redeem their points, your POS app should calculate the redemption as a discount or partial payment. Continue to the next step to continue with the payment for the outstanding balance.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;h4 id=\\&quot;continue-payment-sync\\&quot;&gt;Step 3: Continue with payment&lt;\\\/h4&gt;\\n&lt;p&gt;Continue with the purchase by making a payment request:&lt;\\\/p&gt;\\n&lt;ol&gt;\\n&lt;li&gt;\\n&lt;p&gt;Make a POST request from your POS app to &lt;a href=\\&quot;\\\/point-of-sale\\\/basic-tapi-integration\\\/make-a-payment\\&quot;&gt;initiate the payment&lt;\\\/a&gt;. If you are registering a new customer for your loyalty program, also include parameters described in the &lt;a href=\\&quot;\\\/unified-commerce\\\/loyalty-program\\\/create-profiles#create-profile-from-point-of-sale-payment\\&quot;&gt;Create customer profiles&lt;\\\/a&gt; documentation.&lt;\\\/p&gt;\\n&lt;p&gt;Here is how you can make a &lt;strong&gt;EUR&amp;nbsp;10.99&lt;\\\/strong&gt; payment for a &lt;em&gt;known&lt;\\\/em&gt; customer.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Terminal API request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t\\\\t\\\\\\&quot;SaleToPOIRequest\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\\\&quot;MessageHeader\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;ProtocolVersion\\\\\\&quot;:\\\\\\&quot;3.0\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageClass\\\\\\&quot;:\\\\\\&quot;Service\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageCategory\\\\\\&quot;:\\\\\\&quot;Payment\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageType\\\\\\&quot;:\\\\\\&quot;Request\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleID\\\\\\&quot;:\\\\\\&quot;POSSystemID12345\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;ServiceID\\\\\\&quot;:\\\\\\&quot;0207111105\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;POIID\\\\\\&quot;:\\\\\\&quot;V400m-324688179\\\\\\&quot;\\\\n\\\\t\\\\t\\\\t},\\\\n\\\\t\\\\t\\\\t\\\\\\&quot;PaymentRequest\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleData\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleTransactionID\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TransactionID\\\\\\&quot;:\\\\\\&quot;15887\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TimeStamp\\\\\\&quot;:\\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t\\\\t},\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;PaymentTransaction\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;AmountsReq\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;Currency\\\\\\&quot;:\\\\\\&quot;EUR\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;RequestedAmount\\\\\\&quot;:10.99\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t\\\\t},\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;PaymentData\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;CardAcquisitionReference\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TransactionID\\\\\\&quot;:\\\\\\&quot;oLkO001528797935000\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TimeStamp\\\\\\&quot;:\\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t}\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;You receive a response that includes an &lt;code&gt;AdditionalResponse&lt;\\\/code&gt; object, with a base64-encoded string that you need to decode to get a JSON object, or a string of form-encoded key-value pairs. In our examples, we use form-encoded key-value pairs.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Payment response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t  \\\\\\&quot;SaleToPOIResponse\\\\\\&quot;:{\\\\n\\\\t    \\\\\\&quot;MessageHeader\\\\\\&quot;:{...},\\\\n\\\\t    \\\\\\&quot;PaymentResponse\\\\\\&quot;:{\\\\n\\\\t      \\\\\\&quot;POIData\\\\\\&quot;:{\\\\n\\\\t        \\\\\\&quot;POITransactionID\\\\\\&quot;:{\\\\n\\\\t          \\\\\\&quot;TransactionID\\\\\\&quot;: \\\\\\&quot;oLkO0012498220087567.991517998212382C\\\\\\&quot;\\\\n\\\\t        },\\\\n\\\\t        ...\\\\n\\\\t      },\\\\n\\\\t      \\\\\\&quot;Response\\\\\\&quot;:{\\\\n\\\\t        \\\\\\&quot;Result\\\\\\&quot;:\\\\\\&quot;Success\\\\\\&quot;,\\\\n           \\\\\\&quot;AdditionalResponse\\\\\\&quot;:\\\\\\&quot;...alias=M469509594859802...\\\\\\&quot;\\\\n\\\\t      },\\\\n\\\\t      ...\\\\n\\\\t    },\\\\n\\\\t    \\\\\\&quot;PaymentReceipt\\\\\\&quot;:{...}\\\\n\\\\t  }\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;If the transaction is successful, update the customer&#039;s loyalty balance in your database to reflect their purchase.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;div class=\\&quot;notices blue\\&quot;&gt;\\n&lt;p&gt;You may also want to use a &lt;a href=\\&quot;\\\/point-of-sale\\\/shopper-engagement\\\/display-data\\\/display-receipt\\\/\\&quot;&gt;\\n  &lt;code&gt;DisplayRequest&lt;\\\/code&gt;\\n&lt;\\\/a&gt; to present a message on the terminal screen, welcoming them to your loyalty program, informing them of their points balance, or congratulating them on their loyalty reward.&lt;\\\/p&gt;\\n&lt;\\\/div&gt;\\n&quot;,&quot;altTitle&quot;:null,&quot;oldTabId&quot;:1,&quot;relation&quot;:&quot;&quot;},{&quot;title&quot;:&quot;Asynchronous&quot;,&quot;content&quot;:&quot;\\n&lt;h3&gt;Asynchronous in-person loyalty&lt;\\\/h3&gt;\\n&lt;p&gt;As a simpler way of integrating payment-linked loyalty, you may prefer to use the data you receive in webhooks. You then make all loyalty adjustments retrospectively. This is done by receiving a webhook event, plugged directly into your CRM.&lt;\\\/p&gt;\\n&lt;p&gt;This requires less integration work, but this means that you will not be able to present real-time information to your customer while they are in your store (for example, to inform them of their loyalty balance, or let them know they are due for a reward). By using this flow, you will need to figure out a way of giving the customer a way of registering for your loyalty program, and recording this in your customer database.&lt;\\\/p&gt;\\n&lt;div class=\\&quot;notices green\\&quot;&gt;\\n&lt;p&gt;You need to &lt;a href=\\&quot;\\\/development-resources\\\/webhooks\\\/webhook-types\\\/additional-settings\\&quot;&gt;enable receiving the &lt;code&gt;alias&lt;\\\/code&gt;&lt;\\\/a&gt; of the shopper&#039;s card in the &lt;code&gt;additionalData&lt;\\\/code&gt; of your webhook. You need the &lt;code&gt;alias&lt;\\\/code&gt; to update the loyalty points in your system for the shopper&#039;s loyalty account.&lt;\\\/p&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;To implement an asynchronous flow:&lt;\\\/p&gt;\\n&lt;ol&gt;\\n&lt;li&gt;\\n&lt;p&gt;Make a POST request from your POS app to &lt;a href=\\&quot;\\\/point-of-sale\\\/basic-tapi-integration\\\/make-a-payment\\&quot;&gt;initiate the payment&lt;\\\/a&gt;. If you are creating a profile for a new customer, also include parameters described in the &lt;a href=\\&quot;\\\/unified-commerce\\\/loyalty-program\\\/create-profiles#create-profile-from-point-of-sale-payment\\&quot;&gt;Create customer profiles&lt;\\\/a&gt;) documentation.&lt;\\\/p&gt;\\n&lt;p&gt;Here is how you can make a &lt;strong&gt;EUR&amp;nbsp;10.99&lt;\\\/strong&gt; payment for a &lt;em&gt;known&lt;\\\/em&gt; customer.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Terminal API request&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t\\\\t\\\\\\&quot;SaleToPOIRequest\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\\\&quot;MessageHeader\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;ProtocolVersion\\\\\\&quot;:\\\\\\&quot;3.0\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageClass\\\\\\&quot;:\\\\\\&quot;Service\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageCategory\\\\\\&quot;:\\\\\\&quot;Payment\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;MessageType\\\\\\&quot;:\\\\\\&quot;Request\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleID\\\\\\&quot;:\\\\\\&quot;POSSystemID12345\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;ServiceID\\\\\\&quot;:\\\\\\&quot;0207111105\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;POIID\\\\\\&quot;:\\\\\\&quot;V400m-324688179\\\\\\&quot;\\\\n\\\\t\\\\t\\\\t},\\\\n\\\\t\\\\t\\\\t\\\\\\&quot;PaymentRequest\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleData\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;SaleTransactionID\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TransactionID\\\\\\&quot;:\\\\\\&quot;15887\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;TimeStamp\\\\\\&quot;:\\\\\\&quot;2019-12-04T12:02:49.000Z\\\\\\&quot;\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t\\\\t},\\\\n\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;PaymentTransaction\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;AmountsReq\\\\\\&quot;:{\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;Currency\\\\\\&quot;:\\\\\\&quot;EUR\\\\\\&quot;,\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t\\\\t\\\\\\&quot;RequestedAmount\\\\\\&quot;:10.99\\\\n\\\\t\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t\\\\t}\\\\n\\\\t\\\\t}\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;p&gt;If the payment was successful, you receive a payment response containing &lt;code&gt;Result&lt;\\\/code&gt; &lt;span translate=\\&quot;no\\&quot;&gt;&lt;strong&gt;Success&lt;\\\/strong&gt;&lt;\\\/span&gt;.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;Payment response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;\\\\t{\\\\n\\\\t  \\\\\\&quot;SaleToPOIResponse\\\\\\&quot;:{\\\\n\\\\t    \\\\\\&quot;MessageHeader\\\\\\&quot;:{...},\\\\n\\\\t    \\\\\\&quot;PaymentResponse\\\\\\&quot;:{\\\\n\\\\t      \\\\\\&quot;POIData\\\\\\&quot;:{\\\\n\\\\t        \\\\\\&quot;POITransactionID\\\\\\&quot;:{\\\\n\\\\t          \\\\\\&quot;TransactionID\\\\\\&quot;: \\\\\\&quot;oLkO0012498220087567.991517998212382C\\\\\\&quot;\\\\n\\\\t        },\\\\n\\\\t        ...\\\\n\\\\t      },\\\\n\\\\t      \\\\\\&quot;Response\\\\\\&quot;:{\\\\n\\\\t        \\\\\\&quot;Result\\\\\\&quot;:\\\\\\&quot;Success\\\\\\&quot;,\\\\n\\\\t        \\\\\\&quot;AdditionalResponse\\\\\\&quot;:\\\\\\&quot;...aliasA37317672402294...\\\\\\&quot;\\\\n\\\\t      },\\\\n\\\\t      ...\\\\n\\\\t    },\\\\n\\\\t    \\\\\\&quot;PaymentReceipt\\\\\\&quot;:{...}\\\\n\\\\t  }\\\\n\\\\t}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;After the payment has been processed, Adyen sends a &lt;a href=\\&quot;\\\/point-of-sale\\\/design-your-integration\\\/notifications\\\/standard-notifications\\\/#standard-webhook\\&quot;&gt;webhook event&lt;\\\/a&gt; to your server.&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;AUTHORISATION webhook&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n\\\\\\&quot;notificationItems\\\\\\&quot;:[\\\\n   {\\\\n      \\\\\\&quot;NotificationRequestItem\\\\\\&quot;:{\\\\n         \\\\\\&quot;additionalData\\\\\\&quot;:{\\\\n            ...\\\\n            \\\\\\&quot;shopperInteraction\\\\\\&quot;:\\\\\\&quot;POS\\\\\\&quot;,\\\\n            \\\\\\&quot;alias\\\\\\&quot;:\\\\\\&quot;A37317672402294\\\\\\&quot;,\\\\n         },\\\\n         \\\\\\&quot;amount\\\\\\&quot;:{\\\\n            \\\\\\&quot;currency\\\\\\&quot;:\\\\\\&quot;EUR\\\\\\&quot;,\\\\n            \\\\\\&quot;value\\\\\\&quot;:10.99\\\\n         },\\\\n          ...\\\\n         \\\\\\&quot;eventCode\\\\\\&quot;:\\\\\\&quot;AUTHORISATION\\\\\\&quot;,\\\\n         \\\\\\&quot;merchantAccountCode\\\\\\&quot;:\\\\\\&quot;YOUR_MERCHANT_ACCOUNT\\\\\\&quot;,\\\\n         \\\\\\&quot;merchantReference\\\\\\&quot;:\\\\\\&quot;YOUR_REFERENCE\\\\\\&quot;,\\\\n         \\\\\\&quot;pspReference\\\\\\&quot;:\\\\\\&quot;882589522806623K\\\\\\&quot;,\\\\n         \\\\\\&quot;success\\\\\\&quot;:\\\\\\&quot;true\\\\\\&quot;\\\\n      }\\\\n   }\\\\n]}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&lt;\\\/li&gt;\\n&lt;li&gt;\\n&lt;p&gt;In your loyalty system database, update the loyalty points in your record for the shopper with the &lt;code&gt;alias&lt;\\\/code&gt; from the webhook.&lt;\\\/p&gt;\\n&lt;\\\/li&gt;\\n&lt;\\\/ol&gt;\\n&lt;p&gt;After you have adjusted their loyalty points, you may want to reach out to the customer (using an app, email, or other communication) to let them know their new points balance, or if they are eligible to redeem a reward.&lt;\\\/p&gt;\\n&quot;,&quot;altTitle&quot;:null,&quot;oldTabId&quot;:1,&quot;relation&quot;:&quot;&quot;}]\"\n            :should-update-when-url-changes='false'>\n        <\/tabs>\n    <\/div>\n<\/div>\n","url":"https:\/\/docs.adyen.com\/unified-commerce\/loyalty-program\/payment-linked-loyalty","articleFields":{"description":"Offer a loyalty program without a separate loyalty card or app.","feedback_component":true,"filters_component":false,"decision_tree":"[]","page_id":"b47711e9-13e6-4ab4-8af1-493c49212fd9","last_edit_on":"01-10-2024 17:11"},"algolia":{"url":"https:\/\/docs.adyen.com\/unified-commerce\/loyalty-program\/payment-linked-loyalty","title":"Payment-linked loyalty program","content":"You can use customer recognition to make your existing loyalty program more frictionless for your customers by removing the need for a traditional loyalty card or app. In this tutorial, we'll explain how you can link your loyalty system to their customer profile. When they make a payment in your online or physical store, you can automatically recognize them, and award them with points, discounts, or a reward.\nWhen you offer a payment-linked loyalty, you also give your customers an extra incentive to provide you their contact details, which you can also use to create a customer profile.\nRequirements\nTo use payment-linked loyalty, make sure that:\n\nYou can already create customer profiles and recognize returning customers across your sales channels.\nYou have a loyalty system that keeps track of customer registration, as well as other data such as points balance and rewards eligibility.\n\nOnline loyalty\nWhen your customer makes a purchase in your web or in-app store, attempt to recognize them, and check whether they have already enrolled in your loyalty program.\nFrom here, you can either ask them to register for your loyalty program, or check whether they are eligible for a loyalty reward, before continuing with the transaction.\nStep 1: Recognize customer\nBefore making a purchase, your customer will provide you with their contact details, such as an email address or phone number (for example, when creating or signing in to their account, or through your guest checkout).\nTo recognize whether this is a returning customer:\n\nCheck whether their contact details match a shopperEmail that you have stored in your customer database.\n\nIf the email matches, they are a returning customer. Proceed to the next step to get their loyalty rewards points.\nIf the email is not your database, proceed to step 3 to continue the payment. In the payment request, you might want to include other parameters to create a customer profile for them.\n\n\nStep 2: Request customer input\nAfter you have determined if they are a returning customer, query your loyalty system database using the shopperEmail and check their loyalty program status. Next, present a relevant message in your UI:\n\nIf they are not a member of your loyalty program, this message should ask them to register.\nIf they are already a member, you could inform them how close they are to receiving a reward or, if they have enough points, ask them whether they want to redeem their reward.\n\nStep 3: Continue with payment\nContinue with the purchase by initiating a payment. Here is how you can make a payment for a customer shopperEmail john_smith@example.com with a correspondingshopperReference ShopperID-A16729.\n\n\nMake a POST  \/payments\u00a0request.\n\n\n\nThe response includes:\n\npspReference: our unique identifier for this payment.\nresultCode: Authorised\n\nThe following example shows a successful response with a PSP reference of 881468919096134D.\n{\n    \"pspReference\": \"881468919096134D\",\n    \"resultCode\": \"Authorised\"\n}\n\n\nIn your loyalty system database, update the loyalty points in your record forshopperEmail john_smith@example.com.\n\n\nWhen you have set up a loyalty system for your online transactions you can do the same for in-person transactions.\nIn-person loyalty\nThere are two flows you can use to perform payment-linked loyalty using your point-of-sale integration.\n\n\nSynchronous:  using data you receive from Adyen before the payment is initiated.\nWith this flow, you use the data that you receive from Adyen to query your loyalty system database. You then present loyalty information, such as a points balance or a personalized message, to your customer while they are making their purchase.\n\n\nAsynchronous: using data you receive from a webhook after the payment has been processed.\nThis flow requires less integration work, but you will not be able to present real-time loyalty information to your customer. You update your loyalty system at a later time with the information that you receive from webhooks.\n\n\nTo implement any of these flows, select a tab below:\n\n\n    \n        \n        \n    \n\n","type":"page","locale":"en","boost":17,"hierarchy":{"lvl0":"Home","lvl1":"Omnichannel","lvl2":"Shopper loyalty","lvl3":"Payment-linked loyalty program"},"hierarchy_url":{"lvl0":"https:\/\/docs.adyen.com\/","lvl1":"https:\/\/docs.adyen.com\/unified-commerce","lvl2":"https:\/\/docs.adyen.com\/unified-commerce\/loyalty-program","lvl3":"\/unified-commerce\/loyalty-program\/payment-linked-loyalty"},"levels":4,"category":"Omnichannel","category_color":"green","tags":["Payment-linked","loyalty","program"]}}
