12/09/16

It’s a Wonderful Integration

As part of the larger Mercury Theatre website project, I was tasked with integrating the Spektrix booking system with our WordPress build. This involved importing data from Spektrix into WordPress as a custom post type, which had to run every 15 minutes to keep the systems in sync. Obviously, the main areas of focus for us were security, performance and flexibility.

Security is a very important aspect of using the Spektrix API. We achieved this by making sure our code adhered to best practices and for us to enforce HTTPS connections throughout the site. Spektrix also uses a very secure verification system, which ensures their API can’t be used in an unrecognised or unsecured environment.

At first, I started using WordPress functions to add, remove and edit posts. Usually, this would be the best approach, but in this situation after testing the script execution time, we could vastly improve performance by writing our own SQL queries. This also gave me the flexibility to do more specific queries that would improve the flexibility of the importer.

It’s always our understanding at Fever that people make mistakes and we always write our code to account for this. We had a lot of discussions about every possible user error that could occur and made sure our importer would deal with this. A basic example of this would be if there were two events with the same title. Our script needed to be able to recognise that it’s a new event and for it to be given a unique URL suffix so it does not conflict on the front-end of the website.

We also had the task to restyle all the Spektrix iframes through the site. This was quite a challenge because we had no control over the output of the HTML. This meant we had to be quite creative with our CSS in order to match Mercury Theatre’s aesthetics and for them to work as well as possible on mobile devices. We were especially happy with what we managed to achieve with the donations iframes, which were the focus of many discussions in our Development team.

Emily Childs, Senior Support Consultant from Spektrix dropped us a little message to say:

“I love it! I’ve already shared the new Mercury Rising page with the wider Spektrix team as a wonderful example of a creative, dynamic capital campaign page. The rest of the site looks great too!”

The new Mercury Theatre website launched on Monday 6th September, and can be viewed here. If you need a creative agency with a strong technical ability to help integrate your website with third-party systems and API’s, please contact us to discuss.

We are extremely happy with the Spektrix integration and we hope you enjoy the user experience as much as we have enjoyed building Mercury Theatre’s new website.