SDK · Go
github.com/l1feai/beacons-go — idiomatic Go.
The Go SDK targets idiomatic Go: context, typed errors, no panics, no global state. Binds to the Rust crypto core via cgo (with a pure-Go fallback for cross-compile).
Install
go get github.com/l1feai/beacons-go@latest
What you get
- context.Context throughout, no global timeouts
- Typed errors via errors.Is / errors.As
- cgo crypto + pure-Go fallback
- Compatible with go-fuzz / property testing
Platforms: Linux · macOS · Windows · FreeBSD · ARM · ARM64 · RISC-V
go — enroll a peer
package main
import (
"context"
"fmt"
beacons "github.com/l1feai/beacons-go"
)
func main() {
ctx := context.Background()
client, err := beacons.NewClientFromEnv(ctx)
if err != nil {
panic(err)
}
fleet := beacons.MustFleet("did:oas:acme:fleet:prod")
me := beacons.MustDid("did:oas:acme:agent:scribe-7")
peer, err := client.Fleet(fleet).Enroll(ctx, me)
if err != nil {
panic(err)
}
fmt.Printf("admitted in %s\n", peer.CompositeVerdictDuration())
}Parity
Identical surface in every language.
Every Beacons SDK targets the same set of operations. Cryptographic primitives (Ed25519, HKDF-SHA256, Blake3) come from a shared Rust WASM module so signatures produced in one language verify identically in another. The conformance suite at beacons-conformance exercises cross-language vectors on every release.