Help us improve
Share bugs, ideas, or general feedback.
From gopilot
You are scaffolding a new Go-first project. The Go backend is the source of truth. The frontend consumes it via auto-generated typed SDK.
npx claudepluginhub bishwas-py/gopilot --plugin gopilotHow this skill is triggered — by the user, by Claude, or both
Slash command
/gopilot:initThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are scaffolding a new Go-first project. The Go backend is the source of truth. The frontend consumes it via auto-generated typed SDK.
Scaffolds projects with directory structures, configs, dependencies, linting, testing, CI/CD basics, and docs for frontend, backend, mobile, CLI, libraries, and monorepos.
Provides Go backend patterns for HTTP services (net/http, Chi/Gin/Echo, middleware), concurrency (goroutines, channels, errgroup), database access (sqlx, pgx), and project structure. Detects stack from go.mod.
Provides idiomatic Go patterns for backend APIs with Gin, Echo, Fiber: standard project structure, custom error handling, handler dependency injection, concurrency best practices.
Share bugs, ideas, or general feedback.
You are scaffolding a new Go-first project. The Go backend is the source of truth. The frontend consumes it via auto-generated typed SDK.
skills/_shared/go-patterns.md for Go/Huma conventionssvelte (default) or reactsvelte, read skills/_shared/svelte-patterns.mdreact, read skills/_shared/react-patterns.mdParse $ARGUMENTS as: [project-name] [svelte|react]
svelteCreate the Go backend structure:
backend/
├── cmd/server/
│ └── main.go # Entry point, loads config, starts server
├── internal/
│ ├── api/
│ │ └── router.go # Central router, wires all handlers
│ ├── config/
│ │ └── config.go # Env-based config loader
│ └── database/
│ └── database.go # pgx connection pool
├── Makefile # dev, build, test, lint, db-schema
├── schema.sql # Declarative DB schema (pgschema-style)
├── go.mod
└── .air.toml # Hot reload config
GET /openapi.json*pgxpool.Pool and huma.APIGET /api/v1/healthDATABASE_URL, PORT, ENVdev: # air hot-reload
build: # go build -o bin/server ./cmd/server
test: # go test ./...
lint: # go vet ./...
db-schema: # pgschema apply (or manual psql)
frontend/
├── src/
│ ├── _sdk/ # Will be auto-generated (empty for now)
│ │ └── .gitkeep
│ ├── lib/
│ │ └── server/
│ │ └── go-client.ts # Typed fetch wrapper to Go backend
│ └── routes/
│ └── +page.svelte # Landing page
├── scripts/
│ └── generate-sdk.ts # SDK generation script (placeholder)
├── svelte.config.js # Enable experimental remoteFunctions
├── package.json
├── tsconfig.json
└── vite.config.ts
svelte.config.js must enable:
experimental: { remoteFunctions: true }
frontend/
├── src/
│ ├── _sdk/ # Will be auto-generated (empty for now)
│ │ └── .gitkeep
│ ├── lib/
│ │ └── go-client.ts # Typed fetch wrapper to Go backend
│ └── app/
│ ├── layout.tsx
│ └── page.tsx # Landing page
├── scripts/
│ └── generate-sdk.ts # SDK generation script (placeholder)
├── package.json
├── tsconfig.json
└── next.config.ts
project-root/
├── docker-compose.yml # PostgreSQL 16 on port 5731
├── pnpm-workspace.yaml # Monorepo: [frontend]
├── package.json # Root scripts: dev, generate-sdk, test
└── README.md
{
"scripts": {
"dev": "concurrently \"pnpm run dev:backend\" \"pnpm run dev:frontend\"",
"dev:backend": "cd backend && make dev",
"dev:frontend": "pnpm --filter frontend dev",
"generate-sdk": "pnpm --filter frontend generate-sdk",
"build": "pnpm --filter frontend build",
"test": "cd backend && make test"
}
}
This is the bridge between frontend and Go backend. Create a typed HTTP client:
const BASE_URL = process.env.GO_API_URL ?? 'http://localhost:8080';
type RequestOptions = {
params?: Record<string, string | number | undefined>;
headers?: Record<string, string>;
};
export const goApi = {
async get<T>(path: string, opts?: RequestOptions): Promise<T> { ... },
async post<T>(path: string, body?: unknown, opts?: RequestOptions): Promise<T> { ... },
async put<T>(path: string, body?: unknown, opts?: RequestOptions): Promise<T> { ... },
async patch<T>(path: string, body?: unknown, opts?: RequestOptions): Promise<T> { ... },
async del<T>(path: string, opts?: RequestOptions): Promise<T> { ... },
};
After scaffolding:
cd backend && go mod tidycd frontend && pnpm installdocker compose up -d (start PostgreSQL)pnpm dev — both servers should starthttp://localhost:8080/openapi.json returns spec/gopilot:domain, add endpoints with /gopilot:api, generate SDK with /gopilot:sdk."