u/Pokelego11

Building an API with Zig and Postgres
▲ 75 r/Zig+2 crossposts

Building an API with Zig and Postgres

Hey everyone!

I'm following up on a post I made a couple weeks ago where I made a tutorial on building a basic CRUD API in Zig with just the standard library.

A lot of people seemed to enjoy the video and I got a lot of feedback on extending the video and turning it into a mini-series where we build a more full-fledged API.

So today I extended it from an in-memory datastore to using Postgres! The next video in the mini-series will be about scaling the API to handle thousands of concurrent requests but if you have any other ideas please let me know!

youtu.be
u/Pokelego11 — 8 days ago
▲ 125 r/Zig+1 crossposts

Building a CRUD REST API in Zig

Hey all!

I wanted to share my latest video here about how to build a simple REST API in Zig using the builtin http package.

There are no external dependencies or packages involved and I write every single line of code in the video!

This is not meant to be an API that scales to thousands of requests but if people enjoy this video I do plan to make two follow up videos; one where we switch from an in-memory store to actually using a database, and one where we scale the API to be able to handle thousands of concurrent requests.

Always happy to hear feedback of what people think/want so just let me know!

Cheers

youtu.be
u/Pokelego11 — 23 days ago
▲ 107 r/Zig

Hi everyone!

I've posted a few videos here and I wanted to share my latest today, I just made a video going over some of the bigger items in Zig's latest 0.16 release.

In the video I go over things like:

  • The new "Juicy main"
  • The new way to integrate c-code in build.zig
  • How to replace @Type with the new builtins
  • Basic examples of the new I/O interface(reading/writing a file)
  • Complex examples of the new I/O interface(async/groups/batching/time/select)

I hope people find it valuable(especially the more complex stuff at the end). And please let me know any feedback you have!

Have a great day :)

u/Pokelego11 — 2 months ago