Community Go client for Convex.
This module is community-maintained, pre-v1, and not an official first-party Convex client.
go get github.com/cervantesh/convex-gopackage main
import (
"context"
"log"
"os"
convex "github.com/cervantesh/convex-go"
)
func main() {
ctx := context.Background()
client, err := convex.NewClient(os.Getenv("CONVEX_URL"))
if err != nil {
log.Fatal(err)
}
defer func() { _ = client.Close() }()
if _, err := client.Query(ctx, "messages:list", map[string]any{
"limit": convex.Number(10),
}); err != nil {
log.Fatal(err)
}
if _, err := client.Mutation(ctx, "messages:send", map[string]any{
"body": "Hello from Go",
}); err != nil {
log.Fatal(err)
}
subscription, err := client.Subscribe(ctx, "messages:list", nil)
if err != nil {
log.Fatal(err)
}
defer func() { _ = subscription.Close() }()
if _, err := subscription.Next(ctx); err != nil {
log.Fatal(err)
}
}- docs/USAGE.md for normal use with
convex.NewClient, auth, errors, values, pagination, and explicitNewHTTPClient/NewWebSocketClientflows. - docs/RECIPES.md for cookbook-style operational patterns.
- examples/realtime_chat/README.md for a small chat-style demo application that consumes this SDK from a separate Go module.
- docs/MIGRATION.md for users moving from
convex-js,convex-rs, orconvex-py. - docs/PARITY.md for supported surface and current limits.
- docs/COMPATIBILITY.md for supported Go versions, CI matrix, and live-backend evidence.
- docs/CONFORMANCE.md for offline compatibility fixtures and upstream sources.
- docs/ARCHITECTURE.md for package boundaries and the
advanced
baseclientpath. - docs/MAINTAINERS.md for contributor, quality, and release workflow docs.
- pkg.go.dev for the generated Go API reference.
This module supports Go 1.25 or newer.
- SUPPORT.md covers SDK support scope and issue routing.
- SECURITY.md covers private security reporting.
- CONTRIBUTING.md covers repository workflow details.
- Join the Convex community for broader Convex discussion.