MyTicket Events WordPress plugin comes with free Android Application that is available on Play Market. It allows you to validate tickets with printed QR-code on it. Tickets are PDF printouts that can be customized according to your needs.
How Does the Application Work?
When the application scans the QR-code that is generated by MyTicket Events plugin it gets a list of parameters that includes order ID numbers and the link to your server’s API. The app does not use any third party backend to validate or send information to even though it hosts multiple website owners across the globe.
All the information is transmitted exclusively between the app and your website backend. Important to note that it supports both http and https secured protocols for data exchange. You need to make sure your website uses encrypted connection for data protection.
How to Restrict Application Access?
While the application is hosted globally you can easily restrict access and only allow certain devices to view and validate ticket data hosted on your website. Each application instance has its own unique ID string that can be copied from app’s main settings screen. Refer to the image below.
This ID has to be copied to Appearance > Customizer > MyTicket > Mobile App > Allowed App IDs list section of your WordPress admin. Note that Private access checkbox has to be ticked. Separate each ID by new line. Make sure there are no dots or whitespaces.
How to Validate Tickets?
Once the MyTicket plugin is installed, first PDF ticket is set up and MyTicket Scanner app is installed simply scan the QR-code by attaching your phone’s camera to the code while the app is open. Once scanned you will have popup window with a ticket details including order ID number, attendees name, event title and other useful information.
Note that you can check statuses of your order under orders section of your WordPress admin immediately after app validated or un validated the ticket. The app does not store this information internally. This removes the risk of conflicts when multiple applications used simultaneously.
App does not scan tickets, nothing happens
Most likely the issue comes from your server side. When application tries to retrieve ticket data it can not connect to your server. Make sure that your server is publicly accessible from the Internet.
For example, below is the link where queries are sent. Replace ticketing.as.kenzap.com with your website url. Put appropriate http or https protocol and paste the url into your browser. The response should be “0” which means everything is working fine.
Error 500 or Blank Page
In case you have a blank page this indicates that your server has some internal failure processing the request. Usually this is indicated by error 500 or 501 code. To know what exactly causes this enable WordPress debug logging.
Sometimes the app responds with error 404 code which means that server rejects the response. This might be due to one of the following reasons:
- Your website is password protected and is not publicly accessible from the Internet
- Your server security configuration blocks Ajax requests
- You have restriction application ID restriction set under Appearance > Customizer > MyTicket section.
Next step is to actually send some ticket data to your server. While the url may work properly some methods processing ticket data may fail only when certain parameters are sent. For this purpose you need to create HTTP POST request and send additional data to your server.
There are many application that may help you do this. The screenshot below is from the application called Postman.
When this request is sent the proper response should contain complicated order structure stored in JSON format.
How to Improve Scanning Speed of the Application?
The common assumption here is that scanning speed depends on something that relates to QR-code decoding algorithm. In fact, the scanning itself is quite fast and takes no more than 100ms even on slow Android devices. The main bottleneck here is the quality of your network connection and latency.
Every time the QR-code ticket is scanned the app makes new query to your website’s database to retrieve the latest information about the ticket and its status. This step is mandatory because it ensures that no conflicts happen in case multiple application instances are used and the date is kept synchronized in live with your website server.
First, verify that your Internet connection is fast and stable. Note that Internet speed does not mean latency. Second, insure that latency is reduced to minimum. The latency here means the delay needed for the request to physically travel from your device to your server and come back with the data.
For example, if you server is hosted in Netherlands but your app scans tickets in Johannesburg there is an additional network delay of 250 milliseconds or 1/4 of a seconds.
On top of that your server may also be slow on processing the query. So you need to make sure there are no delays on your server side as well. Usually shared hosting with limited resources perform slower.