一键导入
commory-backend
Go backend for Commory — JWT auth, file-backed storage, MsgLayer import/query, Setup wizard, and mobile API contract.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Go backend for Commory — JWT auth, file-backed storage, MsgLayer import/query, Setup wizard, and mobile API contract.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Android app for Commory — dual runtime modes, Compose UI, MsgLayer backup/restore, server sync, and agent privacy model.
MsgLayer schema v0.1 — the canonical interchange format between Android, Go backend, web, and future agents.
Standardize VisionFlow load, pressure, capacity, and soak testing across Docker, PgBouncer, BullMQ, Redis, workflow execution, and tietiezhi batch generation. Use when an agent needs to run or document high-concurrency validation, 2C4G simulations, multi-user submit tests, workflow stress tests, throughput investigations, OSS cleanup for test runs, or performance reporting and tuning guidance.
| name | commory-backend |
| description | Go backend for Commory — JWT auth, file-backed storage, MsgLayer import/query, Setup wizard, and mobile API contract. |
Work on the Commory Go backend server.
cmd/commory/main.go — CLI entry (serve / import / validate)
internal/cli/root.go — Cobra commands, boot sequence
internal/api/server.go — HTTP handlers, public/private mux
internal/auth/service.go — PBKDF2-HMAC-SHA256 passwords, JWT HS256, login rate-limit, refresh rotation
internal/auth/middleware.go — Bearer token extraction, context propagation
internal/setup/service.go — First-run setup wizard, CheckSetup migration
internal/storage/storage.go — Provider interface (GetSetupStatus, SaveSetup, HasAdminUser, UpdateUserPasswordHash, etc.)
internal/storage/filestore.go — JSON-file-backed Provider, scopeKey isolation, persist-on-write
internal/storage/sqlite.go — SQLite adapter factory
internal/msglayer/validator.go— Schema validation + additionalProperties check
internal/msglayer/types.go — Go structs for MsgLayer v0.1
internal/importers/ — JSON import pipeline
internal/query/ — Timeline, search, identities, threads
internal/config/config.go — Env-driven config (AUTH_SECRET, TLS, ENV, DB_DSN, etc.)
{code, msg, data}./api/ routes; /api/auth/ and /api/setup are public.pbkdf2$ prefix; legacy sha256$ auto-migrates on login.backend/internal/api/server.go and the relevant service file.docs/mobile-api.md for contract alignment.cd backend && go vet ./... && go test ./... -coverprofile=coverage.outreferences/api-routes.md for the full route table.docs/mobile-api.md for the mobile API contract.