Integrations

go-vercel

Try it

Unofficial Go client for the Vercel REST API, generated with oapi-codegen from Vercel's OpenAPI spec. Package `vercel` from `github.com/psyb0t/go-vercel` gives `NewClientWithResponses` a typed `...WithResponse` method for every endpoint in the spec (projects, deployments, domains, DNS, env vars, teams and more), with typed params structs, `JSON200` response bodies and `As...` methods for oneOf unions. Auth is a bearer token added by a `RequestEditorFn`, with an optional `teamId` query parameter. Use when Go code needs to call the Vercel API, or the project already imports go-vercel.

What it does

Typed Go client for the Vercel REST API. Every operation in Vercel's OpenAPI spec is a method on .

The skill document

go-vercel

Typed Go client for the Vercel REST API. Every operation in Vercel's OpenAPI spec is a method on *vercel.ClientWithResponses.

For install, auth details, union responses and error handling, see references/setup.md.

Security & safety

  • Read the token from an environment variable such as VERCEL_TOKEN. Never hardcode it, commit it or log it, and never print request headers.
  • Requests go only to the base URL passed to NewClientWithResponses. Use https://api.vercel.com.
  • Many endpoints change or delete live resources (deployments, projects, domains, DNS records, env vars, teams). Call those only when the user asked for that change, and only on resources the task is about.

When to use

  • Go code needs to read or manage Vercel projects, deployments, domains, env vars or teams.
  • The project already imports github.com/psyb0t/go-vercel.

When NOT to use

  • A shell script or CI step that the vercel CLI already covers.
  • Code in a language other than Go.

Usage

import (
	"context"
	"net/http"
	"os"

	vercel "github.com/psyb0t/go-vercel"
)

auth := vercel.WithRequestEditorFn(func(_ context.Context, req *http.Request) error {
	req.Header.Set("Authorization", "Bearer "+os.Getenv("VERCEL_TOKEN"))

	// Requests act on your personal account unless they name a team.
	if teamID := os.Getenv("VERCEL_TEAM_ID"); teamID != "" {
		query := req.URL.Query()
		query.Set("teamId", teamID)
		req.URL.RawQuery = query.Encode()
	}

	return nil
})

client, err := vercel.NewClientWithResponses("https://api.vercel.com", auth)
if err != nil {
	return err
}

res, err := client.GetAuthUserWithResponse(ctx)
if err != nil {
	return err // transport error
}

if res.JSON200 == nil {
	return fmt.Errorf("vercel: status %d: %s", res.StatusCode(), res.Body)
}

user, err := res.JSON200.User.AsAuthUser()
if err != nil {
	return err
}

fmt.Println(user.Id, user.Username, user.Email)

Listing projects with typed params:

search := "site"

res, err := client.GetProjectsWithResponse(ctx, &vercel.GetProjectsParams{
	Search: &search,
})
if err != nil {
	return err
}

if res.JSON200 == nil {
	return fmt.Errorf("vercel: status %d: %s", res.StatusCode(), res.Body)
}

page, err := res.JSON200.AsGetProjects200JSONResponseBody1()
if err != nil {
	return err
}

for _, project := range page.Projects {
	fmt.Println(project.Id, project.Name)
}

Method names follow the spec's operationId: getProjects becomes GetProjectsWithResponse. Look the name up in the client_*.gen.go files of the module rather than guessing it.

Related skills

Join a video meeting as an AI bot with voice, avatar, and screenshare across four operating modes.

by johnpatternai22 installs8 stars

Find why your productivity system keeps failing, then apply the smallest fix — capacity math, bottleneck routing, durable local notes.

by Iván857 installs69 stars

Fetch raw ad creative, app, ranking, and revenue data from AdMapix as structured JSON.

by fly0pants4.3k installs296 stars

Stores durable facts in a categorized, plain-markdown vault on disk, alongside your agent's built-in memory.

by Iván561 installs18 stars

Generate and edit Draw.io, Mermaid, and Excalidraw diagrams from natural language using a structured JSON spec.

by nssa.io1.0k installs47 stars

More from psyb0t

Browse all skills

Drive a user-deployed mt5-httpapi MetaTrader 5 bridge over HTTP, with per-action confirmation on every real-money call.

by psyb0t108 installs4 stars

Docker-packaged browser automation for QA against anti-bot stacks and authorized detection testing.

by psyb0t138 installs2 stars

Self-hosted OpenAI-compatible speech service — transcription, translation, and synthesis from one container.

by psyb0t13 installs

Run ffmpeg, sox, and ImageMagick jobs against your files in a fixed-allowlist SSH sandbox.

by psyb0t71 installs

Generate speech audio via Qwen3-TTS over SSH with preset voices, voice cloning, and voice design.

by psyb0t55 installs

Drive one or more IMAP/SMTP mailboxes through a single REST + MCP endpoint — read, search, send, mark-seen, and delete across accounts in parallel.

by psyb0t15 installs