Every two weeks I send out a newsletter containing lots of interesting stuff for the modern PHP developer. You can expect quick tips, links to interesting tutorials, opinions and packages. Want to learn the cool stuff? Then sign up now!

Test Driven API Development using Laravel, Dingo and JWT with Documentation

In a new tutorial posted at dotdev.co Diaa Fares shows a good way to develop API’s using Laravel. Along the way he touches on the Dingo packages, JSON Web tokens and documentation generation.

Let’s look at everything we will cover:
Landmark 1: Prepare our TDD environment and creating our first test.
Landmark 2: Installing and configuring Dingo API package.
Landmark 3: What are Transformers, why the need for them and how to use thephpleague/fractal as our transformation layer.
Landmark 4: Introduction about JWT and how to use tymondesigns/jwt-auth for our token based authentication.
Landmark 5: How to use laravel-apidoc-generator to generate nice documentation for our API.
So, pack your bags and let’s dive into our journey!


Freek Van der Herten is a partner and developer at Spatie, an Antwerp based company that specializes in creating web apps with Laravel. After hours he writes about modern PHP and Laravel on this blog. When not coding he’s probably rehearsing with his kraut rock band. He loves waffles and butterflies.
  • Jeroen Noten

    Very cool. JWT stands for JSON Web Token though.