Diving into api-platform

This story begins with this popping up on my twitter feed:

Diving into https://api-platform.com/ I immediately realized this is checking all the boxes, basically everything I tried to build last week.

symfony, react/redux, docker, … 💌!

So I went to https://github.com/api-platform/api-platform/releases got the latest release anddocker-compose up -d worked out of the box like a charm, big thumbs up for that!

I immediately noticed the containers are not using dumb-init but I can remedy that with a pull-request.

So pull up https://api-platform.com/docs/distribution/ and let´s do this!

docker-compose exec app bin/console doctrine:schema:create

Ok immediatly set alias sf="docker-compose exec app bin/console"

sf docrine:schema:create I can live with that!

And now we have a swagger UI running on localhost:80 with a Foo Entity and CRUD already working without any code written, pretty amazing job Kévin Dunglas!

It is beautiful!

swagger UI index
First entity created, success!

Having a look at resource usage of the containers:

We can see memory usage is pretty moderate around 240MiB RAM used in total, which is great for running on a dev-machine but of course this is not under load

Being sidetracked reading about JSON-LD, RDF and FOAF.

And also checkout Postman I guess.

Checking out the /foo endpoint in Postman

To be continued!