Applies to: Terminal API
Learn how to link multiple actions for screen workflows and dismiss actions that are running on the Square Terminal.
With Terminal actions, you can configure a screen workflowawait_next_action
parameter and set it to true
in a CreateTerminalAction
This parameter instructs the Square Terminal to present a modal window with a "Please wait" message after a buyer completes an action. This window allows the Square Terminal to transition to the next action request and display the screen.
If the Square Terminal doesn't receive a follow-up CreateTerminalActionawait_next_action_duration
parameter, which has a default value of 5 minutes.
If you need to dismiss the "Please wait..." screen without waiting for the duration deadline of the action request to elapse, you can call the DismissTerminalAction200
response and dismisses the waiting screen if the Square Terminal is presenting it. If the buyer has already dismissed the waiting screen, the Square Terminal ignores the DismissTerminalAction
action request.
When you call the DismissTerminalAction
- If the currently running action is
IN-PROGRESS
for screen action types that take buyer information, the Square Terminal cancels the action and returns to the idle screen. - If the currently running action for the QR code screen is
IN-PROGRESS
, the Square Terminal completes the action and returns to the idle screen. - If the currently running action is
PENDING
, the Square Terminal cancels the action. - If the currently running action has completed its operation (has the
COMPLETED
status) and the Square Terminal shows the “Please wait...” screen (withawait_next_action parameter
=true
), the Square Terminal dismisses the waiting screen and returns to the idle screen.
The DismissTerminalAction
- Use DismissTerminalAction
DismissTerminalAction if your goal is to clear the screen and allow the Terminal APITerminal API to resolve an ongoing action. - Use CancelTerminalAction
CancelTerminalAction if your goal is to cancel an action.