Protocol buffer schemas shared by KBVE services, games and sites.
SOURCE.md
schemas/proto
Protobuf definitions shared across languages. Canonical source for every wire type in the workspace: a change here fans out to TypeScript, Rust and C# alike.
Migrated from packages/proto in github.com/KBVE/kbve.
Layout
kbve/<domain>/v1/*.proto, which is what the package names say
(package kbve.item.v1) and what every import path assumes. The include root is
this directory, so import "kbve/common/v1/rarity.proto" resolves from here and
nowhere else.
Two shared layers are imported by nearly every domain and are the ones to change carefully:
| Path | What it holds |
|---|---|
kbve/type/v1/ | Identity. Ulid is sixteen bytes on the wire and twenty-six characters wherever a human writes one. |
kbve/common/v1/ | Shared scalars and enums: bounds, colour, decimal, rarity, element, equip slot, registry metadata. |
The rest are domains: the content ones (item, npc, quest, map, spell,
dialogue, profession), the services (jedi, redis, clickhouse,
twitch, git, groq, ci, vm), and the products (meme, forum,
market, portfolio, mc, osrs, rows, jobboard, discordsh, empire,
wallet, bento, chat, icon, asset, staff).
The unversioned pair
meme/meme.proto and kbve/common.proto predate this tree. They are what
apps/memes-web generates its Zod schemas from, and they are superseded by
kbve/meme/v1 and kbve/common/v1 — same domains, versioned packages, one
include root.
They are still here because moving that app onto the versioned packages is its
own change: the generator is a line parser rather than a protobuf compiler, it
skips import statements, and the versioned meme schema reaches across files in
a way the old one does not. buf.yaml ignores both for lint, and the format
task is scoped to kbve/ so buf does not restyle a file whose parser has
opinions about whitespace.
Generated output does not live here
Generated code lands in the language tier that imports it, so a schema’s history
stays reviewable instead of being buried under regenerated artifacts.
apps/memes-web writes its Zod schemas into its own tree; crates/kbve-proto
will do the same with the prost output when it lands.
Tasks
moon run proto:lint runs buf lint, which depends on buf format --diff --exit-code. Both read buf from this project’s package.json — buf is
distributed on npm, and proto has no plugin for it, which is why schemas/* is a
pnpm workspace member despite holding no JavaScript.
buf breaking is not wired yet; see the comment in moon.yml for the line it
lands as once this tree has history on origin/main.
Adding a proto
Copy it verbatim from the KBVE tree and bring its import closure with it. Do not reformat on the way in — a diff against that tree is what tells you whether the two have drifted.
Packages
42 packages · 110 schemas- kbve.asset.v1
8 messages6 enums
- kbve.battle.v1
15 messages1 enum
- kbve.bento.v1
9 messages
- kbve.bones.v1
3 messages3 enums
- kbve.calling.v1
3 messages2 enums
- kbve.chat.v1
1 message2 enums
- kbve.ci.v1
9 messages13 enums
- kbve.clickhouse.v1
16 messages1 enum1 service
- kbve.common
13 messages
- kbve.common.v1
17 messages7 enums
- kbve.dialogue.v1
8 messages2 enums
- kbve.discordsh.v1
30 messages7 enums2 services
- kbve.empire.v1
3 messages1 enum
- kbve.forum.v1
31 messages11 enums
- kbve.git.v1
66 messages3 enums
- kbve.groq.v1
6 messages
- kbve.icon.v1
9 messages4 enums
- kbve.item.v1
32 messages7 enums
- kbve.jedi.v1
5 messages2 enums
- kbve.jobboard.v1
28 messages16 enums1 service
- kbve.map.v1
98 messages52 enums
- kbve.market.v1
21 messages11 enums
- kbve.mc.v1
47 messages12 enums
- kbve.meme.v1
75 messages8 enums4 services
- kbve.npc.v1
32 messages16 enums
- kbve.osrs.v1
43 messages18 enums
- kbve.platform.v1
8 messages1 enum
- kbve.portfolio.v1
10 messages6 enums
- kbve.profession.v1
7 messages2 enums
- kbve.quest.v1
14 messages4 enums
- kbve.rareicon.v1
11 messages
- kbve.redis.v1
22 messages1 service
- kbve.rows.v1
93 messages3 enums5 services
- kbve.rule.v1
2 messages
- kbve.spell.v1
2 messages2 enums
- kbve.staff.v1
10 messages1 enum
- kbve.status.v1
2 messages1 enum
- kbve.twitch.v1
13 messages
- kbve.type.v1
2 messages
- kbve.vm.v1
16 messages6 enums
- kbve.wallet.v1
23 messages5 enums
- meme
75 messages11 enums4 services