Skip to content
Zever
Home

Quickstart

Install, scaffold a project, and serve a working endpoint in three commands.

1 min readEdit on GitHub

You will install Zever, scaffold a project, and serve a working GET /hello endpoint. It takes about five minutes. You need Go 1.27+ and the zever CLI (installation).

Terminal window
curl -fsSL https://raw.githubusercontent.com/zenta-dev/zever/main/install.sh | sh

Then check it with zever --version.

Terminal window
zever new hello
cd hello

zever new writes the minimal tree: schema/app.zen, cmd/server/main.go, internal/app/wiring.go, the sample internal/service/hello module, .env, .env.example, .gitignore, and a README.md. It also runs go mod tidy, so the project builds as-is.

Expected output (abridged):

✔ scaffolded "hello" into hello
wrote hello/internal/app/wiring.go
wrote hello/cmd/server/main.go
wrote hello/internal/service/hello/service.go

The battery picker adds more services: zever new hello --with cache,queue=redis,auth (or --interactive for the prompt). --with takes a comma-separated list of batteries with optional adapter pins. See Customizing and leaving zever for the “batteries you actually need” table with measured dependency footprints.

Run the watcher. It compiles, starts the server on :8080, and restarts on schema or source changes:

Terminal window
zever dev
{"time":"...","level":"INFO","msg":"http server listening","addr":":8080"}

zever serve runs the same server without watching. In a second terminal, call the sample endpoint:

Terminal window
curl -i localhost:8080/hello
HTTP/1.1 200 OK
Content-Type: application/json
{"hello":"world"}

The sample module registers GET /hello and resolves the logger from the container. GET /healthz always returns 200, and GET /readyz returns 200 once the database ping succeeds.

zever new scaffolds a typed wiring file, not a config file. internal/app/wiring.go declares one Ref per service and one container.Provide entry per instance, and cmd/server/main.go hands those providers plus the modules to serve.Main. Adding a battery later is one command:

Terminal window
zever add cache/redis
zever add db --name analytics