Skip to main content

File naming

Each schema lives in its own .json file, named after the event:
The filename is just for humans — the eventName field inside the file is what Vela uses to match incoming events. By convention, keep them in sync.

File structure

Top-level fields

Field properties

Field types

Validation examples

Metadata fields

Metadata fields hold optional contextual data that isn’t part of the core event payload — things like deployment environment, trace IDs, or client version. They have the same id, name, type, and description properties as regular fields, but:
  • They are always optional (no required property)
  • They have no defaultValue or validation
When ingesting, pass metadata in the metadata key:

How diffing works

When you run vela diff or vela push, schemas are matched by eventName. For each schema:
  • No remote match → schema will be created
  • Remote exists, no changes → skipped
  • Remote exists, changes detected → schema will be updated
Fields are compared by name, not id. You can change a field’s id without triggering an update — only changes to name, type, required, enumValues, or validation count as changes.
When updating, the entire fields array replaces the remote version. Removing a field from the local file removes it from the schema. Make sure downstream consumers are updated before removing required fields.