A weekly newsletter of the best news, articles and projects about GraphQL


How to Build a GraphQL API Using Laravel

In this article, Tamerlan Gudabayev walks through how to set up your own GraphQL API using PHP and Laravel. Tamerlan covers migrations and models, seeding a database, defining types, schemas, mutation classes, and more. Follow along to learn more about how to use GraphQL with PHP using Laravel.

How to Build a Task Manager Application Using React, Airtable and GraphQL

Jesus Manuel Olivas recently prototyped a low-code proof-of-concept using React, Airtable, BaseQL, GraphQL and ClerkDev. In this article, Jesus walks through the setup and how to tie all the pieces together. Follow along to learn more about how to use GraphQL in a low-code context.

Polyglot persistence for PostgreSQL & MySQL using GraphQL & TypeScript

Should you use PostgreSQL or MySQL for your next project? Are you moving cloud providers and don't have both options available? Maybe you'd like to start with one option and be able to make the switch later on. Why decide now when you can have both options without any tradeoffs?


What happens if we treat GraphQL Queries as the API definition?

When you ask someone about their API definition in the context of GraphQL, the obvious answer is "the Schema". But what if instead, we use GraphQL Queries as the API definition?

GraphQL: cloud to autonomous yard truck connectivity

More and more GraphQL usage is showing up in applications everywhere as developers recognize the benefits over developing REST and other HTTP-based APIs. However, due to its relatively young age, it lacks a broad range of support across toolkits and libraries. This makes it harder to adapt legacy applications or clients to this new way of communicating. At Outrider, we’re modernizing a critical step in the supply chain and at the same time modernizing communication channels by encouraging the use of our GraphQL API. These integrations enable a live and holistic view into yard operations, in which historically data has been stale and siloed.

The GraphQL Spec, Simplified

The GraphQL Spec, Simplified is a 3-part series starting with the query language, including definitions of the document, operations, selection sets, named and inline fragments, built-in directives, and more. Follow along with Loren Sands-Ramshaw to learn more about the GraphQL spec in an easy-to-understand way.

Making Dgraph a truly GraphQL-native database

From a time of no GraphQL support, to supporting GraphQL natively with as good speed as DQL, Dgraph has improved a lot in the past year. If you compare the v21.03 release with the v20.03 release, you would find that your GraphQL queries are magically ~33% faster. In this article, Abhimanyu Singh Gaur talks about how Dgraph is now a truly GraphQL-native database and why it matters for performance.


GraphQL vs REST—Can GraphQL replace REST?

While REST has been (and still is) a popular way of exposing data to applications, the growing complexity and evolution of development has made it less viable in a range of scenarios. In this post, Abu Sakib talks about how GraphQL can be a suitable replacement for REST and be a game-changer in the API ecosystem. Follow along with Abu to find out more about how GraphQL can replace REST.

That single GraphQL issue that you keep missing

With the increasing popularity of GraphQL, it's important to think about security vulnerabilities. GraphQL implementations are often affected by CSRF. In this article, Tomasz Swiadek and Andrea Brancaleoni go in-depth on how GraphQL is vulnerable to CSRF attacks and what can be done to solve it. Follow along to find out more about the vulnerabilities that might exist in your GraphQL app and how you can protect them.


The most powerful GraphQL Client for the web in just 2kb

Over the last couple of years, we've seen a constant evolution of GraphQL tooling. Developers try to get the maximum out of the constraints they've set for themselves. WunderGraph breaks with these rules to make room for something new. This post describes how the next generation of GraphQL clients change the way we can think about GraphQL as a technology.

GraphQL requests made easy with React Query and TypeScript

Given on a GraphQL schema, we can automatically create TypeScript types for the entire API on the frontend. What’s more is we can easily autogenerate fully-typed custom React hooks for a data-fetching library like React Query. In this article, Iva Kop shows how to set up a GraphQL project with TypeScript and React Query and demonstrates how to autogenerate types.

Stored Procedures, ORMs, and GraphQL

In this article, Steve Smith provides the background and history of ORMs and stored procedures and makes the case that GraphQL is really a new kind of ORM. He goes into detail about thick/smart clients, how APIs serve as stored procedures, and more.

Demystifying GraphQL Queries

In this tutorial, Jaden Baptista provides an overview of what GraphQL is and how it compares to REST. Jaden goes into detail about types, queries, and more to show how GraphQL isn't magic once it's understood. Follow along with Jaden to learn more about GraphQL from the ground up.

5 Headless CMS That You Can You Use To Distribute Content Freely

Lahaul Seth has put together a list of five headless content management systems that can be used for free. GraphQL can be used with many of those listed, including Strapi, Graph CMS, and Sanity. Check out the list for more information on these great free options and choose one for your next project.


Announcing the Neo4j GraphQL Library: Build Low-Code GraphQL APIs Faster

Neo4j has just announced the general availability of the Neo4j GraphQL Library. The library is extensible, low-code, and open source and is designed for building API-driven, intelligent applications faster by tapping into the power of connected data. Read the announcement article to learn more about Neo4j and how to use it in GraphQL with their Neo4j GraphQL Library.

Supercharging file-based content with GraphQL

Tina GraphQL gateway brings reliability to Git-based content management. It acts as an essential piece to provide robust structured content while allowing for portability. In this article, Jeff See demonstrates how to create a blog with Next.js and GraphQL using Tina GraphQL gateway. Follow along to find out more about how you can use your filesystem as a CMS with confidence.

I built a chat app using React and GraphQL

In this tutorial, Abdou Ouahib shows how to build a realtime chat application using React and GraphQL. The front end technologies used include Redux, MaterialUI, and Apollo Client. On the backend, Abdou uses Node, Apollo Server, TypeGraphQL, and PostgreSQL. The app features include user authentication, profiles, friends, notifications, and more.

Graphql Exploitation - Part 2- Unauthorized Execution Of Queries

Like all APIs, those built with GraphQL are not immune to potential exploitation. GraphQL also has some unique features that open up attack vectors that must be considered for any real world app. In this follow-up article, Manmeet shows how unauthorized queries can be executed in GraphQL and how this and other vulnerabilities might be exploited. Follow along with Manmeet to learn more about how you can secure your GraphQL API.


TypeScript with GraphQL done right

Advanced types give your code and open-source libraries the power of providing an API that manipulates data (your application objects) without breaking the “types chain”. In this article, Charly Poly discusses how to get the most out of your React application types with GraphQL code generation and demonstrates how to reason about and make use of advanced types. Follow along with Charly to learn more about TypeScript, React, GraphQL, and how they all fit together.

Dgraph v21.03: Resilient Rocket Release

Dgraph has just announced version 21.03, its first release of 2021. The latest update to Dgraph's native GraphQL graph database includes Apollo federation, upsert mutations, lambda webhooks, and more. Check out the launch announcements to learn more about Dgraph's latest features and how you can use them today.

Nhost is an open source Firebase rival backed by GitHub’s founders

Nhost is an open source backend-as-a-service that serves as an alternative to Firebase and includes a real-time GraphQL API. The company has just announced a $3m round of funding led by Nauta Capital. The company is also backed by angel investors, including GitHub founders Scott Chacon and Tom Preston-Werner. Read more about Nhost's fundraising and how they intend to use it to expedite building out their product.

Connect Amplify DataStore with existing SQL datasources; adding offline and sync features in your application

Amplify DataStore is a library that provides a programming model for leveraging shared and distributed data without writing additional code for offline and online scenarios. With the Amplify CLI, you can easily set up a new application that leverages AWS AppSync and sets up Amazon DynamoDB to power your DataStore application. In this article, Rene Brandel and Brice Pelle show how to use Amplify Datastore, including how to prepare the database, how to configure the backend with the Amplify CLI, and more. Follow along to learn more about AWS Amplify.


Releasing The GraphQL Guide

John Resig and Loren Sands-Ramshaw have just released <em>The GraphQL Guide</em>, a complete reference text for GraphQL. The guide is 886 pages and covers topics such as HTTP, testing, authentication, the GraphQL spec, client libraries, and much more. The authors have provided a 20% launch discount which is valid until April 25. Check out The GraphQL Guide to level up your GraphQL knowledge today.

HTTP caching in GraphQL

GraphQL doesn't come with any built-in support for server-side caching, an issue which often trips up GraphQL server developers. Although not officially supported, there are ways to accomplish HTTP caching with GraphQL. In this article, Leonardo Losoviz goes into detail about how to achieve server-side caching with GraphQL. He talks about accessing GraphQL via GET requests, using persisted queries, and more. Follow along with Leonardo to learn more about how to make your GraphQL servers more performant through caching.

GraphQL Tutorial for Server-Side Swift with Vapor: Getting Started

In this tutorial, Max Desiatov covers how to get started with GraphQL and Server-Side Swift using a concrete API as an example. Max shows how to build a TV show listing API from top to bottom and covers many details of GraphQL along the way, including how GraphQL differs from REST, how to declare model types, fields, queries, and mutations, and more. Follow along with Max to learn more about how to use GraphQL in a Swift app.


Databases, graphs, and GraphQL: The past, present, and future

GraphQL was never conceived as a query language for databases. Yet, it's increasingly being used for this purpose. This article by George Anadiotis explores how and where GraphQL fits in as a query language for databases, the projects and companies that are using it for that purpose, and what the tradeoffs are. Follow along with George to learn more about GraphQL as a query language for databases.

An Advanced GraphQL with Spring Boot and Netflix DGS

In this article, Piotr Minkowski demonstrates how to use the Netflix DGS library to simplify GraphQL development with Spring Boot. He shows advanced topics related to GraphQL and databases such as filtering or relationship fetching. Follow along with Piotr to learn more about how Netflix DGS and Spring Boot can be used together.

Weaviate is an open-source search engine powered by ML, vectors, graphs, and GraphQL

Weaviate is an API-based vector search engine with a graph data model that allows users to add data objects as graph nodes and (automatically or manually) add (machine learning) vectors to represent the nodes. Weaviate can be used for use cases ranging from similarity search to filtering out redundant information (i.e., deduplication) and from image search to enterprise NLP-based search.


How To Condense Your GraphQL Queries With the @materializer Directive

The @materializer directive is a custom directive by StepZen that helps GraphQL API developers reduce the amount of code they need to write. In this article, Lucia Cerchie demonstrates how to use the directive and how developers can benefit from it. Follow along with Lucia to find out more about how you can reduce the amount of code required for your GraphQL servers.

Reducing database queries to a minimum with Data Loaders

A data loader is an abstraction between application code and some backing store, such as a database, allowing batching of requests and caching. In this article by Sixfold, the data loader pattern is explored in more detail in context of Kafka consumers. Read on to learn more about data loaders, Kafka, and how they fit into a GraphQL application.

Forget REST. Here's How to Make a GraphQL API with Laravel

Lighthouse is a GraphQL framework that integrates GraphQL into Laravel applications. In this article, Lloyd Miller demonstrates how to use Lighthouse to expose a GraphQL API from a Laravel app. He covers the installation process, how to create database migrations, how to create a schema, and more. Follow along with Lloyd to learn more about how to use GraphQL in a Laravel app.


Build a Basic GraphQL Server with ASP.NET Core and Entity Framework in 10 Minutes

In this article, Rahul Rai shows how to build a GraphQL server using GraphQL, Autofac, EFCore and the repository pattern. The extensive tutorial goes through the setup process, how to create API models, how to set up a database, and more. Follow along with Rahul to learn more about how to use GraphQL with ASP.NET.

Top 7 GraphQL IDEs you should know about in 2021

The GraphQL ecosystem has grown dramatically since the technology's inception in 2012. IDEs are an important part of the GraphQL toolchain. In this blog post, Vishwa Mehta from Hasura goes through a list of the top 7 IDEs that you should know about in 2021. The list includes popular IDEs like GraphiQL, Insomnia, and Postman, but also includes lesser-known ones. Check out the list of the top 7 GraphQL IDEs to learn more about them and their benefits.

How I’m Developing My Full Stack Web App “With the Guards Up” By Using Apollo and GraphQL

Those familiar with bowling will no doubt have seen how the gutter can be inverted such that the ball is not able to go off track. In this article, Kieron Mckenna brings the analogy of bowling lane guards to app development as he walks through his approach to building full-stack apps "with the guards up". He talks about the problems that we often face when building out an API and a front end to access data from it and shows how we can benefit from tools like Apollo (Client and Server), GraphQL Code Generator, Prisma, and Typescript to make our lives easier.

Building a Realtime GraphQL Chat Application With SMS Notifications

With the emergence of GraphQL came a new way for developers to develop client/server applications. The benefits of developing GraphQL applications are numerous, from explicitly requesting what you need from the server to real-time event-driven communication through subscriptions. This article highlights code-first GraphQL and its superpowers. The article also outlines how to develop a chat application powered by Next.js and Apollo on the frontend, and Prisma, graphql-yoga and SMS notification using the excellent Vonage SMS API on the backend.

The Data Access Layer in Jmix: JPA on Steroids

JPA is a de-facto standard for creating a data model for Java applications. This API does not provide facilities to implement advanced security features or soft deletes so developers have to implement their own solutions. In this article, Andrey Belyaev discusses the data access layer in Jmix and talks about what can be done with this framework and its tools. He then shows how data access works under the hood.


Beyond REST - Rapid Development with GraphQL Microservices

Since early 2020, Netflix has been iteratively developing systems to provide internal stakeholders and business leaders with up-to-date tools and dashboards with the latest information on the pandemic. One approach that is gaining mind-share within Netflix Studio Engineering is the concept of GraphQL microservices (GQLMS) as a backend platform facilitating rapid application development. In this post, Dane Avilla goes in-depth about how Netflix implemented GraphQL Microservices, including details on database views as an API, PostgresSQL composite types, and more.

How Square accelerates product development with Apollo GraphQL

Square started their journey in 2009 with a credit card reader that plugged into the iPhone and iPhone app using a single Ruby on on Rails service. Since then, they have grown into an international company providing a suite of products and platforms to help businesses and individuals participate in the economy. In this webinar by Apollo, Tech Lead on the Platform, Infrastructure, and Engineering Team, Lenny Burdette, discusses how Square works with Apollo to build a better experience for their customers. Check out the webinar to learn more about how Apollo GraphQL is used at scale.


Building REST from GraphQL - a story of engineering in Haskell

Hasura's GraphQL engine is built with Haskell, a language choice some may consider unintuitive. In this article, Lyndon Maydwell recounts how Hasura recently implemented a new feature which maps REST interfaces to GraphQL queries and how Haskell was advantageous in doing so. Read on to find out more about Hasura's new feature and how their engineering team approached it.

Explore GraphQL with Graphman

Graphman is a new macOS and iOS app that allows developers to prototype requests and explore GraphQL APIs. In this post, Tim Roesner illustrates how to use Graphman in both settings. He details how to use GraphQL unions, nested queries, variables and more. Follow along with Tim to find out more about Graphman and how you can use it today.

How we use GraphQL at Europe's largest fashion e-commerce company

Managing consistent and backwards-compatible APIs for web and mobile app frontends is always a complex task in the long-term. Zalando uses GraphQL to solve some of the most common problems of frontend data requirements while gaining speed of delivery in a large and quickly growing organization. In this article, Aditya Pratap Singh talks about GraphQL as Unified-Backend-For-Frontend (UBFF) application. It's the first in a series of posts about problems Zalando solved with GraphQL.


Building a GraphQL CRUD API for your Database with TypeGraphQL & Prisma

Building CRUD APIs can be a tedious chore. The time spent writing glue code, plumbing layers together and doing repetitive work is often better invested into tasks that actually add value and solve interesting problems. In this article, Alex Ruheni shows how to prototype an e-commerce GraphQL CRUD API using TypeGraphQL, Apollo Server and Prisma for database access. Follow along with Alex to learn more about these great technologies and how they can save you time.

Using Lambda on Slash GraphQL with examples

Slash GraphQL is a fully managed GraphQL backend service that pairs well with AWS Lambda. In this post, Apoorv Vardhan demonstrates how to use the Slash GraphQL service along with Lambda functions for custom logic. The article covers how to create a schema, how to get set up locally, how to create a lambda field resolver, and more. Follow along with Apoorv to find out more about how Slash GraphQL and AWS Lambda work together.

Build an app with GraphQL, Lambda, DynamoDB, Serverless Framework, Vue, React and Tailwind

Fullstack Serverless GraphQL is a guide that walks developers through how to build apps with Lambda, DynamoDB, Serverless Framework, React, Vue and Tailwind. The app allows users to book vacations to the moon. The frontend projects explore some advanced patterns in Vue as well as implementing Apollo Local State in React as a replacement for Redux. Check out the tutorial to learn more about how these technologies can be used together.

GraphQL in Swift

In this article, Majid Jabrayilov demonstrates how to use GraphQL in a Swift app. He begins by introducing GraphQL and the benefits it provides, how the tools provided by Apollo fit in, and how to set everything up in a Swift project. Follow along with Majid to find out how you can use GraphQL in your own Swift projects.


Doing More With GraphQL: Interfaces and Unions

GraphQL offers two abstract types: interfaces and unions. Abstract types make APIs easier to use and create room for growth. This article by Abu Sakib presents several examples of what you can do with interfaces and unions and shows the capabilities they can provide for your own projects.

How to Build a GraphQL API for Text Analytics with Python, Flask and Fauna

In this article, Adesina Abdrulrahman demonstrates how to build a text analytics API with GraphQL. The article shows how to use Levenshetein distance in a GraphQL API with the well-known NLTK library. Follow along with Adesina to learn more about how you can bring text analysis to GraphQL.

Querying Data With GraphQL & Ballerina

Ballerina is an open source programming language and platform that is geared towards writing software for the cloud. In Ballerina, the GraphQL object structure is modelled using services. In this article, Anjana Fernando demonstrates how to build a GraphQL application with Ballerina and what developers must be aware of while doing so. Follow along with Anjana to learn more about Ballerina and how to use it with GraphQL.


Open Sourcing the Netflix Domain Graph Service Framework: GraphQL for Spring Boot

Netflix has developed a Domain Graph Service (DGS) framework and has now made it open source. The DGS framework simplifies the implementation of GraphQL, both for standalone and federated GraphQL services. The framework is battle-hardened by Netflix's use at scale. Read on to find out more about DGS and how you can use it in your own projects.

Oh Hello Apollo Client , Goodbye Redux!

Apollo Client is a popular library for using GraphQL in front end applications. Apollo offers its own variety of state management and can be used as a replacement for Redux. In this article, Ankita Kulkarni goes into detail about when one might consider replacing Redux with Apollo Client and what some of the trade offs are. The article goes into detail about local-only fields, reactive variables, and more. Follow along with Ankita to learn more about how you can replace Redux with Apollo Client.

Building A Customer Journey using Domain Driven Design and GraphQL

An important part of building digital experiences is to take special care in designing the user's journey. In this article, Anand Chandrashekar shows how to design and build a customer journey using Domain Driven Design. The demo application is built with GraphQL and uses a Slash GraphQL backend. Follow along with Anand to learn more about Domain Driven Design.

Creating a Twitter Graph Using Slash GraphQL

In this article, John Vester demonstrates how to analyze Twitter search results graphically using GraphQL. As part of the tutorial, he shows how to expose links and nodes that are not apparent through any other data analysis efforts. The demonstration uses Slash GraphQL as a backend and also touches on Angular to visualize the data. Follow along with John to learn more about how to deal with data visualizations using GraphQL.


Generated GraphQL APIs: Tight Coupling as a Service

Generating APIs is becoming more and more popular, especially in the GraphQL community. One of the challenges that comes with generated GraphQL APIs is that there are tradeoffs one must accept which might not bode well for production. One example is that certain information that should be hidden is actually exposed in the generated API. In this post, Jens Neuse discusses GraphQL API generation, the tradeoffs that exist therein, and how to overcome them. Follow along with Jens to learn more about how to be effective with generated GraphQL APIs.

GraphQL Defer Example - Part 1

In this post, Dilan Srilal discusses the GraphQL @defer directive and how it can be used in a GraphQL API. He provides an example with graphql-helix, nexus, and the experimental stream defer package. Follow along with Dilan to find out more about the defer directive and how it is used.

Implementing a GraphQL Server With Components In PHP

PoP is a library by Leonardo Losoviz that is used for creating GraphQL APIs in PHP. In this article, Leonardo describes the architectural design of a GraphQL server written with PoP. He talks about the impetus for PoP and its design, how components are defined with PoP, and more. Follow along with Leonardo to find out more about working with GraphQL in PHP.