It normally takes about a second or so for the payment panel to display. There have been a small number (< 2%) of users reported that they do not see the panel on their first page visit. In all of those cases, if the users refresh the page then the payment panel is shown. In order to better handle those particular cases, I would like to be able to accomplish the below:
Check if payment panel has been successfully constructed and shown on page. If it has not then advise user to refresh the page.
In the try catch block, parse the API errors and provide user with customized messages.