Zig SDK for the Spin serverless application framework created by the Fermyon team.
-
Add
spin
as a dependency in yourbuild.zig.zon
.build.zig.zon
example.{ .name = "<name_of_your_package>", .version = "<version_of_your_package>", .dependencies = .{ .spin = .{ .url = "https://github.com/tensorush/zig-spin/archive/<git_tag_or_commit_hash>.tar.gz", .hash = "<package_hash>", }, }, }
Set
<package_hash>
to12200000000000000000000000000000000000000000000000000000000000000000
, and Zig will provide the correct found value in an error message. -
Add
spin
as a module in yourbuild.zig
.build.zig
exampleconst spin = b.dependency("spin", .{}); exe.addModule("spin", spin.module("spin")); exe.linkLibrary(spin.artifact("spin"));
Legend: π’ - tested, π‘ - untested, π΄ - unimplemented.
Component | Status | Example |
---|---|---|
HTTP (outbound) | π’ | Click |
HTTP (inbound) | π’ | Click |
Redis (outbound) | π΄ | Click |
Redis (inbound) | π΄ | Click |
PostgreSQL | π΄ | Click |
MySQL | π΄ | Click |
SQLite | π‘ | Click |
Config | π’ | Click |
KVS | π΄ | Click |
LLM | π΄ | Click |
-
wit-bindgen-cli v0.2.0
- guest language WIT bindings generator.cargo install --git https://github.com/bytecodealliance/wit-bindgen --rev cb871cf wit-bindgen-cli