Testing REST Pay flows (US)

The following sections provide steps to confirm that your integration properly processes the transactions required for the US region. The video of each transaction lets Clover see that the entire payment flow is handled correctly by the POS.

Preparing to test

Make sure you have the test card provided with your Clover Dev Kit. Use the test card to:

  • Test each flow with the test card and ensure your application processes the payment as expected.
  • Complete the tests required for Clover approval.

If you want to test chip and NFC functionality, purchase the test cards from B2.

Card type

Format

Number

Response

Discover

Plastic

6011 3610 0000 6668

Success

Configuring signature settings

To confirm that your application handles signatures correctly during the tests, your Clover device must be set to take the signature on the screen.

  1. On the Clover device, open the Setup app.
  2. On the sidebar, tap Payments.
  3. In the Signature Settings section, tap Signature entry location, and verify On tablet screen is selected.
  4. Tap Save.
  5. Tap Signature Requirement and verify Always require signature is selected.
  6. Tap Save.
    The signature settings are configured.

Testing the payment flows

If your integration supports all of the REST Pay payment flows, your app approval requires that each of the following tests are successfully completed. Integrations supporting a subset of transaction types can skip the tests that do not apply.

🚧

IMPORTANT

When filming your tests, ensure both the POS and Clover device are in frame during the entire video.

Test #1: Sale with no tipping and emailed receipt

The following sample shows the minimal effective request for this test:

{
  "amount": 5100,
  "receipt_email": "[email protected]",
  "externalPaymentId": "{externalPaymentId}"
}
  1. (POS) Create a charge in the amount of $51.00.
  2. (Clover) Swipe card number 6011 3610 0000 6668 (Discover, plastic).
  3. (Clover) On the Select Account screen, tap Credit.
  4. (Clover) On the Add Signature screen, draw a line, and tap Done.
    The payment is processed with no tipping option displayed. The transaction receipt is sent to the specified email address.

Test #2: Refund a transaction

The following sample shows the minimal effective request for this test:

{
  "fullRefund": true
}
  1. (POS) Select the sale transaction from the first test.
  2. (POS) Refund the full amount of the sale.
  3. (Clover) On the Need a receipt screen, tap No receipt.
    The refund is complete.

Test #3: Sale with tip

This test replicates the payment flow for quick service restaurants and other merchants that ask the customer for a tip before the card is presented. The POS should indicate that the total is updated with the tip amount.

The following sample shows the minimal effective requests for this test. The test also assumes you are not passing custom tipSuggestions in the request and the device is configured to use the default tip settings.

//request #1 (tip)
{
  "baseAmount": 5100
}

//request #2 (payment)

{
  "amount": 5865,
  "receipt_email": "[email protected]",
  "externalPaymentId": "{externalPaymentId}"
}
  1. (POS) Create a tip request for the baseAmount of $51.00.
  2. (Clover) On the Add a Tip screen, tap 15%.
  3. (POS) Create a charge in the amount of $58.65.
  4. (Clover) On the Sale screen, verify the transaction total includes the tip.
  5. (Clover) Swipe card number 6011 3610 0000 6668 (Discover, plastic).
  6. (Clover) On the Select Account screen, tap Credit.
  7. (Clover) On the Add Signature screen, draw a line, and tap Done.
    The sale is complete and the transaction receipt is sent to the specified email address.

Test #4: Auth with tip adjustment

This test replicates the payment flow used for full service restaurants and other merchants that ask the customer for a tip after the card is authorized for an amount. The POS should indicate that the total is updated with the tip amount.

The following sample shows the minimal effective requests for this test.

//request #1 (uncaptured payment)
{
    "amount": 5100,
    "capture": false
}

//request #2 (receipt)
{
  "deliveryOption": {
    "method": "PRINT"
  }
}

//request #3 (tip adjustment)
{
    "tipAmount": {tipAmount}
}
  1. (POS) Create an auth in the amount of $51.00.
  2. (Clover) Swipe card number 6011 3610 0000 6668 (Discover, plastic).
  3. (POS) Create a receipt request and print the receipts.
    The device prints a receipt with a space for the tip and total amounts that the customer needs to write.
  4. (POS) Create a charge capture request for the final amount.
    The transaction is updated with the tip amount and the transaction is finalized at closeout.

Test #5: Pre-auth

This test replicates the payment flow used for hotels, car-rental agencies, and other merchants that require a pre-authorized card.

The following sample shows the minimal effective requests for this test.

//request #1 (pre-authorization)
{
  "amount": 5100,
  "capture": false
}

//request #2 (capture)
{}
  1. (POS) Create and send a pre-auth in the amount of $51.00.
  2. (Clover) Swipe card number 6011 3610 0000 6668 (Discover, plastic).
  3. (POS) Create and send a charge capture request with an empty body to capture the authorized amount.
    The transaction is processed for the final amount.

Test #6: Pre-auth with total adjustment

This test replicates the payment flow used for hotels, car-rental agencies, and other merchants that require a pre-authorized card. In contrast to the previous test, this test displays your application can properly submit a capture request for a different amount than initially pre-authorized.

The following sample shows the minimal effective requests for this test.

//request #1 (pre-authorization)
{
  "amount": 5100,
  "capture": false
}

//request #2 (capture)
{
  "amount": 5610
}
  1. (POS) Create and send a pre-auth in the amount of $51.00.
  2. (Clover) Swipe card number 6011 3610 0000 6668 (Discover, plastic).
  3. (POS) Create and send a charge capture request for 10% more than the original amount (5610).
    The transaction is processed for the final amount.

Did this page help you?