For many years, REST has been the standard pattern for designing APIs. Whilst it has many benefits, REST has been proven to be relatively inflexible and doesn’t stand up well when client requirements change. GraphQL is an alternative approach which addresses these flexibility issues.
GraphQL is a relatively new API design pattern that can be used as an alternative to the traditional REST API. It was built by Facebook and has powered their mobile apps since 2012. Facebook open-sourced it in 2015 and the pattern has steadily gained usage and popularity in the industry in order to feed data to web and mobile clients.
Here at The Distance, we’ve started to use GraphQL in our most recent projects and our developers have seen the huge benefits in using it to get data to our mobile apps in the most efficient way possible. In this blog post, we’ll take a quick overview of GraphQL, look at its pros and cons and the excellent tooling available.