Display Information

This guide shows how to display information to your customers using the card reader screen.

Getting StartedAnchorIcon

The following Graph QL API mutations can be used to display text on the reader screen for your customers. This can be used for a range of business logic from displaying cart items, showing a shipping address confirmation (Note: you can also leverage Custom Prompts for a more automated version of this), or even a plain text welcome message.

Information Displays will not block subsequent reader interactions, meaning you can make repetitive display requests without first canceling a previous one. You can also make a requestChargeFromInStoreReader call while the reader is displaying information, and it will transition into a checkout flow.

The response of these API requests will include a contextId which can be used to cancel the information display.

note

Information Display requests will stay on the screen for 120 seconds or until canceled or overwritten by a subsequent reader interaction.

Request Text DisplayAnchorIcon

This mutation will allow you to push plain text to the screen. This could be used for something like a shipping address confirmation, as shown in the below picture. The Braintree GraphQL API docs contain additional information about character limitations and formatting your request Text Display mutation.

note

Up to 255 characters of text can be displayed using this mutation

note

As of version 5.2.0 requestTextDisplay now supports the title, alignment, waitForNextRequest, displayTimeoutAPI variable fields

This example image includes the title variable which is supported as of version 5.2.0
  1. GraphQL Mutation
  2. GraphQL Variables
  3. Sample API Response
mutation RequestTextDisplayFromInStoreReader($input: RequestTextDisplayFromInStoreReaderInput!) { 
              requestTextDisplayFromInStoreReader(input: $input) { 
                  clientMutationId 
                  id 
                  reader { 
                     id 
                     name
                     status 
                  } 
                  status 
              } 
          }

Request Line Item DisplayAnchorIcon

This mutation can be called each time the POS software adds an item to display the running cart totals to the customer.

As items are added, a scrolling container will automatically move to keep the most recently added items in view.

Adding new items to the display will require the POS to send all items in the cart and new running totals after each update.

note

Up to 249 items can be displayed using this mutation.

note

The displayItems are used for display formatting purposes only and are not passed downstream to the processors or saved in relation to the transaction. All calculations must be performed on the POS. Additional information about character limitations and formatting your mutation can be found in our Braintree GraphQL API docs.

  1. GraphQL Mutation
  2. GraphQL Variables
  3. Sample API Response
mutation RequestItemDisplayFromInStoreReader($input: RequestItemDisplayFromInStoreReaderInput!) { 
              requestItemDisplayFromInStoreReader(input: $input) { 
                  clientMutationId 
                  id 
                  reader { 
                      id 
                      name 
                      status
                  } 
                  status 
              } 
          }

Cancel Information DisplayAnchorIcon

This mutation will allow you to cancel an information display and return to the screensaver.

  1. GraphQL Mutation
  2. GraphQL Variables
  3. Sample API Response
mutation RequestCancelFromInStoreReader(
              $input: RequestCancelFromInStoreReaderInput!
            ) {
              requestCancelFromInStoreReader(input: $input) {
                id
                status
                reader {
                  id
                  name
                  status
                }
              }
            }